Slackware RTAI support

42 views
Skip to first unread message

biff...@yahoo.co.uk

unread,
Jan 31, 2010, 9:50:10 AM1/31/10
to Bifferboard

I've cut another release of the Slackware tarball, which I hope will
be useful for electronics hobbyists wanting to use a Bifferboard
instead of a microcontroller for time-critical tasks.

Of course, I've added the obligatory 'LED blink' programming example,
more details here:
http://sites.google.com/site/bifferboard/Home/desktop-linux-distributions/slackware/rtai

Debian enthusiasts wanting to keep up with my efforts will find it
useful to read here: http://wiki.linuxcnc.org/cgi-bin/emcinfo.pl?Debian_Lenny_Compile_RTAI

Personally, I think this is quite significant, but I have problems to
get across to people just *how* significant, and I suspect there will
not be much interest in trying this out. For people who understand
what RTAI is, I'd welcome suggestions of simple projects that might
get the message across more visibly. I was thinking about a POV
(Persistence of Vision) type of project, which is fun, nice to look at
etc..., but if you have any ideas of things that I can knock up, and
maybe video that would be useful. Hopefully you can think of
something that won't cost me an arm and a leg to buy the bits for.

kind regards,
Biff.

brunoamui

unread,
Jan 31, 2010, 12:15:18 PM1/31/10
to Bifferboard
I was planning to do a port of xenomai to the bifferboard, as it is
what i use in more complicated projects.
i think i'm going to start with some control projects, maybe a motor
controller, then some robotics. I just really need to work my
algorithms to reduce float operations. Anyway, you will be seeing some
bifferbots in the future.

On Jan 31, 12:50 pm, "biffe...@yahoo.co.uk" <biffe...@yahoo.co.uk>
wrote:


> I've cut another release of the Slackware tarball, which I hope will
> be useful for electronics hobbyists wanting to use a Bifferboard
> instead of a microcontroller for time-critical tasks.
>
> Of course, I've added the obligatory 'LED blink' programming example,

> more details here:http://sites.google.com/site/bifferboard/Home/desktop-linux-distribut...

Sunspot

unread,
Jan 31, 2010, 11:16:59 PM1/31/10
to Bifferboard
Thanks for the intro to this.
I suspect the average PIC hardware hobby type has not heard of RTAI (I
had not).
I once tried to control a servo from Linux but the jitter was obvious.
So I added a PIC as i2c slave and also gained, as a bonus, D to A and
lots of GPIO for very little extra power consumption.
The BB on its own with RTAI might be perfect for simple systems - but
for a complex robot may need more lines.


On Jan 31, 2:50 pm, "biffe...@yahoo.co.uk" <biffe...@yahoo.co.uk>
wrote:


> I've cut another release of the Slackware tarball, which I hope will
> be useful for electronics hobbyists wanting to use a Bifferboard
> instead of a microcontroller for time-critical tasks.
>
> Of course, I've added the obligatory 'LED blink' programming example,

> more details here:http://sites.google.com/site/bifferboard/Home/desktop-linux-distribut...

Andrew Scheller

unread,
Feb 2, 2010, 12:14:21 PM2/2/10
to biffe...@googlegroups.com
I'd never heard of RTAI either, and I can't actually imagine using it myself...
although that doesn't stop me asking:

Could this be used to create a 'faster' i2c driver, for people that
(might?) need it?

Could this be used to 'emulate' hardware interrupts on the GPIO pins?

Lurch

> --
> You received this because you are subscribed to the "Bifferboard" Google group - honest!
> To unsubscribe from this group, send email to bifferboard...@googlegroups.com
>

biff...@yahoo.co.uk

unread,
Feb 2, 2010, 1:33:10 PM2/2/10
to Bifferboard

On Feb 2, 5:14 pm, Andrew Scheller <ya...@loowis.durge.org> wrote:
> I'd never heard of RTAI either, and I can't actually imagine using it myself...
> although that doesn't stop me asking:
>
> Could this be used to create a 'faster' i2c driver, for people that
> (might?) need it?

No.

> Could this be used to 'emulate' hardware interrupts on the GPIO pins?

Yes, but several GPIO pins already have interrupts, so there would be
little point.

RTAI is used if you want precise timing, and if you don't want the
scheduler to interrupt your task at inopportune moments. You can also
stop the scheduler by writing a kernel driver, assuming you have a
single CPU, and disabling interrupts and then doing a bunch of stuff
in your kernel module, but this is inconvenient for a number of
reasons:
1) You may interfere with your system clock in this way, because it's
interrupt won't get triggered
2) Other tasks will not get to run until you're done, and if that's a
long time you may have problems, like network connections timing out.
3) You cannot guarantee when you will next be called, and for some
applications that can be critical.

Imagine an application where you wanted to generate sound from one of
the GPIO pins. You can write a program to output different
frequencies, but the moment you load the system, those frequencies are
going to change, so this is an example of something you simply
couldn't do without RTAI, unless you had external hardware. It may be
something that you think is just silly in the first place (sound chips
are cheap, blah, blah blah), but that's beside the point. The fact
is, you have the Bifferboard, it's an off-the-shelf bit of kit you
already bought, far better to download a program to do what you want,
than mess about wiring up external silicon.

There is little you can do with RTAI that you can't do with a
dedicated external AVR or PIC though.

regards,
Biff.


Andrew Scheller

unread,
Feb 7, 2010, 7:55:11 PM2/7/10
to biffe...@googlegroups.com
>> Could this be used to 'emulate' hardware interrupts on the GPIO pins?
> Yes, but several GPIO pins already have interrupts, so there would be
> little point.

Ooh, didn't realise that, never seen it mentioned anywhere. Which GPIO
pins have interrupts?

*rummage*
Ahhh, this is why I thought none of the GPIOs had interrupts
http://groups.google.com/group/bifferboard/browse_thread/thread/18296618155a1d23/17de5329f5a5438f#780298c10b3ec62f

Andy

biff...@yahoo.co.uk

unread,
Feb 8, 2010, 7:31:22 AM2/8/10
to Bifferboard

One of the pins is CTS which can have an associated interrupt. So the
pin has 3 functions: JTAG, GPIO or CTS for the first. serial port.
Tricky to make it work without messing up your serial port
communication, but possible nonetheless.

On Feb 8, 12:55 am, Andrew Scheller <ya...@loowis.durge.org> wrote:
> >> Could this be used to 'emulate' hardware interrupts on the GPIO pins?
> > Yes, but several GPIO pins already have interrupts, so there would be
> > little point.
>
> Ooh, didn't realise that, never seen it mentioned anywhere. Which GPIO
> pins have interrupts?
>
> *rummage*

> Ahhh, this is why I thought none of the GPIOs had interruptshttp://groups.google.com/group/bifferboard/browse_thread/thread/18296...
>
> Andy

Reply all
Reply to author
Forward
0 new messages