docs(i18n): PX4 guide translations (Crowdin) - zh-CN (#27066)

Co-authored-by: Crowdin Bot <support+bot@crowdin.com>
This commit is contained in:
PX4 Build Bot
2026-04-20 09:01:48 +10:00
committed by GitHub
parent 0a4070b5c2
commit 7ab709c202
39 changed files with 1472 additions and 350 deletions
+22 -10
View File
@@ -1,6 +1,8 @@
- [概述](index.md)
- [基本概念](getting_started/px4_basic_concepts.md)
- [Try PX4 (Simulation)](simulation/px4_simulation_quickstart.md)
- [多旋翼](frames_multicopter/index.md)
- [特征](features_mc/index.md)
- [飞行模式](flight_modes_mc/index.md)
@@ -330,6 +332,7 @@
- [RFD900 (SiK) 数传电台](telemetry/rfd900_telemetry.md)
- [ThunderFly TFSIK01 Telemetry Radio](telemetry/tfsik_telemetry.md)
- [HolyBro (SIK) 数传电台](telemetry/holybro_sik_radio.md)
- [HolyBro SiK Long Range Telemetry Radio](telemetry/holybro_sik_longrange.md)
- [WiFi 数传](telemetry/telemetry_wifi.md)
- [ESP8266 WiFi 模块](telemetry/esp8266_wifi_module.md)
- [ESP32 WiFi 模块](telemetry/esp32_wifi_module.md)
@@ -494,6 +497,7 @@
- [Worlds](sim_gazebo_classic/worlds.md)
- [Multi-Vehicle Sim](sim_gazebo_classic/multi_vehicle_simulation.md)
- [仿真故障保护](simulation/failsafes.md)
- [Pre-built Packages](simulation/px4_sitl_prebuilt_packages.md)
- [硬件](hardware/index.md)
- [飞行控制器参考设计](hardware/reference_design.md)
- [制造商的版面支持指南](hardware/board_support_guide.md)
@@ -598,6 +602,7 @@
- [EstimatorBias](msg_docs/EstimatorBias.md)
- [EstimatorBias3d](msg_docs/EstimatorBias3d.md)
- [EstimatorEventFlags](msg_docs/EstimatorEventFlags.md)
- [EstimatorFusionControl](msg_docs/EstimatorFusionControl.md)
- [EstimatorGpsStatus](msg_docs/EstimatorGpsStatus.md)
- [EstimatorInnovations](msg_docs/EstimatorInnovations.md)
- [EstimatorSelectorStatus](msg_docs/EstimatorSelectorStatus.md)
@@ -696,6 +701,7 @@
- [QshellReq](msg_docs/QshellReq.md)
- [QshellRetval](msg_docs/QshellRetval.md)
- [RadioStatus](msg_docs/RadioStatus.md)
- [RangingBeacon](msg_docs/RangingBeacon.md)
- [RateCtrlStatus](msg_docs/RateCtrlStatus.md)
- [RcChannels](msg_docs/RcChannels.md)
- [RcParameterMap](msg_docs/RcParameterMap.md)
@@ -774,6 +780,7 @@
- [HomePositionV0](msg_docs/HomePositionV0.md)
- [RegisterExtComponentReplyV0](msg_docs/RegisterExtComponentReplyV0.md)
- [RegisterExtComponentRequestV0](msg_docs/RegisterExtComponentRequestV0.md)
- [RegisterExtComponentRequestV1](msg_docs/RegisterExtComponentRequestV1.md)
- [VehicleAttitudeSetpointV0](msg_docs/VehicleAttitudeSetpointV0.md)
- [VehicleCommandAckV0](msg_docs/VehicleCommandAckV0.md)
- [VehicleGlobalPositionV0](msg_docs/VehicleGlobalPositionV0.md)
@@ -781,6 +788,7 @@
- [VehicleStatusV0](msg_docs/VehicleStatusV0.md)
- [VehicleStatusV1](msg_docs/VehicleStatusV1.md)
- [VehicleStatusV2](msg_docs/VehicleStatusV2.md)
- [VehicleStatusV3](msg_docs/VehicleStatusV3.md)
- [MAVLink Messaging](mavlink/index.md)
- [Adding Messages](mavlink/adding_messages.md)
- [Streaming Messages](mavlink/streaming_messages.md)
@@ -881,16 +889,20 @@
- [Multi-vehicle simulation](simulation/multi-vehicle-simulation.md)
- [平台测试和连续集成](test_and_ci/index.md)
- [试飞](test_and_ci/test_flights.md)
- [测试 MC_01 - 手动模式](test_cards/mc_01_manual_modes.md)
- [测试 MC_02-完全自主](test_cards/mc_02_full_autonomous.md)
- [测试 MC_03 - 自动手动混合](test_cards/mc_03_auto_manual_mix.md)
- [测试 MC_04 -故障安全测试](test_cards/mc_04_failsafe_testing.md)
- [Test MC_05 - Manual Modes (Inside)](test_cards/mc_05_indoor_flight_manual_modes.md)
- [Test MC_06 - Optical Flow (Inside)](test_cards/mc_06_optical_flow.md)
- [Test MC_07 - Optical Flow Low Mount](test_cards/mc_07_optical_flow_low_mount.md)
- [Test MC_08 - DSHOT ESC](test_cards/mc_08_dshot.md)
- [Test MC_09 - VIO (Visual-Inertial Odometry)](test_cards/mc_09_vio.md)
- [Test MC_10 - Optical Flow / GPS Mixed](test_cards/mc_10_optical_flow_gps_mixed.md)
- [Multicopter](test_and_ci/test_flights.md#multicopter)
- [测试 MC_01 - 手动模式](test_cards/mc_01_manual_modes.md)
- [测试 MC_02-完全自主](test_cards/mc_02_full_autonomous.md)
- [测试 MC_03 - 自动手动混合](test_cards/mc_03_auto_manual_mix.md)
- [测试 MC_04 -故障安全测试](test_cards/mc_04_failsafe_testing.md)
- [Test MC_05 - Manual Modes (Inside)](test_cards/mc_05_indoor_flight_manual_modes.md)
- [Test MC_06 - Optical Flow (Inside)](test_cards/mc_06_optical_flow.md)
- [Test MC_07 - Optical Flow Low Mount](test_cards/mc_07_optical_flow_low_mount.md)
- [Test MC_08 - DSHOT ESC](test_cards/mc_08_dshot.md)
- [Test MC_09 - VIO (Visual-Inertial Odometry)](test_cards/mc_09_vio.md)
- [Test MC_10 - Optical Flow / GPS Mixed](test_cards/mc_10_optical_flow_gps_mixed.md)
- [Fixed Wing](test_and_ci/test_flights.md#fixed-wing)
- [Test FW_01 - Manual Modes](test_cards/fw_01_manual_modes.md)
- [Test FW_02 - Full Autonomous](test_cards/fw_02_full_autonomous.md)
- [单元测试](test_and_ci/unit_tests.md)
- [Fuzz Tests](test_and_ci/fuzz_tests.md)
- [持续集成](test_and_ci/continous_integration.md)
+4
View File
@@ -457,6 +457,10 @@ div.frame_variant td, div.frame_variant th {
<td>SIH Quadcopter X</td>
<td>Maintainer: Romain Chiappinelli &lt;romain.chiap@gmail.com&gt;<p><code>SYS_AUTOSTART</code> = 1100</p></td>
</tr>
<tr id="copter_simulation_sih_hexacopter_x">
<td>SIH Hexacopter X</td>
<td>Maintainer: Romain Chiappinelli &lt;romain.chiap@gmail.com&gt;<p><code>SYS_AUTOSTART</code> = 1105</p></td>
</tr>
</tbody>
</table>
</div>
@@ -101,8 +101,8 @@ A plot of external data vs. onboard estimate (as above) can be generated using [
## Check/Verify VIO Estimate {#verify_estimate}
:::info
The [MAV_ODOM_LP](../advanced_config/parameter_reference.md#MAV_ODOM_LP) parameter mentioned below was removed in PX4 v1.14.
:::warning
The `MAV_ODOM_LP` parameter mentioned below was removed in PX4 v1.14.
This section needs to be updated. <!-- https://github.com/PX4/PX4-Autopilot/pull/20501#issuecomment-1993788815 -->
:::
+1 -1
View File
@@ -201,7 +201,7 @@ In the following example, the vehicle has two ailerons, one elevator, one rudder
#### Flaps and Spoiler Control with Manual Control
The preferred method to manually actuate spoilers and flaps is to map a manual control switch to an `AUX` output (see [Generic Actuator Control with RC](#generic-actuator-control-with-rc)), and then map that AUX output to the flap or spoiler function using [FW_FLAPS_MAN](../advanced_config/parameter_reference.md#FW_FLAPS_MAN) or [FW_SPOILERS_MAN](../advanced_config/parameter_reference.md#FW_SPOILERS_MAN).
The preferred method to manually actuate spoilers and flaps is to map a manual control switch to an `AUX` output (see [Generic Actuator Control with RC](../payloads/generic_actuator_control.md#generic-actuator-control-with-rc)), and then map that AUX output to the flap or spoiler function using [FW_FLAPS_MAN](../advanced_config/parameter_reference.md#FW_FLAPS_MAN) or [FW_SPOILERS_MAN](../advanced_config/parameter_reference.md#FW_SPOILERS_MAN).
The source for the manual control can be RC or MAVLink.
:::warning
+2 -2
View File
@@ -15,8 +15,8 @@ The PX4 dev team and community come together to discuss any topic of interest to
## Who should attend?
- 核心项目维护者
- 组件维护者
- Code Owners
- Reviewers
- 测试团队负责人
- 无人机编码成员
- Community members (you!)
+1 -1
View File
@@ -269,7 +269,7 @@ In overview:
- Images must be stored in a sub folder of `/assets`.
This is two folders down from content folders, so if you add an image you will reference it like:
```plain
```txt
![Image Description](../../assets/path_to_file/filename.jpg)
```
+1 -1
View File
@@ -20,7 +20,7 @@ We pledge to adhere to the [PX4 code of conduct](https://github.com/PX4/PX4-Auto
This section contains information about how you can meet with the community and contribute to PX4:
- [Dev Call](../contribute/dev_call.md) - Discuss architecture, pull requests, impacting issues with the dev team
- [Maintainers](./maintainers.md) - Maintainers of PX4 Subsystems and Ecosystem
- [Maintainers](./maintainers.md) - Maintainer roles, types, and how to become one
- [Support](../contribute/support.md) - Get help and raise issues
- [Source Code Management](../contribute/code.md) - Work with PX4 code
- [Documentation](../contribute/docs.md) - Improve the docs
+41 -12
View File
@@ -1,57 +1,86 @@
# Maintainer Role
Dronecode maintainers have technical leadership and responsibility for specific areas of PX4, and for other ecosystem components such as MAVLink, MAVSDK, QGroundControl, and others.
Dronecode maintainers provide technical leadership for PX4 and for other ecosystem components such as MAVLink, MAVSDK, QGroundControl, and others. Some maintainers take responsibility for specific areas of the project, while others help across the project more broadly.
The maintainer role is defined by the community with help and supervision from the [Dronecode Foundation](https://dronecode.org/).
To find the most up-to-date maintainers list, visit [PX4-Autopilot README](https://github.com/PX4/PX4-Autopilot#maintenance-team).
To find the most up-to-date maintainers list, see [`MAINTAINERS.md`](https://github.com/PX4/PX4-Autopilot/blob/main/MAINTAINERS.md) in the PX4-Autopilot repository.
## Maintainer Types
PX4 recognizes two types of maintainers. Both are full members of the maintainer team, have write access via the [`Dev Team`](https://github.com/orgs/PX4/teams/dev-team) GitHub team, and participate in maintainer decisions.
- **Code Owners** are responsible for a specific category of the project (for example, State Estimation, Multirotor, or CI). They have final say on changes to their area, are the primary reviewers for that code, and help shape its roadmap. This is the role described in detail below.
- **Reviewers** help maintain PX4 across the project without ownership of a specific category. They review, triage, and contribute wherever their interests and time allow. Reviewers have the same access and voting rights as Code Owners, but no on-call responsibility for any specific area of the codebase.
The Reviewer role is a good fit for contributors who want to help steward the project without committing to a specific component up front. A Reviewer may later become a Code Owner for a category by mutual agreement with the existing Code Owners of that category and sign-off from the maintainer team.
## Recruitment Process
If you would like to join the PX4 maintainers team or if you want to nominate someone else follow the steps below:
1. Read the [role description](#dronecode-maintainer-role-description), and make sure you understand the responsibilities of the role.
2. To nominate yourself, reach out to one of the maintainers (see the complete list in the [PX4-Autopilot README](https://github.com/PX4/PX4-Autopilot#maintenance-team)), and seek their sponsorship.
3. Express your interest in becoming a maintainer, and specify which area you would like to maintain.
2. To nominate yourself, reach out to one of the maintainers (see the complete list in [`MAINTAINERS.md`](https://github.com/PX4/PX4-Autopilot/blob/main/MAINTAINERS.md)), and seek their sponsorship.
3. Express your interest in becoming a maintainer, and specify whether you are applying as a **Code Owner** (for a specific category) or as a **Reviewer** (helping across the project without a fixed category).
4. The sponsoring maintainer needs to bring this up for discussion in one of the [weekly developer calls](dev_call.md).
The maintainer team will vote on the call to determine whether to accept you as a maintainer.
A Reviewer may later transition to a Code Owner role for a specific category. This requires agreement from the existing Code Owners of that category and sign-off from the maintainer team, following the same discussion and vote on the weekly developer call.
### Adding a new maintainer
Once the maintainer team has agreed to add a new maintainer, the change is landed via a pull request to [`MAINTAINERS.md`](https://github.com/PX4/PX4-Autopilot/blob/main/MAINTAINERS.md). The process is intentionally simple:
1. A current maintainer opens a PR adding the new maintainer to the appropriate table (**Code Owners** with a category, or **Reviewers**).
2. The PR must be approved by at least one other current maintainer.
3. If the new maintainer is being added as a Code Owner or sub-owner of a specific component, the existing Code Owner of that component must be among the approvers.
Once the PR is merged, the new maintainer proceeds through the [Onboarding Process](#onboarding-process) below.
## Onboarding Process
Once accepted every maintainers will go through the following process:
1. **Discord** server admin will grant you the `dev team` role, which gives you:
1. Basic admin privileges on discord.
2. Access to the `#maintainers` channel.
2. Access to the private `#maintainers` channel for internal maintainer discussion.
2. You will be given access to the GitHub team: "[`Dev Team`](https://github.com/orgs/PX4/teams/dev-team)" which grants you:
1. Permission to merge the PR of any of PX4 workspace repositories after it's approved
2. Permission to trigger GitHub actions when a new contributor opens a PR.
3. Permission to edit Issue/PR contents.
3. **Add your info to official PX4 channels**:
1. Include your information on the PX4 [README](https://github.com/PX4/PX4-Autopilot/blob/main/README.md) next to the rest of the team
2. Listed on the [Maintainers section](https://px4.io/community/maintainers/) of the PX4 website.
3. Add your information to the internal Dronecode database of maintainers to keep you in sync.
4. Community introduction to the new maintainer in the form of a forum post, which is promoted through ever growing official channels
1. Add your information to the internal Dronecode database of maintainers to keep you in sync.
2. Community introduction to the new maintainer in the form of a forum post, which is promoted through ever growing official channels
## Dronecode Maintainer Role Description
The responsibilities and qualifications below describe the **Code Owner** role in detail. **Reviewers** share the same spirit of technical stewardship, community guidance, and participation in maintainer meetings, without being tied to a specific category. Reviewers are expected to review and triage across the project where their expertise and interest apply.
### 概要
Maintainers lead/manage the development of a **specific category (referred to as category below)** of any Open Source Projects hosted within the Dronecode Foundation, such as the PX4 Autopilot.
### Responsibilities
### Responsibilities (Code Owner)
1. Take charge of overseeing the development in their category.
2. Provide guidance/advice on community members in their category.
3. Review relevant pull requests and issues from the community on GitHub.
4. Coordinate with the maintainer group.
5. Keep regular attendance on [weekly meetings ](dev_call.md).
5. Keep regular attendance on [weekly meetings](dev_call.md).
6. Help create and maintain a roadmap for the project your represent.
7. Uphold the [Code of Conduct](https://github.com/Dronecode/foundation/blob/main/CODE-OF-CONDUCT.md) of our community.
### Responsibilities (Reviewer)
1. Review relevant pull requests and issues across the project where your expertise applies.
2. Help triage issues and guide community contributors.
3. Coordinate with the maintainer group.
4. Keep regular attendance on [weekly meetings](dev_call.md).
5. Uphold the [Code of Conduct](https://github.com/Dronecode/foundation/blob/main/CODE-OF-CONDUCT.md) of our community.
### Qualifications
1. Proven track record of valuable contributions.
2. Domain expertise in the category field.
2. Domain expertise in the category field (for Code Owners) or broad working knowledge of the project (for Reviewers).
3. Good overview of the project you are applying to.
4. You need to manage approval from your employer when relevant.
+5
View File
@@ -1,5 +1,10 @@
# 安装文件和代码
:::tip
You only need a toolchain if you want to **modify and build** PX4 from source.
If you just want to run PX4 simulation without changing the code, use a pre-built [Docker container or .deb package](../simulation/px4_sitl_prebuilt_packages.md) instead.
:::
The _supported platforms_ for PX4 development are:
- [Ubuntu Linux (24.04/22.04)](../dev_setup/dev_env_linux_ubuntu.md)
+1 -1
View File
@@ -61,7 +61,7 @@ To build for [other targets](../dev_setup/dev_env.md#supported-targets) you will
This installs:
- **`px4-dev`** — ARM cross-compiler (`arm-gcc-bin@13`), `cmake`, `ninja`, `ccache`, and other build tools
- **Toolchain packages** from the `osx-cross/arm` and `PX4/px4` Homebrew taps — ARM cross-compiler (`arm-gcc-bin@13`), `cmake`, `ninja`, `ccache`, `fastdds`, `genromfs`, `kconfig-frontends`, and other build tools
- **Python packages** from `requirements.txt`
- **`px4-sim`** (via `--sim-tools`) — Gazebo Harmonic simulation (`gz-harmonic`) and related tools
+1
View File
@@ -2,6 +2,7 @@
本节包含有关开始 PX4 开发的主题:
- [PX4 Simulation QuickStart](../simulation/px4_simulation_quickstart.md) — Try PX4 in simulation without a build environment!
- [Initial Setup](../dev_setup/config_initial.md)
- [Toolchain Installation](../dev_setup/dev_env.md)
- [Building the Code](../dev_setup/building_px4.md)
+1 -1
View File
@@ -26,7 +26,7 @@ These flight controllers are [manufacturer supported](../flight_controller/autop
- On-board sensors
- Accel/Gyro: ICM-42688-P\*2(Version1), BMI270\*2(Version2)
- Mag: QMC5883P
- Barometer: DPS310(Version1),SPL06(Version2)
- Barometer: SPL06
### 接口
+72 -23
View File
@@ -2,17 +2,29 @@
<img src="../../assets/site/position_fixed.svg" title="Position fix required (e.g. GPS)" width="30px" />
:::: warning
Offboard control with ROS 2 requires _significant care_ to ensure that it is used safely.
Please read [ROS 2 Offboard Control](#ros-2-offboard-control) carefully to fully understand the risks involved when using it.
A good understanding of [PX4 controller diagrams](../flight_stack/controller_diagrams.md) is advised.
:::tip
[PX4 ROS 2 Interface Library](../ros2/px4_ros2_interface_lib.md) provides a safer alternative.
:::
::::
飞行器根据飞行控制栈外部(如机载计算机)提供的设定值控制位置、速度、加速度、姿态以及推力/力矩。
The setpoints may be provided using MAVLink (or a MAVLink API such as [MAVSDK](https://mavsdk.mavlink.io/)) or by [ROS 2](../ros2/index.md).
PX4 requires that the external controller provides a continuous 2Hz "proof of life" signal, by streaming any of the supported MAVLink setpoint messages or the ROS 2 [OffboardControlMode](../msg_docs/OffboardControlMode.md) message.
PX4只有在收到该种信号超过1秒后才有效,如果该种信号停止飞行控制栈将重新获得控制权(脱离Offboard模式)。
PX4 enables switching to offboard control mode only after receiving the signal for more than a second, and will failsafe (controlled by [COM_OBL_RC_ACT](../advanced_config/parameter_reference.md#COM_OBL_RC_ACT)) if the signal stops.
::: info
- 此模式需要位置或位/姿信息 - 例如 GPS、光流、视觉惯性里程计、mocap 等。
- This mode requires position or pose/attitude information - e.g. GPS, optical flow, visual-inertial odometry, mocap, etc. depending on the type of offboard setpoints that the external controller sends.
- Manual control is disabled except to change modes (you can also fly without any manual controller at all by setting the parameter [COM_RC_IN_MODE](../advanced_config/parameter_reference.md#COM_RC_IN_MODE) to `4: Disable manual control`).
- The vehicle must be already be receiving a stream of MAVLink setpoint messages or ROS 2 [OffboardControlMode](../msg_docs/OffboardControlMode.md) messages before arming in offboard mode or switching to offboard mode when flying.
- The vehicle must already be receiving a stream of MAVLink setpoint messages or ROS 2 [OffboardControlMode](../msg_docs/OffboardControlMode.md) messages before arming in offboard mode or switching to offboard mode when flying.
- The vehicle will exit offboard mode if MAVLink setpoint messages or `OffboardControlMode` are not received at a rate of > 2Hz.
- 并非所有 MAVLink 支持的坐标系和字段值都被设定值消息和飞行器支持。
Read the sections below _carefully_ to ensure only supported values are used.
@@ -38,13 +50,37 @@ In order to hold position in this case the vehicle must receive a stream of `Off
其他操作如起飞、降落、返航,最好使用适当的模式来处理。
像上传、下载任务这样的操作可以在任何模式下执行。
## ROS 2 消息
## ROS 2 Offboard Control
This section describes how to perform offboard control through one of the direct ROS 2 interfaces: UXRCE-DDS or Zenoh.
When using direct ROS 2 offboard control, PX4 setpoint messages generated by external controllers are injected into the [PX4 control pipeline](../flight_stack/controller_diagrams.md).
Because messages from internal and external controllers are indistinguishable within PX4, precise synchronization is required in order to avoid the controllers writing conflicting messages to the same topic.
In Offboard mode (only), an external system can use [`OffboardControlMode`](#the-offboardcontrolmode-px4-message) to specify which setpoint topics PX4 should publish/not publish, allowing them to be written safely by an external controller.
::: warning
PX4 has no means of filtering and distinguishing ROS 2 messages from internal messages, in any mode.
In order to interwork safely, the external controller must:
- Publish PX4 setpoint messages **ONLY** in Offboard mode.
- Specify which setpoints it will write using the `OffboardControlMode` topic.
- Stream the `OffboardControlMode` topic as a keep-alive signal.
- Stream the setpoints it wants: unlike with MAVLink, PX4 won't trigger a failsafe if setpoints aren't sent regularly.
If external setpoints are sent in any other flight mode, or they overwrite topics that have not been disabled by PX4 when in offboard mode, collisions are likely.
This will result in unexpected, and possibly catastrophic, behaviour.
:::
### The `OffboardControlMode` PX4 message
以下 ROS 2 消息及其特定字段和字段值在特定的框架下是允许的。
In addition to providing heartbeat functionality, `OffboardControlMode` has two other main purposes:
1. Controls the level of the [PX4 control architecture](../flight_stack/controller_diagrams.md) at which offboard setpoints must be injected, and disables the bypassed controllers.
2. 确定需要哪种有效估计(位置或速度),以及应该使用哪种设定值消息。
1. Controls which internal PX4 control modules of the [PX4 control architecture](../flight_stack/controller_diagrams.md) shall remain active and which ones shall be disabled when the vehicle is in Offboard Mode.
2. Determines which valid estimates (position, velocity, etc.) are required.
The `OffboardControlMode` message is defined as shown.
@@ -69,33 +105,48 @@ For rovers see the [rover section](#rover).
The fields are ordered in terms of priority such that `position` takes precedence over `velocity` and later fields, `velocity` takes precedence over `acceleration`, and so on.
第一个非零字段(从上到下) 定义了Offboard模式所需的有效估计以及可用的设定值消息。
For example, if the `acceleration` field is the first non-zero value, then PX4 requires a valid `velocity estimate`, and the setpoint must be specified using the `TrajectorySetpoint` message.
For example, if the `acceleration` field is the first non-zero value, then PX4 requires a valid `attitude estimate`, and the setpoint must be specified using the `TrajectorySetpoint` message.
| 期望控制对象 | 位置 | 速度 | 加速度 | 姿态 | 姿态角速率 | 执行器字段 | 直接给电机 | 所需状态估计 | 所需消息 |
| ------------------------------ | --------------------------- | --------------------------- | --------------------------- | --------------------------- | --------------------------- | --------------------------- | --------------------------- | ------ | ------------------------------------------------------------------------------------------------------------------------------- |
| 位置 (NED) | &check; | - | - | - | - | - | - | 位置 | [TrajectorySetpoint](../msg_docs/TrajectorySetpoint.md) |
| 速度 (NED) | &cross; | &check; | - | - | - | - | - | 速度 | [TrajectorySetpoint](../msg_docs/TrajectorySetpoint.md) |
| 加速度(NED) | &cross; | &cross; | &check; | - | - | - | - | 速度 | [TrajectorySetpoint](../msg_docs/TrajectorySetpoint.md) |
| 姿态(FRD) | &cross; | &cross; | &cross; | &check; | - | - | - | | [VehicleAttitudeSetpoint](../msg_docs/VehicleAttitudeSetpoint.md) |
| 体轴角速率 (FRD) | &cross; | &cross; | &cross; | &cross; | &check; | - | - | | [VehicleRatesSetpoint](../msg_docs/VehicleRatesSetpoint.md) |
| 推力和力矩(FRD) | &cross; | &cross; | &cross; | &cross; | &cross; | &check; | - | 无 | [VehicleThrustSetpoint](../msg_docs/VehicleThrustSetpoint.md) and [VehicleTorqueSetpoint](../msg_docs/VehicleTorqueSetpoint.md) |
| 直接给电机和舵机 | &cross; | &cross; | &cross; | &cross; | &cross; | &cross; | &check; | 无 | [ActuatorMotors](../msg_docs/ActuatorMotors.md) and [ActuatorServos](../msg_docs/ActuatorServos.md) |
| 期望控制对象 | 位置 | 速度 | 加速度 | 姿态 | 姿态角速率 | 执行器字段 | 直接给电机 | 所需状态估计 | 所需消息 |
| ------------------------------ | --------------------------- | --------------------------- | --------------------------- | --------------------------- | --------------------------- | --------------------------- | --------------------------- | ---------------- | ------------------------------------------------------------------------------------------------------------------------------- |
| 位置 (NED) | &check; | - | - | - | - | - | - | 位置 | [TrajectorySetpoint](../msg_docs/TrajectorySetpoint.md) |
| 速度 (NED) | &cross; | &check; | - | - | - | - | - | 速度 | [TrajectorySetpoint](../msg_docs/TrajectorySetpoint.md) |
| 加速度(NED) | &cross; | &cross; | &check; | - | - | - | - | attitude | [TrajectorySetpoint](../msg_docs/TrajectorySetpoint.md) |
| 姿态(FRD) | &cross; | &cross; | &cross; | &check; | - | - | - | attitude | [VehicleAttitudeSetpoint](../msg_docs/VehicleAttitudeSetpoint.md) |
| 体轴角速率 (FRD) | &cross; | &cross; | &cross; | &cross; | &check; | - | - | angular velocity | [VehicleRatesSetpoint](../msg_docs/VehicleRatesSetpoint.md) |
| 推力和力矩(FRD) | &cross; | &cross; | &cross; | &cross; | &cross; | &check; | - | 无 | [VehicleThrustSetpoint](../msg_docs/VehicleThrustSetpoint.md) and [VehicleTorqueSetpoint](../msg_docs/VehicleTorqueSetpoint.md) |
| 直接给电机和舵机 | &cross; | &cross; | &cross; | &cross; | &cross; | &cross; | &check; | 无 | [ActuatorMotors](../msg_docs/ActuatorMotors.md) and [ActuatorServos](../msg_docs/ActuatorServos.md) |
where ✓ means that the bit is set, ✘ means that the bit is not set and `-` means that the bit is value is irrelevant.
where ✓ means that the bit is set, ✘ means that the bit is not set and `-` means that the bit value is irrelevant.
:::info
Before using offboard mode with ROS 2, please spend a few minutes understanding the different [frame conventions](../ros2/user_guide.md#ros-2-px4-frame-conventions) that PX4 and ROS 2 use.
:::
### 旋翼机
In the following, the different setpoint messages for the main supported airframes are explained.
For fixed-wing offboard control, please refer to the [PX4 ROS 2 Interface Library](../ros2/px4_ros2_interface_lib.md).
### 多旋翼
- [px4_msgs::msg::TrajectorySetpoint](https://github.com/PX4/PX4-Autopilot/blob/main/msg/versioned/TrajectorySetpoint.msg)
- 支持以下输入组合:
- Position setpoint (`position` different from `NaN`). Non-`NaN` values of velocity and acceleration are used as feedforward terms for the inner loop controllers.
- Velocity setpoint (`velocity` different from `NaN` and `position` set to `NaN`). Non-`NaN` values acceleration are used as feedforward terms for the inner loop controllers.
- Velocity setpoint (`velocity` different from `NaN` and `position` set to `NaN`). Non-`NaN` values of acceleration are used as feedforward terms for the inner loop controllers.
- Acceleration setpoint (`acceleration` different from `NaN` and `position` and `velocity` set to `NaN`)
- All values are interpreted in NED (Nord, East, Down) coordinate system and the units are `[m]`, `[m/s]` and `[m/s^2]` for position, velocity and acceleration, respectively.
- All values are interpreted in NED (North, East, Down) coordinate system and the units are `[m]`, `[m/s]` and `[m/s^2]` for position, velocity and acceleration, respectively.
::: warning
Position, velocity and acceleration control for multicopters are all handled by the `mc_pos_control` module.
This module is enabled if any of `position`, `velocity` and `acceleration` fields are set to true.
However, only the content of the `TrajectorySetpoint` messages determines which of the three controllers shall run.
This means that even if `OffboardControlMode` messages carry the intention of velocity control (only `velocity` field is set) but non-`NaN` position values are sent in the `TrajectorySetpoint` messages, then PX4 will keep running the position controller.
:::
- [px4_msgs::msg::VehicleAttitudeSetpoint](https://github.com/PX4/PX4-Autopilot/blob/main/msg/versioned/VehicleAttitudeSetpoint.msg)
- 支持以下输入组合:
@@ -194,13 +245,11 @@ Ackermann rovers do not support the yaw setpoint.
- [px4_msgs::msg::ActuatorMotors](https://github.com/PX4/PX4-Autopilot/blob/main/msg/versioned/ActuatorMotors.msg) + [px4_msgs::msg::ActuatorServos](https://github.com/PX4/PX4-Autopilot/blob/main/msg/versioned/ActuatorServos.msg)
- 直接控制电机输出和/或伺服系统(舵机)输出。
- Currently works at lower level than then `control_allocator` module.
Do not publish these messages when not in offboard mode.
- All the values normalized in `[-1, 1]`.
For outputs that do not support negative values, negative entries map to `NaN`.
- `NaN` maps to disarmed.
## MAVLink 消息
## MAVLink Offboard Control
下面的 MAVLink 消息及其特定字段和字段值在特定的帧下是允许的。
+22 -15
View File
@@ -110,11 +110,13 @@ The behaviour is fairly complex because it depends on the flight mode, and wheth
Mission _with_ landing pattern:
- **Mission mode:** Mission is continued in "fast-forward mode" (jumps, delay and any other non-position commands ignored, loiter and other position waypoints converted to simple waypoints) and then lands.
- **Mission mode:**
- Mission is continued in "fast-forward mode" and then lands.
- DO_JUMP commands, delays and other non-position mission items are ignored, and loiter and other position waypoints are converted to simple waypoints.
- **Auto mode other than mission mode:**
- Ascend to a safe [minimum return altitude](#minimum-return-altitude) above any expected obstacles.
- 直接飞到最近的航点(对固定翼而言,不是着陆航点),然后降落到航点高度。
- 从该航点以快速模式继续执行任务。
- Continue mission in fast forward mode from that waypoint, using the same traversal rules as above.
- **Manual modes:**
- Ascend to a safe [minimum return altitude](#minimum-return-altitude) above any expected obstacles.
- 直接飞到降落序列位置并下降到航点高度。
@@ -124,7 +126,7 @@ Mission _without_ landing pattern defined:
- **Mission mode:**
- 从上一个航点开始以“快退”(反向)飞行的任务
- 跳,延迟和其他任何非定位命令都会被忽略,悬停和其他位置航点将转换为简单航点。
- DO_JUMP commands, delays and other non-position mission items are ignored, and loiter and other position waypoints are converted to simple waypoints.
- VTOL 无人机在反向飞行任务之前切换到固定翼模式(如果需要)。
- On reaching waypoint 1, the vehicle ascends to the [minimum return altitude](#minimum-return-altitude) and flies to the home position (where it [lands or waits](#loiter-landing-at-destination)).
- **Auto mode other than mission mode:**
@@ -136,6 +138,11 @@ Mission _without_ landing pattern defined:
如果任务在返航模式期间发生更改,则将按照与上述相同的规则根据新任务重新评估行为(例如,如果新任务没有降落顺序并且你在一个任务中,则任务将被逆转)。
:::info
For `RTL_TYPE=4`, PX4 currently chooses between continuing to a mission landing and reversing toward home by comparing raw mission item indices.
This is only an approximation of the flown path length, because the number if mission items is not indicative of the distance remaining and non-position items are also counted.
:::
### 最近的安全目的地返回类型(RTL_TYPE=3)
无人机在该返航类型中:
@@ -205,15 +212,15 @@ For this reason fixed-wing vehicles are configured to use [Mission landing/reall
The RTL parameters are listed in [Parameter Reference > Return Mode](../advanced_config/parameter_reference.md#return-mode) (and summarised below).
| 参数 | 描述 |
| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| <a id="RTL_TYPE"></a>[RTL_TYPE](../advanced_config/parameter_reference.md#RTL_TYPE) | Return mechanism (path and destination).<br>`0`: Return to a rally point or home (whichever is closest) via direct path.<br>`1`: Return to a rally point or the mission landing pattern start point (whichever is closest), via direct path. 如果未定义任务着陆点或集结点,通过直接路径返回起始位置。 If the destination is a mission landing pattern, follow the pattern to land.<br>`2`: Use mission path fast-forward to landing if a landing pattern is defined, otherwise fast-reverse to home. 忽略集结点。 Fly direct to home if no mission plan is defined.<br>`3`: Return via direct path to closest destination: home, start of mission landing pattern or safe point. 如果目的地是飞行任务着陆模式,则按照该模式降落。 |
| <a id="RTL_RETURN_ALT"></a>[RTL_RETURN_ALT](../advanced_config/parameter_reference.md#RTL_RETURN_ALT) | Return altitude in meters (default: 60m) when [RTL_CONE_ANG](../advanced_config/parameter_reference.md#RTL_CONE_ANG) is 0. 如果已经超过这个值, 飞机将返回当前的高度。 |
| <a id="RTL_DESCEND_ALT"></a>[RTL_DESCEND_ALT](../advanced_config/parameter_reference.md#RTL_DESCEND_ALT) | 最小返航高度和无人机从较高的返航高度到减速或者停止的初始下降高度(默认: 30米)。 |
| <a id="RTL_LAND_DELAY"></a>[RTL_LAND_DELAY](../advanced_config/parameter_reference.md#RTL_LAND_DELAY) | Time to wait at `RTL_DESCEND_ALT` before landing (default: 0.5s) -by default this period is short so that the vehicle will simply slow and then land immediately. If set to -1 the system will loiter at `RTL_DESCEND_ALT` rather than landing. 延迟能够使你为起落架的展开部署配置时间(自动触发)。 |
| <a id="RTL_MIN_DIST"></a>[RTL_MIN_DIST](../advanced_config/parameter_reference.md#RTL_MIN_DIST) | 能够触发无人机上升到返航高度,距离起始位置的最小水平距离由那个"锥形"指定。 If the vehicle is horizontally closer than this distance to home, it will return at its current altitude or `RTL_DESCEND_ALT` (whichever is higher) instead of first ascending to RTL_RETURN_ALT. |
| <a id="RTL_CONE_ANG"></a>[RTL_CONE_ANG](../advanced_config/parameter_reference.md#RTL_CONE_ANG) | 圆锥半角决定无人机的 RTL 返航高度。 数值(度数):0、25、45、65、80、90。 Note that 0 is "no cone" (always return at `RTL_RETURN_ALT` or higher), while 90 indicates that the vehicle must return at the current altitude or `RTL_DESCEND_ALT` (whichever is higher). |
| <a id="COM_RC_OVERRIDE"></a>[COM_RC_OVERRIDE](../advanced_config/parameter_reference.md#COM_RC_OVERRIDE) | Controls whether stick movement on a multicopter (or VTOL in MC mode) causes a mode change to [Position mode](../flight_modes_mc/position.md) (except when vehicle is handling a critical battery failsafe). 可以分别为自动模式和 offboard 模式启用此功能,默认情况下在自动模式下启用此功能。 |
| <a id="COM_RC_STICK_OV"></a>[COM_RC_STICK_OV](../advanced_config/parameter_reference.md#COM_RC_STICK_OV) | The amount of stick movement that causes a transition to [Position mode](../flight_modes_mc/position.md) (if [COM_RC_OVERRIDE](#COM_RC_OVERRIDE) is enabled). |
| <a id="RTL_LOITER_RAD"></a>[RTL_LOITER_RAD](../advanced_config/parameter_reference.md#RTL_LOITER_RAD) | [Fixed-wing Only] The radius of the loiter circle (at [RTL_LAND_DELAY](#RTL_LAND_DELAY)). |
| <a id="MIS_TKO_LAND_REQ"></a>[MIS_TKO_LAND_REQ](../advanced_config/parameter_reference.md#MIS_TKO_LAND_REQ) | Specify whether a mission landing or takeoff pattern is _required_. Generally fixed-wing vehicles set this to require a landing pattern but VTOL do not. |
| 参数 | 描述 |
| -------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| <a id="RTL_TYPE"></a>[RTL_TYPE](../advanced_config/parameter_reference.md#RTL_TYPE) | Return mechanism (path and destination).<br>`0`: Return to a rally point or home (whichever is closest) via direct path.<br>`1`: Return to a rally point or the mission landing pattern start point (whichever is closest), via direct path. 如果未定义任务着陆点或集结点,通过直接路径返回起始位置。 If the destination is a mission landing pattern, follow the pattern to land.<br>`2`: Use the mission path to landing while skipping DO_JUMP and other non-position mission items if a landing pattern is defined, otherwise fast-reverse to home with the same traversal rules. 忽略集结点。 Fly direct to home if no mission plan is defined.<br>`3`: Return via direct path to closest destination: home, start of mission landing pattern or safe point. 如果目的地是飞行任务着陆模式,则按照该模式降落。 |
| <a id="RTL_RETURN_ALT"></a>[RTL_RETURN_ALT](../advanced_config/parameter_reference.md#RTL_RETURN_ALT) | Return altitude in meters (default: 60m) when [RTL_CONE_ANG](../advanced_config/parameter_reference.md#RTL_CONE_ANG) is 0. 如果已经超过这个值, 飞机将返回当前的高度。 |
| <a id="RTL_DESCEND_ALT"></a>[RTL_DESCEND_ALT](../advanced_config/parameter_reference.md#RTL_DESCEND_ALT) | 最小返航高度和无人机从较高的返航高度到减速或者停止的初始下降高度(默认: 30米)。 |
| <a id="RTL_LAND_DELAY"></a>[RTL_LAND_DELAY](../advanced_config/parameter_reference.md#RTL_LAND_DELAY) | Time to wait at `RTL_DESCEND_ALT` before landing (default: 0.5s) -by default this period is short so that the vehicle will simply slow and then land immediately. If set to -1 the system will loiter at `RTL_DESCEND_ALT` rather than landing. 延迟能够使你为起落架的展开部署配置时间(自动触发)。 |
| <a id="RTL_MIN_DIST"></a>[RTL_MIN_DIST](../advanced_config/parameter_reference.md#RTL_MIN_DIST) | 能够触发无人机上升到返航高度,距离起始位置的最小水平距离由那个"锥形"指定。 If the vehicle is horizontally closer than this distance to home, it will return at its current altitude or `RTL_DESCEND_ALT` (whichever is higher) instead of first ascending to RTL_RETURN_ALT. |
| <a id="RTL_CONE_ANG"></a>[RTL_CONE_ANG](../advanced_config/parameter_reference.md#RTL_CONE_ANG) | 圆锥半角决定无人机的 RTL 返航高度。 数值(度数):0、25、45、65、80、90。 Note that 0 is "no cone" (always return at `RTL_RETURN_ALT` or higher), while 90 indicates that the vehicle must return at the current altitude or `RTL_DESCEND_ALT` (whichever is higher). |
| <a id="COM_RC_OVERRIDE"></a>[COM_RC_OVERRIDE](../advanced_config/parameter_reference.md#COM_RC_OVERRIDE) | Controls whether stick movement on a multicopter (or VTOL in MC mode) causes a mode change to [Position mode](../flight_modes_mc/position.md) (except when vehicle is handling a critical battery failsafe). 可以分别为自动模式和 offboard 模式启用此功能,默认情况下在自动模式下启用此功能。 |
| <a id="COM_RC_STICK_OV"></a>[COM_RC_STICK_OV](../advanced_config/parameter_reference.md#COM_RC_STICK_OV) | The amount of stick movement that causes a transition to [Position mode](../flight_modes_mc/position.md) (if [COM_RC_OVERRIDE](#COM_RC_OVERRIDE) is enabled). |
| <a id="RTL_LOITER_RAD"></a>[RTL_LOITER_RAD](../advanced_config/parameter_reference.md#RTL_LOITER_RAD) | [Fixed-wing Only] The radius of the loiter circle (at [RTL_LAND_DELAY](#RTL_LAND_DELAY)). |
| <a id="MIS_TKO_LAND_REQ"></a>[MIS_TKO_LAND_REQ](../advanced_config/parameter_reference.md#MIS_TKO_LAND_REQ) | Specify whether a mission landing or takeoff pattern is _required_. Generally fixed-wing vehicles set this to require a landing pattern but VTOL do not. |
+5 -3
View File
@@ -21,11 +21,13 @@ PX4 is an open-source autopilot for drones and autonomous vehicles. It runs on m
</div>
## Try PX4
No hardware needed. Run PX4 in simulation with a single command using [Docker or a .deb package](simulation/px4_simulation_quickstart.md). Connect [QGroundControl](https://qgroundcontrol.com), [MAVSDK](https://mavsdk.mavlink.io/), or [ROS 2](ros2/index.md) and start flying immediately.
## For Developers
:::tip
Building on PX4 or extending the platform? Start here: [Development Guide](development/development.md). Set up your [dev environment](dev_setup/config_initial.md), [build from source](dev_setup/building_px4.md), run [SITL simulation](simulation/index.md), or integrate via [ROS 2](ros2/index.md) and [MAVSDK](https://mavsdk.mavlink.io/).
:::
Want to modify PX4 or build from source? Start with the [Development Guide](development/development.md): set up your [dev environment](dev_setup/dev_env.md), [build the code](dev_setup/building_px4.md), and run [SITL simulation](simulation/index.md).
## 入门指南
+92 -34
View File
@@ -12,25 +12,37 @@ When signing is enabled, PX4 appends a 13-byte [signature](https://mavlink.io/en
Incoming messages are checked against the shared secret key, and unsigned or incorrectly signed messages are rejected (with [exceptions for safety-critical messages](#unsigned-message-allowlist)).
The signing implementation is built into the MAVLink module and is always available no special build flags are required.
It is enabled and disabled at runtime through the [MAV_SIGN_CFG](../advanced_config/parameter_reference.md#MAV_SIGN_CFG) parameter.
The signing implementation is built into the MAVLink module and is always available, with no special build flags required.
The key is stored in an SD card:
- **No key on SD card**:
Signing is disabled.
All messages are sent unsigned and all incoming messages are accepted.
- **Valid key on SD card**:
Signing is active on **all links** (including USB).
Outgoing messages are signed.
Incoming messages must be signed (with [exceptions](#unsigned-message-allowlist)).
## Enable/Disable Signing
The [MAV_SIGN_CFG](../advanced_config/parameter_reference.md#MAV_SIGN_CFG) parameter controls whether signing is active:
Signing is controlled using the standard MAVLink [SETUP_SIGNING](https://mavlink.io/en/messages/common.html#SETUP_SIGNING) message (as per the [MAVLink signing specification](https://mavlink.io/en/guide/message_signing.html)):
| 值 | 模式 | 描述 |
| - | ------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------- |
| 0 | Disabled (default) | No signing. All messages are accepted regardless of signature. |
| 1 | Non-USB | Signing is enabled on all links **except** USB serial connections. USB links accept unsigned messages. |
| 2 | Always | Signing is enforced on all links, including USB. |
- To **enable** signing, send a `SETUP_SIGNING` message with a valid key on any link when no key is currently provisioned (see [Key Provisioning](#key-provisioning)).
- To **disable** signing via MAVLink, send a `SETUP_SIGNING` message with an all-zero key and timestamp.
This message **must be signed with the current active key**.
An unsigned blank-key message is rejected.
- To **change** the signing key, send a `SETUP_SIGNING` message with the new key on any link.
When signing is already active, the message must be signed with the current key.
:::warning
Setting `MAV_SIGN_CFG` alone does not enable signing — a secret key must also be present (see [Key Provisioning](#key-provisioning) below).
If no key has been set (or the key is all zeros with a zero timestamp), all messages are accepted regardless of this parameter.
Signing key changes (enable, disable, or rotate) are **rejected while the vehicle is armed**.
The vehicle must be disarmed before signing configuration can be changed.
:::
To **disable** signing, set `MAV_SIGN_CFG` to zero.
:::tip
If the signing key is lost, you can still disable signing if you have physical access to the vehicle.
Either delete the key file (`/mavlink/mavlink-signing-key.bin`) from the SD card and reboot, or remove the SD card entirely.
:::
## Key Provisioning
@@ -40,11 +52,13 @@ This message contains:
- A 32-byte secret key
- A 64-bit initial timestamp
:::warning
For security, PX4 only accepts `SETUP_SIGNING` messages received on a **USB** connection.
The message is silently ignored on all other link types (telemetry radios, network, and so on).
This ensures that an attacker cannot remotely change the signing key.
:::
PX4 accepts `SETUP_SIGNING` on **any link** (USB, telemetry radio, network, and so on).
When signing is **not active** (no key provisioned), the first `SETUP_SIGNING` with a valid key enables signing.
When signing is **already active**, key changes (including disabling) require that the `SETUP_SIGNING` message is signed with the current key.
Note that `SETUP_SIGNING` is rejected while the vehicle is armed (disarm before provisioning or changing keys).
As per the MAVLink specification, `SETUP_SIGNING` is never forwarded to other links.
## Key Storage
@@ -64,7 +78,7 @@ The file is a 40-byte binary file:
The file is created with mode `0600` (owner read/write only), and the containing `/mavlink/` directory is created with mode `0700` (owner only).
On startup, PX4 reads the key from this file.
If the file exists and contains a non-zero key or timestamp, signing is initialized automatically.
If the file exists and contains a non-zero key or timestamp, signing is activated automatically.
:::info
The timestamp in the file is set when `SETUP_SIGNING` is received.
@@ -73,7 +87,7 @@ A graceful shutdown also writes the current timestamp back, but in practice most
:::info
Storage of the key on the SD card means that signing can be disabled by removing the card.
Note that this requires physical access to the vehicle, and therefore provides the same level of security as allowing signing to be modified via the USB channel.
Note that this requires physical access to the vehicle.
:::
## How It Works
@@ -82,45 +96,89 @@ Note that this requires physical access to the vehicle, and therefore provides t
1. The MAVLink module calls `MavlinkSignControl::start()` during startup.
2. The `/mavlink/` directory is created if it doesn't exist.
3. The `mavlink-signing-key.bin` file is opened (or created empty).
4. If a valid key is found (non-zero key or timestamp), signing is marked as initialized.
5. The `accept_unsigned` callback is registered with the MAVLink library.
3. The `mavlink-signing-key.bin` file is opened if it exists.
4. If a valid key is found (non-zero key or timestamp), signing is activated: the signing struct is wired into the MAVLink library and outgoing messages are signed.
5. If no valid key is found, the signing struct is left disconnected, and the MAVLink library operates with zero signing overhead.
### Outgoing Messages
When signing is initialized, the `MAVLINK_SIGNING_FLAG_SIGN_OUTGOING` flag is set, which causes the MAVLink library to automatically append a [SHA-256 based signature](https://mavlink.io/en/guide/message_signing.html#signature) to every outgoing MAVLink 2 message.
When signing is active (valid key present), the `MAVLINK_SIGNING_FLAG_SIGN_OUTGOING` flag is set, which causes the MAVLink library to automatically append a [SHA-256 based signature](https://mavlink.io/en/guide/message_signing.html#signature) to every outgoing MAVLink 2 message.
When no key is present, signing is completely bypassed with no CPU or bandwidth overhead.
### Incoming Messages
For each incoming message, the MAVLink library checks whether a valid signature is present.
If the message is unsigned or has an invalid signature, the library calls the `accept_unsigned` callback, which decides whether to accept or reject the message based on:
1. **Signing not initialized** If no key has been loaded, all messages are accepted.
2. **Allowlisted message** Certain [safety-critical messages](#unsigned-message-allowlist) are always accepted.
3. **Sign mode** — The `MAV_SIGN_CFG` parameter determines behavior:
- Mode 0 (disabled): All unsigned messages are accepted.
- Mode 1 (non-USB): Unsigned messages are accepted only on USB links.
- Mode 2 (always): Unsigned messages are rejected on all links.
1. **Signing not active**: If no key has been loaded, all messages are accepted.
2. **Allowlisted message**: Certain [safety-critical messages](#unsigned-message-allowlist) are always accepted.
## Unsigned Message Allowlist
The following messages are **always** accepted unsigned, regardless of the signing mode.
The following messages are **always** accepted unsigned, regardless of the signing state.
These are safety-critical messages that may originate from systems that don't support signing:
| 消息 | ID | Reason |
| -------------------------------------------------------------------------------------------- | --- | -------------------------------------------------------- |
| [HEARTBEAT](https://mavlink.io/en/messages/common.html#HEARTBEAT) | 0 | System discovery and liveness detection |
| [RADIO_STATUS](https://mavlink.io/en/messages/common.html#RADIO_STATUS) | 109 | Radio link status from SiK radios and other radio modems |
| [ADSB_VEHICLE](https://mavlink.io/en/messages/common.html#ADSB_VEHICLE) | 246 | ADS-B traffic information for collision avoidance |
| [COLLISION](https://mavlink.io/en/messages/common.html#COLLISION) | 247 | Collision threat warnings |
## Security Considerations
- **Physical access required for key setup**: The `SETUP_SIGNING` message is only accepted over USB, so an attacker must have physical access to the vehicle to provision or change the key.
### Signing is enforced on all links
When signing is active, **all links require signed messages**.
This means:
- An attacker cannot send unsigned commands on any link.
- Changing or disabling the key requires sending a `SETUP_SIGNING` message **signed with the current key**.
- Signing can be disabled via MAVLink by sending a signed `SETUP_SIGNING` with an all-zero key.
### Armed guard
`SETUP_SIGNING` is rejected while the vehicle is armed.
This prevents the signing configuration from being changed during flight, whether by accident or by an attacker who has obtained the key.
### Lost key recovery
If the signing key is lost on the GCS side and no device has the current key:
- **Remove the SD card** and delete `/mavlink/mavlink-signing-key.bin`, then reboot.
- **Reflash via SWD/JTAG** if the SD card is not accessible.
:::warning
There is no software-only recovery path for a lost key.
This is intentional: any MAVLink-based recovery mechanism would also be available to an attacker.
Physical access to the SD card or debug port is required.
:::
### Other considerations
- **Initial key provisioning**: When no key is provisioned, `SETUP_SIGNING` is accepted unsigned on any link.
Once a key is active, subsequent changes require a signed message.
Provision the initial key over a trusted connection, such as USB.
- **Key not exposed via parameters**: The secret key is stored in a separate file on the SD card, not as a MAVLink parameter, so it cannot be read back through the parameter protocol.
- **SD card access**: Anyone with physical access to the SD card can read or modify the `mavlink-signing-key.bin` file, or just remove the card.
- **SD card access**: Anyone with physical access to the SD card can read or modify the `mavlink-signing-key.bin` file, or remove the card entirely to disable signing.
Ensure physical security of the vehicle if signing is used as a security control.
- **Replay protection**: The MAVLink signing protocol includes a timestamp that prevents replay attacks.
The on-disk timestamp is updated when a new key is provisioned via `SETUP_SIGNING`.
A graceful shutdown also persists the current timestamp, but since most vehicles are powered off by pulling the battery, the timestamp will typically reset to the value from the last key provisioning on reboot.
- **No encryption**: Message signing provides authentication and integrity, but messages are still sent in plaintext.
An eavesdropper can read message contents but cannot forge or modify them without the key.
A graceful shutdown also persists the current timestamp, but since most vehicles are powered off by pulling the battery, the on-disk timestamp will typically remain at the value from the last key provisioning on reboot.
- **No encryption**: Message signing provides **authentication and integrity only**.
Messages are still sent in plaintext.
An eavesdropper can read all message contents (telemetry, commands, parameters, missions) but cannot forge or modify them without the key.
- **Allowlisted messages bypass signing**: A small set of [safety-critical messages](#unsigned-message-allowlist) are always accepted unsigned.
An attacker can spoof these specific messages (e.g. fake `ADSB_VEHICLE` traffic) even when signing is active.
### What signing does NOT protect against
| Attack | Why |
| ----------------------------------------------------- | ------------------------------------------------------- |
| Eavesdropping | Messages are not encrypted |
| SD card extraction | Key file is readable by anyone with physical access |
| Spoofed `HEARTBEAT`/`RADIO_STATUS`/`ADSB`/`COLLISION` | These are allowlisted unsigned |
| Lost key without SD card access | Requires SWD reflash |
| Key rotation | No automatic mechanism; manual re-provisioning required |
| In-flight key changes | `SETUP_SIGNING` rejected while armed |
+33 -13
View File
@@ -37,22 +37,32 @@ See [Message Signing](message_signing.md) for full details.
Steps:
1. Connect the vehicle via **USB** (key provisioning only works over USB).
2. Provision a 32-byte secret key using the [SETUP_SIGNING](https://mavlink.io/en/messages/common.html#SETUP_SIGNING) message.
3. Set [MAV_SIGN_CFG](../advanced_config/parameter_reference.md#MAV_SIGN_CFG) to **1** (signing enabled on all links except USB) or **2** (signing on all links including USB).
4. Provision the same key on all ground control stations and companion computers that need to communicate with the vehicle.
5. Verify that unsigned messages from unknown sources are rejected.
1. Connect to the vehicle over a **trusted link** (USB or other secure connection).
2. Provision a 32-byte secret key using the [SETUP_SIGNING](https://mavlink.io/en/messages/common.html#SETUP_SIGNING) message. This works on any link, but use a trusted one for initial provisioning.
3. Provision the same key on all ground control stations and companion computers that need to communicate with the vehicle.
4. Verify that unsigned messages from unknown sources are rejected.
:::info
`MAV_SIGN_CFG=1` is recommended for most deployments.
This enforces signing on telemetry radios and network links while allowing unsigned access over USB for maintenance.
USB connections require physical access to the vehicle, which provides equivalent security to physical key access.
Once a key is provisioned, signing is enforced automatically on **all links** (including USB).
Changing or disabling the key requires a signed `SETUP_SIGNING` message.
Signing changes are rejected while the vehicle is armed.
Signing can also be disabled by physically removing the key file from the SD card.
:::
### 2. Secure Physical Access
- Protect access to the SD card. The signing key is stored at `/mavlink/mavlink-signing-key.bin` and can be read or removed by anyone with physical access.
- USB connections bypass signing when `MAV_SIGN_CFG=1`. Ensure USB ports are not exposed in deployed configurations.
- **SD card**: The signing key is stored at `/mavlink/mavlink-signing-key.bin`.
Anyone with physical access to the SD card can read, modify, or remove the key file.
- **USB ports**: USB follows the same signing rules as all other links.
When signing is active, USB requires signed messages.
- **Debug ports (SWD/JTAG)**: If exposed, [Debug Ports](../debug/swd_debug.md) allow full firmware reflash and bypass all software security.
Not all vehicles expose debug connectors.
:::warning
Signing protects all MAVLink links.
The primary physical attack surface is the SD card (key file extraction or deletion).
If your threat model includes physical access, secure the SD card slot and debug ports.
:::
### 3. Secure Network Links
@@ -63,9 +73,19 @@ USB connections require physical access to the vehicle, which provides equivalen
### 4. Understand the Limitations
- **No encryption**: Message signing provides authentication and integrity, but messages are sent in plaintext. An eavesdropper can read telemetry and commands but cannot forge them.
- **Allowlisted messages**: A small set of [safety-critical messages](message_signing.md#unsigned-message-allowlist) (RADIO_STATUS, ADSB_VEHICLE, COLLISION) are always accepted unsigned.
- **Key management**: There is no automatic key rotation. Keys must be reprovisioned manually via USB if compromised.
- **No encryption**:
Message signing provides authentication and integrity, but messages are sent in plaintext.
An eavesdropper can read telemetry and commands but cannot forge them.
- **Allowlisted messages**:
A small set of [safety-critical messages](message_signing.md#unsigned-message-allowlist) (`HEARTBEAT`, `RADIO_STATUS`, `ADSB_VEHICLE`, `COLLISION`) are always accepted unsigned on all links.
An attacker could spoof these specific messages.
- **Key management**:
There is no automatic key rotation.
Keys must be reprovisioned manually via a signed `SETUP_SIGNING` message.
- **Lost key recovery**:
If the signing key is lost on all GCS devices, the only recovery is physical: remove the SD card and delete the key file, or reflash via SWD/JTAG.
There is no software-only recovery path.
See [Message Signing: Lost Key Recovery](message_signing.md#lost-key-recovery) for details.
## Integrator Responsibility
+193 -191
View File
@@ -96,208 +96,210 @@ They are not build into the module, and hence are neither published or subscribe
:::details
See messages
- [NavigatorStatus](../msg_docs/NavigatorStatus.md)
- [OpenDroneIdSystem](../msg_docs/OpenDroneIdSystem.md)
- [VehicleOpticalFlow](../msg_docs/VehicleOpticalFlow.md)
- [DistanceSensorModeChangeRequest](../msg_docs/DistanceSensorModeChangeRequest.md)
- [EstimatorAidSource3d](../msg_docs/EstimatorAidSource3d.md)
- [SatelliteInfo](../msg_docs/SatelliteInfo.md)
- [GimbalDeviceInformation](../msg_docs/GimbalDeviceInformation.md)
- [FixedWingLateralGuidanceStatus](../msg_docs/FixedWingLateralGuidanceStatus.md)
- [GeofenceResult](../msg_docs/GeofenceResult.md)
- [TiltrotorExtraControls](../msg_docs/TiltrotorExtraControls.md)
- [QshellReq](../msg_docs/QshellReq.md)
- [VehicleCommandAckV0](../msg_docs/VehicleCommandAckV0.md)
- [VehicleImu](../msg_docs/VehicleImu.md)
- [PositionControllerLandingStatus](../msg_docs/PositionControllerLandingStatus.md)
- [EstimatorSensorBias](../msg_docs/EstimatorSensorBias.md)
- [GpioRequest](../msg_docs/GpioRequest.md)
- [UavcanParameterValue](../msg_docs/UavcanParameterValue.md)
- [ParameterResetRequest](../msg_docs/ParameterResetRequest.md)
- [EstimatorBias3d](../msg_docs/EstimatorBias3d.md)
- [CameraStatus](../msg_docs/CameraStatus.md)
- [UavcanParameterRequest](../msg_docs/UavcanParameterRequest.md)
- [VehicleStatusV1](../msg_docs/VehicleStatusV1.md)
- [MountOrientation](../msg_docs/MountOrientation.md)
- [Gripper](../msg_docs/Gripper.md)
- [RtlStatus](../msg_docs/RtlStatus.md)
- [PositionSetpoint](../msg_docs/PositionSetpoint.md)
- [GpsInjectData](../msg_docs/GpsInjectData.md)
- [Cpuload](../msg_docs/Cpuload.md)
- [SensorAccelFifo](../msg_docs/SensorAccelFifo.md)
- [EstimatorAidSource2d](../msg_docs/EstimatorAidSource2d.md)
- [HoverThrustEstimate](../msg_docs/HoverThrustEstimate.md)
- [HealthReport](../msg_docs/HealthReport.md)
- [DatamanRequest](../msg_docs/DatamanRequest.md)
- [FailureDetectorStatus](../msg_docs/FailureDetectorStatus.md)
- [RangingBeacon](../msg_docs/RangingBeacon.md)
- [AirspeedWind](../msg_docs/AirspeedWind.md)
- [VelocityLimits](../msg_docs/VelocityLimits.md)
- [SensorGyro](../msg_docs/SensorGyro.md)
- [GimbalControls](../msg_docs/GimbalControls.md)
- [LandingTargetInnovations](../msg_docs/LandingTargetInnovations.md)
- [YawEstimatorStatus](../msg_docs/YawEstimatorStatus.md)
- [NeuralControl](../msg_docs/NeuralControl.md)
- [DebugArray](../msg_docs/DebugArray.md)
- [WheelEncoders](../msg_docs/WheelEncoders.md)
- [EstimatorSelectorStatus](../msg_docs/EstimatorSelectorStatus.md)
- [ConfigOverridesV0](../msg_docs/ConfigOverridesV0.md)
- [NormalizedUnsignedSetpoint](../msg_docs/NormalizedUnsignedSetpoint.md)
- [VehicleStatusV0](../msg_docs/VehicleStatusV0.md)
- [SensorGnssRelative](../msg_docs/SensorGnssRelative.md)
- [SensorGyroFft](../msg_docs/SensorGyroFft.md)
- [GpioOut](../msg_docs/GpioOut.md)
- [OpenDroneIdSelfId](../msg_docs/OpenDroneIdSelfId.md)
- [RaptorStatus](../msg_docs/RaptorStatus.md)
- [VehicleGlobalPositionV0](../msg_docs/VehicleGlobalPositionV0.md)
- [OrbTestLarge](../msg_docs/OrbTestLarge.md)
- [MissionResult](../msg_docs/MissionResult.md)
- [GeofenceStatus](../msg_docs/GeofenceStatus.md)
- [VehicleAngularVelocity](../msg_docs/VehicleAngularVelocity.md)
- [DifferentialPressure](../msg_docs/DifferentialPressure.md)
- [IrlockReport](../msg_docs/IrlockReport.md)
- [PowerMonitor](../msg_docs/PowerMonitor.md)
- [ArmingCheckRequestV0](../msg_docs/ArmingCheckRequestV0.md)
- [Ping](../msg_docs/Ping.md)
- [DeviceInformation](../msg_docs/DeviceInformation.md)
- [VehicleStatusV2](../msg_docs/VehicleStatusV2.md)
- [EstimatorStatus](../msg_docs/EstimatorStatus.md)
- [HeaterStatus](../msg_docs/HeaterStatus.md)
- [SensorMag](../msg_docs/SensorMag.md)
- [ParameterSetUsedRequest](../msg_docs/ParameterSetUsedRequest.md)
- [LaunchDetectionStatus](../msg_docs/LaunchDetectionStatus.md)
- [GpioConfig](../msg_docs/GpioConfig.md)
- [ParameterResetRequest](../msg_docs/ParameterResetRequest.md)
- [PwmInput](../msg_docs/PwmInput.md)
- [DebugValue](../msg_docs/DebugValue.md)
- [FixedWingLateralStatus](../msg_docs/FixedWingLateralStatus.md)
- [MavlinkLog](../msg_docs/MavlinkLog.md)
- [UlogStreamAck](../msg_docs/UlogStreamAck.md)
- [EventV0](../msg_docs/EventV0.md)
- [FixedWingRunwayControl](../msg_docs/FixedWingRunwayControl.md)
- [EscEepromRead](../msg_docs/EscEepromRead.md)
- [TecsStatus](../msg_docs/TecsStatus.md)
- [UlogStream](../msg_docs/UlogStream.md)
- [ParameterSetValueRequest](../msg_docs/ParameterSetValueRequest.md)
- [VehicleConstraints](../msg_docs/VehicleConstraints.md)
- [Ekf2Timestamps](../msg_docs/Ekf2Timestamps.md)
- [RoverSpeedStatus](../msg_docs/RoverSpeedStatus.md)
- [PositionControllerStatus](../msg_docs/PositionControllerStatus.md)
- [DebugArray](../msg_docs/DebugArray.md)
- [DifferentialPressure](../msg_docs/DifferentialPressure.md)
- [GimbalDeviceInformation](../msg_docs/GimbalDeviceInformation.md)
- [FlightPhaseEstimation](../msg_docs/FlightPhaseEstimation.md)
- [EstimatorEventFlags](../msg_docs/EstimatorEventFlags.md)
- [GpsDump](../msg_docs/GpsDump.md)
- [OrbTestLarge](../msg_docs/OrbTestLarge.md)
- [VehicleImuStatus](../msg_docs/VehicleImuStatus.md)
- [SensorBaro](../msg_docs/SensorBaro.md)
- [SensorsStatus](../msg_docs/SensorsStatus.md)
- [TrajectorySetpoint6dof](../msg_docs/TrajectorySetpoint6dof.md)
- [IridiumsbdStatus](../msg_docs/IridiumsbdStatus.md)
- [Mission](../msg_docs/Mission.md)
- [VehicleLocalPositionV0](../msg_docs/VehicleLocalPositionV0.md)
- [OpenDroneIdArmStatus](../msg_docs/OpenDroneIdArmStatus.md)
- [NeuralControl](../msg_docs/NeuralControl.md)
- [NormalizedUnsignedSetpoint](../msg_docs/NormalizedUnsignedSetpoint.md)
- [ActuatorArmed](../msg_docs/ActuatorArmed.md)
- [GainCompression](../msg_docs/GainCompression.md)
- [GimbalDeviceSetAttitude](../msg_docs/GimbalDeviceSetAttitude.md)
- [GimbalManagerInformation](../msg_docs/GimbalManagerInformation.md)
- [EscStatus](../msg_docs/EscStatus.md)
- [AutotuneAttitudeControlStatus](../msg_docs/AutotuneAttitudeControlStatus.md)
- [FailureDetectorStatus](../msg_docs/FailureDetectorStatus.md)
- [HoverThrustEstimate](../msg_docs/HoverThrustEstimate.md)
- [EstimatorStates](../msg_docs/EstimatorStates.md)
- [VehicleImu](../msg_docs/VehicleImu.md)
- [GeofenceResult](../msg_docs/GeofenceResult.md)
- [VehicleGlobalPositionV0](../msg_docs/VehicleGlobalPositionV0.md)
- [CanInterfaceStatus](../msg_docs/CanInterfaceStatus.md)
- [MissionResult](../msg_docs/MissionResult.md)
- [DistanceSensorModeChangeRequest](../msg_docs/DistanceSensorModeChangeRequest.md)
- [RangingBeacon](../msg_docs/RangingBeacon.md)
- [OrbitStatus](../msg_docs/OrbitStatus.md)
- [MavlinkTunnel](../msg_docs/MavlinkTunnel.md)
- [CameraCapture](../msg_docs/CameraCapture.md)
- [ManualControlSwitches](../msg_docs/ManualControlSwitches.md)
- [RaptorInput](../msg_docs/RaptorInput.md)
- [VehicleStatusV2](../msg_docs/VehicleStatusV2.md)
- [ArmingCheckRequestV0](../msg_docs/ArmingCheckRequestV0.md)
- [VehicleAngularAccelerationSetpoint](../msg_docs/VehicleAngularAccelerationSetpoint.md)
- [OrbTestMedium](../msg_docs/OrbTestMedium.md)
- [TiltrotorExtraControls](../msg_docs/TiltrotorExtraControls.md)
- [UavcanParameterValue](../msg_docs/UavcanParameterValue.md)
- [Gripper](../msg_docs/Gripper.md)
- [FollowTarget](../msg_docs/FollowTarget.md)
- [SensorsStatusImu](../msg_docs/SensorsStatusImu.md)
- [ConfigOverridesV0](../msg_docs/ConfigOverridesV0.md)
- [SatelliteInfo](../msg_docs/SatelliteInfo.md)
- [PowerButtonState](../msg_docs/PowerButtonState.md)
- [DeviceInformation](../msg_docs/DeviceInformation.md)
- [ActuatorServosTrim](../msg_docs/ActuatorServosTrim.md)
- [AirspeedValidatedV0](../msg_docs/AirspeedValidatedV0.md)
- [RegisterExtComponentRequestV1](../msg_docs/RegisterExtComponentRequestV1.md)
- [BatteryStatusV0](../msg_docs/BatteryStatusV0.md)
- [EscEepromWrite](../msg_docs/EscEepromWrite.md)
- [ActionRequest](../msg_docs/ActionRequest.md)
- [InternalCombustionEngineStatus](../msg_docs/InternalCombustionEngineStatus.md)
- [LogMessage](../msg_docs/LogMessage.md)
- [SensorGyroFifo](../msg_docs/SensorGyroFifo.md)
- [IrlockReport](../msg_docs/IrlockReport.md)
- [CellularStatus](../msg_docs/CellularStatus.md)
- [ActuatorOutputs](../msg_docs/ActuatorOutputs.md)
- [FollowTargetStatus](../msg_docs/FollowTargetStatus.md)
- [SystemPower](../msg_docs/SystemPower.md)
- [SensorAccel](../msg_docs/SensorAccel.md)
- [Vtx](../msg_docs/Vtx.md)
- [EstimatorInnovations](../msg_docs/EstimatorInnovations.md)
- [VehicleStatusV1](../msg_docs/VehicleStatusV1.md)
- [SensorGyroFft](../msg_docs/SensorGyroFft.md)
- [ParameterUpdate](../msg_docs/ParameterUpdate.md)
- [Ekf2Timestamps](../msg_docs/Ekf2Timestamps.md)
- [SensorGnssRelative](../msg_docs/SensorGnssRelative.md)
- [VehicleLocalPositionSetpoint](../msg_docs/VehicleLocalPositionSetpoint.md)
- [SensorAirflow](../msg_docs/SensorAirflow.md)
- [DebugKeyValue](../msg_docs/DebugKeyValue.md)
- [Event](../msg_docs/Event.md)
- [MountOrientation](../msg_docs/MountOrientation.md)
- [EstimatorFusionControl](../msg_docs/EstimatorFusionControl.md)
- [VehicleAcceleration](../msg_docs/VehicleAcceleration.md)
- [EstimatorGpsStatus](../msg_docs/EstimatorGpsStatus.md)
- [MagnetometerBiasEstimate](../msg_docs/MagnetometerBiasEstimate.md)
- [LandingTargetInnovations](../msg_docs/LandingTargetInnovations.md)
- [VehicleOpticalFlowVel](../msg_docs/VehicleOpticalFlowVel.md)
- [Mission](../msg_docs/Mission.md)
- [VehicleAirData](../msg_docs/VehicleAirData.md)
- [SensorBaro](../msg_docs/SensorBaro.md)
- [RegisterExtComponentReplyV0](../msg_docs/RegisterExtComponentReplyV0.md)
- [Px4ioStatus](../msg_docs/Px4ioStatus.md)
- [TecsStatus](../msg_docs/TecsStatus.md)
- [InternalCombustionEngineControl](../msg_docs/InternalCombustionEngineControl.md)
- [RcChannels](../msg_docs/RcChannels.md)
- [DebugVect](../msg_docs/DebugVect.md)
- [AirspeedWind](../msg_docs/AirspeedWind.md)
- [QshellRetval](../msg_docs/QshellRetval.md)
- [SensorUwb](../msg_docs/SensorUwb.md)
- [HomePositionV0](../msg_docs/HomePositionV0.md)
- [GimbalManagerSetAttitude](../msg_docs/GimbalManagerSetAttitude.md)
- [CameraTrigger](../msg_docs/CameraTrigger.md)
- [PositionSetpoint](../msg_docs/PositionSetpoint.md)
- [VehicleStatusV0](../msg_docs/VehicleStatusV0.md)
- [BatteryInfo](../msg_docs/BatteryInfo.md)
- [FuelTankStatus](../msg_docs/FuelTankStatus.md)
- [Rpm](../msg_docs/Rpm.md)
- [RateCtrlStatus](../msg_docs/RateCtrlStatus.md)
- [ControlAllocatorStatus](../msg_docs/ControlAllocatorStatus.md)
- [AdcReport](../msg_docs/AdcReport.md)
- [Cpuload](../msg_docs/Cpuload.md)
- [FigureEightStatus](../msg_docs/FigureEightStatus.md)
- [RoverAttitudeStatus](../msg_docs/RoverAttitudeStatus.md)
- [VehicleConstraints](../msg_docs/VehicleConstraints.md)
- [SensorGnssStatus](../msg_docs/SensorGnssStatus.md)
- [RcParameterMap](../msg_docs/RcParameterMap.md)
- [VehicleStatusV3](../msg_docs/VehicleStatusV3.md)
- [GpsInjectData](../msg_docs/GpsInjectData.md)
- [FixedWingLateralGuidanceStatus](../msg_docs/FixedWingLateralGuidanceStatus.md)
- [ButtonEvent](../msg_docs/ButtonEvent.md)
- [PpsCapture](../msg_docs/PpsCapture.md)
- [LoggerStatus](../msg_docs/LoggerStatus.md)
- [InternalCombustionEngineStatus](../msg_docs/InternalCombustionEngineStatus.md)
- [ManualControlSwitches](../msg_docs/ManualControlSwitches.md)
- [TakeoffStatus](../msg_docs/TakeoffStatus.md)
- [TuneControl](../msg_docs/TuneControl.md)
- [VelocityLimits](../msg_docs/VelocityLimits.md)
- [DatamanRequest](../msg_docs/DatamanRequest.md)
- [HeaterStatus](../msg_docs/HeaterStatus.md)
- [LogMessage](../msg_docs/LogMessage.md)
- [SensorMag](../msg_docs/SensorMag.md)
- [GpioOut](../msg_docs/GpioOut.md)
- [YawEstimatorStatus](../msg_docs/YawEstimatorStatus.md)
- [SensorHygrometer](../msg_docs/SensorHygrometer.md)
- [DronecanNodeStatus](../msg_docs/DronecanNodeStatus.md)
- [EstimatorSelectorStatus](../msg_docs/EstimatorSelectorStatus.md)
- [IridiumsbdStatus](../msg_docs/IridiumsbdStatus.md)
- [PowerMonitor](../msg_docs/PowerMonitor.md)
- [RegisterExtComponentRequestV0](../msg_docs/RegisterExtComponentRequestV0.md)
- [VehicleOpticalFlow](../msg_docs/VehicleOpticalFlow.md)
- [GimbalManagerStatus](../msg_docs/GimbalManagerStatus.md)
- [EstimatorStatus](../msg_docs/EstimatorStatus.md)
- [OpenDroneIdOperatorId](../msg_docs/OpenDroneIdOperatorId.md)
- [RtlTimeEstimate](../msg_docs/RtlTimeEstimate.md)
- [GpioIn](../msg_docs/GpioIn.md)
- [ParameterSetValueRequest](../msg_docs/ParameterSetValueRequest.md)
- [GeneratorStatus](../msg_docs/GeneratorStatus.md)
- [MagWorkerData](../msg_docs/MagWorkerData.md)
- [ActuatorControlsStatus](../msg_docs/ActuatorControlsStatus.md)
- [LedControl](../msg_docs/LedControl.md)
- [VehicleAngularVelocity](../msg_docs/VehicleAngularVelocity.md)
- [SensorAccelFifo](../msg_docs/SensorAccelFifo.md)
- [OpenDroneIdSystem](../msg_docs/OpenDroneIdSystem.md)
- [SensorGyro](../msg_docs/SensorGyro.md)
- [NavigatorMissionItem](../msg_docs/NavigatorMissionItem.md)
- [DatamanResponse](../msg_docs/DatamanResponse.md)
- [GeofenceStatus](../msg_docs/GeofenceStatus.md)
- [VehicleLocalPositionV0](../msg_docs/VehicleLocalPositionV0.md)
- [TrajectorySetpoint6dof](../msg_docs/TrajectorySetpoint6dof.md)
- [SensorTemp](../msg_docs/SensorTemp.md)
- [EstimatorBias](../msg_docs/EstimatorBias.md)
- [OpenDroneIdSelfId](../msg_docs/OpenDroneIdSelfId.md)
- [SensorsStatus](../msg_docs/SensorsStatus.md)
- [EstimatorAidSource1d](../msg_docs/EstimatorAidSource1d.md)
- [RaptorStatus](../msg_docs/RaptorStatus.md)
- [ParameterSetValueResponse](../msg_docs/ParameterSetValueResponse.md)
- [RoverRateStatus](../msg_docs/RoverRateStatus.md)
- [PurePursuitStatus](../msg_docs/PurePursuitStatus.md)
- [TaskStackInfo](../msg_docs/TaskStackInfo.md)
- [CameraStatus](../msg_docs/CameraStatus.md)
- [WheelEncoders](../msg_docs/WheelEncoders.md)
- [GimbalManagerSetManualControl](../msg_docs/GimbalManagerSetManualControl.md)
- [UlogStream](../msg_docs/UlogStream.md)
- [SensorGyroFifo](../msg_docs/SensorGyroFifo.md)
- [QshellReq](../msg_docs/QshellReq.md)
- [SensorPreflightMag](../msg_docs/SensorPreflightMag.md)
- [NavigatorStatus](../msg_docs/NavigatorStatus.md)
- [LandingTargetPose](../msg_docs/LandingTargetPose.md)
- [EstimatorSensorBias](../msg_docs/EstimatorSensorBias.md)
- [SensorSelection](../msg_docs/SensorSelection.md)
- [VehicleMagnetometer](../msg_docs/VehicleMagnetometer.md)
- [ActuatorTest](../msg_docs/ActuatorTest.md)
- [SensorGnssStatus](../msg_docs/SensorGnssStatus.md)
- [TaskStackInfo](../msg_docs/TaskStackInfo.md)
- [PositionControllerStatus](../msg_docs/PositionControllerStatus.md)
- [AdcReport](../msg_docs/AdcReport.md)
- [UlogStreamAck](../msg_docs/UlogStreamAck.md)
- [TakeoffStatus](../msg_docs/TakeoffStatus.md)
- [FollowTargetEstimator](../msg_docs/FollowTargetEstimator.md)
- [OpenDroneIdArmStatus](../msg_docs/OpenDroneIdArmStatus.md)
- [VehicleOpticalFlowVel](../msg_docs/VehicleOpticalFlowVel.md)
- [FixedWingRunwayControl](../msg_docs/FixedWingRunwayControl.md)
- [GpioConfig](../msg_docs/GpioConfig.md)
- [SensorPreflightMag](../msg_docs/SensorPreflightMag.md)
- [OrbitStatus](../msg_docs/OrbitStatus.md)
- [Rpm](../msg_docs/Rpm.md)
- [InputRc](../msg_docs/InputRc.md)
- [SensorTemp](../msg_docs/SensorTemp.md)
- [TuneControl](../msg_docs/TuneControl.md)
- [SensorAccel](../msg_docs/SensorAccel.md)
- [CameraTrigger](../msg_docs/CameraTrigger.md)
- [GimbalManagerSetManualControl](../msg_docs/GimbalManagerSetManualControl.md)
- [PurePursuitStatus](../msg_docs/PurePursuitStatus.md)
- [CanInterfaceStatus](../msg_docs/CanInterfaceStatus.md)
- [AirspeedValidatedV0](../msg_docs/AirspeedValidatedV0.md)
- [EstimatorBias](../msg_docs/EstimatorBias.md)
- [RtlTimeEstimate](../msg_docs/RtlTimeEstimate.md)
- [MagWorkerData](../msg_docs/MagWorkerData.md)
- [PowerButtonState](../msg_docs/PowerButtonState.md)
- [QshellRetval](../msg_docs/QshellRetval.md)
- [RcChannels](../msg_docs/RcChannels.md)
- [Px4ioStatus](../msg_docs/Px4ioStatus.md)
- [ActuatorControlsStatus](../msg_docs/ActuatorControlsStatus.md)
- [FlightPhaseEstimation](../msg_docs/FlightPhaseEstimation.md)
- [EstimatorGpsStatus](../msg_docs/EstimatorGpsStatus.md)
- [EscEepromWrite](../msg_docs/EscEepromWrite.md)
- [OpenDroneIdOperatorId](../msg_docs/OpenDroneIdOperatorId.md)
- [GimbalDeviceSetAttitude](../msg_docs/GimbalDeviceSetAttitude.md)
- [VehicleAttitudeSetpointV0](../msg_docs/VehicleAttitudeSetpointV0.md)
- [CellularStatus](../msg_docs/CellularStatus.md)
- [BatteryStatusV0](../msg_docs/BatteryStatusV0.md)
- [ButtonEvent](../msg_docs/ButtonEvent.md)
- [SystemPower](../msg_docs/SystemPower.md)
- [FuelTankStatus](../msg_docs/FuelTankStatus.md)
- [LandingGearWheel](../msg_docs/LandingGearWheel.md)
- [VehicleLocalPositionSetpoint](../msg_docs/VehicleLocalPositionSetpoint.md)
- [DronecanNodeStatus](../msg_docs/DronecanNodeStatus.md)
- [SensorCorrection](../msg_docs/SensorCorrection.md)
- [SensorHygrometer](../msg_docs/SensorHygrometer.md)
- [EscReport](../msg_docs/EscReport.md)
- [EstimatorAidSource1d](../msg_docs/EstimatorAidSource1d.md)
- [MavlinkTunnel](../msg_docs/MavlinkTunnel.md)
- [ParameterUpdate](../msg_docs/ParameterUpdate.md)
- [GimbalManagerStatus](../msg_docs/GimbalManagerStatus.md)
- [GimbalManagerInformation](../msg_docs/GimbalManagerInformation.md)
- [SensorSelection](../msg_docs/SensorSelection.md)
- [DebugValue](../msg_docs/DebugValue.md)
- [GpioIn](../msg_docs/GpioIn.md)
- [RateCtrlStatus](../msg_docs/RateCtrlStatus.md)
- [EstimatorFusionControl](../msg_docs/EstimatorFusionControl.md)
- [LaunchDetectionStatus](../msg_docs/LaunchDetectionStatus.md)
- [DatamanResponse](../msg_docs/DatamanResponse.md)
- [ControlAllocatorStatus](../msg_docs/ControlAllocatorStatus.md)
- [Vtx](../msg_docs/Vtx.md)
- [Event](../msg_docs/Event.md)
- [OrbTest](../msg_docs/OrbTest.md)
- [BatteryInfo](../msg_docs/BatteryInfo.md)
- [RoverRateStatus](../msg_docs/RoverRateStatus.md)
- [VehicleAcceleration](../msg_docs/VehicleAcceleration.md)
- [RcParameterMap](../msg_docs/RcParameterMap.md)
- [InternalCombustionEngineControl](../msg_docs/InternalCombustionEngineControl.md)
- [RoverSpeedStatus](../msg_docs/RoverSpeedStatus.md)
- [MagnetometerBiasEstimate](../msg_docs/MagnetometerBiasEstimate.md)
- [PwmInput](../msg_docs/PwmInput.md)
- [NavigatorMissionItem](../msg_docs/NavigatorMissionItem.md)
- [RadioStatus](../msg_docs/RadioStatus.md)
- [ArmingCheckReplyV0](../msg_docs/ArmingCheckReplyV0.md)
- [VehicleAirData](../msg_docs/VehicleAirData.md)
- [ActuatorOutputs](../msg_docs/ActuatorOutputs.md)
- [GimbalManagerSetAttitude](../msg_docs/GimbalManagerSetAttitude.md)
- [EstimatorInnovations](../msg_docs/EstimatorInnovations.md)
- [RoverAttitudeStatus](../msg_docs/RoverAttitudeStatus.md)
- [EstimatorStates](../msg_docs/EstimatorStates.md)
- [LedControl](../msg_docs/LedControl.md)
- [RegisterExtComponentRequestV0](../msg_docs/RegisterExtComponentRequestV0.md)
- [EstimatorEventFlags](../msg_docs/EstimatorEventFlags.md)
- [FixedWingLateralStatus](../msg_docs/FixedWingLateralStatus.md)
- [VehicleAngularAccelerationSetpoint](../msg_docs/VehicleAngularAccelerationSetpoint.md)
- [ActuatorArmed](../msg_docs/ActuatorArmed.md)
- [SensorsStatusImu](../msg_docs/SensorsStatusImu.md)
- [OrbTestMedium](../msg_docs/OrbTestMedium.md)
- [MavlinkLog](../msg_docs/MavlinkLog.md)
- [ParameterSetValueResponse](../msg_docs/ParameterSetValueResponse.md)
- [EventV0](../msg_docs/EventV0.md)
- [GpsDump](../msg_docs/GpsDump.md)
- [GeneratorStatus](../msg_docs/GeneratorStatus.md)
- [LandingTargetPose](../msg_docs/LandingTargetPose.md)
- [DebugKeyValue](../msg_docs/DebugKeyValue.md)
- [GainCompression](../msg_docs/GainCompression.md)
- [VehicleRoi](../msg_docs/VehicleRoi.md)
- [FollowTargetStatus](../msg_docs/FollowTargetStatus.md)
- [FollowTarget](../msg_docs/FollowTarget.md)
- [SensorUwb](../msg_docs/SensorUwb.md)
- [PpsCapture](../msg_docs/PpsCapture.md)
- [HomePositionV0](../msg_docs/HomePositionV0.md)
- [LoggerStatus](../msg_docs/LoggerStatus.md)
- [RegisterExtComponentReplyV0](../msg_docs/RegisterExtComponentReplyV0.md)
- [SensorAirflow](../msg_docs/SensorAirflow.md)
- [DebugVect](../msg_docs/DebugVect.md)
- [ActuatorServosTrim](../msg_docs/ActuatorServosTrim.md)
- [Ping](../msg_docs/Ping.md)
- [Airspeed](../msg_docs/Airspeed.md)
- [RaptorInput](../msg_docs/RaptorInput.md)
- [GpioRequest](../msg_docs/GpioRequest.md)
- [ArmingCheckReplyV0](../msg_docs/ArmingCheckReplyV0.md)
- [EstimatorAidSource2d](../msg_docs/EstimatorAidSource2d.md)
- [OrbTest](../msg_docs/OrbTest.md)
- [RadioStatus](../msg_docs/RadioStatus.md)
- [PositionControllerLandingStatus](../msg_docs/PositionControllerLandingStatus.md)
- [EscReport](../msg_docs/EscReport.md)
- [VehicleAttitudeSetpointV0](../msg_docs/VehicleAttitudeSetpointV0.md)
- [ParameterSetUsedRequest](../msg_docs/ParameterSetUsedRequest.md)
- [VehicleCommandAckV0](../msg_docs/VehicleCommandAckV0.md)
- [AutotuneAttitudeControlStatus](../msg_docs/AutotuneAttitudeControlStatus.md)
- [SensorCorrection](../msg_docs/SensorCorrection.md)
- [LandingGearWheel](../msg_docs/LandingGearWheel.md)
- [FollowTargetEstimator](../msg_docs/FollowTargetEstimator.md)
- [UavcanParameterRequest](../msg_docs/UavcanParameterRequest.md)
- [VehicleRoi](../msg_docs/VehicleRoi.md)
- [EstimatorBias3d](../msg_docs/EstimatorBias3d.md)
- [HealthReport](../msg_docs/HealthReport.md)
- [RtlStatus](../msg_docs/RtlStatus.md)
:::
+26
View File
@@ -790,6 +790,32 @@ lsm303d <command> [arguments...]
status print status info
```
## lsm6dsv
Source: [drivers/imu/st/lsm6dsv](https://github.com/PX4/PX4-Autopilot/tree/main/src/drivers/imu/st/lsm6dsv)
### Usage {#lsm6dsv_usage}
```
lsm6dsv <command> [arguments...]
Commands:
start
[-s] Internal SPI bus(es)
[-S] External SPI bus(es)
[-b <val>] board-specific bus (default=all) (external SPI: n-th bus
(default=1))
[-c <val>] chip-select pin (for internal SPI) or index (for external SPI)
[-m <val>] SPI mode
[-f <val>] bus frequency in kHz
[-q] quiet startup (no message if no device found)
[-R <val>] Rotation
default: 0
stop
status print status info
```
## lsm9ds1
Source: [drivers/imu/st/lsm9ds1](https://github.com/PX4/PX4-Autopilot/tree/main/src/drivers/imu/st/lsm9ds1)
+4 -2
View File
@@ -46,10 +46,11 @@ The flag comments are used as label for the failsafe state machine simulation
| battery_warning | `uint8` | | | Battery warning level (see BatteryStatus.msg) |
| battery_low_remaining_time | `bool` | | | Low battery based on remaining flight time |
| battery_unhealthy | `bool` | | | Battery unhealthy |
| fd_critical_failure | `bool` | | | Critical failure (attitude/altitude limit exceeded, or external ATS) |
| fd_critical_failure | `bool` | | | Critical failure (attitude limit exceeded, or external ATS) |
| fd_esc_arming_failure | `bool` | | | ESC failed to arm |
| fd_imbalanced_prop | `bool` | | | Imbalanced propeller detected |
| fd_motor_failure | `bool` | | | Motor failure |
| fd_alt_loss | `bool` | | | Uncommanded altitude loss (rotary-wing, altitude-controlled flight) |
| geofence_breached | `bool` | | | Geofence breached (one or multiple) |
| mission_failure | `bool` | | | Mission failure |
| vtol_fixed_wing_system_failure | `bool` | | | vehicle in fixed-wing system failure failsafe mode (after quad-chute) |
@@ -114,10 +115,11 @@ bool battery_low_remaining_time # Low battery based on remaining flight ti
bool battery_unhealthy # Battery unhealthy
# Failure detector
bool fd_critical_failure # Critical failure (attitude/altitude limit exceeded, or external ATS)
bool fd_critical_failure # Critical failure (attitude limit exceeded, or external ATS)
bool fd_esc_arming_failure # ESC failed to arm
bool fd_imbalanced_prop # Imbalanced propeller detected
bool fd_motor_failure # Motor failure
bool fd_alt_loss # Uncommanded altitude loss (rotary-wing, altitude-controlled flight)
# Other
bool geofence_breached # Geofence breached (one or multiple)
@@ -23,12 +23,13 @@ Request to register an external component.
| replace_internal_mode | `uint8` | | | vehicle_status::NAVIGATION_STATE_\* |
| activate_mode_immediately | `bool` | | | switch to the registered mode (can only be set in combination with an executor) |
| not_user_selectable | `bool` | | | mode cannot be selected by the user |
| request_offboard_setpoints | `bool` | | | set to true if the registered mode wants to receive offboard trajectory setpoints via MAVLink |
## Constants
| 参数名 | 类型 | 值 | 描述 |
| --------------------------------------------------------------------------------------------------------------------------------------------------------- | -------- | - | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| <a id="#MESSAGE_VERSION"></a> MESSAGE_VERSION | `uint32` | 1 | |
| <a id="#MESSAGE_VERSION"></a> MESSAGE_VERSION | `uint32` | 2 | |
| <a id="#LATEST_PX4_ROS2_API_VERSION"></a> LATEST_PX4_ROS2_API_VERSION | `uint16` | 1 | API version compatibility. Increase this on a breaking semantic change. Changes to any message field are detected separately and do not require an API version change. |
| <a id="#ORB_QUEUE_LENGTH"></a> ORB_QUEUE_LENGTH | `uint8` | 2 | |
@@ -42,7 +43,7 @@ Click here to see original file
```c
# Request to register an external component
uint32 MESSAGE_VERSION = 1
uint32 MESSAGE_VERSION = 2
uint64 timestamp # time since system start (microseconds)
@@ -62,6 +63,7 @@ bool enable_replace_internal_mode # set to true if an internal mode should be r
uint8 replace_internal_mode # vehicle_status::NAVIGATION_STATE_*
bool activate_mode_immediately # switch to the registered mode (can only be set in combination with an executor)
bool not_user_selectable # mode cannot be selected by the user
bool request_offboard_setpoints # set to true if the registered mode wants to receive offboard trajectory setpoints via MAVLink
uint8 ORB_QUEUE_LENGTH = 2
```
@@ -0,0 +1,69 @@
---
pageClass: is-wide-page
---
# RegisterExtComponentRequestV1 (UORB message)
Request to register an external component.
**TOPICS:** register_ext_component_request_v1
## Fields
| 参数名 | 类型 | Unit [Frame] | Range/Enum | 描述 |
| ------------------------------------------------------------------------------------------- | ---------- | ---------------------------------------------------------------- | ---------- | -------------------------------------------------------------------------------------------------------------------------- |
| timestamp | `uint64` | | | time since system start (microseconds) |
| request_id | `uint64` | | | ID, set this to a random value |
| name | `char[25]` | | | either the requested mode name, or component name |
| px4_ros2_api_version | `uint16` | | | Set to LATEST_PX4_ROS2_API_VERSION |
| register_arming_check | `bool` | | | |
| register_mode | `bool` | | | registering a mode also requires arming_check to be set |
| register_mode_executor | `bool` | | | registering an executor also requires a mode to be registered (which is the owned mode by the executor) |
| enable_replace_internal_mode | `bool` | | | set to true if an internal mode should be replaced |
| replace_internal_mode | `uint8` | | | vehicle_status::NAVIGATION_STATE_\* |
| activate_mode_immediately | `bool` | | | switch to the registered mode (can only be set in combination with an executor) |
| not_user_selectable | `bool` | | | mode cannot be selected by the user |
## Constants
| 参数名 | 类型 | 值 | 描述 |
| --------------------------------------------------------------------------------------------------------------------------------------------------------- | -------- | - | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| <a id="#MESSAGE_VERSION"></a> MESSAGE_VERSION | `uint32` | 1 | |
| <a id="#LATEST_PX4_ROS2_API_VERSION"></a> LATEST_PX4_ROS2_API_VERSION | `uint16` | 1 | API version compatibility. Increase this on a breaking semantic change. Changes to any message field are detected separately and do not require an API version change. |
| <a id="#ORB_QUEUE_LENGTH"></a> ORB_QUEUE_LENGTH | `uint8` | 2 | |
## Source Message
[Source file (GitHub)](https://github.com/PX4/PX4-Autopilot/blob/main/msg/px4_msgs_old/msg/RegisterExtComponentRequestV1.msg)
:::details
Click here to see original file
```c
# Request to register an external component
uint32 MESSAGE_VERSION = 1
uint64 timestamp # time since system start (microseconds)
uint64 request_id # ID, set this to a random value
char[25] name # either the requested mode name, or component name
uint16 LATEST_PX4_ROS2_API_VERSION = 1 # API version compatibility. Increase this on a breaking semantic change. Changes to any message field are detected separately and do not require an API version change.
uint16 px4_ros2_api_version # Set to LATEST_PX4_ROS2_API_VERSION
# Components to be registered
bool register_arming_check
bool register_mode # registering a mode also requires arming_check to be set
bool register_mode_executor # registering an executor also requires a mode to be registered (which is the owned mode by the executor)
bool enable_replace_internal_mode # set to true if an internal mode should be replaced
uint8 replace_internal_mode # vehicle_status::NAVIGATION_STATE_*
bool activate_mode_immediately # switch to the registered mode (can only be set in combination with an executor)
bool not_user_selectable # mode cannot be selected by the user
uint8 ORB_QUEUE_LENGTH = 2
```
:::
+5 -2
View File
@@ -23,6 +23,7 @@ Encodes the system state of the vehicle published by commander.
| nav_state | `uint8` | | | Currently active mode |
| executor_in_charge | `uint8` | | | Current mode executor in charge (0=Autopilot) |
| nav_state_display | `uint8` | | | User-visible nav state sent via MAVLink (executor state if active, otherwise nav_state) |
| accepts_offboard_setpoints | `bool` | | | True if the current mode accepts offboard trajectory setpoints via MAVLink |
| valid_nav_states_mask | `uint32` | | | Bitmask for all valid nav_state values |
| can_set_nav_states_mask | `uint32` | | | Bitmask for all modes that a user can select |
| hil_state | `uint8` | | | |
@@ -57,7 +58,7 @@ Encodes the system state of the vehicle published by commander.
| 参数名 | 类型 | 值 | 描述 |
| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------- | -- | ----------------------------------------------------- |
| <a id="#MESSAGE_VERSION"></a> MESSAGE_VERSION | `uint32` | 3 | |
| <a id="#MESSAGE_VERSION"></a> MESSAGE_VERSION | `uint32` | 4 | |
| <a id="#ARMING_STATE_DISARMED"></a> ARMING_STATE_DISARMED | `uint8` | 1 | |
| <a id="#ARMING_STATE_ARMED"></a> ARMING_STATE_ARMED | `uint8` | 2 | |
| <a id="#ARM_DISARM_REASON_STICK_GESTURE"></a> ARM_DISARM_REASON_STICK_GESTURE | `uint8` | 1 | |
@@ -122,7 +123,7 @@ Click here to see original file
```c
# Encodes the system state of the vehicle published by commander
uint32 MESSAGE_VERSION = 3
uint32 MESSAGE_VERSION = 4
uint64 timestamp # time since system start (microseconds)
@@ -187,6 +188,8 @@ uint8 NAVIGATION_STATE_MAX = 31
uint8 executor_in_charge # Current mode executor in charge (0=Autopilot)
uint8 nav_state_display # User-visible nav state sent via MAVLink (executor state if active, otherwise nav_state)
bool accepts_offboard_setpoints # True if the current mode accepts offboard trajectory setpoints via MAVLink
uint32 valid_nav_states_mask # Bitmask for all valid nav_state values
uint32 can_set_nav_states_mask # Bitmask for all modes that a user can select
+248
View File
@@ -0,0 +1,248 @@
---
pageClass: is-wide-page
---
# VehicleStatusV3 (UORB message)
Encodes the system state of the vehicle published by commander.
**TOPICS:** vehicle_status_v3
## Fields
| 参数名 | 类型 | Unit [Frame] | Range/Enum | 描述 |
| ---------------------------------------------------------------------------------------------------------------- | -------- | ---------------------------------------------------------------- | ---------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| timestamp | `uint64` | | | time since system start (microseconds) |
| armed_time | `uint64` | | | Arming timestamp (microseconds) |
| takeoff_time | `uint64` | | | Takeoff timestamp (microseconds) |
| arming_state | `uint8` | | | |
| latest_arming_reason | `uint8` | | | |
| latest_disarming_reason | `uint8` | | | |
| nav_state_timestamp | `uint64` | | | time when current nav_state activated |
| nav_state_user_intention | `uint8` | | | Mode that the user selected (might be different from nav_state in a failsafe situation) |
| nav_state | `uint8` | | | Currently active mode |
| executor_in_charge | `uint8` | | | Current mode executor in charge (0=Autopilot) |
| nav_state_display | `uint8` | | | User-visible nav state sent via MAVLink (executor state if active, otherwise nav_state) |
| valid_nav_states_mask | `uint32` | | | Bitmask for all valid nav_state values |
| can_set_nav_states_mask | `uint32` | | | Bitmask for all modes that a user can select |
| hil_state | `uint8` | | | |
| vehicle_type | `uint8` | | | |
| failsafe | `bool` | | | true if system is in failsafe state (e.g.:RTL, Hover, Terminate, ...) |
| failsafe_and_user_took_over | `bool` | | | true if system is in failsafe state but the user took over control |
| failsafe_defer_state | `uint8` | | | one of FAILSAFE_DEFER_STATE_\* |
| gcs_connection_lost | `bool` | | | datalink to GCS lost |
| gcs_connection_lost_counter | `uint8` | | | counts unique GCS connection lost events |
| high_latency_data_link_lost | `bool` | | | Set to true if the high latency data link (eg. RockBlock Iridium 9603 telemetry module) is lost |
| is_vtol | `bool` | | | True if the system is VTOL capable |
| is_vtol_tailsitter | `bool` | | | True if the system performs a 90° pitch down rotation during transition from MC to FW |
| in_transition_mode | `bool` | | | True if VTOL is doing a transition |
| in_transition_to_fw | `bool` | | | True if VTOL is doing a transition from MC to FW |
| system_type | `uint8` | | | system type, contains mavlink MAV_TYPE |
| system_id | `uint8` | | | system id, contains MAVLink's system ID field |
| component_id | `uint8` | | | subsystem / component id, contains MAVLink's component ID field |
| safety_button_available | `bool` | | | Set to true if a safety button is connected |
| safety_off | `bool` | | | Set to true if safety is off |
| power_input_valid | `bool` | | | set if input power is valid |
| usb_connected | `bool` | | | set to true (never cleared) once telemetry received from usb link |
| open_drone_id_system_present | `bool` | | | |
| open_drone_id_system_healthy | `bool` | | | |
| parachute_system_present | `bool` | | | |
| parachute_system_healthy | `bool` | | | |
| traffic_avoidance_system_present | `bool` | | | |
| rc_calibration_in_progress | `bool` | | | |
| calibration_enabled | `bool` | | | |
| pre_flight_checks_pass | `bool` | | | true if all checks necessary to arm pass |
## Constants
| 参数名 | 类型 | 值 | 描述 |
| --------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------- | -- | ----------------------------------------------------- |
| <a id="#MESSAGE_VERSION"></a> MESSAGE_VERSION | `uint32` | 3 | |
| <a id="#ARMING_STATE_DISARMED"></a> ARMING_STATE_DISARMED | `uint8` | 1 | |
| <a id="#ARMING_STATE_ARMED"></a> ARMING_STATE_ARMED | `uint8` | 2 | |
| <a id="#ARM_DISARM_REASON_STICK_GESTURE"></a> ARM_DISARM_REASON_STICK_GESTURE | `uint8` | 1 | |
| <a id="#ARM_DISARM_REASON_RC_SWITCH"></a> ARM_DISARM_REASON_RC_SWITCH | `uint8` | 2 | |
| <a id="#ARM_DISARM_REASON_COMMAND_INTERNAL"></a> ARM_DISARM_REASON_COMMAND_INTERNAL | `uint8` | 3 | |
| <a id="#ARM_DISARM_REASON_COMMAND_EXTERNAL"></a> ARM_DISARM_REASON_COMMAND_EXTERNAL | `uint8` | 4 | |
| <a id="#ARM_DISARM_REASON_MISSION_START"></a> ARM_DISARM_REASON_MISSION_START | `uint8` | 5 | |
| <a id="#ARM_DISARM_REASON_LANDING"></a> ARM_DISARM_REASON_LANDING | `uint8` | 6 | |
| <a id="#ARM_DISARM_REASON_PREFLIGHT_INACTION"></a> ARM_DISARM_REASON_PREFLIGHT_INACTION | `uint8` | 7 | |
| <a id="#ARM_DISARM_REASON_KILL_SWITCH"></a> ARM_DISARM_REASON_KILL_SWITCH | `uint8` | 8 | |
| <a id="#ARM_DISARM_REASON_RC_BUTTON"></a> ARM_DISARM_REASON_RC_BUTTON | `uint8` | 13 | |
| <a id="#ARM_DISARM_REASON_FAILSAFE"></a> ARM_DISARM_REASON_FAILSAFE | `uint8` | 14 | |
| <a id="#NAVIGATION_STATE_MANUAL"></a> NAVIGATION_STATE_MANUAL | `uint8` | 0 | Manual mode |
| <a id="#NAVIGATION_STATE_ALTCTL"></a> NAVIGATION_STATE_ALTCTL | `uint8` | 1 | Altitude control mode |
| <a id="#NAVIGATION_STATE_POSCTL"></a> NAVIGATION_STATE_POSCTL | `uint8` | 2 | Position control mode |
| <a id="#NAVIGATION_STATE_AUTO_MISSION"></a> NAVIGATION_STATE_AUTO_MISSION | `uint8` | 3 | Auto mission mode |
| <a id="#NAVIGATION_STATE_AUTO_LOITER"></a> NAVIGATION_STATE_AUTO_LOITER | `uint8` | 4 | Auto loiter mode |
| <a id="#NAVIGATION_STATE_AUTO_RTL"></a> NAVIGATION_STATE_AUTO_RTL | `uint8` | 5 | Auto return to launch mode |
| <a id="#NAVIGATION_STATE_POSITION_SLOW"></a> NAVIGATION_STATE_POSITION_SLOW | `uint8` | 6 | |
| <a id="#NAVIGATION_STATE_FREE5"></a> NAVIGATION_STATE_FREE5 | `uint8` | 7 | |
| <a id="#NAVIGATION_STATE_ALTITUDE_CRUISE"></a> NAVIGATION_STATE_ALTITUDE_CRUISE | `uint8` | 8 | Altitude with Cruise mode |
| <a id="#NAVIGATION_STATE_FREE3"></a> NAVIGATION_STATE_FREE3 | `uint8` | 9 | |
| <a id="#NAVIGATION_STATE_ACRO"></a> NAVIGATION_STATE_ACRO | `uint8` | 10 | Acro mode |
| <a id="#NAVIGATION_STATE_FREE2"></a> NAVIGATION_STATE_FREE2 | `uint8` | 11 | |
| <a id="#NAVIGATION_STATE_DESCEND"></a> NAVIGATION_STATE_DESCEND | `uint8` | 12 | Descend mode (no position control) |
| <a id="#NAVIGATION_STATE_TERMINATION"></a> NAVIGATION_STATE_TERMINATION | `uint8` | 13 | Termination mode |
| <a id="#NAVIGATION_STATE_OFFBOARD"></a> NAVIGATION_STATE_OFFBOARD | `uint8` | 14 | |
| <a id="#NAVIGATION_STATE_STAB"></a> NAVIGATION_STATE_STAB | `uint8` | 15 | Stabilized mode |
| <a id="#NAVIGATION_STATE_FREE1"></a> NAVIGATION_STATE_FREE1 | `uint8` | 16 | |
| <a id="#NAVIGATION_STATE_AUTO_TAKEOFF"></a> NAVIGATION_STATE_AUTO_TAKEOFF | `uint8` | 17 | Takeoff |
| <a id="#NAVIGATION_STATE_AUTO_LAND"></a> NAVIGATION_STATE_AUTO_LAND | `uint8` | 18 | Land |
| <a id="#NAVIGATION_STATE_AUTO_FOLLOW_TARGET"></a> NAVIGATION_STATE_AUTO_FOLLOW_TARGET | `uint8` | 19 | Auto Follow |
| <a id="#NAVIGATION_STATE_AUTO_PRECLAND"></a> NAVIGATION_STATE_AUTO_PRECLAND | `uint8` | 20 | Precision land with landing target |
| <a id="#NAVIGATION_STATE_ORBIT"></a> NAVIGATION_STATE_ORBIT | `uint8` | 21 | Orbit in a circle |
| <a id="#NAVIGATION_STATE_AUTO_VTOL_TAKEOFF"></a> NAVIGATION_STATE_AUTO_VTOL_TAKEOFF | `uint8` | 22 | Takeoff, transition, establish loiter |
| <a id="#NAVIGATION_STATE_EXTERNAL1"></a> NAVIGATION_STATE_EXTERNAL1 | `uint8` | 23 | |
| <a id="#NAVIGATION_STATE_EXTERNAL2"></a> NAVIGATION_STATE_EXTERNAL2 | `uint8` | 24 | |
| <a id="#NAVIGATION_STATE_EXTERNAL3"></a> NAVIGATION_STATE_EXTERNAL3 | `uint8` | 25 | |
| <a id="#NAVIGATION_STATE_EXTERNAL4"></a> NAVIGATION_STATE_EXTERNAL4 | `uint8` | 26 | |
| <a id="#NAVIGATION_STATE_EXTERNAL5"></a> NAVIGATION_STATE_EXTERNAL5 | `uint8` | 27 | |
| <a id="#NAVIGATION_STATE_EXTERNAL6"></a> NAVIGATION_STATE_EXTERNAL6 | `uint8` | 28 | |
| <a id="#NAVIGATION_STATE_EXTERNAL7"></a> NAVIGATION_STATE_EXTERNAL7 | `uint8` | 29 | |
| <a id="#NAVIGATION_STATE_EXTERNAL8"></a> NAVIGATION_STATE_EXTERNAL8 | `uint8` | 30 | |
| <a id="#NAVIGATION_STATE_MAX"></a> NAVIGATION_STATE_MAX | `uint8` | 31 | |
| <a id="#HIL_STATE_OFF"></a> HIL_STATE_OFF | `uint8` | 0 | |
| <a id="#HIL_STATE_ON"></a> HIL_STATE_ON | `uint8` | 1 | |
| <a id="#VEHICLE_TYPE_UNSPECIFIED"></a> VEHICLE_TYPE_UNSPECIFIED | `uint8` | 0 | |
| <a id="#VEHICLE_TYPE_ROTARY_WING"></a> VEHICLE_TYPE_ROTARY_WING | `uint8` | 1 | |
| <a id="#VEHICLE_TYPE_FIXED_WING"></a> VEHICLE_TYPE_FIXED_WING | `uint8` | 2 | |
| <a id="#VEHICLE_TYPE_ROVER"></a> VEHICLE_TYPE_ROVER | `uint8` | 3 | |
| <a id="#FAILSAFE_DEFER_STATE_DISABLED"></a> FAILSAFE_DEFER_STATE_DISABLED | `uint8` | 0 | |
| <a id="#FAILSAFE_DEFER_STATE_ENABLED"></a> FAILSAFE_DEFER_STATE_ENABLED | `uint8` | 1 | |
| <a id="#FAILSAFE_DEFER_STATE_WOULD_FAILSAFE"></a> FAILSAFE_DEFER_STATE_WOULD_FAILSAFE | `uint8` | 2 | Failsafes deferred, but would trigger a failsafe |
## Source Message
[Source file (GitHub)](https://github.com/PX4/PX4-Autopilot/blob/main/msg/px4_msgs_old/msg/VehicleStatusV3.msg)
:::details
Click here to see original file
```c
# Encodes the system state of the vehicle published by commander
uint32 MESSAGE_VERSION = 3
uint64 timestamp # time since system start (microseconds)
uint64 armed_time # Arming timestamp (microseconds)
uint64 takeoff_time # Takeoff timestamp (microseconds)
uint8 arming_state
uint8 ARMING_STATE_DISARMED = 1
uint8 ARMING_STATE_ARMED = 2
uint8 latest_arming_reason
uint8 latest_disarming_reason
uint8 ARM_DISARM_REASON_STICK_GESTURE = 1
uint8 ARM_DISARM_REASON_RC_SWITCH = 2
uint8 ARM_DISARM_REASON_COMMAND_INTERNAL = 3
uint8 ARM_DISARM_REASON_COMMAND_EXTERNAL = 4
uint8 ARM_DISARM_REASON_MISSION_START = 5
uint8 ARM_DISARM_REASON_LANDING = 6
uint8 ARM_DISARM_REASON_PREFLIGHT_INACTION = 7
uint8 ARM_DISARM_REASON_KILL_SWITCH = 8
uint8 ARM_DISARM_REASON_RC_BUTTON = 13
uint8 ARM_DISARM_REASON_FAILSAFE = 14
uint64 nav_state_timestamp # time when current nav_state activated
uint8 nav_state_user_intention # Mode that the user selected (might be different from nav_state in a failsafe situation)
uint8 nav_state # Currently active mode
uint8 NAVIGATION_STATE_MANUAL = 0 # Manual mode
uint8 NAVIGATION_STATE_ALTCTL = 1 # Altitude control mode
uint8 NAVIGATION_STATE_POSCTL = 2 # Position control mode
uint8 NAVIGATION_STATE_AUTO_MISSION = 3 # Auto mission mode
uint8 NAVIGATION_STATE_AUTO_LOITER = 4 # Auto loiter mode
uint8 NAVIGATION_STATE_AUTO_RTL = 5 # Auto return to launch mode
uint8 NAVIGATION_STATE_POSITION_SLOW = 6
uint8 NAVIGATION_STATE_FREE5 = 7
uint8 NAVIGATION_STATE_ALTITUDE_CRUISE = 8 # Altitude with Cruise mode
uint8 NAVIGATION_STATE_FREE3 = 9
uint8 NAVIGATION_STATE_ACRO = 10 # Acro mode
uint8 NAVIGATION_STATE_FREE2 = 11
uint8 NAVIGATION_STATE_DESCEND = 12 # Descend mode (no position control)
uint8 NAVIGATION_STATE_TERMINATION = 13 # Termination mode
uint8 NAVIGATION_STATE_OFFBOARD = 14
uint8 NAVIGATION_STATE_STAB = 15 # Stabilized mode
uint8 NAVIGATION_STATE_FREE1 = 16
uint8 NAVIGATION_STATE_AUTO_TAKEOFF = 17 # Takeoff
uint8 NAVIGATION_STATE_AUTO_LAND = 18 # Land
uint8 NAVIGATION_STATE_AUTO_FOLLOW_TARGET = 19 # Auto Follow
uint8 NAVIGATION_STATE_AUTO_PRECLAND = 20 # Precision land with landing target
uint8 NAVIGATION_STATE_ORBIT = 21 # Orbit in a circle
uint8 NAVIGATION_STATE_AUTO_VTOL_TAKEOFF = 22 # Takeoff, transition, establish loiter
uint8 NAVIGATION_STATE_EXTERNAL1 = 23
uint8 NAVIGATION_STATE_EXTERNAL2 = 24
uint8 NAVIGATION_STATE_EXTERNAL3 = 25
uint8 NAVIGATION_STATE_EXTERNAL4 = 26
uint8 NAVIGATION_STATE_EXTERNAL5 = 27
uint8 NAVIGATION_STATE_EXTERNAL6 = 28
uint8 NAVIGATION_STATE_EXTERNAL7 = 29
uint8 NAVIGATION_STATE_EXTERNAL8 = 30
uint8 NAVIGATION_STATE_MAX = 31
uint8 executor_in_charge # Current mode executor in charge (0=Autopilot)
uint8 nav_state_display # User-visible nav state sent via MAVLink (executor state if active, otherwise nav_state)
uint32 valid_nav_states_mask # Bitmask for all valid nav_state values
uint32 can_set_nav_states_mask # Bitmask for all modes that a user can select
uint8 hil_state
uint8 HIL_STATE_OFF = 0
uint8 HIL_STATE_ON = 1
# Current vehicle locomotion method. A vehicle can have different methods (e.g. VTOL transitions from RW to FW method)
uint8 vehicle_type
uint8 VEHICLE_TYPE_UNSPECIFIED = 0
uint8 VEHICLE_TYPE_ROTARY_WING = 1
uint8 VEHICLE_TYPE_FIXED_WING = 2
uint8 VEHICLE_TYPE_ROVER = 3
uint8 FAILSAFE_DEFER_STATE_DISABLED = 0
uint8 FAILSAFE_DEFER_STATE_ENABLED = 1
uint8 FAILSAFE_DEFER_STATE_WOULD_FAILSAFE = 2 # Failsafes deferred, but would trigger a failsafe
bool failsafe # true if system is in failsafe state (e.g.:RTL, Hover, Terminate, ...)
bool failsafe_and_user_took_over # true if system is in failsafe state but the user took over control
uint8 failsafe_defer_state # one of FAILSAFE_DEFER_STATE_*
# Link loss
bool gcs_connection_lost # datalink to GCS lost
uint8 gcs_connection_lost_counter # counts unique GCS connection lost events
bool high_latency_data_link_lost # Set to true if the high latency data link (eg. RockBlock Iridium 9603 telemetry module) is lost
# VTOL flags
bool is_vtol # True if the system is VTOL capable
bool is_vtol_tailsitter # True if the system performs a 90° pitch down rotation during transition from MC to FW
bool in_transition_mode # True if VTOL is doing a transition
bool in_transition_to_fw # True if VTOL is doing a transition from MC to FW
# MAVLink identification
uint8 system_type # system type, contains mavlink MAV_TYPE
uint8 system_id # system id, contains MAVLink's system ID field
uint8 component_id # subsystem / component id, contains MAVLink's component ID field
bool safety_button_available # Set to true if a safety button is connected
bool safety_off # Set to true if safety is off
bool power_input_valid # set if input power is valid
bool usb_connected # set to true (never cleared) once telemetry received from usb link
bool open_drone_id_system_present
bool open_drone_id_system_healthy
bool parachute_system_present
bool parachute_system_healthy
bool traffic_avoidance_system_present
bool rc_calibration_in_progress
bool calibration_enabled
bool pre_flight_checks_pass # true if all checks necessary to arm pass
```
:::
+2
View File
@@ -271,6 +271,7 @@ Graphs showing how these are used [can be found here](../middleware/uorb_graph.m
- [HomePositionV0](HomePositionV0.md) — GPS home position in WGS84 coordinates.
- [RegisterExtComponentReplyV0](RegisterExtComponentReplyV0.md)
- [RegisterExtComponentRequestV0](RegisterExtComponentRequestV0.md) — Request to register an external component.
- [RegisterExtComponentRequestV1](RegisterExtComponentRequestV1.md) — Request to register an external component.
- [VehicleAttitudeSetpointV0](VehicleAttitudeSetpointV0.md)
- [VehicleCommandAckV0](VehicleCommandAckV0.md) — Vehicle Command Ackonwledgement uORB message. Used for acknowledging the vehicle command being received. Follows the MAVLink COMMAND_ACK message definition.
- [VehicleGlobalPositionV0](VehicleGlobalPositionV0.md) — Fused global position in WGS84. This struct contains global position estimation. It is not the raw GPS. measurement (@see vehicle_gps_position). This topic is usually published by the position. estimator, which will take more sources of information into account than just GPS,. e.g. control inputs of the vehicle in a Kalman-filter implementation.
@@ -278,3 +279,4 @@ Graphs showing how these are used [can be found here](../middleware/uorb_graph.m
- [VehicleStatusV0](VehicleStatusV0.md) — Encodes the system state of the vehicle published by commander.
- [VehicleStatusV1](VehicleStatusV1.md) — Encodes the system state of the vehicle published by commander.
- [VehicleStatusV2](VehicleStatusV2.md) — Encodes the system state of the vehicle published by commander.
- [VehicleStatusV3](VehicleStatusV3.md) — Encodes the system state of the vehicle published by commander.
+1 -1
View File
@@ -67,7 +67,7 @@ Please continue reading for [upgrade instructions](#upgrade-guide).
### Control
- **[Offboard]** [ros2 offboard control](../flight_modes/offboard.md#ros-2-messages) allows for direct motors and servo control ([PX4-Autopilot#22222](https://github.com/PX4/PX4-Autopilot/pull/22222))
- **[Offboard]** [ros2 offboard control](../flight_modes/offboard.md#ros-2-offboard-control) allows for direct motors and servo control ([PX4-Autopilot#22222](https://github.com/PX4/PX4-Autopilot/pull/22222))
### Estimation
+1 -1
View File
@@ -79,7 +79,7 @@ Please continue reading for [upgrade instructions](#upgrade-guide).
- Add synthetic mecanum rover model: [PX4-gazebo-models#113](https://github.com/PX4/PX4-gazebo-models/pull/113)
- Update synthetic ackermann rover model: [PX4-gazebo-models#117](https://github.com/PX4/PX4-gazebo-models/pull/117)
- [Simulation-in-Hardware (SIH)](../sim_sih/index.md#compatibility) <!-- Listed in https://docs.px4.io/main/en/sim_sih/#compatibility : Check the PRs -->
- [Simulation-in-Hardware (SIH)](../sim_sih/index.md#supported-vehicle-types) <!-- Listed in https://docs.px4.io/main/en/sim_sih/#compatibility : Check the PRs -->
- New simulation: MC Hexacopter X
- New simulation: Ackermann Rover
+31 -19
View File
@@ -1,14 +1,39 @@
# SIH on Flight Controller Hardware
SIH can run directly on flight controller hardware with `SYS_HITL=2`.
This replaces real sensors with simulated data while running on the actual autopilot, useful for testing without propellers.
[SIH](../sim_sih/index.md) can run directly on flight controller hardware with `SYS_AUTOSTART` set to the desired value for the frame.
This replaces real sensors with simulated data while running on the actual autopilot.
For a comparison of SIH and HITL on hardware, see [Hardware Simulation](../simulation/hardware.md).
## Starting SIH
1. Connect the flight controller to QGroundControl via USB.
2. Set `SYS_AUTOSTART` parameter to the desired airframe.
3. Reboot the flight controller.
4. The SIH module starts automatically and provides simulated sensor data.
:::tip
To ensure there is no leftover parameter from previous setup, it is recommended to reset all the parameters to firmware's default before modifying `SYS_AUTOSTART`.
:::
The following airframes are supported.
| SIH Airframe | SYS_AUTOSTART | Status |
| --------------- | ---------------------------------- | ------------ |
| Quadrotor X | 1100 | Stable |
| Airplane | 1101 | Experimental |
| Tailsitter Duo | 1102 | Experimental |
| 标准垂起固定翼 | 1103 | Experimental |
| Ackermann Rover | 1104 | Experimental |
| Hexacopter X | 1105 | Experimental |
Once running, the vehicle can be controlled from QGroundControl or an RC controller.
## Firmware Builds with SIH
The SIH module is included in many, but not all, default firmware builds.
This list can change between PX4 releases. Always verify using the method in [Check if SIH is in Firmware](#check-if-sih-is-in-firmware).
This list can change between PX4 releases.
Always verify using the method in [Check if SIH is in Firmware](#check-if-sih-is-in-firmware).
The table below lists build targets that include SIH at the time of writing:
@@ -73,7 +98,8 @@ You can add SIH to any board -- see [Check if SIH is in Firmware](#check-if-sih-
## Check if SIH is in Firmware
SIH is included in most default firmware builds. To verify, search for `sih` in the parameter list in QGroundControl. If `SIH_*` parameters are available, the module is included.
SIH is included in [most default firmware builds](#check-if-sih-is-in-firmware).
To verify, search for `sih` in the parameter list in QGroundControl. If `SIH_*` parameters are available, the module is included.
To add SIH to a custom build, enable it in the board configuration:
@@ -81,20 +107,6 @@ To add SIH to a custom build, enable it in the board configuration:
CONFIG_MODULES_SIMULATION_SIMULATOR_SIH=y
```
## Starting SIH
1. Connect the flight controller to QGroundControl via USB.
2. Set `SYS_HITL` parameter to `2`.
3. Reboot the flight controller.
4. The SIH module starts automatically and provides simulated sensor data.
Once running, the vehicle can be controlled from QGroundControl or an RC controller.
:::warning
To save flash memory on boards with limited storage, SIH can be built with only quadrotor support.
Set `SIH_VEHICLE_TYPE` before building to limit included vehicle models.
:::
## Visualization (Optional) {#hardware-visualization}
If you need a visual aid to see what the simulated vehicle is doing on hardware:
@@ -117,7 +129,7 @@ On macOS, this is typically `/dev/tty.usbmodem*`.
## Controlling Actuators
:::warning
If you want to control throttling actuators in SIH, make sure to remove propellers for safety.
If you want to control throttle actuators in SIH, make sure to remove propellers for safety.
:::
In some scenarios, it may be useful to control an actuator while running SIH on hardware. For example, you might want to verify that winches or grippers are functioning correctly by checking the servo responses.
+35 -11
View File
@@ -6,13 +6,18 @@ SIH (Simulation-In-Hardware) is a lightweight, headless simulator with zero exte
No GUI, no external processes, no rendering overhead — just PX4 running a C++ physics model.
This makes it the fastest way to iterate on flight code.
:::tip
SIH is also available as a [prebuilt Docker container or .deb package](../simulation/px4_sitl_prebuilt_packages.md), which is useful if you don't need to modify PX4 itself.
See [PX4 Simulation QuickStart](../simulation/px4_simulation_quickstart.md) for a one-line instruction on how this is used.
:::
## 综述
SIH runs as a PX4 module that replaces real sensor and actuator hardware with a simulated physics model.
It provides simulated IMU, GPS, barometer, magnetometer, and airspeed sensor data via uORB, and reads actuator outputs to update the vehicle state at each timestep.
The simulation runs in lockstep with PX4, ensuring deterministic and reproducible results.
It also integrates seamlessly with ROS 2 via with no additional configuration (see [ROS 2 Integration](#ros-2-integration) below).
It also integrates seamlessly with ROS 2 with no additional configuration (see [ROS 2 Integration](#ros-2-integration) below).
Two modes are supported:
@@ -35,7 +40,7 @@ The following vehicle types are supported:
| Ackermann Rover <Badge type="tip" text="PX4 v1.16" /> | `make px4_sitl_sih sihsim_rover` | Experimental |
:::warning
Only the quadrotor vehicle type is stable and recommended for development. All other vehicle types (hexarotor, fixed-wing, VTOL, rover) are experimental and may have aerodynamic model or controller interaction issues that produce unrealistic flight behavior.
Only the quadrotor vehicle type is stable and recommended for development. All other vehicle types (hexarotor, fixed-wing, VTOL, rover) are experimental and may have aerodynamic model or controller interaction issues that produce unrealistic flight behaviour.
:::
### How SIH Works
@@ -92,7 +97,7 @@ Flags:
- `-a` for airplane model
- `-t` for tailsitter model
- `-o` enable display-only mode.
- `-o` enables display-only mode.
See [jMAVSim Display-Only Mode](../sim_jmavsim/index.md#display-only-mode) for details.
@@ -199,9 +204,13 @@ Each instance allocates ports automatically (all offset by instance number):
See [Port Reference](#port-reference) for the complete list of ports.
## SIH on Flight Controller Hardware {#sih-on-flight-controller-hardware}
## Running the SIH on Flight Controller Hardware {#sih-on-flight-controller-hardware}
SIH can also run on flight controller hardware with `SYS_HITL=2`, replacing real sensors with simulated data while running on the actual autopilot.
:::info
The SIH on flight controller is community supported.
:::
SIH can also run on flight controller hardware, replacing real sensors with simulated data while running on the actual autopilot.
See [SIH on Flight Controller Hardware](hardware.md) for setup instructions.
## Adding New Airframes
@@ -239,7 +248,7 @@ The specific differences for SIH simulation airframes are listed in the sections
### SIH on Flight Controller
For FC-specific airframe setup (file locations, `HIL_ACT_FUNC*` parameters), see [Adding New Airframes (FC)](hardware.md#adding-new-airframes-fc).
See [Adding New Airframes (FC)](../sim_sih/hardware.md#adding-new-airframes-fc) in _SIH on Flight Controller Hardware_.
### SIH as SITL
@@ -266,8 +275,22 @@ The dynamic models for the various vehicles are:
- Tailsitter: based on Chiappinelli (2018), see references below
- Rover: bicycle model with linear tire model
Since PX4 v1.17, the propeller model for fixed-wing, tailsitter, and VTOL pusher vehicles is based on [UIUC propeller data](https://m-selig.ae.illinois.edu/props/propDB.html).
The maximum thrust force is realistically reduced as aircraft speed increases.
**Propeller model with advance ratio**
Since PX4 v1.17, the propeller model for fixed-wing, tailsitter, and VTOL pusher vehicles is based on the equations from UIUC Propeller Database.
<img width="588" height="183" alt="UIUC_prop_equations" src="https://github.com/user-attachments/assets/55413486-b23b-4269-9ac5-dd630ec0849b" />
This model includes the thrust coefficient CT(J) and power coefficient CP(J) as functions of the advance ratio J.
As a result, the maximum thrust force is realistically reduced as the aircraft speed is increased.
The SIH implements the thrust and power coefficients as second-order polynomial fits.
CT = SIH_F_CT0 + SIH_F_CT1⋅J + SIH_F_CT2⋅J²
CP = SIH_F_CP0 + SIH_F_CP1⋅J + SIH_F_CP2⋅J²
If `SIH_F_CT0` and `SIH_F_CP0` are non-zero and positive, the SIH uses the model with advance ratio.
If not, the SIH uses a simple model with maximum thrust force given by `SIH_F_T_MAX` and maximum torque given by `SIH_F_Q_MAX`.
**References:**
@@ -275,19 +298,20 @@ The maximum thrust force is realistically reduced as aircraft speed increases.
2. W. Khan, "Dynamics modeling of agile fixed-wing unmanned aerial vehicles," Ph.D. thesis, Dept. of Mechanical Engineering, McGill University, Montreal, 2016.
3. R. Chiappinelli, "Modeling and control of a flying wing tailsitter unmanned aerial vehicle," M.Sc. thesis, Dept. of Mechanical Engineering, McGill University, Montreal, 2018.
4. S. Anumakonda, "Everything you need to know about Self-Driving Cars," 2021. [Link](https://srianumakonda.medium.com/everything-you-need-to-know-about-self-driving-in-30-minutes-b38d68bd3427)
5. J.B. Brandt, R.W. Deters, G.K. Ananda, O.D. Dantsker, and M.S. Selig, UIUC Propeller Database, Vols 1-4, University of Illinois at Urbana-Champaign, Department of Aerospace Engineering, retrieved from https://m-selig.ae.illinois.edu/props/propDB.html.
## 视频
@[youtube](https://youtu.be/PzIpSCRD8Jo)
SIH demo with a fixed-wing vehicle @[youtube](https://youtu.be/PzIpSCRD8Jo)
How to parametrize the thrust and power coefficients CT & CP @[youtube](https://www.youtube.com/watch?v=KNSd9ge0sSw)
## Credits
SIH was originally developed by Coriolis g Corporation.
The airplane model and tailsitter models were added by Altitude R&D inc.
Both are Canadian companies:
- Coriolis g developed a new type of Vertical Takeoff and Landing (VTOL) vehicles based on passive coupling systems;
- [Altitude R&D](https://www.altitude-rd.com/) is specialized in dynamics, control, and real-time simulation (today relocated in Zurich).
- [Altitude R&D](https://www.altitude-rd.com/) is specialized in dynamics, control, and real-time simulation (located in Zurich).
The simulator is released for free under BSD license.
+1 -1
View File
@@ -47,7 +47,7 @@ To control how fast the battery depletes to the minimal value use the parameter
By changing [SIM_BAT_MIN_PCT](../advanced_config/parameter_reference.md#SIM_BAT_MIN_PCT) in flight, you can also test regaining capacity to simulate inaccurate battery state estimation or in-air charging technology.
:::
It is also possible to disable the simulated battery using [SIM_BAT_ENABLE](../advanced_config/parameter_reference.md#SIM_BAT_ENABLE) in order to, for example, provide an external battery simulation via MAVLink.
The simulated battery can be completely disabled by setting [SIM_BAT_DRAIN](../advanced_config/parameter_reference.md#SIM_BAT_DRAIN) to 0. This is useful, for example, if you provide an external battery simulation via MAVLink.
## GPS 损失
+5 -1
View File
@@ -27,11 +27,15 @@ See [PX4-Autopilot#23602](https://github.com/PX4/PX4-Autopilot/issues/23602) for
| 仿真器 | 描述 |
| ------------------------------------------------ | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| [Gazebo](../sim_gazebo_gz/index.md) | Gazebo supersedes [Gazebo Classic](../sim_gazebo_classic/index.md), featuring more advanced rendering, physics and sensor models. It is the only version of Gazebo available from Ubuntu Linux 22.04<br><br>A powerful 3D simulation environment that is particularly suitable for testing object-avoidance and computer vision. 它还可用于 [多工具仿真](../simulation/multi-vehicle-simulation.md),通常用于 [ROS](../simulation/ros_interface.md),这是一种用于自动控制的工具集。 <br><br><strong>Supported Vehicles:</strong> Quad, VTOL (Standard, Tailsitter, Tiltroter), Plane, Rovers |
| [Gazebo Classic](../sim_gazebo_classic/index.md) | A powerful 3D simulation environment that is particularly suitable for testing object-avoidance and computer vision. It can also be used for [multi-vehicle simulation](../simulation/multi-vehicle-simulation.md) and is commonly used with [ROS](../simulation/ros_interface.md), a collection of tools for automating vehicle control.<br><br>**Supported Vehicles:** Quad ([Iris](../airframes/airframe_reference.md#copter_quadrotor_x_generic_quadcopter)), Hex (Typhoon H480), [Generic Standard VTOL (QuadPlane)](../airframes/airframe_reference.md#vtol_standard_vtol_generic_standard_vtol), Tailsitter, Plane, Rover, Submarine |
| [SIH](../sim_sih/index.md) | A lightweight, headless simulator that runs physics directly inside PX4 as a C++ module (no external dependencies). Headless by default for fastest iteration. Supports ROS 2 via uXRCE-DDS. Can also run on flight controller hardware (`SYS_HITL=2`).<br><br>**Supported Vehicles:** Quad, Hex, Plane, Tailsitter, Standard VTOL, Rover |
| [Gazebo Classic](../sim_gazebo_classic/index.md) | A powerful 3D simulation environment that is particularly suitable for testing object-avoidance and computer vision. It can also be used for [multi-vehicle simulation](../simulation/multi-vehicle-simulation.md) and is commonly used with [ROS](../simulation/ros_interface.md), a collection of tools for automating vehicle control.<br><br>**Supported Vehicles:** Quad ([Iris](../airframes/airframe_reference.md#copter_quadrotor_x_generic_quadcopter)), Hex (Typhoon H480), [Generic Standard VTOL (QuadPlane)](../airframes/airframe_reference.md#vtol_standard_vtol_generic_standard_vtol), Tailsitter, Plane, Rover, Submarine |
There are also a number of [Community Supported Simulators](../simulation/community_supported_simulators.md).
:::tip
To run PX4 SITL without setting up a build environment, [pre-built packages and containers](px4_sitl_prebuilt_packages.md) are available.
:::
### Simulator Comparison
| 特性 | Gazebo | SIH |
@@ -0,0 +1,25 @@
# PX4 Simulation QuickStart
First install [Docker](https://docs.docker.com/get-docker/) (a free tool that runs containers).
The following command will then run a PX4 quadrotor simulation that you can connect to [QGroundControl](https://qgroundcontrol.com), [MAVSDK](https://mavsdk.mavlink.io/) or [ROS 2](../ros2/user_guide.md) (on Linux, macOS, and Windows):
```sh
docker run --rm -it -p 14550:14550/udp px4io/px4-sitl:latest
```
That's it — open [QGroundControl](https://qgroundcontrol.com) and fly!
::: tip
To try [other vehicle types](../sim_sih/#supported-vehicle-types) append the corresponding line below to the command:
```sh
-e PX4_SIM_MODEL=sihsim_airplane # Plane
-e PX4_SIM_MODEL=sihsim_standard_vtol # Standard VTOL
-e PX4_SIM_MODEL=sihsim_rover # Ackermann rover
```
For more information and options see [Container Images](../simulation/px4_sitl_prebuilt_packages.md#container-images) (in _Pre-built SITL Packages_) and [SIH Simulation](../sim_sih/index.md).
:::
@@ -0,0 +1,297 @@
# Pre-built SITL Packages
Pre-built packages let you run [PX4 SITL simulation](index.md) without setting up a build environment.
This is very useful if you don't need to modify PX4 itself.
For example, if you want to write drone apps using [MAVSDK](https://mavsdk.mavlink.io) or [ROS 2](../ros2/user_guide.md), or you just want to fly with PX4.
:::tip
See [PX4 Simulation QuickStart](px4_simulation_quickstart.md) for a one-line instruction to run the SIH package in a container.
:::
## What's Available
Two simulators are packaged, each available as a `.deb` package (Ubuntu) or a Docker [container](#container-images) (any OS):
| 仿真器 | Format | Package / Image | Size |
| -------------------------------------------- | -------------------- | ----------------------- | ----------------------- |
| [SIH](../sim_sih/index.md) | .deb | `px4` | ~10 MB |
| | container | `px4io/px4-sitl` | ~100 MB |
| [Gazebo Harmonic](../sim_gazebo_gz/index.md) | .deb | `px4-gazebo` | ~30 MB |
| | container | `px4io/px4-sitl-gazebo` | ~2 GB |
SIH is a lightweight, headless simulator built into PX4 with no external dependencies.
Gazebo provides full 3D simulation with camera, LiDAR, and custom worlds.
Sizes are approximate and vary between releases.
For help choosing between simulators, see the [simulator comparison table](index.md#simulator-comparison).
### Versions and Releases
Packages and images are versioned to match PX4 tags (e.g. `v1.17.0`, `v1.17.0~beta1`).
`.deb` packages are built for **Ubuntu 22.04 (Jammy)** and **24.04 (Noble)**, on both **amd64** and **arm64**.
Container images support **amd64** and **arm64**.
Stable releases and pre-releases are published on the [PX4 Releases](https://github.com/PX4/PX4-Autopilot/releases) page.
## .deb Packages (Ubuntu)
Download the `.deb` file for your Ubuntu version and architecture from the [PX4 Releases](https://github.com/PX4/PX4-Autopilot/releases) page, then install as shown below.
After installation the binary is added to the default Ubuntu system paths, and can be run from anywhere.
### px4 (SIH)
No extra repositories are required:
```bash
sudo apt install ./px4_*.deb
```
### px4-gazebo (Gazebo Harmonic)
The package depends on Gazebo Harmonic runtime libraries from the OSRF repository.
Add the repository first, then install:
```bash
# Add OSRF Gazebo repository (one-time setup)
sudo curl -fsSL https://packages.osrfoundation.org/gazebo.gpg \
-o /usr/share/keyrings/pkgs-osrf-archive-keyring.gpg
echo "deb [arch=$(dpkg --print-architecture) signed-by=/usr/share/keyrings/pkgs-osrf-archive-keyring.gpg] \
http://packages.osrfoundation.org/gazebo/ubuntu-stable $(lsb_release -cs) main" \
| sudo tee /etc/apt/sources.list.d/gazebo-stable.list > /dev/null
sudo apt update
# Install (resolves Gazebo dependencies automatically)
sudo apt install ./px4-gazebo_*.deb
```
### Uninstalling
```bash
sudo apt remove px4 # SIH package
sudo apt remove px4-gazebo # Gazebo package
```
## Container Images
Container images are built using the same `.deb` packages described above, packaged into minimal Docker images.
They are published to [Docker Hub](https://hub.docker.com/u/px4io) on every tagged release.
You will need to [install Docker](https://docs.docker.com/get-docker/).
| Image | 仿真器 |
| ----------------------------- | --------------------------------- |
| `px4io/px4-sitl:<tag>` | SIH (headless) |
| `px4io/px4-sitl-gazebo:<tag>` | Gazebo Harmonic |
Tags follow PX4 versions (e.g. `v1.17.0`).
### Running
```bash
# SIH
docker run --rm -it -p 14550:14550/udp px4io/px4-sitl:latest
# Gazebo
docker run --rm -it -p 14550:14550/udp px4io/px4-sitl-gazebo:latest
```
Pass environment variables with `-e`:
```bash
docker run --rm -it -p 14550:14550/udp \
-e PX4_SIM_MODEL=sihsim_airplane \
px4io/px4-sitl:latest
```
The quick-start command above only exposes the QGroundControl port.
To use MAVSDK, uXRCE-DDS (ROS 2), or MAVSim Viewer, expose the additional ports:
```bash
docker run --rm -it \
-p 14550:14550/udp \
-p 14540:14540/udp \
-p 8888:8888/udp \
-p 19410:19410/udp \
px4io/px4-sitl:latest
```
| Port | Protocol | Used by |
| ----- | -------- | ---------------------------------------------- |
| 14550 | UDP | QGroundControl |
| 14540 | UDP | MAVSDK / offboard API |
| 8888 | UDP | uXRCE-DDS agent (ROS 2) |
| 19410 | UDP | SIH display (MAVSim Viewer) |
On Linux, you can skip individual port flags and use `--network host` instead:
```bash
docker run --rm -it --network host px4io/px4-sitl:latest
```
## 配置
These options apply to both `.deb` packages and containers.
Note that after the first section below we only show how to use them with the deb packages (the pattern for using the options doesn't change).
### Vehicle Selection
Set `PX4_SIM_MODEL` to choose a vehicle.
SIH:
```bash
# Deb package
PX4_SIM_MODEL=sihsim_airplane px4
# Container
docker run --rm -it -p 14550:14550/udp px4io/px4-sitl:latest -e PX4_SIM_MODEL=sihsim_airplane
```
Gazebo:
```
# Deb package
PX4_SIM_MODEL=gz_x500 px4-gazebo
# Container
docker run --rm -it -p 14550:14550/udp px4io/px4-sitl-gazebo:latest -e PX4_SIM_MODEL=gz_x500
```
See [SIH Supported Vehicles](../sim_sih/index.md#supported-vehicle-types) and [Gazebo Vehicles](../sim_gazebo_gz/vehicles.md) for the full lists.
### World Selection (Gazebo only)
```sh
PX4_GZ_WORLD=baylands PX4_SIM_MODEL=gz_x500 px4-gazebo
```
See [Gazebo Worlds](../sim_gazebo_gz/worlds.md) for available worlds.
### Environment Variables
| Variable | 描述 | 默认值 |
| -------------------- | ------------------------------------------------------------------------------------------------------ | ----------------------------- |
| `PX4_SIM_MODEL` | Vehicle model (e.g. `gz_x500`, `sihsim_quadx`) | (required) |
| `PX4_GZ_WORLD` | Gazebo world name, without `.sdf` (e.g. `baylands`) | `default` |
| `HEADLESS` | Set to `1` to disable Gazebo GUI | (unset) |
| `PX4_UXRCE_DDS_PORT` | uXRCE-DDS agent UDP port | `8888` |
| `PX4_UXRCE_DDS_NS` | uXRCE-DDS ROS namespace | (none) |
| `XDG_DATA_HOME` | Base directory for per-instance working data (parameters, dataman) | `$HOME/.local/share` |
## Multi-Instance
Multiple simulated vehicles can run simultaneously by passing the `-i` flag with an instance number.
Each instance must be started in a separate terminal (or container). This works with both simulators.
```sh
# Terminal 1
PX4_SIM_MODEL=sihsim_quadx px4 -i 0
# Terminal 2
PX4_SIM_MODEL=sihsim_quadx px4 -i 1
```
MAVLink and uXRCE-DDS port numbers are automatically offset by the instance number.
Each package (`px4` and `px4-gazebo`) is a standalone install. Do not mix instances from the two packages in the same session.
## MAVLink and QGroundControl
PX4 opens several MAVLink UDP ports on startup.
[QGroundControl](https://qgroundcontrol.com) auto-connects on UDP port 14550.
You can also connect [MAVSDK](https://mavsdk.mavlink.io) or any MAVLink-compatible tool.
| Link | 模式 | UDP Local Port | UDP Remote Port | Data Rate |
| ----------------------------------------- | ------- | ---------------- | ---------------- | --------- |
| GCS link | Normal | 18570 + instance | 14550 | 4 Mbps |
| API/Offboard link | Onboard | 14580 + instance | 14540 + instance | 4 Mbps |
| Onboard link to camera | Onboard | 14280 + instance | 14030 + instance | 4 kbps |
| Onboard link to gimbal | Gimbal | 13030 + instance | 13280 + instance | 400 kbps |
| SIH display (SIH only) | Custom | 19450 + instance | 19410 + instance | 400 kbps |
By default, MAVLink only listens on localhost.
Set parameter `MAV_{i}_BROADCAST = 1` to enable network access.
## ROS 2 Integration
The `uxrce_dds_client` module starts automatically and connects to a Micro XRCE-DDS Agent over UDP.
Run the agent before starting PX4:
```sh
MicroXRCEAgent udp4 -p 8888
```
| 设置 | 默认值 |
| ---------- | ----------- |
| Transport | UDP |
| Agent IP | `127.0.0.1` |
| Agent Port | `8888` |
Environment variables `PX4_UXRCE_DDS_PORT` and `PX4_UXRCE_DDS_NS` override the corresponding PX4 parameters ([UXRCE_DDS_PRT](../advanced_config/parameter_reference.md#UXRCE_DDS_PRT), [UXRCE_DDS_NS_IDX](../advanced_config/parameter_reference.md#UXRCE_DDS_NS_IDX)) at runtime without modifying stored parameters:
```sh
PX4_UXRCE_DDS_PORT=9999 PX4_UXRCE_DDS_NS=drone1 PX4_SIM_MODEL=sihsim_quadx px4
```
## Daemon Mode
Start PX4 without an interactive shell (useful for CI pipelines and automated testing):
```sh
PX4_SIM_MODEL=sihsim_quadx px4 -d
```
## Installed File Layout
### px4
```txt
/opt/px4/
bin/
px4 # PX4 binary
px4-* # Module symlinks
px4-alias.sh # Shell aliases
etc/ # ROMFS (init scripts, mixers, airframes)
init.d-posix/
/usr/bin/px4 -> /opt/px4/bin/px4
```
### px4-gazebo
```txt
/opt/px4-gazebo/
bin/
px4 # PX4 binary
px4-gazebo # Gazebo wrapper (sets GZ_SIM_* env vars)
px4-* # Module symlinks
px4-alias.sh # Shell aliases
etc/ # ROMFS (init scripts, mixers, airframes)
init.d-posix/
share/gz/
models/ # Gazebo vehicle models
worlds/ # Gazebo world files
server.config
lib/gz/plugins/ # PX4 Gazebo plugins
/usr/bin/px4-gazebo -> /opt/px4-gazebo/bin/px4-gazebo
```
### Runtime directories (created on first run, per user)
```sh
$XDG_DATA_HOME/px4/rootfs/<instance>/ # parameters, dataman, eeprom
```
## Building .deb Files Locally
To build `.deb` files locally (e.g. to package a custom PX4 branch):
```sh
# SIH — produces px4_*.deb
make px4_sitl_sih
cd build/px4_sitl_sih && cpack -G DEB
# Gazebo — produces px4-gazebo_*.deb
make px4_sitl_default
cd build/px4_sitl_default && cpack -G DEB
```
+100
View File
@@ -0,0 +1,100 @@
# Holybro SiK Telemetry Radio - Long Range
This Holybro SiK Long Range Telemetry Radio is a small, light, and inexpensive open-source radio platform with an extended range (~20km) compared to the standard model.
This radio is plug-and-play, ready for all Pixhawk Standard and other similar flight controllers, providing the easiest way to set up a telemetry connection between your controller and a ground station.
It uses open-source firmware that has been specially designed to work well with MAVLink packets and to be integrated with PX4, ArduPilot, Mission Planner and QGroundControl.
The radios are available in 915 MHz or 433 MHz versions.
Please purchase the model that is appropriate for your country/region.
![Sik Telemetry Radio - Long Range](../../assets/hardware/telemetry/holybro_sik_longrange/holybro_sik_longrange.jpg)
## 购买渠道
- [Holybro SiK Telemetry Radio - Long Range](https://holybro.com/collections/telemetry-radios/products/sik-telemetry-radio-1w)
## 特性
- 1W maximum RF output and up to 20km range (compared to 100mW/300m for the short range version).
- Open-source SIK firmware
- Plug-n-play for Pixhawk Standard Flight Controllers
- The Easiest way to connect your controller and Ground Station
- Interchangeable air and ground radio
- 6-position JST-GH connector
## 技术规范
- 1 W maximum output power (adjustable) -117 dBm receive sensitivity
- RP-SMA connector
- 2-way full-duplex communication through adaptive TDM UART interface
- Transparent serial link
- MAVLink protocol framing
- Frequency Hopping Spread Spectrum (FHSS) Configurable duty cycle
- Error correction corrects up to 25% of bit errors Open-source SIK firmware
- Configurable through Mission Planner & APM Planner
- FT230X USB to BASIC UART IC
- USB Type C connector
- XT30 power connector for 7~28V DC input
## LEDs Indicators Status
The radios have four status LEDs.
The USB `RX` and `TX` LEDs indicate the status of reception and transmission of the USB port.
The `RADIO` and `ACT` two LED lights indicate the status of the RF circuit.
- USB-TX LED (orange):
- Blinking: USB port has data transmission
- Off: USB port has no data transmission
- USB-RX LED (orange):
- Blinking: USB port has data reception
- Off: USB port has no data reception
- Radio LED (Green)
- Blinking: Searching for another radio
- Solid: Link is established with another radio
- ACT LED (Red)
- Flashing: Transmitting data
- Solid: In firmware update mode
![Holybro SiK LongRange LED Indicators](../../assets/hardware/telemetry/holybro_sik_longrange/holybro_sik_longrange_label.png)
## Connecting to Flight Controller
Supply the power (7~28V) to the radio via the XT30 connector.
Use the 6-pin JST-GH connector that comes with the radio to connect the radio to your flight controller's `TELEM1` port.
Note that `TELEM2` can also be used, but you may need to [configure the telemetry port](../peripherals/mavlink_peripherals.md) on some flight controllers.
## Connecting to a PC or Ground Station
First, power the module with a 7~28V DC source.
Then, connect the radio to your Windows PC or Ground Station using a Type-C USB cable.
The necessary drivers should be installed automatically, and the radio will appear as a new “USB Serial Port” in the Windows Device Manager under Ports (COM & LPT).
The Mission Planner's COM Port selection drop-down should also include the newly added COM port.
## Packages Include
### Single Radio
- 1W Radio modules with antennas (1)
- High-gain omnidirectional antenna (1)
- Male Type-C to male Type-C USB cable (1)
- Male XT30 to female XT30 adapter cable (1)
- Male XT30 to female XT60 adapter cable (1)
- JST-GH-6P to JST-GH-6P cable (1) (for Pixhawk Standard FC)
- Rubber damping grommet (3)
![Sik Telemetry Radio - LongRange Package1](../../assets/hardware/telemetry/holybro_sik_longrange/holybro_sik_longrange_include1.png)
### Pair Radios
- 1W Radio modules with antennas (2)
- High-gain omnidirectional antenna (2)
- Male Type-C to male Type-C USB cable (1)
- Male XT30 to female XT30 adapter cable (1)
- Male XT30 to female XT60 adapter cable (1)
- JST-GH-6P to JST-GH-6P cable (1) (for Pixhawk Standard FC)
- Rubber damping grommet (3)
![Sik Telemetry Radio - LongRange Package2](../../assets/hardware/telemetry/holybro_sik_longrange/holybro_sik_longrange_include2.png)
+1
View File
@@ -6,6 +6,7 @@ PX4支持多种类型数传电台:
- [SiK Radio](../telemetry/sik_radio.md) based firmware (more generally, any radio with a UART interface should work).
- [HolyBro SiK Telemetry Radio](../telemetry/holybro_sik_radio.md)
- [HolyBro SiK Long Range](../telemetry/holybro_sik_longrange.md)
- [RFD900 Telemetry Radio](../telemetry/rfd900_telemetry.md)
- [ThunderFly TFSIK01 Telemetry Radio](../telemetry/tfsik_telemetry.md)
- <del>_HKPilot Telemetry Radio_</del> (Discontinued)
+1
View File
@@ -14,6 +14,7 @@ Hardware for the SiK radio can be obtained from various manufacturers/stores in
## Vendors
- [Holybro Telemetry Radio](../telemetry/holybro_sik_radio.md)
- [HolyBro SiK Long Range](../telemetry/holybro_sik_longrange.md)
- [RFD900 Telemetry Radio](../telemetry/rfd900_telemetry.md)
- [ThunderFly TFSIK01 Telemetry Radio](../telemetry/tfsik_telemetry.md)
- <del>_HKPilot Telemetry Radio_</del> (Discontinued)
+7
View File
@@ -22,6 +22,8 @@ For significant changes to the system you should also run general flight tests u
These test cards define "standard" flight tests.
These are run by the test team as part of release testing, and for more significant system changes.
### 多旋翼
- [MC_01 - Manual modes](../test_cards/mc_01_manual_modes.md)
- [MC_02 - Full Autonomous](../test_cards/mc_02_full_autonomous.md)
- [MC_03 - Auto Manual Mix](../test_cards/mc_03_auto_manual_mix.md)
@@ -32,3 +34,8 @@ These are run by the test team as part of release testing, and for more signific
- [MC_08 - DSHOT ESC](../test_cards/mc_08_dshot.md)
- [MC_09 - VIO (Visual-Inertial Odometry)](../test_cards/mc_09_vio.md)
- [MC_10 - Optical Flow / GPS Mixed](../test_cards/mc_10_optical_flow_gps_mixed.md)
### Fixed Wing
- [FW_01 - Manual Modes](../test_cards/fw_01_manual_modes.md)
- [FW_02 - Full Autonomous](../test_cards/fw_02_full_autonomous.md)
+46
View File
@@ -0,0 +1,46 @@
# Test FW_01 - Manual Modes
## Objective
To test that manual flight modes work as expected for fixed wing vehicles.
## Preflight
Ensure that the vehicle can go into Stabilized, Altitude, and Position mode while still on the ground.
## Flight Tests
❏ 自稳
&nbsp;&nbsp;&nbsp;&nbsp;❏ Wings level with stick centered
&nbsp;&nbsp;&nbsp;&nbsp;❏ Pitch/Roll response with correct bank angle limits
&nbsp;&nbsp;&nbsp;&nbsp;❏ Yaw coordination
&nbsp;&nbsp;&nbsp;&nbsp;❏ Throttle response 1:1
❏ 高度
&nbsp;&nbsp;&nbsp;&nbsp;❏ Altitude should hold current value with stick centered
&nbsp;&nbsp;&nbsp;&nbsp;❏ Pitch input controls climb/descend rate
&nbsp;&nbsp;&nbsp;&nbsp;❏ Throttle automatically managed to maintain airspeed
&nbsp;&nbsp;&nbsp;&nbsp;❏ Roll/Yaw respond correctly to stick movement
❏ 定点
&nbsp;&nbsp;&nbsp;&nbsp;❏ Vehicle should hold current heading and loiter with stick centered
&nbsp;&nbsp;&nbsp;&nbsp;❏ Altitude should hold current value
&nbsp;&nbsp;&nbsp;&nbsp;❏ Roll input commands heading change
## 预期成果
- Takeoff should be smooth (hand launch or runway)
- No oscillations should be present in any of the above flight modes
- Vehicle should maintain stable flight throughout all mode transitions
- Landing approach should be stable and controllable
@@ -0,0 +1,64 @@
# Test FW_02 - Full Autonomous
## Objective
To test the auto modes such as Mission, Takeoff, Hold, and RTL for fixed wing vehicles.
## Preflight
Plan a mission on the ground. Ensure the mission has:
- Takeoff as first waypoint
- Changes in altitude throughout the mission
- Last waypoint is an RTL
- Duration of 1 to 2 minutes
## Flight Tests
❏ Takeoff
&nbsp;&nbsp;&nbsp;&nbsp;❏ Engage Takeoff mode (hand launch or runway)
&nbsp;&nbsp;&nbsp;&nbsp;❏ Vehicle should climb to takeoff altitude
&nbsp;&nbsp;&nbsp;&nbsp;❏ Vehicle should hold/loiter after reaching takeoff altitude
❏ Mission
&nbsp;&nbsp;&nbsp;&nbsp;❏ Auto takeoff (hand launch or runway)
&nbsp;&nbsp;&nbsp;&nbsp;❏ Verify changes in altitude throughout the mission
&nbsp;&nbsp;&nbsp;&nbsp;❏ Verify Mission Ends in RTL
&nbsp;&nbsp;&nbsp;&nbsp;❏ Duration of 1 to 2 minutes
&nbsp;&nbsp;&nbsp;&nbsp;❏ Auto land or hold at end
❏ Hold
&nbsp;&nbsp;&nbsp;&nbsp;❏ Engage Hold mode during flight
&nbsp;&nbsp;&nbsp;&nbsp;❏ Vehicle should orbit at current position and altitude
&nbsp;&nbsp;&nbsp;&nbsp;❏ Orbit radius and direction should match parameters
❏ RTL
&nbsp;&nbsp;&nbsp;&nbsp;❏ Arm and takeoff in any manual mode
&nbsp;&nbsp;&nbsp;&nbsp;❏ Fly out ~200m from start point
&nbsp;&nbsp;&nbsp;&nbsp;❏ Engage Return mode
&nbsp;&nbsp;&nbsp;&nbsp;❏ Vehicle should climb to RTL altitude if below it
&nbsp;&nbsp;&nbsp;&nbsp;❏ Vehicle should return to home and hold or land
## 预期成果
- 任务应该在第一次尝试时上传
- Vehicle should automatically takeoff upon engaging Auto
- Waypoint tracking should be smooth with appropriate turn radius
- Vehicle should adjust height to RTL altitude before returning home
- Landing approach should be stable (if auto-land is configured)