![]() |
Autonomous Programming
This is what we're trying to do:
Use the optical encoder, in place of a joystick, to control the motors, by setting the motors to perform different actions when the encoder gives back a certain reading. How exactly would we go about doing this? |
Re: Autonomous Programming
When I was programming our autonomous I used the Delay and Feed block under the watchdog blocks and just passed the Error reference in between the bits of code I wanted to have execute. I'll try to post a example of this as soon as I can.
|
Re: Autonomous Programming
Use the encoder value as the input to a case statement. Name the cases as ranges like "0..2499" and "2500..6999", and set the motors appropriately in each case.
Either put the whole thing in a while loop, or use Autonomous Iterative which calls your code repeatedly. |
| All times are GMT -5. The time now is 11:01. |
Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi