How openpilot/openpilot works
OpenPilot is an autopilot and ground-control platform for configurable vehicles. Its principal workflow is vehicle sensing and state estimation, followed by flight-mode/control decisions and actuator commands; UAVObjects carry shared state and UAVTalk provides a communications subsystem, while the Ground Control Station configures and monitors the vehicle. The README documents GCS-loaded programming-language configuration and a multi-platform package. Most flight-module wiring was not sampled, so those relationships are shown as unverified rather than asserted as direct calls.
Main entry points: uavobjectmanager.c UAVObject manager · stateestimation.c State estimation · manualcontrol.c Manual control · openpilotgcs Ground Control Station
Components 23
Flight runtime
- Sensor acquisition
flight/modules/Sensors/sensors.c - GPS decoding
flight/modules/GPS/GPS.c - State estimation
flight/modules/StateEstimation/stateestimation.c - Altitude estimation
flight/modules/Altitude/altitude.c - Attitude estimation
flight/modules/Attitude/attitude.c - Manual control
flight/modules/ManualControl/manualcontrol.c - Arming handler
flight/modules/ManualControl/armhandler.c - Stabilization loops
flight/modules/Stabilization/stabilization.c - Path planning
flight/modules/PathPlanner/pathplanner.c - Path following
flight/modules/PathFollower/pathfollower.c - Actuator output
flight/modules/Actuator/actuator.c - Airspeed sensing
flight/modules/Airspeed/airspeed.c
Vehicle data and links
- UAVObject manager
flight/uavobjects/uavobjectmanager.c - UAVTalk transport
flight/uavtalk/uavtalk.c - Telemetry
flight/modules/Telemetry/telemetry.c - Radio receiver
flight/modules/Receiver/receiver.c
Ground control
- Ground Control Station
ground/openpilotgcs - Flight log manager
ground/openpilotgcs/src/plugins/flightlog/flightlogmanager.cpp - Object generator
ground/uavobjgenerator/main.cpp - Vehicle configuration
Platform services
- Task scheduler
flight/pios/common/libraries/FreeRTOS/Source/tasks.c - Board I/O
flight/pios
Other components
- Pilot
Connections 23
- Pilot → Radio receiver: sends controls
- Radio receiver → Manual control: provides input
- Sensor acquisition → State estimation: provides measurements
- GPS decoding → State estimation: provides position
- Airspeed sensing → State estimation: provides airspeed
- State estimation → Attitude estimation: shares estimates
- Manual control → Arming handler: dispatches command
- Arming handler → UAVObject manager: updates flight status
flight/modules/ManualControl/armhandler.c - Manual control → Stabilization loops: provides setpoints
- Path planning → Path following: defines paths
- Path following → Stabilization loops: provides setpoints
- Stabilization loops → Actuator output: commands outputs
- Sensor acquisition → Board I/O: reads hardware
- Actuator output → Board I/O: drives hardware
- UAVObject manager → Telemetry: shares vehicle data
- Telemetry → UAVTalk transport: transports telemetry
- UAVTalk transport → Ground Control Station: exchanges data
- Ground Control Station → Vehicle configuration: loads configuration
- Vehicle configuration → UAVObject manager: configures vehicle
- Ground Control Station → Flight log manager: manages logs
ground/openpilotgcs/src/plugins/flightlog/flightlogmanager.cpp - Flight log manager → UAVObject manager: reads object data
ground/openpilotgcs/src/plugins/flightlog/flightlogmanager.cpp - Object generator → UAVObject manager: generates definitions
- Task scheduler → Sensor acquisition: schedules runtime