diff options
| author | hathach <[email protected]> | 2024-04-02 16:38:40 +0700 |
|---|---|---|
| committer | hathach <[email protected]> | 2024-04-02 16:38:40 +0700 |
| commit | 7d3d60f96de3f6e15291c9302463c294e2dc98de (patch) | |
| tree | 9066cd077fd07703326391c46c3e55f165b1db5b /src/host/usbh.h | |
| parent | e802fe0677c901a444e7c9b5d67be2a1f400adee (diff) | |
add hcd_configure() to change max NAK dynamically
Diffstat (limited to 'src/host/usbh.h')
| -rw-r--r-- | src/host/usbh.h | 14 |
1 files changed, 12 insertions, 2 deletions
diff --git a/src/host/usbh.h b/src/host/usbh.h index 0e31e80a7..57362c778 100644 --- a/src/host/usbh.h +++ b/src/host/usbh.h @@ -73,11 +73,21 @@ typedef struct { tusb_desc_interface_t desc; } tuh_itf_info_t; -// ConfigID for tuh_config() +// ConfigID for tuh_configure() enum { - TUH_CFGID_RPI_PIO_USB_CONFIGURATION = OPT_MCU_RP2040 << 8 // cfg_param: pio_usb_configuration_t + TUH_CFGID_INVALID = 0, + TUH_CFGID_RPI_PIO_USB_CONFIGURATION = 100, // cfg_param: pio_usb_configuration_t + TUH_CFGID_MAX3421 = 200, }; +typedef union { + // For TUH_CFGID_RPI_PIO_USB_CONFIGURATION use pio_usb_configuration_t + + struct { + uint8_t max_nak; + } max3421; +} tuh_configure_param_t; + //--------------------------------------------------------------------+ // APPLICATION CALLBACK //--------------------------------------------------------------------+ |
