中级会员
- 积分
- 316
- 金钱
- 316
- 注册时间
- 2018-4-4
- 在线时间
- 30 小时
|
楼主 |
发表于 2018-7-17 10:48:31
|
显示全部楼层
本帖最后由 肥油玉帝 于 2018-7-17 10:50 编辑
我知道了,是应为在调用过OSStart()函数之后,CPU就转去运行μCOS-II操作系统了
OSStart()的官方英文注释是(前半部分):This function is used to start the multitasking process which lets uC/OS-II manages the task that you have created. OSStart()具体内容是:
[mw_shl_code=c,true]void OSStart (void)
{
if (OSRunning == OS_FALSE) {
OS_SchedNew(); /* Find highest priority's task priority number */
OSPrioCur = OSPrioHighRdy;
OSTCBHighRdy = OSTCBPrioTbl[OSPrioHighRdy]; /* Point to highest priority task ready to run */
OSTCBCur = OSTCBHighRdy;
OSStartHighRdy(); /* Execute target specific code to start task */
}
}[/mw_shl_code]
|
|