View Single Post
  #10   Spotlight this post!  
Unread 11-06-2010, 13:01
isaacdl isaacdl is offline
I have a white hat..it's just dirty
AKA: Isaac Dontje Lindell
FRC #3018 (Nordic Storm)
 
Join Date: Oct 2009
Rookie Year: 2010
Location: St. Peter
Posts: 32
isaacdl is an unknown quantity at this point
Re: no control of bot when kicker is operating

Quote:
Originally Posted by Ether View Post
It sounds like your "driving" code has to wait for your "kicking" code to complete.

If this is the case, there are two (at least) different ways to solve this:

1) put your kicking code and driving code into separate tasks so that the OS can multitask them for you,

or

2) use a state machine for your kicker code, so that it doesn't bring everything to a halt while it's waiting for the delay

We're trying option one right now, but having never had to program multiple threads, could you explain how to do it? We're trying various things we're finding on the internet, but none of it is exactly what we need.
If it matters, we're using SimpleRobotTemplate (so like Independent from LabView ) as opposed to IterativeRobot.