Difference between revisions of "Installation/Linux"
HectoPascal (talk | contribs) |
HectoPascal (talk | contribs) |
||
Line 75: | Line 75: | ||
== Manual Installation of Individual Packages == | == Manual Installation of Individual Packages == | ||
Users of | Users of other Linux flavors or anyone needing manual control of each individual package can install them independently. The list of dependencies of the Debian package is located in the [[http://cvs.savannah.gnu.org/viewvc/paparazzi/paparazzi3/debian/control.etch?revision=1.16&view=markup <tt> debian/control.etch</tt>]] file and may help users of other distributions. | ||
The binary packages and some corresponding source tarballs can be downloaded from | |||
http://paparazzi.enac.fr/debian/dists/etch/main/binary-i386/ | |||
For distributions using RPM packaging, the [[http://packages.debian.org/unstable/source/alien alien]] can be used to translate a .deb package into a .rpm packages. | |||
== Software Updates == | == Software Updates == |
Revision as of 10:49, 3 January 2008
Precompiled binaries can be downloaded and executed with the paparazzi-bin package but to maintain the power and flexibility of open-source code, most operations within Paparazzi involve recompilation of autopilot and/or ground station code. Therefore the typical installation requires all of the necessary C and OCaml compilers as well as some XML and Ivy handlers. These tools are provided by the paparazzi-dev package.
The Paparazzi sources are hosted by Savannah.
The Paparazzi packages are hosted at the ENAC repository.
Installation on Debian based distributions
Paparazzi is packaged for Debian as well as all of its dependencies. The repository hosted at ENAC holds their latest version.
Installation from the Command Line
Just add the following line to your repository list (/etc/apt/sources.list). Replace etch by sarge (oldstable distribution) or sid (unstable distribution) if needed. Note: It is no longer required to specify both sarge and etch.
File: /etc/apt/sources.list |
deb http://paparazzi.enac.fr/debian etch main |
Then, update your sources and install the precompiled binaries or the dependencies needed for recompiling from the source (dev), and the cross-compiler (arm7) :
apt-get update apt-get install paparazzi-bin apt-get install paparazzi-dev apt-get install paparazzi-arm7
Note: It is not recommended to install both paparazzi-bin and paparazzi-dev. While the bin package is self-contained and should be sufficient for users who do not want to patch the code, the dev meta-package provides only the tools to compile the source code which must be separately downloaded, from an archive or the CVS repository.
Note: Installation works fine on the Ubuntu 7.10 distribution (using the etch distro).
Optional/Obsolete Packages
Users of older AVR based boards will also need the paparazzi-avr package.
Extra for Ubuntu 7.04 and 7.10
The Braille TTY driver interferes with FTDI USB Serial adapters and should be removed:
sudo apt-get remove brltty
Installation thru Synaptic Package Manager
- Launch Synaptic Package Manager (Applications/System Tools Menu)
- In Settings/Repositories, add a new repository on URI = http://paparazzi.enac.fr/debian, Distribution = etch (or sarge or sid), Section = main
- Search for paparazzi-bin, paparazzi-dev, and paparazzi-arm7 packages (use the Search button)
- Mark them for installation (right-click on package names)
- Left-click on Apply
Installing the Source Code (not needed with paparazzi-bin)
After the paparazzi-dev package is installed the complete source code should be downloaded from the CVS repository. See the project page at Savannah for more details. From the directory of your choice type:
cvs -z3 -d:pserver:anonymous@cvs.savannah.nongnu.org:/sources/paparazzi co paparazzi3
This will download all of the code and install it into paparazzi3/
If you cannot use the CVS install, dayly updated tarballs can also be fetched from the Downloads page.
Launching the Software
If you are using the paparazzi-bin package or the Live-CD, just launch the paparazzi binary application and you will be guided through the installation of your personal configuration files.
If you are using the source code, the first step is to compile it. From the paparazzi3 directory (cd paparazzi3), run
make
You will have to run these command after each update of the source (cvs update command). Launch the software from the paparazzi3 directory with
./paparazzi
From the Paparazzi_Center Paparazzi Center interface, select the MJ5 aircraft, select the sim target and Build it. Then Execute the Simulation session.
If (and only if) you want to directly launch some Paparazzi agents (the Tools of the Paparazzi_Center Paparazzi Center), without using the Paparazzi Center, you must have the Paparazzi source and home environment variables set correctly in your shell. These variables can be automatically set in your shell by adding the following lines to your .bashrc file:
File: /home/your_username/.bashrc |
export PAPARAZZI_HOME=your paparazzi3 directory export PAPARAZZI_SRC=your paparazzi3 directory |
If you wish to manually set the env variables (i.e. when compiling a backup copy of your code in a different folder) execute the following command from the folder you wish to set as your active paparazzi folder:
export PAPARAZZI_HOME=`pwd`;export PAPARAZZI_SRC=`pwd`
Verify that your variables are set correctly with the following command:
env | grep PAPARAZZI
which should return the following:
PAPARAZZI_HOME=your paparazzi3 directory PAPARAZZI_SRC=your paparazzi3 directory
Manual Installation of Individual Packages
Users of other Linux flavors or anyone needing manual control of each individual package can install them independently. The list of dependencies of the Debian package is located in the [ debian/control.etch] file and may help users of other distributions.
The binary packages and some corresponding source tarballs can be downloaded from
http://paparazzi.enac.fr/debian/dists/etch/main/binary-i386/
For distributions using RPM packaging, the [alien] can be used to translate a .deb package into a .rpm packages.
Software Updates
Paparazzi is a very rapidly evolving project and as such, you will find that variables and functions are frequently added, changed, or removed. Update your software with care and caution, and always test the functionality on the ground and in the air as some updates will affect tuning parameters. Your airframe file will not be updated by the CVS system and therefore any new or modified variable names will need to be added manually. The compiler will usually identify the problem variables at which point you can look at some of the most recent airframe files on the CVS to find the proper syntax. See the Compiling page for more help if needed.
That said, keeping your software up to date is easy with the CVS system. The system will compare all source code files with the server and update any that are needed, automatically merging any minor changes that you have incorporated along the way.
To download and automatically merge any updated source files, run the following command from your Paparazzi directory
cvs update -d
where the -d is needed to get any new directories.
After any CVS update or source code modification the code can be recompiled from your paparazzi3 directory with the following command:
make
The make command will only recompile portions of the software where changed have been detected. If it does not behave as expected you can deleted all compiled files and recompile from scratch with the following commands:
make clean make
See the Compiling page for more info.
Users making changes to their code structure may prefer to have more control over the updating and merging process and may wish to install and use tkcvs instead which provides highlighted comparisons of any files that differ between your code and the CVS server and allows for a file by file update.
To update your Linux distribution as well as any dependencies of Paparazzi (seldom necessary), run the following as root:
apt-get update apt get upgrade
LiveCd
The LiveCD is an easy way to test Paparazzi: no installation is required and no changes are made to your computer. Simply burn the image as a boot CD and reboot! The LiveCD includes Linux and the complete paparazzi binary package (code source, tools and cross compilers). It is intended for demonstration only and not frequently updated but it contains the complete system and can store changed files on a pen drive or compressed file on your hard drive so that it can compile, flash, and operate any aircraft, albeit slowly.
The CD image is available from the Downloads page.
The Paparazzi demo is launchable on the Live CD from the Paparazzi icon.
Knoppix allows for all the user data to be saved on a hard disk partition (most file systems are supported) or on a removable device (typically a USB pendrive). Note that this action is not destructive: the user data tree is compressed and stored on your file system as a single file (knoppix.img).
- From the Knoppix menu (second from bottom left), choose Configure, Create a persistent KNOPPIX disk image
- Choose your media (be sure to connect your USB pendrive before booting!)
- Choose if you want an encrypted filesystem (to protect your flight plan designed for the next MAV competition :-) )
- Choose the size of your home directory (100Mb is recommended)
On the next reboot, this saved state will be automatically located and loaded.
Using this persistent feature, the Paparazzix Live CD can really be used to configure, simulate and fly an aircraft with the Paparazzi system.
The Live CD can also be used to install a Debian system on the hard disk, using the knoppix-installer command. Be sure to backup the hard disk before trying ...