All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jan Kiszka <jan.kiszka@siemens.com>
To: Gilles Chanteperdrix <gilles.chanteperdrix@xenomai.org>
Cc: "xenomai@xenomai.org" <xenomai@xenomai.org>
Subject: Re: [Xenomai] Write a hard real time usb driver
Date: Mon, 03 Nov 2014 18:22:34 +0100	[thread overview]
Message-ID: <5457B9DA.5020407@siemens.com> (raw)
In-Reply-To: <20141103171457.GJ9327@sisyphus.hd.free.fr>

On 2014-11-03 18:14, Gilles Chanteperdrix wrote:
> On Mon, Nov 03, 2014 at 06:12:11PM +0100, Jan Kiszka wrote:
>> On 2014-11-03 09:03, Jeroen Van den Keybus wrote:
>>>> I try to write a hard real time usb driver. I communicate my device  using
>>>> open(), read() etc. My device is a gpio module.
>>>
>>>
>>> I assume you want to control an USB host controller using a GPIO interface ?
>>>
>>>
>>>> I am coding a kernel module
>>>> to communicate the device using xenomai on real time. But I am not sure
>>>> that this way is reasonable. If I should going on this way, what should I
>>>> implement? Could you give me some example or link to write hard real time
>>>> usb driver for* physical* device?
>>>
>>>
>>> I cannot help you with that, but one important issue to consider is that
>>> the USB protocol itself operates with small, hardware controlled time slots
>>> of 1 ms (USB1.x) or 125 usec (USB2.0). You may therefore need a significant
>>> amount of software to properly distribute real-time traffic in these -
>>> essentially asynchronous - slots. The latency of a real-time process
>>> waiting for USB data can therefore also be as large as the time slot
>>> duration. If your real-time requirements are modest, you may be able to
>>> live with that. Still, count on a major software effort: just have a look
>>> at the Linux USB driver framework.
>>>
>>> Alternatively, you could check if you can synchronize your real-time
>>> process with the USB controller frame rate.
>>>
>>
>> FWIW, we still don't have USB 2.0 support (though I vaguely remember
>> previous efforts in that direction),
> 
> There is one here:
> http://sourceforge.net/projects/usb20rt.berlios/
> 
> Have not looked at the code though.

Yeah, that's the one I recalled. Seems dead, unfortunately.

Jan

-- 
Siemens AG, Corporate Technology, CT RTC ITP SES-DE
Corporate Competence Center Embedded Linux


  reply	other threads:[~2014-11-03 17:22 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-11-03  0:10 [Xenomai] Write a hard real time usb driver Seda Seda
2014-11-03  8:03 ` Jeroen Van den Keybus
2014-11-03 17:12   ` Jan Kiszka
2014-11-03 17:14     ` Gilles Chanteperdrix
2014-11-03 17:22       ` Jan Kiszka [this message]
2014-11-03 19:30         ` Hasret Sarıyer

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=5457B9DA.5020407@siemens.com \
    --to=jan.kiszka@siemens.com \
    --cc=gilles.chanteperdrix@xenomai.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.