I am working on building a N64 to USB adapter using a PIC24FJ64GB002 microcontroller. Right now I've got everything working except the Analog joystick doesn't work as expected. Could someone please tell me how it actually does the encoding? (i.e. does the controller return the difference in position from the last time it was polled or does it actually return the current joystick position?)
Also, is the scale from 127 to -128 on the x and y axis or is it 0 to 255?
Thanks,
-Dan
P.S. I know that you can buy adapters like what I'm trying to build but this seemed like a fun way to learn to create USB HIDs
N64 controller joystick encoding
Moderator:Moderators
- jjhammerstein
- Senior Member
- Posts:1562
- Joined:Tue Nov 18, 2008 7:15 pm
- Location:Southern CT
- Contact:
Re: N64 controller joystick encoding
This would probably be useful:
http://www.instructables.com/id/Use-an- ... ontroller/" onclick="window.open(this.href);return false;
http://www.instructables.com/id/Use-an- ... ontroller/" onclick="window.open(this.href);return false;
GET FREE WOW GOLD SEX VISIT MODRETRO
- evilteddy
- Portablizer
- Posts:423
- Joined:Tue Mar 25, 2008 2:11 am
- 360 GamerTag:Kirren of Smeg
- Steam ID:kizzinator
- Location:Newcastle, Australia
Re: N64 controller joystick encoding
The joystick output is represented as 2s complement which does range from -128 to 127. However the actual range of any N64 joystick is much less. Using a range of -80 to 80 seems to be the best fit to a number of controllers. It's not an artifact of bad joysticks, game's are programmed to expect input within these bounds and you'll get many amusing joystick problems if you have a larger range.
Re: N64 controller joystick encoding
Thanks for the help. I finally got it all working (I had the bit order reversed for the joystick).
-Dan
-Dan