MCUXpresso SDK API Reference Manual
Rev 2.12.1
NXP Semiconductors
|
Macros | |
#define | FSL_OSA_BM_TIMER_NONE 0U |
Bare Metal does not use timer. More... | |
#define | FSL_OSA_BM_TIMER_SYSTICK 1U |
Bare Metal uses SYSTICK as timer. More... | |
#define | FSL_OSA_BM_TIMER_CONFIG FSL_OSA_BM_TIMER_NONE |
Configure what timer is used in Bare Metal. More... | |
#define | OSA_WAIT_FOREVER 0xFFFFFFFFU |
Constant to pass as timeout value in order to wait indefinitely. More... | |
#define | TASK_MAX_NUM 7 |
How many tasks can the bare metal support. More... | |
#define | FSL_OSA_TIME_RANGE 0xFFFFFFFFU |
OSA's time range in millisecond, OSA time wraps if exceeds this value. More... | |
#define | OSA_DEFAULT_INT_HANDLER ((osa_int_handler_t)(&DefaultISR)) |
The default interrupt handler installed in vector table. More... | |
Typedefs | |
typedef void * | task_param_t |
Type for task parameter. | |
typedef uint32_t | event_flags_t |
Type for an event flags group, bit 32 is reserved. | |
Functions | |
void | DefaultISR (void) |
The default interrupt handler installed in vector table. More... | |
void | OSA_ProcessTasks (void) |
Process OSA tasks. More... | |
uint8_t | OSA_TaskShouldYield (void) |
Check OSA Task Should Yield. More... | |
Thread management | |
#define | PRIORITY_OSA_TO_RTOS(osa_prio) (osa_prio) |
To provide unified priority for upper layer, OSA layer makes conversation. | |
#define | PRIORITY_RTOS_TO_OSA(rtos_prio) (rtos_prio) |
#define FSL_OSA_BM_TIMER_NONE 0U |
#define FSL_OSA_BM_TIMER_SYSTICK 1U |
#define FSL_OSA_BM_TIMER_CONFIG FSL_OSA_BM_TIMER_NONE |
#define OSA_WAIT_FOREVER 0xFFFFFFFFU |
#define TASK_MAX_NUM 7 |
#define FSL_OSA_TIME_RANGE 0xFFFFFFFFU |
#define OSA_DEFAULT_INT_HANDLER ((osa_int_handler_t)(&DefaultISR)) |
void DefaultISR | ( | void | ) |
void OSA_ProcessTasks | ( | void | ) |
This function is used to process registered tasks.
Example below shows how to use this API in baremetal.
uint8_t OSA_TaskShouldYield | ( | void | ) |
This function is used to check task should yield, When this function returns 1, an OSA task has to run. This function is typically used with Interrupt disabled before executing WFI instruction.