关于 RTX51

dell9 2003-10-15 11:48:58
我用书上的例程
#include <rtx51tny.h>

int counter0;
int counter1;
void job0 (void) _task_ 0 {
os_create (1); /* mark task 1 as ready */
while (1) { /* loop forever */
counter0++; /* update the counter */
}
}
void job1 (void) _task_ 1 {
while (1) { /* loop forever */
counter1++; /* update the counter */
}
}

为什么在 Keil uVision 上不能编译通过?
是本身就不能在这里用吗?
提示说
'os_create' :missing function-prototype
'os_create': requires ANSI-style prototype
Target not created

我在option中选择了 tiny 和 full 都不行
...全文
75 3 打赏 收藏 转发到动态 举报
写回复
用AI写文章
3 条回复
切换为时间正序
请发表友善的回复…
发表回复
dell9 2003-10-16
  • 打赏
  • 举报
回复
thanks
galle 2003-10-15
  • 打赏
  • 举报
回复
没有'os_create'这个函数!你可以建一个,在编译
unsigned char os_create(unsigned char i){
_nop_();
}
就没有这个错误了!
easyflash 2003-10-15
  • 打赏
  • 举报
回复
应该是os_create_task

27,373

社区成员

发帖
与我相关
我的任务
社区描述
硬件/嵌入开发 单片机/工控
社区管理员
  • 单片机/工控社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧