61 const int8_t index = getButtonIndexPS5(b);
if (index < 0)
return 0;
69 const int8_t index = getButtonIndexPS5(b);
if (index < 0)
return 0;
77 const int8_t index = getButtonIndexPS5(b);
if (index < 0)
return 0;
102 else if (
buf[0] == 0x31) {
105 Notify(
PSTR(
"\r\nReport is too short: "), 0x80);
113 Notify(
PSTR(
"\r\nUnknown report id: "), 0x80);
121 if (ps5Data.
btn.
val != oldButtonState.
val) {
122 buttonClickState.
val = ps5Data.
btn.
val & ~oldButtonState.val;
129 if (checkDpad(
RIGHT))
154 oldButtonState.
val = 0;
162 buttonClickState.
dpad = 0;
172 ps5Output.
r = ps5Output.
g = ps5Output.
b = 0;
const uint8_t PS5_BUTTONS[]
void Parse(uint8_t len, uint8_t *buf)
bool getButtonPress(ButtonEnum b)
bool getButtonClick(ButtonEnum b)
uint8_t getAnalogHat(AnalogHatEnum a)
virtual void sendOutputReport(PS5Output *output)=0
uint8_t getAnalogButton(ButtonEnum b)
constexpr int8_t ButtonIndex(ButtonEnum key)
struct ps5TouchpadXY::@31 finger[2]
#define pgm_read_byte(addr)