|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
| Thread Tools | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
test autonomous mode
How does one test their autonomous code. How do you set your robot into autonomous mode. Then how do you turn off autonomous remotely?
|
|
#2
|
|||
|
|||
|
Re: test autonomous mode
This is what we did last year:
We created a "key" (as in a wire on a keychain). Whenever we wanted to put our robot in autonomous mode, we would close a circuit between the autonomous mode pin and +5v with the ends of the "key." We pulled out the key when we were done. |
|
#3
|
|||||
|
|||||
|
Re: test autonomous mode
Quote:
|
|
#4
|
|||||
|
|||||
|
Re: test autonomous mode
we actually wired that circuit to a switch on our oi last year for testing purposes...
|
|
#5
|
|||||
|
|||||
|
Re: test autonomous mode
Our team created a dongle (basically the same thing) by taking a DB-25 casing and attaching an SPST on the top of it (wiring the same as mentioned above). This allowed us quick usage of the autonomous mode and also made it easy to lend the dongle to others in the pits. I highly suggest this method as it is very easy to build and to use!
|
|
#6
|
|||
|
|||
|
Re: test autonomous mode
I was under the impression that input from the OI is ignored when in autonomous mode. So how did you get it out of auto mode?
|
|
#7
|
|||||
|
|||||
|
Re: test autonomous mode
Quote:
The dongle was used only to test the autonomous programs so we really didn't have much need to switch out of the mode. Still, if problems did arise, we could simply switch the dongle off and user mode would pop right back up. This became useful at times when program bugs would send the robot scrambling in a random direction on a murderous rampage (which happened more than once)! One great thing about the OI is that it will read control input during disabled mode. This allows you to give the robot information (such as which program to run) up to the last second before the buzzer. Our team used this to our advantage, allowing us to have 7 autonomous programs (3 switches, binary) that we could choose as we set up the controls and switch quickly if problems came up (we used the last binary position - 0 - as a manual override in the program just in case something went wrong with both the program AND the dongle (quelle catastrophe!). |
|
#8
|
|||||
|
|||||
|
Re: test autonomous mode
for testing purposes, we wired the switch into the competition port, utilizing the autonomous pin and a ground. if it was a close, the robot saw auton_mode = 1 and it would act based on that. When we flipped the switch off, auton_mode = 0 and it would act as if the 15 seconds was over...That's how were wired our controls for testing. We unplugged our stuff from the competition port when we would go to a match.
|
|
#9
|
|||
|
|||
|
Re: test autonomous mode
Oops, i was asking ShadowKnight.
|
|
#10
|
|||||
|
|||||
|
Re: test autonomous mode
does that answer your question?
|
|
#11
|
|||
|
|||
|
Re: test autonomous mode
theres a schematic to make a dongle that connects to the oi and controls the auto mode, disabling the robot, and the channel it runs on here http://www.innovationfirst.com/FIRST...nout_Guide.PDFPinout Guide
|
|
#12
|
||||
|
||||
|
Re: test autonomous mode
best thing to do is to wire up the auton and disable switches as the post above suggested
then you will be using auton mode exactly the same as it will be used at the regionals if you kludge some special user interface switch and let your own code decide when its suppose to run auton mode you may end up like many teams last year, who thought they had auton mode working great, but it would not work with the FIRST equipment on the field. The 'competition port' switch setup is the only way to go. |
|
#13
|
|||
|
|||
|
Re: test autonomous mode
can it not be as simple as setting the value of autonomous_mode = 1?
(if not mind letting me know why please!) |
|
#14
|
||||
|
||||
|
Re: test autonomous mode
yes, you could just hardcode the if/while statement... but I believe autonomous_mode is reset each getdata(), so you'd probably just want to replace autonomous_mode with 1, instead of assigning it
|
|
#15
|
||||
|
||||
|
Re: test autonomous mode
If you don't have time to do the soldering (or if you're too lazy), setting your team number to 0000 turns autonomous mode on too, if you briefly connect the tether cable between the OI and RC after setting it. You can't turn it off remotely though, since this makes the RC act completely independantly of the OI.
|
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| how can you use a gyro in autonomous mode | magical hands | Programming | 3 | 02-01-2004 13:31 |
| Programming Autonomous mode | Jared Stofflett | Programming | 3 | 11-11-2003 09:32 |
| autonomous mode problem on field | Chris_C | Programming | 17 | 26-03-2003 19:11 |
| autonomous mode timer | Don | Programming | 6 | 09-02-2003 22:16 |
| autonomous mode? | bigwalt | Technical Discussion | 1 | 21-01-2003 01:14 |