本主题提供了无人机和使用 PX4 的基本介绍（主要面向新手用户，但对有经验的用户也是一个很好的介绍）。
无人机是无人驾驶的 ”机器人“ 设备，可以远程或自动控制。
无人机的 ”大脑“ 被称为自动驾驶仪。 它由在 设备控制器</ 0>（“飞行控制器”）硬件上运行的 飞行堆栈* 软件组成。</p>
PX4 is powerful open source autopilot flight stack.
Some of PX4's key features are:
PX4 is a core part of a broader drone platform that includes the QGroundControl ground station, Pixhawk hardware, and MAVSDK for integration with companion computers, cameras and other hardware using the MAVLink protocol. PX4 is supported by the Dronecode Project.
QGroundControl 可以在 Windows，Android，MacOS 或 Linux 上运行。 从 这里 下载并安装。
PX4最初设计为在 Pixhawk Series 控制器上运行，但现在可以在 Linux 计算机和其他硬件上运行。 选择飞行控制板时，您应当考虑飞行器的物理尺寸限制，想要执行的活动，还有必不可少的成本。
PX4 使用传感器来确定飞行器状态（稳定和启用自动控制所需）。 系统最低要求 陀螺仪，加速度计，磁力计（罗盘）和气压计。 需要 GPS 或其他定位系统来启用所有自动模式和一些辅助模式。 固定翼和 VTOL 飞行器还应包括空速传感器（强烈推荐）。
许多 PX4 无人机使用无刷电机，其由飞行控制器通过电子调速器（ESC）驱动（ESC将来自飞行控制器的信号转换为合适的功率水平，传递给电机）。
有关 PX4 支持的 ESC/Motors 的信息，请参阅：
PX4 无人机通常由锂聚合物（LiPo）电池供电。 电池通常使用电源模块 或电源管理板 连接到系统，它为飞行控制器和 ESC（用于电动机）提供单独的动力。
无线电控制（RC ）系统用于手动 控制飞行器。 它由一个遥控装置组成，使用发射机来与飞行器上的接收机通信。 一些 RC 系统还可以接自动驾驶仪传回的收遥测信息。
RC系统选择说明如何选择 RC 系统。 其他相关主题包括：
A computer joystick connected through QGroundControl can also be used to manually control PX4 (QGC converts joystick movements into MAVLink messages that are sent over the telemetry link). This approach is used by ground control units that have an integrated ground control station, like the UAVComponents MicroNav shown below. Joysticks are also commonly used to fly the vehicle in simulation.
It is common for vehicles to have a safety switch that must be engaged before the vehicle can be armed (when armed, motors are powered and propellers can turn). Commonly the safety switch is integrated into a GPS unit, but it may also be a separate physical component.
A vehicle that is armed is potentially dangerous. The safety switch is an additional mechanism that prevents arming from happening by accident.
Data/Telemetry Radios can provide a wireless MAVLink connection between a ground control station like QGroundControl and a vehicle running PX4. This makes it possible to tune parameters while a vehicle is in flight, inspect telemetry in real-time, change a mission on the fly, etc.
PX4 can be controlled from a separate on-vehicle companion computer via a serial cable or wifi. The companion computer will usually communicate using a MAVLink API like the MAVSDK or MAVROS.
Using a Robotics API requires software development skills, and is outside the scope of this guide.
PX4 uses SD memory cards for storing flight logs (SD support may not be present on every flight controller).
The maximum supported SD card size on Pixhawk boards is 32GB.
A number of recommended cards are listed in: Developer Guide > Logging
Vehicles may have moving parts, some of which are potentially dangerous when powered (in particular motors and propellers)!
To reduce the chance of accidents:
- PX4 vehicles are disarmed (unpowered) when not in use, and must be explicitly armed before taking off.
- Some vehicles additionally require a safety switch be disengaged before arming can succeed.
- Arming is prevented if the vehicle is not in a "healthy" state.
- A vehicle will also usually revert to the disarmed state after landing or if a pilot does not take off quickly enough.
Arming is triggered by default (Mode 2 transmitters) by holding the RC throttle/yaw stick on the bottom right for one second (to disarm, hold stick on bottom left). It is also possible to configure PX4 to arm using an RC button on the RC control (and arming commands can be sent from a ground station).
A detailed overview of arming and arming configuration can be found here: Prearm, Arm, Disarm Configuration.
Flight modes provide different types/levels of vehicle automation and autopilot assistance to the user (pilot). Autonomous modes are fully controlled by the autopilot, and require no pilot/remote control input. These are used, for example, to automate common tasks like takeoff, returning to the home position, and landing. Other autonomous modes execute pre-programmed missions, follow a GPS beacon, or accept commands from an offboard computer or ground station.
Manual modes are controlled by the user (via the RC control sticks/joystick) with assistance from the autopilot. Different manual modes enable different flight characteristics - for example, some modes enable acrobatic tricks, while others are impossible to flip and will hold position/course against wind.
Not all flight modes are available on all vehicle types, and some modes can only be used when specific conditions have been met (e.g. many modes require a global position estimate).
PX4 has configurable failsafe systems to protect and recover your vehicle if something goes wrong! These allow you to specify areas and conditions under which you can safely fly, and the action that will be performed if a failsafe is triggered (for example, landing, holding position, or returning to a specified point).
You can only specify the action for the first failsafe event. Once a failsafe occurs the system will enter special handling code, such that subsequent failsafe triggers are managed by separate system level and vehicle specific code.
The main failsafe areas are listed below:
- Low Battery
- Remote Control (RC) Loss
- Position Loss (global position estimate quality is too low).
- Offboard Loss (e.g. lose connection to companion computer)
- Data Link Loss (e.g. lose telemetry connection to GCS).
- Geofence Breach (restrict vehicle to flight within a virtual cylinder).
- Mission Failsafe (prevent a previous mission being run at a new takeoff location).
- Traffic avoidance (triggered by transponder data from e.g. ADSB transponders).
For more information see: Safety (Basic Configuration).
All the vehicles, boats and aircraft have a heading direction or an orientation based on their forward motion.
It is important to know the vehicle heading direction in order to align the autopilot with the vehicle vector of movement. Multicopters have a heading even when they are symmetrical from all sides! Usually manufacturers use a colored props or colored arms to indicate the heading.
In our illustrations we will use red coloring for the front propellers of multicopter to show heading.
You can read in depth about heading in Flight Controller Orientation