Clarification Needed for Sandstorm Period

This year, will each robot start in autonomous mode? If so, how would one implement teleop code into the “Autonomous Independent” vi?
Reference:
"* Sandstorm Coding

  • Mode - Despite the Sandstorm not truly being an “Autonomous” mode, all code (DS, robot code, etc.) will continue to refer to this period as “Autonomous” or “Auto” for continuity.
  • Mode Transitions - The field will transition through modes in the same way as prior seasons. Prior to the start of the match, robot’s will be in Disabled Mode. Once the match starts, they will transition to Autonomous Enabled mode. At the end of the Sandstorm, robots will briefly transition through Disabled (~.5s), if team’s are driving their robot with joysticks/gamepads at this time, there will be a noticeable hitch. Finally the robot will transition to Teleop Enabled mode for the remainder of the match until the buzzer sounds. When the match expires, the robot will return to Disabled mode.
  • Joystick Access - For this season only, joystick data will not be cached on the transition to Autonomous. Teams will be able to access updated joystick data throughout the Autonomous/Sandstorm period.
  • Game Data - There is no game data for the 2019 season."

Add something like this to Autonomous Independent.vi
It just calls your Teleop.vi where your regular driving code is.

  • Just create an unending loop (it gets killed when Sandstorm ends)
  • Give it a Wait of 20ms (the standard joystick update rate)
  • Drag Teleop.vi from the Project Manager into the loop.
  • Create-> Constant on the top input node and set it to Execute

Thank you for the help! The code works as intended.

Will periodic still run in the auto period?. As you suggested we placed our automated functions in periodic, and it works nicely. We want to make sure those same functions work during auto.

Periodic runs at all times, through all modes (after Begin.vi has finished executing).
So anything in there will run during both the Sandstorm (autonomous) and Teleop phases.

Thanks for info, especially how to run the teleop portion withou duplicating code in both vi’s

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.