diff options
| author | hathach <[email protected]> | 2026-05-27 19:20:58 +0700 |
|---|---|---|
| committer | hathach <[email protected]> | 2026-05-27 19:20:58 +0700 |
| commit | 616acfa7328b1a05ea0370a3628fc6a07f4caf57 (patch) | |
| tree | 6c4593800a79099a1f13a8c24cc84bd8e95ef380 /src/osal/osal_rtx4.h | |
| parent | 4a131e1562d8e388bb86592278324ab6bc9f215d (diff) | |
osal add osal_task_get_current_handle()
Diffstat (limited to 'src/osal/osal_rtx4.h')
| -rw-r--r-- | src/osal/osal_rtx4.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/osal/osal_rtx4.h b/src/osal/osal_rtx4.h index e1930c96c..e5b708a2c 100644 --- a/src/osal/osal_rtx4.h +++ b/src/osal/osal_rtx4.h @@ -37,6 +37,12 @@ extern "C" { //--------------------------------------------------------------------+ // TASK API //--------------------------------------------------------------------+ +typedef OS_TID osal_task_handle_t; + +TU_ATTR_ALWAYS_INLINE static inline osal_task_handle_t osal_task_get_current_handle(void) { + return os_tsk_self(); +} + TU_ATTR_ALWAYS_INLINE static inline void osal_task_delay(uint32_t msec) { uint16_t hi = msec >> 16; uint16_t lo = msec; |
