View Single Post
  #3   Spotlight this post!  
Unread 26-01-2006, 18:09
gnormhurst's Avatar
gnormhurst gnormhurst is offline
Norm Hurst
AKA: gnorm
#0381 (The Tornadoes)
Team Role: Programmer
 
Join Date: Jan 2004
Location: Trenton, NJ
Posts: 138
gnormhurst will become famous soon enoughgnormhurst will become famous soon enough
Re: Need help with our deadspace.

Quote:
Originally Posted by billbo911
I believe what you are seeing is the Dead band built into the Victors themselves. This window, approx. 117 to 137, is to allow for the fact that most Joysticks don't always return to 127 at dead center, there is some variability. So, IFI designed this window to accommodate this variability. My suggestion: Calibrate the Victor to the input being used.

Other users here may suggest alternatives to this. Programming that will apply the standard slope equation, Y=MX+B, is one of them. I find that calibrating the Victor is a little easier, but by no means is it "The Best" way to do it.
I spent many hours developing a drive system that was less sensitive at slow speeds. Here is a thread that includes the code.

I also got around the fact that the Victor controllers see a value within about +/-7 units of 127 and just call it zero. If the value you want to send is less than 127, subtract an additional 7. If it is more than 127, add an additional 7:

if ( val > 127 )
val += 7;
if ( val < 127 )
val -= 7;

The Victors have a calibration procedure designed to match them to your joystick, but I like to calibrate them to specific values, so I wrote some code that would produce 127s, then 0s when I pushed one button, then 255s when I pushed another (like I was swinging the joystick through its range). I used that while I calibrated the Victors. The Victor calibration procedure is explained in the Victor data sheet.
__________________
Trenton Tornadoes 381
2004 Philadelphia Regional Winners
2006 Xerox Creativity Award
---
My corner of the USPTO.
My favorite error message from gcc: main is usually a function
My favorite error message from Windows: There is not enough disk space available to delete this file.