Changes
/* Analog PC Joysticks */
* [[Connector:Analogue joystick (CPC Plus only)|Analog Joystick Port Pin-Outs]]
The buttons are accessed same ways as for Digital Joysticks (ie. as part of the keyboard matrix).
The analog inputs are read from memory mapped ASIC registers: 6808h ADC0 Analogue Joystick 1, X-Axis (00h=Left= Analog CPC+ Joysticks 0 ohm, 3Fh=Right=138K ohm) 6809h ADC1 Analogue Joystick 1, Y-Axis (00h=Up =0 ohm, 3Fh=Down =138K ohm) 680Ah ADC2 Analogue Joystick 2, X-Axis (00h=Left=0 ohm, 3Fh=Right=138K ohm) 680Bh ADC3 Analogue Joystick 2, Y-Axis (00h=Up =0 ohm, 3Fh=Down =138K ohm) 680Ch ADC4 Unused, wired to +5V (twice the maximum of 2.5V) (returns 3Fh) 680Dh ADC5 Unused, wired to GND (equivalent to 0 ohm) (returns 00h) 680Eh ADC6 Unused, wired to +5V (twice the maximum of 2.5V) (returns 3Fh) 680Fh ADC7 Unused, wired to GND (equivalent to 0 ohm) (returns 00h)To read that registers: Unlock the ASIC, and then map its register to memory at 4000h..7FFFh.
== Analog CPC+ Games with Analog Joystick Support Joysticks ==
Analogue joysticks confirmed to be compatible with the CPC+:* [[Tennis Cup 2 ( Cartridge )Amstrad Analogue Joystick AJ-5]]* [[Sinclair SPJ-1|Amstrad's Sinclair SPJ-1]] allows player 2 to use analog port.
Analog PC Joysticks have a very similar 15pin connector. But with some differences, which cause compatibility problems. Statistically, many people reported the analog PC joysticks ''Yet I found out that 'do work''' with analog CPC+ software. Many other people reported it was impossible to go to directions Down and left won't work - though it's quite possibly that they simply made some fundamental mistakes (yet up and right worked), probably due like trying to : 'use "digital" 15pin joysticks as "analog" joystick, or that they didn't even had proper CPC+ software for testing).
*''this PC analog joystick is of a slightly more recent generation 'Button Common Pin''' - In PCs, the button-common-pin can be at Pin4 or Pin5, on the CPC+ it must be Pin4 (yet still using 15pin plugor Pin12 for 3rd-4th button; if any).''If necessary, rewire that pins.
*''4 button joystick'Reversed Supply Voltages''' - Compared with PC Gameports, while Amstrad supports only 2 the +5V and GND are connected vice-versa in the CPC+. This is most probably no problem for the cause of failure to get all directions properlypotentiometers (both PC and CPC+ use Pin1 as pot-common).However, it is a problem if the joystick contains '''additional electronics''' (auto-fire circuits, electrolyte capacitors, circuits inside of ''digital'' joysticks/gamepads that do emulate analog signals, etc.) These won't work (and may get damaged by the reversed voltages). If necessary, remove any such electronics before connected the joystick to the CPC+.
* '''Resistor Values''' - In PCs, the A/D conversion is done by software timings, meaning the PCs could handle joysticks with different potentiometer types (anything from 10 kiloohm to many megaohm should work). The CPC+ does the A/D conversion by hardware, this requires less CPU load, but it also means that it requires fixed potentiometer types (circa '''138k'''Ω).
** Analog PC joysticks are reportedly most commonly using '''100k''', '''120k''', or '''150k'''Ω pots. These types should be more or less compatible with the CPC+ (100K/120K won't reach the ADC=3Fh max value, for example, resolution might be only ADC=00h..30h. And 150K would be clipped to ADC=3Fh for anything above 138kΩ).
** To handle those different pot types, CPC+ software should include calibration options.
** There are also some PC joysticks with incompatible pot types like '''300k'''Ω - these won't work (since values above 138k will be clipped).
[[Category:HardwareCPC Plus]][[Category:PeripheralsFutureOS]][[Category:CPC PlusGames Programming]][[Category:StubInput Device]][[Category:Peripherals]]