To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.robotics.handyboardOpen lugnet.robotics.handyboard in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Robotics / Handy Board / 7066
7065  |  7067
Subject: 
Re: IC trouble - function definition - understand now, Thanks
Newsgroups: 
lugnet.robotics.handyboard
Date: 
Sat, 13 Nov 1999 19:39:12 GMT
Original-From: 
Terry Gathright <terrygathright@/SayNoToSpam/home.com>
Viewed: 
1052 times
  
Sorry,
Forgot to enclose the code. what is wrong here?



long time;


void
phony()
{
while (digital(2) == 1) {
time = mseconds();
printf("%d\n", mseconds());
}
if (mseconds () >1413 ) fd(1);
else bk(1);

}


void
start()
{
phony();
}


void main()
{
while(1)
start();
}
-----Original Message-----
From: John Bachman <bachman@anatek.mv.com>
To: handyboard@media.mit.edu <handyboard@media.mit.edu>
Date: Saturday, November 13, 1999 12:48 PM
Subject: Re: IC trouble - function definition - understand now, Thanks


Rich got it.  Nested functions was the problem.  I don't recall seeing that discussed in the IC manual and I think it is OK in C.

Nonetheless, thanks to all for helping this hapless programmer.

John

You have the definition of phony() nested inside the definition
of start().  I don't know what ANSI C and/or C++ let you do, but this is
invalid IC.
*Rich*
--
Richard F. Drushel, Ph.D.            | "Aplysia californica" is your taxonomic
Department of Biology, Slug Division | nomenclature.  /  A slug, by any other
Case Western Reserve University      | name, is still a slug by nature.
Cleveland, Ohio  44106-7080  U.S.A.  |     -- apologies to Data, "Ode to Spot"




1 Message in This Thread:

Entire Thread on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact
    

Custom Search

©2005 LUGNET. All rights reserved. - hosted by steinbruch.info GbR