View Single Post
  #4   Spotlight this post!  
Unread 18-02-2003, 00:17
DanL DanL is offline
Crusty Mentor
FRC #0097
Team Role: Mentor
 
Join Date: Jan 2002
Rookie Year: 2001
Location: Somerville, MA
Posts: 682
DanL is just really niceDanL is just really niceDanL is just really niceDanL is just really niceDanL is just really nice
Send a message via AIM to DanL
IF auton mode = 1 THEN

First of all, I'm not sure if your line "IF auton mode = 1 THEN" is a typo cause you were typing fast, or if it's copied from your code. The variable is "auton_mode," so double check that (although I'd assume you'd get a tokenize error if you forgot the _ in your code).

Another problem may be the actual status of this bit. Have you followed the instructions on enabling auto mode (here or here)? There are basically two ways to do it: set the team number to zero, or make a dongle (the dongle I made this year is shown below).

If you're checking the auton_mode bit, you have to have turned it on in the first place. Not sure if you did this or not - you never specified.

--

Another suggestions: just a small note: it would have been a lot more simpler and elegant if you just hooked the left and right side to one toggle switch...

IF sw = 1 THEN <left code>
ELSE <right code>

But with the goto imdone, it'll still work.
__________________
Dan L
Team 97 Mentor
Software Engineer, Vecna Technologies