QP_RTOS notes

1. QP&UCOSII task creation notes

1.

In the UCOSII version of QP, a function is called every time a task is created, task_function()

Use different pdata parameters to determine the state machine that the task selects to execute. Each state machine has its own explanation.

This way is very good, I haven't thought about it before.

2. UCOS task statistics

In this version, the task statistics of the OS are not done, and it needs to be called once in the task execution, so that you can know how many idle counters are executed in 100ms. Use this as a benchmark.

Calculate the CPU utilization.

3. The size of the message pool

If the message pool is too small, there will be some time-consuming operations in the program, which will not respond. At this time, the message pool of the current task will become more and more, causing a crash.

So writing a program is almost the same as bare metal, so it’s best not to wait.

For some things, you can also directly use the original OS to handle some tasks. Just send the message out.

Guess you like

Origin blog.csdn.net/C_ROOKIES/article/details/114699287