diff options
| author | hathach <[email protected]> | 2020-08-07 14:47:32 +0700 |
|---|---|---|
| committer | hathach <[email protected]> | 2020-08-07 14:47:32 +0700 |
| commit | 01b9b77d3b94ed83931d6a51c1b357f03f188e76 (patch) | |
| tree | e71242fedc96e40837bcf6deb988618796b2b145 /src/device/usbd.h | |
| parent | 9df8057702fcbc8086b223c164e1734db7beca25 (diff) | |
allow application driver to overwrite built-in one
- position application driver before built-in
- remove dcd.h from public include.
Diffstat (limited to 'src/device/usbd.h')
| -rw-r--r-- | src/device/usbd.h | 16 |
1 files changed, 3 insertions, 13 deletions
diff --git a/src/device/usbd.h b/src/device/usbd.h index 098e94075..5338be157 100644 --- a/src/device/usbd.h +++ b/src/device/usbd.h @@ -35,7 +35,6 @@ #endif #include "common/tusb_common.h" -#include "dcd.h" //--------------------------------------------------------------------+ // Application API @@ -53,6 +52,7 @@ void tud_task (void); bool tud_task_event_ready(void); // Interrupt handler, name alias to DCD +extern void dcd_int_handler(uint8_t rhport); #define tud_int_handler dcd_int_handler // Get current bus speed @@ -75,21 +75,11 @@ bool tud_remote_wakeup(void); // Enable pull-up resistor on D+ D- // Return false on unsupported MCUs -static inline bool tud_disconnect(void) -{ - TU_VERIFY(dcd_disconnect); - dcd_disconnect(TUD_OPT_RHPORT); - return true; -} +bool tud_disconnect(void); // Disable pull-up resistor on D+ D- // Return false on unsupported MCUs -static inline bool tud_connect(void) -{ - TU_VERIFY(dcd_connect); - dcd_connect(TUD_OPT_RHPORT); - return true; -} +bool tud_connect(void); // Carry out Data and Status stage of control transfer // - If len = 0, it is equivalent to sending status only |
