|
Embedded Artistry Framework
Embedded Systems C++ Framework
|
Thread types and definitions. More...
Typedefs | |
| using | handle_t = uintptr_t |
| Generic type for thread handles. More... | |
| using | input_t = void * |
| Thread function's input data type. More... | |
| using | func_t = void(*)(input_t) |
| Thread function prototype. More... | |
Enumerations | |
| enum | state : uint8_t { state::ready = 0, state::executing, state::suspended, state::terminated, state::completed } |
| Thread's operational state. More... | |
| enum | priority : uint8_t { priority::panic = 0, priority::interrupt, priority::realtime, priority::veryHigh, priority::high, priority::aboveNormal, priority::normal, priority::belowNormal, priority::low, priority::lowest, priority::idle } |
| Default priority settings. More... | |
Thread types and definitions.
| using embvm::thread::func_t = typedef void (*)(input_t) |
Thread function prototype.
The function prototype for functions which can be passed to the thread object.
Survey results: pthread: void *(*start_routine)(void*) freertos: void (*task)(void) threadx: void (*task)(ulong) CMSIS: void*(*task)(void*)
| using embvm::thread::handle_t = typedef uintptr_t |
Generic type for thread handles.
| using embvm::thread::input_t = typedef void* |
Thread function's input data type.
Type of input argument sent to the thread function on start.
Survey results: threadx takes in a ULONG FreeRTOS, pthread use void* CMSIS settled on void*
We default to void*
|
strong |
Default priority settings.
These are default priority settings, allowing consumers to specify thread priority by a portable named value, rather than explicit numeric values. The named priority values are set to specific values within the RTOS-specific thread implementation.
This enumeration should be preferred to raw numeric values because the priority scheme changes from RTOS to RTOS. Code specifing exact priority numbers is not portable. However, if more precise priority specification is needed, do not use these types.
|
strong |
1.8.15