Thread: pbasic question
View Single Post
  #6   Spotlight this post!  
Unread 23-06-2002, 23:50
archiver archiver is offline
Forum Archival System
#0047 (ChiefDelphi)
 
Join Date: May 2001
Location: Pontiac, MI
Posts: 21,214
archiver has a reputation beyond reputearchiver has a reputation beyond reputearchiver has a reputation beyond reputearchiver has a reputation beyond reputearchiver has a reputation beyond reputearchiver has a reputation beyond reputearchiver has a reputation beyond reputearchiver has a reputation beyond reputearchiver has a reputation beyond reputearchiver has a reputation beyond reputearchiver has a reputation beyond repute
Re: dead zone

Posted by Joe Ross at 1/31/2001 2:59 AM EST


Engineer on team #330, Beach Bot, from Hope Chapel Academy and NASA/JPL , J&F Machine, and Raytheon.


In Reply to: Re: dead zone
Posted by Josh Vetter on 1/30/2001 10:40 PM EST:



: How do you create the dead zone? We are a rookie team, and need all the programming help we can get.

There are many different ways to program a dead zone. The simplest (but not always the best) is to use an if statement.

in pseudo-code:

if joystick is greater than 117 AND joystick is less than 137 then joystick = 127

127 is the neutral position, so if the joystick value is ever +/- 10 from the neutral position, then the robot won't move. out team has found that a value of +/- between 5 and 10 works the best.

There are a few problems with this method. If you can find them, then you probably don't need help developing a dead stick routine ;-)

You should also read the whitepaper on filtering the joysticks availible from innovationfirst.com. It contains a "dead stick" routine among other things



__________________
This message was archived from an earlier forum system. Some information may have been left out. Start new discussion in the current forums, and refer back to these threads when necessary.