[Date Prev][Date Next]
[Chronological]
[Thread]
[Top]
Re: [rtl] Would RTLinux work for this application?
Donald Gaffney wrote:
>
> Hello,
>
> I just discovered RTLinux yesterday, so please pardon my newbie-ness.
>
> I have the following feedback problem:
>
> - Collect 4 analog signals
> - Run some PID calculations
> - Dump 64 bits (digital) to an external control system
>
> This needs to occur at least every 100 microseconds (10 kHz).
I have a RT Linux based system composed of three tasks. The fastest
runs at 8Khz. This runs fine on a 486 66Mhz, system with 8MB RAM.
I do less per cycle then the above however but with slower hardware.
The trick is to (1) read the analog signal, then (2) start the A to D
conversion. In that order. This way you are not waiting for the
conversion to take place while in the RT task. I would estimate you
could do your task with only about 10% CPU utilization, leaving the rest
for "normal" Linux stuff.
For 10Khz use the RTC tied to an interrupt and make the task interrupt
driven. I think the sound example program is closest to what you want.
--
--Chris Albertson
chris@topdog.logicon.com Voice: 626-351-0089 X127
Logicon RDA, Pasadena California Fax: 626-351-0699
--- [rtl] ---
For more information on Real-Time Linux see:
http://rtlinux.cs.nmt.edu/