From: Gilles Chanteperdrix <gilles.chanteperdrix@xenomai.org>
To: Andy Pugh <andy@bodgesoc.org>
Cc: "xenomai@xenomai.org" <xenomai@xenomai.org>
Subject: Re: [Xenomai] Dedicated Core?
Date: Mon, 31 Mar 2014 14:24:02 +0200 [thread overview]
Message-ID: <53395E62.4070005@xenomai.org> (raw)
In-Reply-To: <CAN1+YZXRk1abosuhKawqxS=FwuLj1anjZb8Ezt4F9224WNzAzQ@mail.gmail.com>
On 03/31/2014 02:19 PM, Andy Pugh wrote:
> On 31 March 2014 12:29, Gilles Chanteperdrix
> <gilles.chanteperdrix@xenomai.org> wrote:
>
>> In the end, Andrey succeeded to have precise control by using timers,
>> in kernel-space, instead of threads in user-space, and a little trick:
>> waking up early and spinning waiting for the target time.
>
> LinuxCNC is rather tightly wedded to the thread model. The PWM /
> Stepgen / Encoder modules already exist and are in use on many
> machines.
> It is possible to run LinuxCNC with Xenomai in both kernel mode and
> user mode, but for reasons that I am not clear on the conclusion has
> been that user mode is preferable.
> (This may not be the same distinction as you are making).
>
I do not advocate putting everything in kernel-space, like in the old
days. What I mean is that the user/kernel interface, should act as an
"hardware abstraction layer". So, for instance, for a PWM, the interface
between driver and application should be ioctl(s) to pass period and
duty cycle. The driver should take care of the low-level details of
toggling the GPIO for the given period and duty cycle, and the
application should only call the ioctls when it wants to change the
period or duty cycle.
--
Gilles.
prev parent reply other threads:[~2014-03-31 12:24 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-03-30 20:49 [Xenomai] Dedicated Core? Charles Steinkuehler
2014-03-30 21:41 ` Gilles Chanteperdrix
2014-03-30 22:04 ` Charles Steinkuehler
2014-03-30 23:20 ` Lennart Sorensen
2014-03-30 23:22 ` Gilles Chanteperdrix
2014-03-31 11:29 ` Gilles Chanteperdrix
2014-03-31 12:19 ` Andy Pugh
2014-03-31 12:24 ` 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=53395E62.4070005@xenomai.org \
--to=gilles.chanteperdrix@xenomai.org \
--cc=andy@bodgesoc.org \
--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.