Go to Post Too complicated for Wildstang? Start browsing CD-media...... - AdamHeard [more]
Home
Go Back   Chief Delphi > Technical > Control System
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Reply
 
Thread Tools Rating: Thread Rating: 6 votes, 5.00 average. Display Modes
  #1   Spotlight this post!  
Unread 17-02-2008, 16:46
Abrakadabra Abrakadabra is offline
Here We Go !!!
AKA: Scott Kukshtel, Mr. K
FRC #3467 (The Windham Windup!)
Team Role: Mentor
 
Join Date: Jan 2007
Rookie Year: 2002
Location: Windham, New Hampshire
Posts: 159
Abrakadabra has a brilliant futureAbrakadabra has a brilliant futureAbrakadabra has a brilliant futureAbrakadabra has a brilliant futureAbrakadabra has a brilliant futureAbrakadabra has a brilliant futureAbrakadabra has a brilliant futureAbrakadabra has a brilliant futureAbrakadabra has a brilliant futureAbrakadabra has a brilliant futureAbrakadabra has a brilliant future
Logitech NASCAR Wheel / Chicklet Safety Issue?

We're using the Chicklet with the Logitech NASCAR Steering Wheel. It's all working great, but we've got a small issue that concerns me.

Because the foot pedals return a value of 255 when up and 0 when fully depressed, our code has to account for this in a different way than we would for a normal joystick. In essence, this means that an input of 127 to our code looks like a halfway depressed foot pedal.

That's all well and good until the Chicklet is unplugged or loses power while the robot is still powered on. If that happens, then the OI outputs a value of 127, the robot thinks we've told it to move, and off it goes!

We have a disable switch plugged into our OI Competition port at all times, but we've had some cases where the switch wasn't down when the chicklet was unplugged. And I'm actually more worried about the potential for robot misbehavior at competition. Any comments? Any ideas for how our code could detect a missing Chicklet?
Reply With Quote
  #2   Spotlight this post!  
Unread 18-02-2008, 14:34
WaterFreak WaterFreak is offline
Registered User
FRC #0708 (Hardwired Fusion)
Team Role: Mentor
 
Join Date: Feb 2007
Rookie Year: 2002
Location: Warrington, PA
Posts: 29
WaterFreak is a splendid one to beholdWaterFreak is a splendid one to beholdWaterFreak is a splendid one to beholdWaterFreak is a splendid one to beholdWaterFreak is a splendid one to beholdWaterFreak is a splendid one to beholdWaterFreak is a splendid one to behold
Re: Logitech NASCAR Wheel / Chicklet Safety Issue?

one thing I could think to try would be to use a variable to "save" the value and a counter.

If the value = 127 three times in a row, disable movement until some "non-127" value.

Pseudo code might look a little like this......

if (fwd == 127) or (rev == 127)
{
count++;
}else
{
count = 0;
disable = false;
}

if (count == 3)
{
disable = true;
}

Hope this helps you.
__________________
Thanks, Jim Orr
Senior Software Engineer - Motorola, Connected Home
Supporting Team 708 - Hardwired Fusion
Reply With Quote
  #3   Spotlight this post!  
Unread 18-02-2008, 14:47
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: Logitech NASCAR Wheel / Chicklet Safety Issue?

For multiple reasons I suggest subtracting the value of one pedal from the other to get your speed value. Example:
Code:
speed = ((int)left_pedal - (int)right_pedal)/2 + 127;
Now speed is like a joystick y-axis. As long as both the pedals are the same value (255, 127 etc) your robot should not move.
__________________
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"
Reply With Quote
  #4   Spotlight this post!  
Unread 19-02-2008, 00:51
Abrakadabra Abrakadabra is offline
Here We Go !!!
AKA: Scott Kukshtel, Mr. K
FRC #3467 (The Windham Windup!)
Team Role: Mentor
 
Join Date: Jan 2007
Rookie Year: 2002
Location: Windham, New Hampshire
Posts: 159
Abrakadabra has a brilliant futureAbrakadabra has a brilliant futureAbrakadabra has a brilliant futureAbrakadabra has a brilliant futureAbrakadabra has a brilliant futureAbrakadabra has a brilliant futureAbrakadabra has a brilliant futureAbrakadabra has a brilliant futureAbrakadabra has a brilliant futureAbrakadabra has a brilliant futureAbrakadabra has a brilliant future
Re: Logitech NASCAR Wheel / Chicklet Safety Issue?

Thanks for the responses. Brian, I think you nailed the solution. We'll be trying out something like that first thing next Thursday (Granite State Regional).

Hope to see you all in Atlanta!
Reply With Quote
Reply


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
NASCAR Racing Wheel Maria*61806* Control System 0 31-01-2008 09:58
Logitech NASCAR Racing Wheel Compatible with USB Chicklet kE7JLM Technical Discussion 0 17-01-2008 10:01
Comments on the Logitech steering wheel with pedals waialua359 Control System 7 14-12-2007 16:08


All times are GMT -5. The time now is 20:42.

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