FRC1076 / RobotKitLib

Robotpy-WPILIB equivalent for raspberry pi robot kit
1 stars 1 forks source link

PRACTICE: Add a simple auton routine to the robot #83

Open VeeBallbach opened 3 years ago

VeeBallbach commented 3 years ago

Write code in robot.py that drives the robot forwards at 70% speed for 3 seconds in autonomous mode. You can use either arcadeDrive or tankDrive to move it, and you can use code from the timer.py file (in pikitlib) to check how long it's been moving.

VeeBallbach commented 3 years ago

Tip: you'll need a bit of code in both autonomousInit() and autonomousPeriodic()! Remember - code in Init happens once when the robot is first started, while code in Periodic is looped over and over.

VeeBallbach commented 3 years ago

Also, the code doesn't create a timer for you yet - you'll have to add one yourself in robotInit()