OS_MAX_TASKS
OS_MAX_TASKS 指定應用程序中可以存在的最大應用程序任務數(shù)。 請注意,OS_MAX_TASKS 不能大于 253(自 V2.80 起),因為 μC/OS-II 當前為自己保留了兩個任務(參見 uCOS_II.H 中的 OS_N_SYS_TASKS)。 如果將 OS_MAX_TASKS 設置為系統(tǒng)中任務的確切數(shù)量,則需要確保在添加其他任務時修改此值。 相反,如果您使 OS_MAX_TASKS 遠高于您當前的任務要求(以供將來擴展),那么您就是在浪費寶貴的 RAM。
OS_MAX_TASKS
OS_MAX_TASKS specifies the maximum number of application tasks that can exist in your application. Note that OS_MAX_TASKS cannot be greater than 253 (as of V2.80) because μC/OS-II currently reserves two tasks for itself (see OS_N_SYS_TASKS in uCOS_II.H). If you set OS_MAX_TASKS to the exact number of tasks in your system, you need to make sure that you revise this value when you add additional tasks. Conversely, if you make OS_MAX_TASKS much higher than your current task requirements (for future expansion), you are wasting valuable RAM.
|