[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
about rt-task period
hello
when testing if the periodis too short,I find the code below do not work
correctly
-----------------------------------
int overrun = 0;
do{
pthread_wait_np();
if(overrun) {
conpr("overrun!\n");
break;
}
overrun++;
/* calculation code */
overrun--;
}while(1);
------------------------------------
for example, the calculation elapse 17 us, I set period=20us,
the min,max value(actual period minus 20us) is about 2.6 ,
9us /*see examples/measurement/rt_process.c*/,but if set period=10us,
the min,max is about 23,30us , greater than perid! "overrun" doesn't
work, why?
thanks.
__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail
http://personal.mail.yahoo.com/