Sun, 23 Apr 2000 Muhammad Ali Imran wrote:
> Can we make an X-windows application realtime...... its mouse responses etc
> all should be realtime....

What kind of latencies are we dealing with here? Is it just a matter of "rock
solid feel" and reliability, or is it also about smooth, full frame rate
(60-200 Hz) animation?

> From the explanation in documentation X Windows run on the linux kernel
> which is running as a least priority task on the rt microkernel......

Yes, that's about it. X is a user space driver (ie a daemon with direct
hardware access permissions) running as a normal Linux process. If you want
real time in user space, you can use the lowlatency patch;

        http://www.gardena.net/benno/linux/audio/

which should be enough for graphics. It can handle audio with 2-3 ms rock
solid code -> output latency; video is in the range 15 ms/frame. However, real
time threads have to run as SCHED_FIFO or SCHED_RR, which doesn't work too well
with X...

As an alternative to X (which is a complex beast not at all written for real
time video), you could check out svgalib. The easiest way would be to set up a
display from user space, and then use the video RAM directly from an RTL
thread, or from a SCHED_FIFO thread under Linux/lowlatency. In the RTL case,
you also have to port the mouse driver (and keyboard?) to RTL, if you need "RTL
quality real time" all the way through. For Linux/lowlatency, I think you're
fine with a SCHED_FIFO thread that's synchronized with the vertical blanking
(you may need to hack a kernel driver for that - not sure), and nonblocking I/O
for mouse and keyboard. (Works great with audio [block on read or write] + MIDI
[nonblocking] for soft synths and the like.)


David Olofson
   Programmer
   Reologica Instruments AB
   Scheelevägen 30
   S-223 63  LUND
   +46 (0)46 - 12 77 60
-- [rtl] ---
To unsubscribe:
echo "unsubscribe rtl" | mail [EMAIL PROTECTED] OR
echo "unsubscribe rtl <Your_email>" | mail [EMAIL PROTECTED]
---
For more information on Real-Time Linux see:
http://www.rtlinux.org/rtlinux/

Reply via email to