diff options
| author | hathach <[email protected]> | 2026-02-27 23:34:48 +0700 |
|---|---|---|
| committer | hathach <[email protected]> | 2026-02-27 23:42:40 +0700 |
| commit | 7ea02fd6c9e376679bc1fe025bb73e43664e17c6 (patch) | |
| tree | 8ff5476245cfb8fe7d885512a4ec03c05167dfa9 /src/tusb.h | |
| parent | 8302adfab8727896c4a10935a15c32fbdcba3b8e (diff) | |
add osal_time_millis() to osal requirement
implement tusb_time_millis_api() with osal_time_millis() when OS is not NONE
Diffstat (limited to 'src/tusb.h')
| -rw-r--r-- | src/tusb.h | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/src/tusb.h b/src/tusb.h index 62b3b9783..742009a2e 100644 --- a/src/tusb.h +++ b/src/tusb.h @@ -135,7 +135,7 @@ //--------------------------------------------------------------------+ -// User API +// Application API //--------------------------------------------------------------------+ #if CFG_TUH_ENABLED || CFG_TUD_ENABLED @@ -174,6 +174,16 @@ bool tusb_deinit(uint8_t rhport); #endif +//--------------------------------------------------------------------+ +// +//--------------------------------------------------------------------+ + +// Get current milliseconds, required by some port/configuration without RTOS +extern uint32_t tusb_time_millis_api(void); + +// Delay in milliseconds, use tusb_time_millis_api() by default. required by some port/configuration with no RTOS +extern void tusb_time_delay_ms_api(uint32_t ms); + #ifdef __cplusplus } #endif |
