On 10/04/2011 03:06 PM, Julien Delange wrote:
> void polling_task(void * arg)
> {
>    int                      i;
>    double                tmp;
>    int                     ret;
>    uint8_t               raw[128 * 16];
>    double               rate = 0.0001;

Your "rate" looks more like a period to me (that is, the reciprocal).
The corresponding rate would be 10000.

>    int                      result;
>    unsigned long     missed;
>    a4l_insn_t          insn_tab[16];
>    a4l_insnlst_t       insnlst;
> 
> 
>    insnlst.count = 16;
>    insnlst.insns = insn_tab;
> 
>    for (i=0; i<16; i++)
>    {
>       insn_tab[i].type             = A4L_INSN_READ;
>       insn_tab[i].idx_subd      = 0;
>       insn_tab[i].chan_desc   = chdesc[i];
>       insn_tab[i].data_size     = 8;
>       insn_tab[i].data             = &raw[128 * i];
>    }
>    rt_task_set_periodic(NULL, TM_NOW, rate * 1000000000.0);

1000000000.0 * 0.0001 is 100000, that is 100us, not 1ms. As of why you
get 2ms (or 200us, maybe ?) is still a mystery. Could you send us your
kernel configuration?
Are not the analogy calls blocking?

-- 
                                            Gilles.

_______________________________________________
Xenomai-help mailing list
[email protected]
https://mail.gna.org/listinfo/xenomai-help

Reply via email to