View Single Post
  #4   Spotlight this post!  
Unread 15-01-2006, 22:55
amateurrobotguy's Avatar
amateurrobotguy amateurrobotguy is offline
Lead Programmer/Senior Engineer
no team
 
Join Date: Feb 2005
Rookie Year: 2000
Location: ****
Posts: 136
amateurrobotguy is infamous around these partsamateurrobotguy is infamous around these partsamateurrobotguy is infamous around these partsamateurrobotguy is infamous around these partsamateurrobotguy is infamous around these partsamateurrobotguy is infamous around these parts
Re: Need a little help with how to break out of the box

Thanks for not sabatoging me *wink* Well, one more question, since I just found out that it take slighly longer to go out to other.c files for 1 single function than to just put in a separate subroutine, I just want to know how to create my own subroutine here is what I did, tell me if I am right please:

void Automation(void)
{
*Code here*
}

Now, do I need to specifically do something like this or does it only run it once unless it has a loop in itself ~[or if it is in a loop, will it get run more than once?]:

void Automation(void)
{
int automationhasrun=0
if automationhasrun=0
{
*Code here*
automationhasrun=1
}
else {}
}
__________________
I quit FRC over 2 years ago (more if you're reading this past 2010).