From: Gilles Chanteperdrix <gilles.chanteperdrix@xenomai.org>
To: Moustapha Bikienga <mbikienga@gmail.com>
Cc: xenomai@xenomai.org
Subject: Re: [Xenomai] Posix_skin_periodic_tasks
Date: Tue, 29 May 2012 19:31:06 +0200 [thread overview]
Message-ID: <4FC507DA.6070209@xenomai.org> (raw)
In-Reply-To: <CANzShzfFDnC6C_v4-Xv_dxaX70kgP1vYcRqc2kfYVAj-Qxn5+g@mail.gmail.com>
On 05/29/2012 03:24 PM, Moustapha Bikienga wrote:
> Hi.
>
> I want to write periodic tasks by using POSIX skin in userspace. My Xenomai
> version is 2.6
> Where can I see some examples ?
"cyclictest" contained in xenomai sources is an example of periodic
task, but it may not be easy to read. The portable way of doing this is
to use clock_nanosleep with the TIMER_ABSTIME flag, updating the struct
timespec argument by adding the fixed period.
The non portable way is to use pthread_make_periodic_np and pthread_wait_np
Documentation of the various services:
http://www.xenomai.org/documentation/xenomai-2.6/html/api/group__posix__time.html#ga924d51d78cdcd9d7dee2613fb3a33cd1
http://www.xenomai.org/documentation/xenomai-2.6/html/api/group__posix__thread.html#gafe8deaa3c89e0a07e59f0e58f9ec1473
http://www.xenomai.org/documentation/xenomai-2.6/html/api/group__posix__thread.html#ga1f18e6e7dd5342463ca8546ef3a36c34
--
Gilles.
prev parent reply other threads:[~2012-05-29 17:31 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-05-29 13:24 [Xenomai] Posix_skin_periodic_tasks Moustapha Bikienga
2012-05-29 17:31 ` Gilles Chanteperdrix [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4FC507DA.6070209@xenomai.org \
--to=gilles.chanteperdrix@xenomai.org \
--cc=mbikienga@gmail.com \
--cc=xenomai@xenomai.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.