|
Re: Auto Code NOT Running (as expected)
Autonomous Independent is only called once, when autonomous mode begins, and runs until it's done (or until it's aborted by the framework when teleop mode begins). It's not like Teleop, which gets called every time new data arrives from the Driver Station and needs to finish quickly. If you want to do different things at different times, you'll have to put the code that reads the time and decides what to do inside a while loop.
But since you're just doing a sequence of events with delays between them, you can use a Flat Sequence structure very effectively. See the attached code snippet. (You can put it inside a case structure to control whether or not it runs, based on the joystick throttle the way you did it in your code.)
|