> What do I need if I don't want a periodic thread?
> That is, I want to set a dead-line for my thread without using periodic
> thread?
>
next_time=calc_time(); /* calculate the next time you want to run in NS */
now=clock_gethrtime(); /* get the current time */
while(1){
clock_nanosleep(CLOCK_REATLTIME,TIMER_ABSTIME,hrt2ts(now+next_time),NULL);
< your rt code >
next_time=calc_time();
now=clock_gethrtime();
}
hofrat
-- [rtl] ---
To unsubscribe:
echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR
echo "unsubscribe rtl <Your_email>" | mail [EMAIL PROTECTED]
--
For more information on Real-Time Linux see:
http://www.rtlinux.org/