IDs for PlayStation 4 controllers


NOTES

WINDOWS: seems to work fine without any special drivers on Windows 10 (and I seem to recall the same on Windows 7). DS4Windows is the popular 3rd-party utility here, but it will make the PS4 controller look like a 360 controller, which means that it will be indistinguishable from an XInput device to flixel (DS4Windows: http://ds4windows.com).

LINUX: the PS4 controller will be detected as an XInput device when using xpad (see notes in XInputID.hx)

MAC: the PS4 controller seemed to work perfectly without anything special installed, and was not detected in the 360Controller control panel, so it might just work right out of the box!

Static variables

@:value(12)staticinlineread onlyCIRCLE:Int = 12

@:value(7)staticinlineread onlyDPAD_DOWN:Int = 7

@:value(8)staticinlineread onlyDPAD_LEFT:Int = 8

@:value(9)staticinlineread onlyDPAD_RIGHT:Int = 9

@:value(6)staticinlineread onlyDPAD_UP:Int = 6

@:value(14)staticinlineread onlyL1:Int = 14

@:value(16)staticinlineread onlyL2:Int = 16

@:value(new FlxGamepadAnalogStick(0, 1, { up : 24, down : 25, left : 26, right : 27 }))staticread onlyLEFT_ANALOG_STICK:FlxGamepadAnalogStick = new FlxGamepadAnalogStick(0, 1, { up : 24, down : 25, left : 26, right : 27 })

@:value(20)staticinlineread onlyLEFT_STICK_CLICK:Int = 20

@:value(19)staticinlineread onlyOPTIONS:Int = 19

@:value(22)staticinlineread onlyPS:Int = 22

@:value(15)staticinlineread onlyR1:Int = 15

@:value(17)staticinlineread onlyR2:Int = 17

@:value(new FlxGamepadAnalogStick(2, 5, { up : 28, down : 29, left : 30, right : 31 }))staticread onlyRIGHT_ANALOG_STICK:FlxGamepadAnalogStick = new FlxGamepadAnalogStick(2, 5, { up : 28, down : 29, left : 30, right : 31 })

@:value(21)staticinlineread onlyRIGHT_STICK_CLICK:Int = 21

@:value(18)staticinlineread onlySHARE:Int = 18

@:value(10)staticinlineread onlySQUARE:Int = 10

@:value(23)staticinlineread onlyTOUCHPAD_CLICK:Int = 23

@:value(13)staticinlineread onlyTRIANGLE:Int = 13

@:value(11)staticinlineread onlyX:Int = 11