diff --git a/src/daemon/drivers/sc/by_cable.c b/src/daemon/drivers/sc/by_cable.c index 455456792..faba7dcc8 100644 --- a/src/daemon/drivers/sc/by_cable.c +++ b/src/daemon/drivers/sc/by_cable.c @@ -36,7 +36,9 @@ void input_interrupt_cb(Daemon* d, USBDevHandle hndl, uint8_t endpoint, const ui // TODO: Deallocate sc return; } - handle_input(sc, (SCInput*)data); + SCInput* i = (SCInput*)data; + if (i->ptype == PT_INPUT) + handle_input(sc, i); } diff --git a/src/daemon/drivers/sc/sc.h b/src/daemon/drivers/sc/sc.h index 9e0397ecb..654712e03 100644 --- a/src/daemon/drivers/sc/sc.h +++ b/src/daemon/drivers/sc/sc.h @@ -72,9 +72,9 @@ struct SCController { }; typedef enum { - PT_IDLE = 0x04, PT_INPUT = 0x01, PT_HOTPLUG = 0x03, + PT_IDLE = 0x04, PT_OFF = 0x9f, PT_AUDIO = 0xb6, PT_CLEAR_MAPPINGS = 0x81,