Steven Seeger wrote:
 > If I want a periodic task to wait on a condition variable whose purpose
 > is to wait until the task is needed again, should I set it non-periodic
 > first and then set it periodic again after it wakes up?
 > 
 >  
 > 
 > If I am running in periodic timebase mode, I notice weird behavior
 > without this behavior. It seems ok in aperiodic mode, however.

Could you reduce your code to a minimal example showing this behaviour?

 > Also, if I set the native skin to periodic mode, the latency default
 > setting of 4200 doesn't change tick types, therefore it causes all my
 > calls to rt_task_set_periodic() fail with jiffies less than this.

Try the attached patch. It looks like a condition got negated when
replacing the test by a predicate.

-- 


                                            Gilles Chanteperdrix.
Index: ksrc/nucleus/pod.c
===================================================================
--- ksrc/nucleus/pod.c  (revision 3460)
+++ ksrc/nucleus/pod.c  (working copy)
@@ -3305,7 +3305,8 @@ int xnpod_set_thread_periodic(xnthread_t
                        xntimer_stop(&thread->ptimer);
 
                goto unlock_and_exit;
-       } else if (xntbase_periodic_p(xnthread_time_base(thread)) && period < 
nklatency) {
+       } else if (!xntbase_periodic_p(xnthread_time_base(thread))
+                  && period < nklatency) {
                /* LART: detect periods which are shorter than the
                 * intrinsic latency figure; this must be a joke... */
                err = -EINVAL;
_______________________________________________
Xenomai-help mailing list
[email protected]
https://mail.gna.org/listinfo/xenomai-help

Reply via email to