Hi!

I am just playing around with Xenomai to understand it.
And I have one question concerning the entry function that will be called from
rt_task_start (Native API).
What happens if this entry function reaches its end or a return within the 
function is
called?

I have made a simple example that lead to strange effects.
In my example (see complete C Code in attachement) I create to tasks
that do the same.
The entry functions look like:

void taska(void *cookie)
{
    RTIME delay;
    int i;
    printf("Hi, I am task A %s\n", (char*)cookie);
    delay = 100000;

    for (i=0; i<200; i++)
    {
        rt_task_sleep(delay);
    }

    printf("This is the end of A\n");
    // rt_task_delete(0);
}
When I do not place the rt_task_delete(0) at the end of the function
my second task will never reach the end with the second printf.
Whenever I use rt_task_delete(0) at the end of the function it works perfectly.

My question is now: What happens if the task's entry function returns?

Thanks for any feedback on that question.

Regards

Mathias


-- 
Mathias Koehrer
[EMAIL PROTECTED]


Viel oder wenig? Schnell oder langsam? Unbegrenzt surfen + telefonieren
ohne Zeit- und Volumenbegrenzung? DAS TOP ANGEBOT JETZT bei Arcor: günstig
und schnell mit DSL - das All-Inclusive-Paket für clevere Doppel-Sparer,
nur  44,85 €  inkl. DSL- und ISDN-Grundgebühr!
http://www.arcor.de/rd/emf-dsl-2

Attachment: multitasks.c.gz
Description: PostScript document

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

Reply via email to