Welcome, Guest. Please login or register.

Author Topic: PC-Amiga joystick – Re-linearalisation in software  (Read 1793 times)

Description:

0 Members and 1 Guest are viewing this topic.

Offline HodgkinsonTopic starter

  • Hero Member
  • *****
  • Join Date: Apr 2006
  • Posts: 1080
    • Show all replies
    • http://www.myspace.com/em_radiation *****and ***** www.booni.info
PC-Amiga joystick – Re-linearalisation in software
« on: March 05, 2008, 11:46:18 AM »
Hi there,
I’m just in the process of making up two PC-Amiga joystick converters, and I’ve got a bit of a problem. PC Joystick potentiometers are wired as variable resistors fed from +5v, and if I feed their signal into a fixed resistor to ground, I will end up with a non-linear response (With the signal taken from between the pot and fixed resistor) against joystick position, as opposed to standard Amiga joysticks that have their potentiometers wired as potentiometers - And thus produce a linear response with joystick position.

One way around this would be to re-wire the joystick or add a selector switch, but its a real PITA to go round sawing big holes in all your best joysticks.
Other methods include a ADC -> [Maths] -> DAC -> Joystick port (No chance...); or finding a uA constant current sink device as opposed to the fixed resistor as this will produce a linear output (Also more complex than what I was hoping for...)

With all the simple-looking commercially available adaptors, is there any software out there to re-linearalise the joystick signal before it is received by a game, for example?

I've seen one or two files on Aminet that look promising and I'd like your recommendations.

Regards and TIA,
Hodgkinson.
Main A1200D: WB3.0, 3.1 ROMs, 2GB HDD, Blizzard 1230IV (64MB RAM + FPU) and a whole load of custom heatsinks... :flame:
 

Offline HodgkinsonTopic starter

  • Hero Member
  • *****
  • Join Date: Apr 2006
  • Posts: 1080
    • Show all replies
    • http://www.myspace.com/em_radiation *****and ***** www.booni.info
Re: PC-Amiga joystick – Re-linearalisation in software
« Reply #1 on: March 05, 2008, 01:42:09 PM »
Have a look at the port pinout – There’s PotX and PotY lines on the ports specially for analogue joysticks. I’m trying to get the X and Y axes of a conventional analogue PC joystick to work on the Amiga – Linearly – Without any nasty hacks to the joystick itself.

Having said that, thanks for the post ;-)

FYI: As for on-off joysticks, these units that I've bought are rather interesting: Link

EDIT: The pinouts seem to suggest that the fire button is on a different signal line when in a analogue joystick as compared to a digital joystick. Is this so? All the games I've tried so far use the centre button on a SEGA pad to fire, and im wondering if I should connect the fire button to the same line as in the SEGA pad, or wether it needs to move to a different rail for a analogue joystick.

Thanks,
Hodgkinson.
Main A1200D: WB3.0, 3.1 ROMs, 2GB HDD, Blizzard 1230IV (64MB RAM + FPU) and a whole load of custom heatsinks... :flame:
 

Offline HodgkinsonTopic starter

  • Hero Member
  • *****
  • Join Date: Apr 2006
  • Posts: 1080
    • Show all replies
    • http://www.myspace.com/em_radiation *****and ***** www.booni.info
Re: PC-Amiga joystick – Re-linearalisation in software
« Reply #2 on: March 05, 2008, 02:31:22 PM »
Hmmm. Opto-couplers are usually designed for digital signals, but I suppose one could be used as an analogue device. The trick is that you’d have to find one with the exact correct response curve of LED current to detector resistance to correct that of the joystick output - By no means a simple task.

Thanks for the comment though ;-)
Main A1200D: WB3.0, 3.1 ROMs, 2GB HDD, Blizzard 1230IV (64MB RAM + FPU) and a whole load of custom heatsinks... :flame: