请指导rtx51
#include <rtx51tny.h>
unsigned char counter0;
unsigned char counter1;
void job0 (void) _task_ 0 {
os_create_task (1); /* mark task 1 as ready */
while (1) { /* loop forever */
if (++counter0 ==0x00) /* update the counter */
os_send_signal (1); /* signal task 1 */
}
}
void job1 (void) _task_ 1 {
while (1) { /* loop forever */
os_wait (K_SIG, 0, 0); /* wait for a signal */
counter1++; /* update the counter */
}
}
此程序有错吗
运行时出错,而且达不到理想结果
请指导
发表时间:2003年7月24日7:20:08