Real-Time Embedded Multithreading: Using ThreadX and ARM

The thread services described in this appendix include:
| tx_thread_create | Create an application thread |
| tx_thread_delete | Delete an application thread |
| tx_thread_identify | Retrieve pointer to currently executing thread |
| tx_thread_info_get | Retrieve information about a thread |
| tx_thread_preemption_change | Change preemption-threshold of thread |
| tx_thread_priority_change | Change priority of an application thread |
| tx_thread_relinquish | Relinquish control to other application threads |
| tx_thread_resume | Resume suspended application thread |
| tx_thread_sleep | Suspend current thread for specified time |
| tx_thread_suspend | Suspend an application thread |
| tx_thread_terminate | Terminate an application thread |
| tx_thread_time_slice_change | Change time-slice of application thread |
| tx_thread_wait_abort | Abort suspension of specified thread |
Create an application thread
UINT <b class="bold">tx_thread_create</b>(TX_THREAD <b class="bold">*thread_ptr,</b> CHAR <b class="bold">*name_ptr,</b> VOID (<b class="bold">*entry_function</b>)(ULONG), ULONG <b class="bold">entry_input,</b> VOID <b class="bold">*stack_start,</b> ULONG <b class="bold">stack_size,</b> UINT <b class="bold">priority,</b> UINT <b class="bold">preempt_threshold,</b> ULONG <b class="bold">time_slice,</b> UINT <b class="bold">auto_start</b>)
This service creates an application thread, which will start execution at the specified task entry function. The stack, priority, preemption-threshold, and time-slice...