There are a few steps you need to follow in order to install RTAI on your linux: |
There are a few steps you need to follow in order to install RTAI on your linux: (for some real handholding see RtaiSteps) |
1. Get a kernel source from http://www.kernel.org . For example 2.4.21(http://www.kernel.org/pub/linux/kernel/v2.4/linux-2.4.21.tar.bz2)
2. Get a RTAI-package from http://www.rtai.org . For example RTAI-3.1 (http://download.gna.org/rtai/stable/v3/rtai-3.1.tar.bz2)
3. Unpack the kernel source:
# cd /usr/src
# tar xvjf linux-2.4.21.tar.bz2
# ln -s linux-2.4.21 linux
4. Unpack RTAI to /usr/src/rtai-3.1:
# tar xvjf rtai-3.1.tar.bz2
# ln -s rtai-3.1 rtai
5. Patch the kernel (this will modify the kernel source to contain the RTAI-extensions):
# cd /usr/src/linux
# patch -p1 < ../rtai/rtai-core/arch/i386/patches/hal12-2.4.21.patch
6. Configure the kernel:
# make menuconfig
Make sure that
- "Adeos" is selected
- "Loadable module support -> Set version information on all module symbols" is disabled
- Disable all Power Management options.
7. Compile the kernel:
# make dep
# make bzImage
# make modules
# make modules_install
8. Install the kernel:
# cd /usr/src/linux
# cp arch/i386/boot/bzImage /boot/vmlinuz-2.4.21-adeos
# cp System.map /boot/System?.map-2.4.21-adeos
9. Modify LILO or GRUB for the new kernel
10. After the kernel is compiled and installed successfully, compile RTAI:
# cd /usr/src/rtai
# make menuconfig
# make
# make install
11. If no errors occured, reboot now, select the new kernel from the GRUB/LILO menu.
12. To test RTAI:
# cd /usr/realtime/testsuite/kern/latency/
# ./run