mirror of
https://github.com/mcgurk/Arduino-USB-HID-RetroJoystickAdapter
synced 2024-11-25 10:32:19 -05:00
Update RetroJoystickAdapter_PlaystationAnalog.ino
This commit is contained in:
parent
569821d7c2
commit
6353727eeb
@ -124,6 +124,12 @@ void interpretJoystickState_analog() {
|
|||||||
if ( !(btngrp1&DOWN) ) Joystick.setHatSwitch(0,180); //DOWN
|
if ( !(btngrp1&DOWN) ) Joystick.setHatSwitch(0,180); //DOWN
|
||||||
if ( !(btngrp1&LEFT) ) Joystick.setHatSwitch(0,270); //LEFT
|
if ( !(btngrp1&LEFT) ) Joystick.setHatSwitch(0,270); //LEFT
|
||||||
if ( !(btngrp1&RIGHT) ) Joystick.setHatSwitch(0,90); //RIGHT
|
if ( !(btngrp1&RIGHT) ) Joystick.setHatSwitch(0,90); //RIGHT
|
||||||
|
|
||||||
|
if ( !(btngrp1&UP) && !(btngrp1&RIGHT) ) Joystick.setHatSwitch(0,45); //UP-RIGHT
|
||||||
|
if ( !(btngrp1&RIGHT) && !(btngrp1&DOWN) ) Joystick.setHatSwitch(0,135); //RIGHT-DOWN
|
||||||
|
if ( !(btngrp1&DOWN) && !(btngrp1&LEFT) ) Joystick.setHatSwitch(0,225); //DOWN-LEFT
|
||||||
|
if ( !(btngrp1&LEFT) && !(btngrp1&UP) ) Joystick.setHatSwitch(0,315); //LEFT-UP
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user