diff options
| author | hathach <[email protected]> | 2018-02-28 14:25:08 +0700 |
|---|---|---|
| committer | hathach <[email protected]> | 2018-02-28 14:25:08 +0700 |
| commit | 9bf083d44929564141d5c092d63cc2053358f794 (patch) | |
| tree | 9733cfa1fa3f7673ca78078d3ebc49cd4fade696 /tinyusb/osal | |
| parent | 9b7cd608aa4addf40cbe2135b38a78378e6f428f (diff) | |
osal clean up remove OSAL_TASK_DEF, OSAL_TASK_FUNCTION
Diffstat (limited to 'tinyusb/osal')
| -rw-r--r-- | tinyusb/osal/osal.h | 4 | ||||
| -rw-r--r-- | tinyusb/osal/osal_freeRTOS.h | 12 | ||||
| -rw-r--r-- | tinyusb/osal/osal_none.h | 5 |
3 files changed, 0 insertions, 21 deletions
diff --git a/tinyusb/osal/osal.h b/tinyusb/osal/osal.h index 9c136d4d9..9f7a2b320 100644 --- a/tinyusb/osal/osal.h +++ b/tinyusb/osal/osal.h @@ -116,10 +116,6 @@ uint32_t osal_tick_get(void); typedef uint32_t osal_task_t;
tusb_error_t osal_task_create(osal_task_t *task);
-#define OSAL_TASK_DEF(code, stack_depth, prio) osal_task_t variable
-#define OSAL_TASK_REF(name) (&name)
-#define OSAL_TASK_FUNCTION(task_func, p_para) void task_func(void * p_para)
-
void osal_task_delay(uint32_t msec);
#define OSAL_TASK_LOOP_BEGIN
diff --git a/tinyusb/osal/osal_freeRTOS.h b/tinyusb/osal/osal_freeRTOS.h index a8d6a9a46..363aa1863 100644 --- a/tinyusb/osal/osal_freeRTOS.h +++ b/tinyusb/osal/osal_freeRTOS.h @@ -64,18 +64,6 @@ extern "C" { //--------------------------------------------------------------------+ // TASK API //--------------------------------------------------------------------+ -#define OSAL_TASK_FUNCTION portTASK_FUNCTION - -#define OSAL_TASK_DEF(task_code, task_stack_depth, task_prio) \ - osal_task_t osal_task_def_##task_code = {\ - .name = #task_code , \ - .code = task_code , \ - .stack_depth = task_stack_depth , \ - .prio = task_prio \ - } - -#define OSAL_TASK_REF(name) (&osal_task_def_##name) - static inline bool osal_task_create(osal_func_t code, const char* name, uint32_t stack_size, void* param, uint32_t prio, osal_task_t* task_hdl) { return xTaskCreate(code, (const signed char*) name, stack_size, param, prio, task_hdl); diff --git a/tinyusb/osal/osal_none.h b/tinyusb/osal/osal_none.h index 5701797cc..6b0148949 100644 --- a/tinyusb/osal/osal_none.h +++ b/tinyusb/osal/osal_none.h @@ -69,17 +69,12 @@ uint32_t tusb_tick_get(void); // OSAL_TASK_LOOP_ENG
// }
//--------------------------------------------------------------------+
-#define OSAL_TASK_DEF(code, stack_depth, prio)
-
-
static inline bool osal_task_create(osal_func_t code, const char* name, uint32_t stack_size, void* param, uint32_t prio, osal_task_t* task_hdl)
{
(void) code; (void) name; (void) stack_size; (void) param; (void) prio; (void) task_hdl;
return true;
}
-#define OSAL_TASK_FUNCTION(task_func, p_para) tusb_error_t task_func(void * p_para)
-
#define TASK_RESTART \
state = 0
|
