diff --git a/src/fs/phy.c b/src/fs/phy.c index 5cda820..a675635 100644 --- a/src/fs/phy.c +++ b/src/fs/phy.c @@ -159,7 +159,7 @@ int phy_unserialize_data(const uint8_t *data, uint16_t len, phy_data_t *phy) { } } if (!phy_data.enabled_usb_itf_present) { - phy_data.enabled_usb_itf = PHY_USB_ITF_CCID | PHY_USB_ITF_WCID | PHY_USB_ITF_HID | PHY_USB_ITF_KB; + phy_data.enabled_usb_itf = PHY_USB_ITF_ALL; phy_data.enabled_usb_itf_present = true; } return PICOKEY_OK; diff --git a/src/fs/phy.h b/src/fs/phy.h index 872917a..7b25cb2 100644 --- a/src/fs/phy.h +++ b/src/fs/phy.h @@ -52,6 +52,7 @@ #define PHY_USB_ITF_HID 0x4 #define PHY_USB_ITF_KB 0x8 #define PHY_USB_ITF_LWIP 0x10 +#define PHY_USB_ITF_ALL (PHY_USB_ITF_CCID | PHY_USB_ITF_WCID | PHY_USB_ITF_HID | PHY_USB_ITF_KB | PHY_USB_ITF_LWIP) #define PHY_LED_DRIVER_PICO 0x1 #define PHY_LED_DRIVER_PIMORONI 0x2 diff --git a/src/usb/usb.c b/src/usb/usb.c index 7c4ca0a..eeefe86 100644 --- a/src/usb/usb.c +++ b/src/usb/usb.c @@ -98,7 +98,7 @@ void usb_init(void) queue_init(&card_to_usb_q, sizeof(uint32_t), 64); queue_init(&usb_to_card_q, sizeof(uint32_t), 64); - uint8_t enabled_usb_itf = PHY_USB_ITF_CCID | PHY_USB_ITF_WCID | PHY_USB_ITF_HID | PHY_USB_ITF_KB | PHY_USB_ITF_LWIP; + uint8_t enabled_usb_itf = PHY_USB_ITF_ALL; #ifndef ENABLE_EMULATION if (phy_data.enabled_usb_itf_present) { enabled_usb_itf = phy_data.enabled_usb_itf;