diff options
| author | hathach <[email protected]> | 2018-05-17 20:04:52 +0700 |
|---|---|---|
| committer | hathach <[email protected]> | 2018-05-17 20:04:52 +0700 |
| commit | 3a64acaa28222cda74d9b1dc97a028951ed26688 (patch) | |
| tree | 05f8b7546e35ea3d8cf651af741a2d602df2b315 /tinyusb/device | |
| parent | ea7efb0fd63e872aedadb9387ecb4877cb2044bd (diff) | |
complete enhancing osal with static memory
Diffstat (limited to 'tinyusb/device')
| -rw-r--r-- | tinyusb/device/usbd.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/tinyusb/device/usbd.c b/tinyusb/device/usbd.c index 7fa73edbc..9fe6a5446 100644 --- a/tinyusb/device/usbd.c +++ b/tinyusb/device/usbd.c @@ -169,6 +169,8 @@ typedef struct ATTR_ALIGNED(4) VERIFY_STATIC(sizeof(usbd_task_event_t) <= 12, "size is not correct");
+OSAL_TASK_DEF(_usbd_task_def, "usbd", usbd_task, CFG_TUD_TASK_PRIO, CFG_TUD_TASK_STACKSIZE);
+
/*------------- event queue -------------*/
OSAL_QUEUE_DEF(_usbd_qdef, USBD_TASK_QUEUE_DEPTH, usbd_task_event_t);
static osal_queue_t _usbd_q;
@@ -220,7 +222,7 @@ tusb_error_t usbd_init (void) _usbd_ctrl_sem = osal_semaphore_create(&_usbd_sem_def);
VERIFY(_usbd_q, TUSB_ERROR_OSAL_SEMAPHORE_FAILED);
- osal_task_create(usbd_task, "usbd", CFG_TUD_TASK_STACKSIZE, NULL, CFG_TUD_TASK_PRIO);
+ osal_task_create(&_usbd_task_def);
//------------- Core init -------------//
arrclr_( _usbd_descs );
|
