View Single Post
  #23   Spotlight this post!  
Unread 20-02-2010, 08:37
Luke Pike's Avatar
Luke Pike Luke Pike is offline
Programmer
FRC #1501 (THRUST)
Team Role: Mentor
 
Join Date: Jan 2008
Rookie Year: 2008
Location: Huntington
Posts: 114
Luke Pike is a name known to allLuke Pike is a name known to allLuke Pike is a name known to allLuke Pike is a name known to allLuke Pike is a name known to allLuke Pike is a name known to all
Re: sample code to move robot autonomously

Glad it helped you.

The easiest way to use this code in teleop also is to make it a subvi. To do this, select all the code for the state machine (while loop included). Then, go to the "Edit" menu and select "Make SubVI". LabVIEW with put the code in a new vi and automatically creat the inputs for you. Save this vi, then you can drop it in teleop to use it.

Note: for this to work, the state machine must stop the loop when it's done. If you want to run the state machine in autonomous more then once, you can make another state machine which calls the sub state machine.
__________________
Twitter Profile
Reply With Quote