JoyWarrior 20 A8-8 Resolution

This is the English forum for all topics related to JoyWarrior. Please post in English only

Moderator: Guido Körber

Post Reply
Chris Dancer
Posts: 3
Joined: Mon Nov 01, 2004 1:18 pm
Location: UK

JoyWarrior 20 A8-8 Resolution

Post by Chris Dancer »

I'm using the J/W 20 A8-8 with a potentiometer wired as recommended. I am getting its position by reading the Windows JoyInfoEx structure. However, I am only getting 7-bit resolution (128 steps).
I have calibrated it using the windows joystick calibration tool. This is in Windows Me.
Can anyone suggest why I am not seeing the full 8-bit resolution of the ADC chip?
Guido Körber
Site Admin
Posts: 2856
Joined: Tue Nov 25, 2003 10:25 pm
Location: Germany/Berlin
Contact:

Re: JoyWarrior 20 A8-8 Resolution

Post by Guido Körber »

What does this mean: You are getting only 128 steps? The values should range from 0 to 255 unless you are using a pot that is way off the 100K.
Chris Dancer
Posts: 3
Joined: Mon Nov 01, 2004 1:18 pm
Location: UK

Post by Chris Dancer »

Hi Guido,

Actually the pot is a 22K, but since it is used as a potential divider in the 20A8-8, that doesn't matter - the ADC is reading a voltage.

The situation is more complex than I thought. This is what I'm seeing in Win Me:

XPos range is either 0 - 65024, in steps of 512, ie.
0 / 512 / 1024 / etc.

OR: 256 - 65280 in steps of 512, ie.
256 / 768 / 1280 / etc.

So there are 2 possible scales, each with 128 values. The device changes from one scale to the other randomly as you move the slider of the pot, eg. with the slider on the bottom, it reads 0; move it up and back down again, now it reads 256.

I tried it on my XP laptop, and it's even stranger. There are 2 scales again, but now they go:
0 / 485 / 970 / 1456 / .... / 65535
and:
242 / 728 / 1213 / 1699 / ... / 65535

I should point out that I went through the Windows joystick calibration routine on both computers. Perhaps this is the cause of the problem?

Chris
Guido Körber
Site Admin
Posts: 2856
Joined: Tue Nov 25, 2003 10:25 pm
Location: Germany/Berlin
Contact:

Post by Guido Körber »

Sorry, my fault, I misread the part number and assumed JW24A8-8, which would require a 100K pot.

The effect you are seeing is caused by an internal jitter filter that suppresses changes of only +/-1.
Chris Dancer
Posts: 3
Joined: Mon Nov 01, 2004 1:18 pm
Location: UK

Post by Chris Dancer »

That explains why the readings are so unnaturally stable :-)

Great for game controllers, not so good for analog input though...
Guido Körber
Site Admin
Posts: 2856
Joined: Tue Nov 25, 2003 10:25 pm
Location: Germany/Berlin
Contact:

Post by Guido Körber »

Actually we have been considering to drop the jitter filter in the next version.
Post Reply