Difference between revisions of "Booz"
Line 1: | Line 1: | ||
== Overview == | == Overview == | ||
Booz is an attempt at extending paparazzi to VTOLs. At the current stage of the project, the system provides a quite satisfying attitude control (auto1) and is able to more or less navigate autonomously. It is able to use simple paparazzi flight plans ( only go instructions ) and uses paparazzi telemetry and datalink, which means you can use all the paparazzi ground | Booz is an attempt at extending paparazzi to VTOLs. At the current stage of the project, the system provides a quite satisfying attitude control (auto1) and is able to more or less navigate autonomously. It is able to use simple paparazzi flight plans ( only go instructions ) and uses paparazzi telemetry and datalink, which means you can use all the paparazzi ground segment applications ( plotter, settings, gcs, etc...) | ||
It flies on a variety of quadrirotor platforms | It flies on a variety of quadrirotor platforms | ||
Line 15: | Line 15: | ||
[[Image:booz2_a4.jpg]] | [[Image:booz2_a4.jpg]] | ||
The current autopilot consist in 3 boards | |||
The main board, comprising power supply, a LPC2148 and a barometer. | |||
[[Image:booz2_main.jpg]] | |||
The imu board, comprising 3 gyrometers, 3 accelerometers, 3 magnetometers and a 16 bits ADC. | |||
[[Image:booz2_imu.jpg]] | |||
The GPS board, using a LEA-5H by ublox | |||
[[Image:booz2_gps.jpg]] | |||
Revision as of 10:15, 26 July 2009
Overview
Booz is an attempt at extending paparazzi to VTOLs. At the current stage of the project, the system provides a quite satisfying attitude control (auto1) and is able to more or less navigate autonomously. It is able to use simple paparazzi flight plans ( only go instructions ) and uses paparazzi telemetry and datalink, which means you can use all the paparazzi ground segment applications ( plotter, settings, gcs, etc...)
It flies on a variety of quadrirotor platforms
and less common vehicles
The current autopilot consist in 3 boards
The main board, comprising power supply, a LPC2148 and a barometer.
The imu board, comprising 3 gyrometers, 3 accelerometers, 3 magnetometers and a 16 bits ADC.
The GPS board, using a LEA-5H by ublox
Running a simulator : quick start guide
- Extract a copy of paparazzi3 svn
svn co svn://svn.savannah.nongnu.org/paparazzi/paparazzi3/trunk paparazzi3
- Install all required dependancies
apt-get install paparazzi-dev libtool
- Compile JSBSIM
cvs -z3 -d:pserver:anonymous@jsbsim.cvs.sourceforge.net:/cvsroot/jsbsim co -P JSBSim cd JSBSim ./autogen.sh ./configure --enable-maintainer-mode --enable-compile-warnings --enable-libraries --enable-shared --prefix=/opt/jsbsim make sudo make install
here is a patch to silent warnings
- Compile paparazzi
cd paparazzi3/trunk make
- Compile the vehicle
make AIRCRAFT=BOOZ2_A1 clean_ac sim
- Start paparazzi_center if you want click to start programs
./paparazzi
- Start messages to watch the middleware activity ( from the tool menu of paparazzi center) or with
./sw/ground_segment/tmtc/messages
- Start the sim
LD_LIBRARY_PATH=/opt/jsbsim/lib ./var/BOOZ2_A1/sim/simsitl
You should now see activity in the "messages" window
- Plot the value of a message field.
start 'plotter' ( from the tool menu of paparazzi center) or with
./sw/logalizer/plotter
for example drag the label 'int32 phi' from the BOOZ2_FP message to the drawing area of the plotter
- Use the datalink to change the temetry mode
start 'settings' ( from the tool menu of paparazzi center) or with
./sw/ground_segment/tmtc/settings -ac BOOZ2_A1
start 'server' to dispatch datalink messages ( from the tool menu of paparazzi center) or with
./sw/ground_segment/tmtc/server
change the field "telemetry" on the first page to "Att loop" and send by pressing the green check button. THe label on the left or the drop box should change to "Att loop" confirming your essage has been received. "message" should now show that the message "BOOZ2_STAB_ATTITUDE" is received
- Use flightgear to visualize your vehicle
If you want a view of a quadrotor in flightgear, make a link from
/usr/share/games/FlightGear/Models/Aircraft/paparazzi to PAPARAZZI_SRC/conf/simulator/flightgear/
start flighgear with
fgfs --fdm=null --native-gui=socket,in,30,,5501,udp --prop:/sim/model/path=Models/Aircraft/paparazzi/mikrokopter.xml
restart your simulator with
LD_LIBRARY_PATH=/opt/jsbsim/lib ./var/BOOZ2_A1/sim/simsitl --fghost 127.0.0.1
- Save you session
Tunning the attitude control loop
Here we are going to use the simulator to demonstrate a way of tunning the attitude control loop.
- Restart your previous session
- Set telemetry mode to "Att loop"
- Display two real time plotter windows
In the first one, plot the field "m_phi" from the "BOOZ2_STAB_ATTITUDE" message. This is our estimation of roll angle. On top of that, plot the field "phi" from the "BOOZ2_STAB_ATTITUDE_REFERENCE" message. This is our reference roll angle, that is, the roll value we are trying to achieve.
In the second plotter, plot the fields "delta_a_fb" and "delta_a_ff". Those are respectively the feddback and feedforward part of our roll command. The sum of those two terms is what is used as roll command.The feedforward part is the part used to follow our trajectory and the feedback part is the part used to reject perturbations.
- In "Settings", go to the "Att Loop" tab
We notice that the vehicle doesn't follow accurately the step trajectory we are trying to make him do.
Start by setting the value of the proportional gain ('pgain_phi') to 1000 instead of 400. The vehicle now follows the trajectory faster but overshoots. To prevent that, increase the value of the derivative gain ('dgain p') from -300 to -700.
If you look at the plotter where you're ploting the commands, you'll notice that during steps, the feedback command has to work hard. This means that our feedforward command is badly tunned, and namely not working hard enough.Increase the value of the feedforward gain ('ddgain p') from 300 to 540. You'll notice that now the feedback command has becomed marginal during the steps. This is the right value for the gain. Anything bigger will make the feedback command fight against the feedforward command during steps, anything smaller will make the feedback command have to complement the feedforward command.
And by now, you should have found the rounding bug I'm fighting with