View Single Post
  #1   Spotlight this post!  
Unread 05-02-2013, 10:58
Anatole's Avatar
Anatole Anatole is offline
Registered User
FRC #4531 (STEMpunk 4531)
Team Role: Programmer
 
Join Date: Feb 2013
Rookie Year: 2013
Location: RobotLand
Posts: 7
Anatole is an unknown quantity at this point
Question Programmatically Toggling a Boolean Control

Hey,
I have a Boolean control set so that when a joystick button is pressed and released, it switches a case statement.
Since the joystick button is momentary I have it set up so:
True + False = True, then the next True+False sets it back to False. In essence, pressing & releasing the joystick button toggles the case structure.
Now, my question is, I have a sequence inside each case structure. I want to be able to toggle the case structure programmatically when the sequence is finished. (Basically, the program can run back and forth between true and false, but the user can hit the joystick button to manually override the back and forth.)
Any ideas on how I can do this?
Thanks!
Reply With Quote