ABSTRACT

The main function of Real Time-Thread (RT-Thread) management is to manage and schedule threads. The thread scheduler of RT-Thread is preemptive, and its main job is to find the highest priority thread from the list of ready threads to ensure that the highest-priority thread can be run. The priority of the RT-Thread thread indicates the thread's priority of being scheduled. Each thread has a time slice parameter, but time slice is only effective for ready-state threads of the same priority. “Entry” in Thread Control Block is the thread's entry function, which is a function for the thread to achieve the intended functionality. An idle thread is the lowest-priority thread created by the system, and its thread state is always ready. RT-Thread's thread has an independent stack.