Fix esp build for non-hid

Signed-off-by: Pol Henarejos <pol.henarejos@cttc.es>
This commit is contained in:
Pol Henarejos
2026-08-29 21:08:34 +02:00
parent 8e437f7ca6
commit b35df81a03
2 changed files with 8 additions and 2 deletions
@@ -15,8 +15,12 @@ set(PICOKEYS_REQUIRES
esp_tinyusb
efuse
mbedtls
tinycbor
)
if(USB_ITF_HID)
list(APPEND PICOKEYS_REQUIRES
tinycbor
)
endif()
if (USB_ITF_LWIP)
list(APPEND PICOKEYS_REQUIRES
+3 -1
View File
@@ -415,8 +415,10 @@ static uint16_t ccid_open(uint8_t rhport, tusb_desc_interface_t const *itf_desc,
tusb_desc_endpoint_t const *desc_ep = (tusb_desc_endpoint_t const *)((uint8_t *)itf_desc + drv_len - sizeof(tusb_desc_endpoint_t));
TU_ASSERT(usbd_edpt_open(rhport, desc_ep), 0);
uint8_t msg[] = { 0x50, 0x03 };
#if defined(PICO_PLATFORM) || defined(ESP_PLATFORM)
#if defined(PICO_PLATFORM)
usbd_edpt_xfer(rhport, desc_ep->bEndpointAddress, msg, sizeof(msg));
#elif defined(ESP_PLATFORM)
usbd_edpt_xfer(rhport, desc_ep->bEndpointAddress, msg, sizeof(msg), false);
#else
usbd_edpt_xfer(rhport, desc_ep->bEndpointAddress, msg, sizeof(msg), sizeof(msg));
#endif