Juggling Molecules with Linux
An anonymous reader writes "This article at LinuxDevices.com describes an interesting project at the University of Vermont in which researchers use real-time Linux to build a laser trap that manipulates individual molecules by means of a computer-controlled laser beam. The project makes use of RTLinux, a real-time enhanced version of Linux that allows the system to process interrupts every 50 microsecond, sample new data, and timeshare the laser beam position. 'If the computer failed to respond, for even a millisecond, then we would drop the balls,' explained one of the researchers. Gives a whole new meaning to BSOD, eh?"
For a 200MHz Pentium (this is an old review), the testers tried sending one billion interrupts with a latency check. When they required 8 microsecond latency, they missed one interrupt in a billion. When they only needed 10ms latency, they didn't lose any.
Comparable figures are available for various real-time Linux systems. Note that these figures are for a 650MHz CPU. The times are slightly better than for QNX, but the CPU is 3x faster.
Bear in mind that "RTLinux" programs aren't running under Linux. They're running below Linux. They can't make most system calls, for example. QNX programs are ordinary programs, and can make system calls.
The Linux 2.6 kernel isn't bad, though. Running real-time with millisecond response as high-priority Linux threads can actually work in 2.6. In 2.4, no way. You have to be very careful not to load any high-latency drivers, though.
If you ever had to perform real time processing using Microsoft Windows you would regard the comment as kind. Windows employs a constant blizzard of interupts which makes response times unpredictable at this scale.
Actually the BSOD is the least of the problems, with lags and leads being the primary problem.