Go to Post They are "Human Dream and Inspiration Enablement Devices" but since that takes too long to say and explain I use the word "robot". - Foster [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 26-02-2004, 17:12
WizardOfAz's Avatar
WizardOfAz WizardOfAz is offline
Lead Mentor
AKA: Bill Bennett
FRC #1011 (CRUSH)
Team Role: Engineer
 
Join Date: Mar 2003
Rookie Year: 2002
Location: Tucson, AZ
Posts: 101
WizardOfAz will become famous soon enough
Send a message via AIM to WizardOfAz
competition_mode aka rxdata.rc_mode_byte.mode.disabled

The bit called "disabled" in the mode structure in ifi_default.h, with the comment "/* Competition enabled = 1, disabled = 0 */", and also called competition_mode in ifi_aliases.h, may leave some people wondering what the bit really indicates, as it did me. I got the following clarification from IFI:

Quote:
The bit is 1 whenever the RC is disabled before and after the match.
The bit is 0 during Autonomous mode and regular operation of the RC.
This is the same behavior as the "comp_mode" bit last year, which I suspected, but with the seemingly conflicting names and comments, I wanted to get it right.

A use we make of this bit is to know if we're in a "real game" or not. If I ever see this bit set to 1, I set a static variable realgame to 1 forevermore. I then use this realgame bit to disable various test features, since I never want them used during a real game.

Anyway, wanted to post this clarification from IFI in case anybody else needed it. I couldn't find the info elsewhere in CD.

Bill
  #2   Spotlight this post!  
Unread 28-02-2004, 23:35
EricS-Team180's Avatar
EricS-Team180 EricS-Team180 is offline
SPAM, the lunchmeat of superheroes!
AKA: Eric Schreffler
FRC #0180 (SPAM)
Team Role: Engineer
 
Join Date: Apr 2002
Rookie Year: 2001
Location: Stuart, Florida
Posts: 561
EricS-Team180 has a reputation beyond reputeEricS-Team180 has a reputation beyond reputeEricS-Team180 has a reputation beyond reputeEricS-Team180 has a reputation beyond reputeEricS-Team180 has a reputation beyond reputeEricS-Team180 has a reputation beyond reputeEricS-Team180 has a reputation beyond reputeEricS-Team180 has a reputation beyond reputeEricS-Team180 has a reputation beyond reputeEricS-Team180 has a reputation beyond reputeEricS-Team180 has a reputation beyond repute
Re: competition_mode aka rxdata.rc_mode_byte.mode.disabled

...is it just me or does competition_mode = 0 (False) as an indicator that the competition is under way, seem just a bit (ha!) ironic?

...we use it to toggle an "init flag" that we check for pre-game auto-calibrations.

Eric Schreffler
__________________

Don't PANIC!
S. P. A. M.
  #3   Spotlight this post!  
Unread 29-02-2004, 01:22
The Lucas's Avatar
The Lucas The Lucas is offline
CaMOElot, it is a silly place
AKA: My First Name is really "The" (or Brian)
FRC #0365 (The Miracle Workerz); FRC#1495 (AGR); FRC#4342 (Demon)
Team Role: Mentor
 
Join Date: Mar 2002
Rookie Year: 2001
Location: Dela-Where?
Posts: 1,564
The Lucas has a reputation beyond reputeThe Lucas has a reputation beyond reputeThe Lucas has a reputation beyond reputeThe Lucas has a reputation beyond reputeThe Lucas has a reputation beyond reputeThe Lucas has a reputation beyond reputeThe Lucas has a reputation beyond reputeThe Lucas has a reputation beyond reputeThe Lucas has a reputation beyond reputeThe Lucas has a reputation beyond reputeThe Lucas has a reputation beyond repute
Send a message via AIM to The Lucas
Re: competition_mode aka rxdata.rc_mode_byte.mode.disabled

The comp_mode bit is rather useful. While it is equal to 1 (disabled) I use the 8 OI Feedback LEDs to calibrate the 2 joysticks (4 axis). Red means the axis is less than or equal to 127 and Green means the axis is greater than or equal to 127. The Operators have to play around with the calibration wheels until they get all 8 LEDs on before they are cleared for take-off. It's quite fun to watch them and be overly critical by saying things like "You just missed center like 10 times in a row!" and "Are you sure you know how to use a joystick?" They will point out things like "I got them both on, but that one blinks so much I think I am going to have a seizure"

I am glad the Master uP handles all of the actual disabling of outputs in this Robot Controller. Teams used to mess with the disable bit check in thier code in previous years, and thier beacon would stay on while disabled. This freaked me out because you could never figured out when they were actually disabled. Although with this RC you may still be able to control PWMs 13-16 (User uP controlled PWMs) which is a scary idea that I am sure no one on my team will let me test out. That is if I tell them about it first, I could just tell them it is a new Autonomous strategy
__________________
Electrical & Programming Mentor ---Team #365 "The Miracle Workerz"
Programming Mentor ---Team #4342 "Demon Robotics"
Founding Mentor --- Team #1495 Avon Grove High School
2007 CMP Chairman's Award - Thanks to all MOE members (and others) past and present who made it a reality.
Robot Inspector
"I don't think I'm ever more ''aware'' than I am right after I burn my thumb with a soldering iron"
  #4   Spotlight this post!  
Unread 29-02-2004, 08:24
KenWittlief KenWittlief is offline
.
no team
Team Role: Engineer
 
Join Date: Mar 2003
Location: Rochester, NY
Posts: 4,213
KenWittlief has a reputation beyond reputeKenWittlief has a reputation beyond reputeKenWittlief has a reputation beyond reputeKenWittlief has a reputation beyond reputeKenWittlief has a reputation beyond reputeKenWittlief has a reputation beyond reputeKenWittlief has a reputation beyond reputeKenWittlief has a reputation beyond reputeKenWittlief has a reputation beyond reputeKenWittlief has a reputation beyond reputeKenWittlief has a reputation beyond repute
Re: competition_mode aka rxdata.rc_mode_byte.mode.disabled

no matter what you do in your code, when the controller is disabled all 16 pwms, and all the relay outs will be off. There is another layer of SW above the code that we see - we only tell it what we want the output to do, that other code actually controls the outputs

Messing with the 'comp_mode' bit wont change that, it never has - they are disabled outside the code that we have access to.

If someone had their rotating light on last year when the robot was disabled, they must of had it plugged directly into the fuse box, or had a mistake in their wiring.
Closed Thread


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
The AKA Profile Field. Brandon Martus CD Forum Support 17 01-08-2003 18:54
Use of the AKA Profile Field Brandon Martus Announcements 0 30-07-2003 22:54
Looking for ways to incorporate Mt. Dew (aka - F.I.R.S.T. Fuel) into food recipes! Elgin Clock Chit-Chat 27 28-01-2003 11:09
Wonder Wheels (aka Side Slip Wheels) Scott358 Technical Discussion 4 08-01-2002 12:36
10 Spots left to Nationals aka The Championships? Hymnson General Forum 1 01-10-2001 18:48


All times are GMT -5. The time now is 01:11.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi