MAV_AUTOPILOT describe type of autopilot(Flight Controller board)
ex. PIXHAWK,ArduPilotMega / ArduCopter
Ref:
// Auto Pilot modes // ---------------- #define STABILIZE 0 // hold level position #define ACRO 1 // rate control #define ALT_HOLD 2 // Altitude Hold #define AUTO 3 // Waypoint #define GUIDED 4 // Hold a single location from command #define LOITER 5 // Hold a single location #define RTL 6 // return to launch #define CIRCLE 7 // orbit around a single location #define LAND 9 // Landing #define OF_LOITER 10 // Hold a single location using optical flow sensor #define DRIFT 11 // DRIFT mode (Note: 12 is no longer used) #define SPORT 13 // earth frame rate control #define FLIP 14 // flip the vehicle on the roll axis #define AUTOTUNE 15 // autotune the vehicle's roll and pitch gains #define POSHOLD 16 // position hold with manual override #define NUM_MODES 17
base_mode & MOTORS_ARMED) >> 7
typedef union {
float floatingPoint;
byte binary[4];
} binaryFloat;
binaryFloat temp;
temp.floatingPoint = 3.1416;
Serial.write(temp.binary[3]);
Serial.write(temp.binary[2]);
Serial.write(temp.binary[1]);
Serial.write(temp.binary[0]);
git clone git://github.com/mavlink/mavlink.git
sudo apt-get install python-matplotlib
cd ~ mkdir -p src cd src git clone https://github.com/mavlink/mavlink/ cd mavlink/pymavlink python setup.py install --user
export PYTHONPATH="$HOME/.local/lib/python2.6/site-packages/:$PYTHONPATH" export PATH="$HOME/.local/lib/python2.6/bin/:$PATH"
self.setStyleSheet('font-size: 8pt; font-family: Tahoma;')