ArduPilot Programming Libraries
The the libraries are shared with Copter, Plane and Rover. Below is a high level list of libraries and their function.
Core libraries:
- AP_AHRS - attitude estimation using DCM or EKF
- AP_Common - core includes required by all sketches and libraries
- AP_Math - various math functions especially useful for vector manipulation
- AC_PID - PID controller library
- AP_InertialNav - inertial navigation library for blending accelerometer inputs with gps and baro data
- AC_AttitudeControl -
- AP_WPNav - waypoint navigation library
- AP_Motors - multicopter and traditional helicopter motor mixing
- RC_Channel - a library to more convert pwm input/output from APM_RC into internal units such as angles
- AP_HAL, AP_HAL_AVR, AP_HAL_PX4 - libraries to implement the “Hardware abstraction layer” which presents an identical interface to the high level code so that it can more easily be ported to different boards.
Sensor libraries:
- AP_InertialSensor - reads gyro and accelerometer data, perform calibration and provides data in standard units (deg/s, m/s) to main code and other libraries
- AP_RangeFinder - sonar and ir distance sensor interfaced library
- AP_Baro - barometer interface library
- AP_GPS - gps interface library
- AP_Compass - 3-axis compass interface library
- AP_OpticalFlow - optical flow sensor interface library
Other libraries:
- AP_Mount, AP_Camera, AP_Relay - camera mount control library, camera shutter control libraries
- AP_Mission - stores/retrieves mission commands from eeprom
- AP_Buffer - a simple FIFO buffer for use with inertial navigation