|Installation of the RTAI-Lab
The first part is the installation of the mesa 3D libraries which have dependencies for ELFK which in turn xrtailab uses to display executed code, the example described later uses this to display a sine wave.
So as root:
Download MesaLib-6.x.x.tar.bz2 from http://sourceforge.net/projects/mesa3d
tar jxvf MesaLib-6.x.x.tar.bz2
make linux-x86 && make install
The ELFTK library is needed by the xrtailab for various windows as well as for the oscilloscope display, downloaded using the following subversion commands to get the latest versions
svn co https://ede.svn.sourceforge.net/svnroot/ede/trunk/efltk
svn co https://ede.svn.sourceforge.net/svnroot/ede/trunk/ede
./configure –disable-mysql –disable-unixODBC
We need to edit /etc/ld.so.conf and add the path /usr/local/lib
Then run /sbin/ldconfig to update the library database
Used to increase the functionality of the RTAI at a later stage
tar –xvxf comedib-0.8.1.tar.gz
tar –xvzf comedi-0.7.76.gz
prepare the build system for compilation, check versions, etc.
make && make install
Very similar to the Comedilib installation
cp include/linux/comedi.h include/linux/comedilib.h /usr/include
cp include/linux/comedi.h include/linux/comedilib.h /usr/local/include
ln –s /usr/include/comedi.h /usr/include/linux/comedi.h
ln –s /usr/include/comedilib.h /usr/include/linux/comedilib.h
We need to recompile the RTAI to install the RTAI-Lab and include Comedi that has just been installed.
Comedi support over LXRT [*]
Include the comedi installation directory (where libcomedi.a, comedi.h and comedi.h can be found)
Include the ELFTK Installation Directory
Exit and save configuration
Make && make install
The version used here is 4.1.2 and is downloaded from scilab.org to the /usr/local directory.
tar zxvf scilab-4.1.2-src.tar.gz
Since fedora core 5 is used here the following command is used:
Note: at this point do NOT make install
ln –s /usr/localscilab-4.1.2/binscilab/usr/local/bin/scilab
To check that scilab runs correctly, type
In the command line if it opens with errors then restart the installation and use dmesg to check for errors with the installation.
These include the blocks that will be for Real time code generation developed by Roberto bucher. Again the commands used for the correct installation are shown below.
Download the add-on tar ball from http://web.dti.supsi.ch/~bucher/scilab.html
tar zxvf scilab-4.1.2-rtailab.tgz
This creates a file in the USERNAME/.Scilab/scilab-4.1.2/ called .scilab which must be edited and added with the lines
%scicos_menu($+1)=['RTAI','RTAI CodeGen','Set Target']
This adds menus to the Scicos application, the menu button for the RTAI code generation and another for the actual link to the RTAI blocks under the edit heading.
To finish, Scilab is added to the executable path using
ln -s /usr/local/scilab-4.x.x/bin/scilab scilab
This concludes the installation of the RTAI-lab