Captain's Universe Home
Captain's Universe Home
Cosmic Ray Muon DetectorTeleGarden Pages
Time on MarsBryophyllum Plants
Jupiter Radio AstronomyAncient Pages
Salzburg Tourist GuideEarth Magnetometer
  H O M E     AJAX & MORE     LINUX & MORE     RTAI     XENOMAI     ADEOS IPIPE      
    JAVA & BROWSERS     *NIX     ELECTRONICS     REVIEWS     ARTEMIA     FAIRY SHRIMP      



RTAI Installation Guide - Installation of RTAI with Kernel 2.6.7 (on Fedora Core 2):

UPDATE:
Meanwhile RTAI 3.1, RTAI 3.2 were released (RTAI 3.3 is coming soon) and kernel 2.6.14.3 is the most recent 2.6 kernel. The installation process is unchanged and the instructions below apply to any recent RTAI and kernel versions.

Unpack the kernel source:
# cd /usr/src
# tar xvjf linux-2.6.7.tar.bz2
# ln -s linux-2.6.7 linux
Unpack or copy RTAI to /usr/src/vesuvio or /usr/src/rtai-3.1.xxxx
# ln -s vesuvio rtai
or
# ln -s rtai-3.1xxxx rtai


Patch the kernel:
# cd /usr/src/linux
# patch -p1 < ../rtai/rtai-core/arch/i386/patches/hal6c1-2.6.7.patch
Copy the existing (Fedora) kernel config file to /usr/src/linux
# cp /boot/config-2.6.xxxx /usr/src/linux/.config
Configure the kernel:
# make menuconfig
(you need to "make menuconfig" even if you accept the default Fedora config!)

Make sure that
  • "Adeos" is selected (Adeos Support -> Adeos Support)
  • "Loadable module support -> Module versioning support" is disabled
  • "Kernel hacking -> Compile the kernel with frame pointers" is disabled
  • "Processor type and features -> Use register arguments" is disabled (CONFIG_REGPARM)



Compile the kernel:
# make
# make modules_install install

After the kernel is compiled and installed successfully, compile RTAI:
# cd /usr/src/rtai
# make menuconfig
If you want to do some serial port I/O enable "Add-ons -> Serial line driver"
(if you're new to RTAI just accept the default config - after saving the config wait until all configuration is done)
# make
# make install
If no errors occured, reboot now, select the new kernel from the GRUB menu. (so far Fedora 2 performs fine with the patched vanilla kernel 2.6.7)

To test RTAI:
# cd /usr/realtime/testsuite/kern/latency/
# ./run
Now you should see some min. max. latency output.

Two RTAI examples - FIFO and shared memory usage



TROUBLESHOOTING:

☯ If you get this error when running /usr/realtime/testsuite/kern/latency/run:
Error opening /dev/rtf/3
-or- Error opening /dev/rtf/1
-or- Error opening /dev/rtf/2
-or- Error opening /dev/rtf/3
-or- Error opening /dev/rtf/4
-or- Error opening /dev/rtf/5
-or- Error opening /dev/rtf/6
-or- Error opening /dev/rtf/7
-or- Error opening /dev/rtf/8
-or- Error opening /dev/rtf/9
then have a look if /dev/rtf exists (probably not) and if there are any nodes in it. If there are no nodes, create this shell script and run it:
#!/bin/bash
mkdir /dev/rtf
for n in `seq 0 9`
do
        f=/dev/rtf/$n
        mknod -m 666 $f c 150 $n
done
The nodes actually should have been created during "make install", but in case...
If /dev/rtf0 to /dev/rtf9 and /dev/rtai_shm are missing aswell, run this script:
#!/bin/bash
mknod -m 666 /dev/rtai_shm c 10 254
for n in `seq 0 9`
do
        f=/dev/rtf$n
        mknod -m 666 $f c 150 $n
done


If you get this error:
RTAI[hal]: ERROR, LOCAL APIC CONFIGURED BUT NOT AVAILABLE/ENABLED
pass "lapic" to the kernel in grub. e.g.:
title           RTAI 3.2 kernel 2.6.10
root            (hd0,0)
kernel          /boot/vmlinuz-2.6.10-adeos root=/dev/hda1 ro lapic
savedefault
boot


For further details see the Kernel Compilation HowTo!

Last-Modified: Sat, 04 Feb 2006 16:13:49 GMT

Google
 
Web www.captain.at
go to top
© 1996-2010 . All rights reserved.
No reproduction, distribution, publishing or transmission of the copyrighted materials at this site is permitted. Policy
go to top