...
\Micrium\Software\uC-USB-Device-V4\OS\Template
Table - Core OS port API summary summarizes all the functions that need to be implemented in the RTOS port file. For more information on how these functions should be implemented, refer to the Core Layer RTOS Model page and to the Core OS Functions reference.
Anchor |
---|
| Table - Core OS port API summary |
---|
| Table - Core OS port API summary |
---|
|
Panel |
---|
borderWidth | 0 |
---|
title | Table - Core OS port API summary |
---|
|
|
Note that you must declare at least one task for the core events management within your RTOS port. This task should simply call the core function USBD_CoreTaskHandler
in an infinite loop. Furthermore, if you plan using the debugging feature, you must also create a task for this purpose. This task should simply call the core function USBD_DbgTaskHandler
in an infinite loop. Listing - Core task and debug task typical implementation shows how these two task functions body should be implemented.
Anchor |
---|
| Listing - Core task and debug task typical implementation |
---|
| Listing - Core task and debug task typical implementation |
---|
|
Code Block |
---|
language | cpp |
---|
title | Listing - Core task and debug task typical implementation |
---|
linenumbers | true |
---|
|
static void USBD_OS_CoreTask (void *p_arg)
{
(void)&p_arg;
while (DEF_ON) {
USBD_CoreTaskHandler();
}
}
static void USBD_OS_TraceTask (void *p_arg)
{
(void)&p_arg;
while (DEF_ON) {
USBD_DbgTaskHandler();
}
} |