View Single Post
  #8   Spotlight this post!  
Unread 22-01-2003, 23:38
Travis Hoffman's Avatar Unsung FIRST Hero
Travis Hoffman Travis Hoffman is offline
O-H
FRC #0048 (Delphi E.L.I.T.E.)
Team Role: Engineer
 
Join Date: Sep 2001
Rookie Year: 2001
Location: Warren, Ohio USA
Posts: 4,047
Travis Hoffman has a reputation beyond reputeTravis Hoffman has a reputation beyond reputeTravis Hoffman has a reputation beyond reputeTravis Hoffman has a reputation beyond reputeTravis Hoffman has a reputation beyond reputeTravis Hoffman has a reputation beyond reputeTravis Hoffman has a reputation beyond reputeTravis Hoffman has a reputation beyond reputeTravis Hoffman has a reputation beyond reputeTravis Hoffman has a reputation beyond reputeTravis Hoffman has a reputation beyond repute
My weird experience with comp_mode

Here's a line of code that has been in Xtremachen's control program for as long as I've been a programmer on the team:

rotatinglight = 1 - comp_mode

Our light has always worked properly - it's been on when the robot was enabled and off when it was disabled. This is the case during matches and also when using the homemade Competition Port dongle. For us, comp_mode has always been equal to ZERO when the robot has been enabled.

http://www.innovationfirst.com/FIRST...nout_Guide.PDF

Here's why I think comp_mode = 0 during a match. I might be completely wrong - it wouldn't be the first time.

According to the official Competition Port pinout, you must connect Ground Pin 8 to Disable Pin 6 in order to DISABLE the robot. This is the same thing you do to turn a digital input on - completing the circuit between ground and the input pin yields a logical 1 inside the program. If the Competition Port inputs follow the same pattern, then the comp_mode input turns ON when you close the circuit (robot disabled) and OFF when you open the circuit (robot enabled). If this is all true, then comp_mode = 0 during a match.
__________________

Travis Hoffman, Enginerd, FRC Team 48 Delphi E.L.I.T.E.
Encouraging Learning in Technology and Engineering - www.delphielite.com
NEOFRA - Northeast Ohio FIRST Robotics Alliance - www.neofra.com
NEOFRA / Delphi E.L.I.T.E. FLL Regional Partner