Can a thread use message communication as well as one-shot timers?

Aref Taidi aref.taidi at newera-computing.com
Thu Oct 11 20:33:23 CEST 2007


Hello everyone,

I have a hard realtime user space thread that uses rt_receivex() to
receive messages from other threads. I would also like to start a
oneshot timer from this thread to check things out every second, so that
in between the thread can receive messages.

Following some examples in the showroom I make the following calls with
appropriate parameters (omitted below) in this order:

rt_task_init_schmod();
mlockall();
rt_grow_and_lock_stack();
rt_make_hard_real_time();
rt_task_use_fpu(netman_task, 1); 
start_rt_timer(0);
rt_init_timer();
rt_insert_timer();

But the above causes the PC to hang needing a reboot. But if I don't use
the last 3 function calls everything works, but I won't have a timer!!
Please can someone tell me what I am doing wrong?

Many thanks in advance,

A.T.





More information about the Rtai mailing list