mirror of
https://github.com/PX4/PX4-Autopilot.git
synced 2026-05-29 19:57:12 +08:00
New Crowdin translations - uk
This commit is contained in:
committed by
Hamish Willee
parent
5af5bdb478
commit
f9c36b8235
@@ -210,7 +210,7 @@ The Lua script works by extracting the `obstacle_distance_fused` data at each ti
|
|||||||
type: px4_msgs::msg::ObstacleDistance
|
type: px4_msgs::msg::ObstacleDistance
|
||||||
```
|
```
|
||||||
|
|
||||||
For more information see [DDS Topics YAML](../middleware/uxrce_dds.md#dds-topics-yaml) in _uXRCE-DDS (PX4-ROS 2/DDS Bridge)_.
|
For more information see [DDS Topics YAML](../middleware/uxrce_dds.md#dds-topics-yaml) in [uXRCE-DDS](../middleware/uxrce_dds.md) (PX4-ROS 2/DDS Bridge)_.
|
||||||
|
|
||||||
3. Open PlotJuggler and navigate to the **Tools > Reactive Script Editor** section.
|
3. Open PlotJuggler and navigate to the **Tools > Reactive Script Editor** section.
|
||||||
In the **Script Editor** tab, add following scripts in the appropriate sections:
|
In the **Script Editor** tab, add following scripts in the appropriate sections:
|
||||||
|
|||||||
@@ -96,13 +96,13 @@ Exporting the messages allows ROS 2 and the uXRCE-DDS agent to be independent of
|
|||||||
|
|
||||||
While `px4_msgs` has messages for all uORB topics in PX4, not all messages in `px4_msgs` are available to ROS 2/PlotJuggler by default.
|
While `px4_msgs` has messages for all uORB topics in PX4, not all messages in `px4_msgs` are available to ROS 2/PlotJuggler by default.
|
||||||
The set that are available must be built into the client running on PX4.
|
The set that are available must be built into the client running on PX4.
|
||||||
These are defined in [dds_topics.yaml](https://github.com/PX4/PX4-Autopilot/blob/main/src/modules/uxrce_dds_client/dds_topics.yaml).
|
These are defined in [dds_topics.yaml](../middleware/dds_topics.md).
|
||||||
|
|
||||||
The instructions below explain the changes needed to monitor topics that are not available by default.
|
The instructions below explain the changes needed to monitor topics that are not available by default.
|
||||||
|
|
||||||
### Missing Topics
|
### Missing Topics
|
||||||
|
|
||||||
If a normal uORB topic is not available in PlotJuggler you will need to modify the [dds_topics.yaml](https://github.com/PX4/PX4-Autopilot/blob/main/src/modules/uxrce_dds_client/dds_topics.yaml) to include the topic and rebuild PX4.
|
If a normal uORB topic is not available in PlotJuggler you will need to modify the [dds_topics.yaml](../middleware/dds_topics.md) ([source](https://github.com/PX4/PX4-Autopilot/blob/main/src/modules/uxrce_dds_client/dds_topics.yaml)) to include the topic and rebuild PX4.
|
||||||
|
|
||||||
If working with real hardware you will need to build and [install](../config/firmware.md#installing-px4-main-beta-or-custom-firmware) custom firmware after changing the YAML file.
|
If working with real hardware you will need to build and [install](../config/firmware.md#installing-px4-main-beta-or-custom-firmware) custom firmware after changing the YAML file.
|
||||||
|
|
||||||
@@ -122,7 +122,7 @@ cd ~/ros2_ws/ && colcon build
|
|||||||
|
|
||||||
### Custom Topics
|
### Custom Topics
|
||||||
|
|
||||||
After defining the topic, follow the instructions above to add the topic to [dds_topics.yaml](https://github.com/PX4/PX4-Autopilot/blob/main/src/modules/uxrce_dds_client/dds_topics.yaml), and export the new message into your ROS 2 workspace.
|
After defining the topic, follow the instructions above to add the topic to [dds_topics.yaml](../middleware/dds_topics.md), and export the new message into your ROS 2 workspace.
|
||||||
|
|
||||||
## Дивись також
|
## Дивись також
|
||||||
|
|
||||||
|
|||||||
@@ -128,8 +128,7 @@ To enable recording for EKF replay you must set the parameters to enable a [sing
|
|||||||
|
|
||||||
Для виконання повторення EKF2:
|
Для виконання повторення EKF2:
|
||||||
|
|
||||||
- Запишіть оригінальний журнал.
|
- Record the original log with `SDLOG_MODE` set to `1` to log from boot.
|
||||||
Optionally set `SDLOG_MODE` to `1` to log from boot.
|
|
||||||
|
|
||||||
- In addition to the `replay` environment variable, set `replay_mode` to `ekf2`:
|
- In addition to the `replay` environment variable, set `replay_mode` to `ekf2`:
|
||||||
|
|
||||||
|
|||||||
@@ -0,0 +1,277 @@
|
|||||||
|
# dds_topics.yaml — PX4 Topics Exposed to ROS 2
|
||||||
|
|
||||||
|
:::info
|
||||||
|
This document is [auto-generated](https://github.com/PX4/PX4-Autopilot/blob/main/Tools/msg/generate_msg_docs.py) from the source code.
|
||||||
|
:::
|
||||||
|
|
||||||
|
The [dds_topics.yaml](https://github.com/PX4/PX4-Autopilot/blob/main/src/modules/uxrce_dds_client/dds_topics.yaml) file specifies which uORB message definitions are compiled into the [uxrce_dds_client](../modules/modules_system.md#uxrce-dds-client) module when [PX4 is built](../middleware/uxrce_dds.md#code-generation), and hence which topics are available for ROS 2 applications to subscribe or publish (by default).
|
||||||
|
|
||||||
|
This document shows a markdown-rendered version of [dds_topics.yaml](https://github.com/PX4/PX4-Autopilot/blob/main/src/modules/uxrce_dds_client/dds_topics.yaml), listing the publications, subscriptions, and so on.
|
||||||
|
|
||||||
|
## Publications
|
||||||
|
|
||||||
|
| Topic | Тип | Rate Limit |
|
||||||
|
| --------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------- |
|
||||||
|
| `/fmu/out/register_ext_component_reply` | [px4_msgs::msg::RegisterExtComponentReply](../msg_docs/RegisterExtComponentReply.md) | |
|
||||||
|
| `/fmu/out/arming_check_request` | [px4_msgs::msg::ArmingCheckRequest](../msg_docs/ArmingCheckRequest.md) | 5.0 |
|
||||||
|
| `/fmu/out/mode_completed` | [px4_msgs::msg::ModeCompleted](../msg_docs/ModeCompleted.md) | 50.0 |
|
||||||
|
| `/fmu/out/battery_status` | [px4_msgs::msg::BatteryStatus](../msg_docs/BatteryStatus.md) | 1.0 |
|
||||||
|
| `/fmu/out/collision_constraints` | [px4_msgs::msg::CollisionConstraints](../msg_docs/CollisionConstraints.md) | 50.0 |
|
||||||
|
| `/fmu/out/estimator_status_flags` | [px4_msgs::msg::EstimatorStatusFlags](../msg_docs/EstimatorStatusFlags.md) | 5.0 |
|
||||||
|
| `/fmu/out/failsafe_flags` | [px4_msgs::msg::FailsafeFlags](../msg_docs/FailsafeFlags.md) | 5.0 |
|
||||||
|
| `/fmu/out/manual_control_setpoint` | [px4_msgs::msg::ManualControlSetpoint](../msg_docs/ManualControlSetpoint.md) | 25.0 |
|
||||||
|
| `/fmu/out/message_format_response` | [px4_msgs::msg::MessageFormatResponse](../msg_docs/MessageFormatResponse.md) | |
|
||||||
|
| `/fmu/out/position_setpoint_triplet` | [px4_msgs::msg::PositionSetpointTriplet](../msg_docs/PositionSetpointTriplet.md) | 5.0 |
|
||||||
|
| `/fmu/out/sensor_combined` | [px4_msgs::msg::SensorCombined](../msg_docs/SensorCombined.md) | |
|
||||||
|
| `/fmu/out/timesync_status` | [px4_msgs::msg::TimesyncStatus](../msg_docs/TimesyncStatus.md) | 10.0 |
|
||||||
|
| `/fmu/out/vehicle_land_detected` | [px4_msgs::msg::VehicleLandDetected](../msg_docs/VehicleLandDetected.md) | 5.0 |
|
||||||
|
| `/fmu/out/vehicle_attitude` | [px4_msgs::msg::VehicleAttitude](../msg_docs/VehicleAttitude.md) | |
|
||||||
|
| `/fmu/out/vehicle_control_mode` | [px4_msgs::msg::VehicleControlMode](../msg_docs/VehicleControlMode.md) | 50.0 |
|
||||||
|
| `/fmu/out/vehicle_command_ack` | [px4_msgs::msg::VehicleCommandAck](../msg_docs/VehicleCommandAck.md) | |
|
||||||
|
| `/fmu/out/vehicle_global_position` | [px4_msgs::msg::VehicleGlobalPosition](../msg_docs/VehicleGlobalPosition.md) | 50.0 |
|
||||||
|
| `/fmu/out/vehicle_gps_position` | [px4_msgs::msg::SensorGps](../msg_docs/SensorGps.md) | 50.0 |
|
||||||
|
| `/fmu/out/vehicle_local_position` | [px4_msgs::msg::VehicleLocalPosition](../msg_docs/VehicleLocalPosition.md) | 50.0 |
|
||||||
|
| `/fmu/out/vehicle_odometry` | [px4_msgs::msg::VehicleOdometry](../msg_docs/VehicleOdometry.md) | |
|
||||||
|
| `/fmu/out/vehicle_status` | [px4_msgs::msg::VehicleStatus](../msg_docs/VehicleStatus.md) | 5.0 |
|
||||||
|
| `/fmu/out/airspeed_validated` | [px4_msgs::msg::AirspeedValidated](../msg_docs/AirspeedValidated.md) | 50.0 |
|
||||||
|
| `/fmu/out/vtol_vehicle_status` | [px4_msgs::msg::VtolVehicleStatus](../msg_docs/VtolVehicleStatus.md) | |
|
||||||
|
| `/fmu/out/home_position` | [px4_msgs::msg::HomePosition](../msg_docs/HomePosition.md) | 5.0 |
|
||||||
|
|
||||||
|
## Subscriptions
|
||||||
|
|
||||||
|
| Topic | Тип |
|
||||||
|
| ------------------------------------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
||||||
|
| /fmu/in/register_ext_component_request | [px4_msgs::msg::RegisterExtComponentRequest](../msg_docs/RegisterExtComponentRequest.md) |
|
||||||
|
| /fmu/in/unregister_ext_component | [px4_msgs::msg::UnregisterExtComponent](../msg_docs/UnregisterExtComponent.md) |
|
||||||
|
| /fmu/in/config_overrides_request | [px4_msgs::msg::ConfigOverrides](../msg_docs/ConfigOverrides.md) |
|
||||||
|
| /fmu/in/arming_check_reply | [px4_msgs::msg::ArmingCheckReply](../msg_docs/ArmingCheckReply.md) |
|
||||||
|
| /fmu/in/message_format_request | [px4_msgs::msg::MessageFormatRequest](../msg_docs/MessageFormatRequest.md) |
|
||||||
|
| /fmu/in/mode_completed | [px4_msgs::msg::ModeCompleted](../msg_docs/ModeCompleted.md) |
|
||||||
|
| /fmu/in/config_control_setpoints | [px4_msgs::msg::VehicleControlMode](../msg_docs/VehicleControlMode.md) |
|
||||||
|
| /fmu/in/distance_sensor | [px4_msgs::msg::DistanceSensor](../msg_docs/DistanceSensor.md) |
|
||||||
|
| /fmu/in/manual_control_input | [px4_msgs::msg::ManualControlSetpoint](../msg_docs/ManualControlSetpoint.md) |
|
||||||
|
| /fmu/in/offboard_control_mode | [px4_msgs::msg::OffboardControlMode](../msg_docs/OffboardControlMode.md) |
|
||||||
|
| /fmu/in/onboard_computer_status | [px4_msgs::msg::OnboardComputerStatus](../msg_docs/OnboardComputerStatus.md) |
|
||||||
|
| /fmu/in/obstacle_distance | [px4_msgs::msg::ObstacleDistance](../msg_docs/ObstacleDistance.md) |
|
||||||
|
| /fmu/in/sensor_optical_flow | [px4_msgs::msg::SensorOpticalFlow](../msg_docs/SensorOpticalFlow.md) |
|
||||||
|
| /fmu/in/goto_setpoint | [px4_msgs::msg::GotoSetpoint](../msg_docs/GotoSetpoint.md) |
|
||||||
|
| /fmu/in/telemetry_status | [px4_msgs::msg::TelemetryStatus](../msg_docs/TelemetryStatus.md) |
|
||||||
|
| /fmu/in/trajectory_setpoint | [px4_msgs::msg::TrajectorySetpoint](../msg_docs/TrajectorySetpoint.md) |
|
||||||
|
| /fmu/in/vehicle_attitude_setpoint | [px4_msgs::msg::VehicleAttitudeSetpoint](../msg_docs/VehicleAttitudeSetpoint.md) |
|
||||||
|
| /fmu/in/vehicle_mocap_odometry | [px4_msgs::msg::VehicleOdometry](../msg_docs/VehicleOdometry.md) |
|
||||||
|
| /fmu/in/vehicle_rates_setpoint | [px4_msgs::msg::VehicleRatesSetpoint](../msg_docs/VehicleRatesSetpoint.md) |
|
||||||
|
| /fmu/in/vehicle_visual_odometry | [px4_msgs::msg::VehicleOdometry](../msg_docs/VehicleOdometry.md) |
|
||||||
|
| /fmu/in/vehicle_command | [px4_msgs::msg::VehicleCommand](../msg_docs/VehicleCommand.md) |
|
||||||
|
| /fmu/in/vehicle_command_mode_executor | [px4_msgs::msg::VehicleCommand](../msg_docs/VehicleCommand.md) |
|
||||||
|
| /fmu/in/vehicle_thrust_setpoint | [px4_msgs::msg::VehicleThrustSetpoint](../msg_docs/VehicleThrustSetpoint.md) |
|
||||||
|
| /fmu/in/vehicle_torque_setpoint | [px4_msgs::msg::VehicleTorqueSetpoint](../msg_docs/VehicleTorqueSetpoint.md) |
|
||||||
|
| /fmu/in/actuator_motors | [px4_msgs::msg::ActuatorMotors](../msg_docs/ActuatorMotors.md) |
|
||||||
|
| /fmu/in/actuator_servos | [px4_msgs::msg::ActuatorServos](../msg_docs/ActuatorServos.md) |
|
||||||
|
| /fmu/in/aux_global_position | [px4_msgs::msg::VehicleGlobalPosition](../msg_docs/VehicleGlobalPosition.md) |
|
||||||
|
| /fmu/in/fixed_wing_longitudinal_setpoint | [px4_msgs::msg::FixedWingLongitudinalSetpoint](../msg_docs/FixedWingLongitudinalSetpoint.md) |
|
||||||
|
| /fmu/in/fixed_wing_lateral_setpoint | [px4_msgs::msg::FixedWingLateralSetpoint](../msg_docs/FixedWingLateralSetpoint.md) |
|
||||||
|
| /fmu/in/longitudinal_control_configuration | [px4_msgs::msg::LongitudinalControlConfiguration](../msg_docs/LongitudinalControlConfiguration.md) |
|
||||||
|
| /fmu/in/lateral_control_configuration | [px4_msgs::msg::LateralControlConfiguration](../msg_docs/LateralControlConfiguration.md) |
|
||||||
|
|
||||||
|
## Subscriptions Multi
|
||||||
|
|
||||||
|
None
|
||||||
|
|
||||||
|
## Not Exported
|
||||||
|
|
||||||
|
These messages are not listed in the yaml file.
|
||||||
|
They are not build into the module, and hence are neither published or subscribed.
|
||||||
|
|
||||||
|
:::details
|
||||||
|
See messages
|
||||||
|
|
||||||
|
- [SensorCorrection](../msg_docs/SensorCorrection.md)
|
||||||
|
- [ActuatorOutputs](../msg_docs/ActuatorOutputs.md)
|
||||||
|
- [FixedWingRunwayControl](../msg_docs/FixedWingRunwayControl.md)
|
||||||
|
- [EstimatorInnovations](../msg_docs/EstimatorInnovations.md)
|
||||||
|
- [FlightPhaseEstimation](../msg_docs/FlightPhaseEstimation.md)
|
||||||
|
- [PurePursuitStatus](../msg_docs/PurePursuitStatus.md)
|
||||||
|
- [Px4ioStatus](../msg_docs/Px4ioStatus.md)
|
||||||
|
- [SatelliteInfo](../msg_docs/SatelliteInfo.md)
|
||||||
|
- [GeofenceResult](../msg_docs/GeofenceResult.md)
|
||||||
|
- [GimbalManagerStatus](../msg_docs/GimbalManagerStatus.md)
|
||||||
|
- [ManualControlSwitches](../msg_docs/ManualControlSwitches.md)
|
||||||
|
- [OpenDroneIdSelfId](../msg_docs/OpenDroneIdSelfId.md)
|
||||||
|
- [OpenDroneIdSystem](../msg_docs/OpenDroneIdSystem.md)
|
||||||
|
- [EventV0](../msg_docs/EventV0.md)
|
||||||
|
- [QshellRetval](../msg_docs/QshellRetval.md)
|
||||||
|
- [RoverThrottleSetpoint](../msg_docs/RoverThrottleSetpoint.md)
|
||||||
|
- [AirspeedValidatedV0](../msg_docs/AirspeedValidatedV0.md)
|
||||||
|
- [RcChannels](../msg_docs/RcChannels.md)
|
||||||
|
- [SensorAccel](../msg_docs/SensorAccel.md)
|
||||||
|
- [GimbalDeviceAttitudeStatus](../msg_docs/GimbalDeviceAttitudeStatus.md)
|
||||||
|
- [EscStatus](../msg_docs/EscStatus.md)
|
||||||
|
- [RoverAttitudeSetpoint](../msg_docs/RoverAttitudeSetpoint.md)
|
||||||
|
- [RateCtrlStatus](../msg_docs/RateCtrlStatus.md)
|
||||||
|
- [AirspeedWind](../msg_docs/AirspeedWind.md)
|
||||||
|
- [InputRc](../msg_docs/InputRc.md)
|
||||||
|
- [GpioIn](../msg_docs/GpioIn.md)
|
||||||
|
- [LaunchDetectionStatus](../msg_docs/LaunchDetectionStatus.md)
|
||||||
|
- [VehicleImu](../msg_docs/VehicleImu.md)
|
||||||
|
- [Event](../msg_docs/Event.md)
|
||||||
|
- [SensorUwb](../msg_docs/SensorUwb.md)
|
||||||
|
- [ActuatorServosTrim](../msg_docs/ActuatorServosTrim.md)
|
||||||
|
- [DatamanResponse](../msg_docs/DatamanResponse.md)
|
||||||
|
- [OrbTest](../msg_docs/OrbTest.md)
|
||||||
|
- [VehicleLocalPositionSetpoint](../msg_docs/VehicleLocalPositionSetpoint.md)
|
||||||
|
- [VehicleAngularVelocity](../msg_docs/VehicleAngularVelocity.md)
|
||||||
|
- [FollowTargetStatus](../msg_docs/FollowTargetStatus.md)
|
||||||
|
- [NormalizedUnsignedSetpoint](../msg_docs/NormalizedUnsignedSetpoint.md)
|
||||||
|
- [YawEstimatorStatus](../msg_docs/YawEstimatorStatus.md)
|
||||||
|
- [TakeoffStatus](../msg_docs/TakeoffStatus.md)
|
||||||
|
- [UlogStreamAck](../msg_docs/UlogStreamAck.md)
|
||||||
|
- [OrbTestLarge](../msg_docs/OrbTestLarge.md)
|
||||||
|
- [RoverSteeringSetpoint](../msg_docs/RoverSteeringSetpoint.md)
|
||||||
|
- [CameraCapture](../msg_docs/CameraCapture.md)
|
||||||
|
- [VehicleRoi](../msg_docs/VehicleRoi.md)
|
||||||
|
- [ActuatorArmed](../msg_docs/ActuatorArmed.md)
|
||||||
|
- [FixedWingLateralGuidanceStatus](../msg_docs/FixedWingLateralGuidanceStatus.md)
|
||||||
|
- [ParameterSetValueResponse](../msg_docs/ParameterSetValueResponse.md)
|
||||||
|
- [GeofenceStatus](../msg_docs/GeofenceStatus.md)
|
||||||
|
- [VehicleAngularAccelerationSetpoint](../msg_docs/VehicleAngularAccelerationSetpoint.md)
|
||||||
|
- [SensorGnssRelative](../msg_docs/SensorGnssRelative.md)
|
||||||
|
- [PowerMonitor](../msg_docs/PowerMonitor.md)
|
||||||
|
- [RoverVelocityStatus](../msg_docs/RoverVelocityStatus.md)
|
||||||
|
- [ParameterResetRequest](../msg_docs/ParameterResetRequest.md)
|
||||||
|
- [RoverAttitudeStatus](../msg_docs/RoverAttitudeStatus.md)
|
||||||
|
- [TecsStatus](../msg_docs/TecsStatus.md)
|
||||||
|
- [EstimatorSelectorStatus](../msg_docs/EstimatorSelectorStatus.md)
|
||||||
|
- [CanInterfaceStatus](../msg_docs/CanInterfaceStatus.md)
|
||||||
|
- [Ping](../msg_docs/Ping.md)
|
||||||
|
- [LedControl](../msg_docs/LedControl.md)
|
||||||
|
- [Wind](../msg_docs/Wind.md)
|
||||||
|
- [VehicleStatusV0](../msg_docs/VehicleStatusV0.md)
|
||||||
|
- [ActuatorTest](../msg_docs/ActuatorTest.md)
|
||||||
|
- [IridiumsbdStatus](../msg_docs/IridiumsbdStatus.md)
|
||||||
|
- [FailureDetectorStatus](../msg_docs/FailureDetectorStatus.md)
|
||||||
|
- [GimbalManagerSetAttitude](../msg_docs/GimbalManagerSetAttitude.md)
|
||||||
|
- [Gripper](../msg_docs/Gripper.md)
|
||||||
|
- [SensorMag](../msg_docs/SensorMag.md)
|
||||||
|
- [DebugValue](../msg_docs/DebugValue.md)
|
||||||
|
- [SensorPreflightMag](../msg_docs/SensorPreflightMag.md)
|
||||||
|
- [RcParameterMap](../msg_docs/RcParameterMap.md)
|
||||||
|
- [LandingGear](../msg_docs/LandingGear.md)
|
||||||
|
- [GimbalDeviceInformation](../msg_docs/GimbalDeviceInformation.md)
|
||||||
|
- [VehicleOpticalFlow](../msg_docs/VehicleOpticalFlow.md)
|
||||||
|
- [UlogStream](../msg_docs/UlogStream.md)
|
||||||
|
- [GimbalControls](../msg_docs/GimbalControls.md)
|
||||||
|
- [RoverRateSetpoint](../msg_docs/RoverRateSetpoint.md)
|
||||||
|
- [LogMessage](../msg_docs/LogMessage.md)
|
||||||
|
- [RoverVelocitySetpoint](../msg_docs/RoverVelocitySetpoint.md)
|
||||||
|
- [GpioOut](../msg_docs/GpioOut.md)
|
||||||
|
- [TaskStackInfo](../msg_docs/TaskStackInfo.md)
|
||||||
|
- [VelocityLimits](../msg_docs/VelocityLimits.md)
|
||||||
|
- [MagWorkerData](../msg_docs/MagWorkerData.md)
|
||||||
|
- [ParameterUpdate](../msg_docs/ParameterUpdate.md)
|
||||||
|
- [TrajectorySetpoint6dof](../msg_docs/TrajectorySetpoint6dof.md)
|
||||||
|
- [SensorBaro](../msg_docs/SensorBaro.md)
|
||||||
|
- [VehicleImuStatus](../msg_docs/VehicleImuStatus.md)
|
||||||
|
- [InternalCombustionEngineStatus](../msg_docs/InternalCombustionEngineStatus.md)
|
||||||
|
- [VehicleOpticalFlowVel](../msg_docs/VehicleOpticalFlowVel.md)
|
||||||
|
- [GimbalManagerSetManualControl](../msg_docs/GimbalManagerSetManualControl.md)
|
||||||
|
- [Rpm](../msg_docs/Rpm.md)
|
||||||
|
- [MagnetometerBiasEstimate](../msg_docs/MagnetometerBiasEstimate.md)
|
||||||
|
- [MountOrientation](../msg_docs/MountOrientation.md)
|
||||||
|
- [ActionRequest](../msg_docs/ActionRequest.md)
|
||||||
|
- [OpenDroneIdArmStatus](../msg_docs/OpenDroneIdArmStatus.md)
|
||||||
|
- [SensorAccelFifo](../msg_docs/SensorAccelFifo.md)
|
||||||
|
- [LoggerStatus](../msg_docs/LoggerStatus.md)
|
||||||
|
- [GeneratorStatus](../msg_docs/GeneratorStatus.md)
|
||||||
|
- [InternalCombustionEngineControl](../msg_docs/InternalCombustionEngineControl.md)
|
||||||
|
- [Ekf2Timestamps](../msg_docs/Ekf2Timestamps.md)
|
||||||
|
- [LandingTargetPose](../msg_docs/LandingTargetPose.md)
|
||||||
|
- [PositionControllerLandingStatus](../msg_docs/PositionControllerLandingStatus.md)
|
||||||
|
- [UavcanParameterValue](../msg_docs/UavcanParameterValue.md)
|
||||||
|
- [OrbitStatus](../msg_docs/OrbitStatus.md)
|
||||||
|
- [PositionControllerStatus](../msg_docs/PositionControllerStatus.md)
|
||||||
|
- [EstimatorStatus](../msg_docs/EstimatorStatus.md)
|
||||||
|
- [DatamanRequest](../msg_docs/DatamanRequest.md)
|
||||||
|
- [HoverThrustEstimate](../msg_docs/HoverThrustEstimate.md)
|
||||||
|
- [FixedWingLateralStatus](../msg_docs/FixedWingLateralStatus.md)
|
||||||
|
- [NavigatorMissionItem](../msg_docs/NavigatorMissionItem.md)
|
||||||
|
- [Cpuload](../msg_docs/Cpuload.md)
|
||||||
|
- [EstimatorAidSource3d](../msg_docs/EstimatorAidSource3d.md)
|
||||||
|
- [RoverRateStatus](../msg_docs/RoverRateStatus.md)
|
||||||
|
- [EscReport](../msg_docs/EscReport.md)
|
||||||
|
- [DebugArray](../msg_docs/DebugArray.md)
|
||||||
|
- [ControlAllocatorStatus](../msg_docs/ControlAllocatorStatus.md)
|
||||||
|
- [SensorHygrometer](../msg_docs/SensorHygrometer.md)
|
||||||
|
- [EstimatorSensorBias](../msg_docs/EstimatorSensorBias.md)
|
||||||
|
- [EstimatorBias3d](../msg_docs/EstimatorBias3d.md)
|
||||||
|
- [GimbalManagerInformation](../msg_docs/GimbalManagerInformation.md)
|
||||||
|
- [QshellReq](../msg_docs/QshellReq.md)
|
||||||
|
- [CameraStatus](../msg_docs/CameraStatus.md)
|
||||||
|
- [GpsInjectData](../msg_docs/GpsInjectData.md)
|
||||||
|
- [FigureEightStatus](../msg_docs/FigureEightStatus.md)
|
||||||
|
- [TransponderReport](../msg_docs/TransponderReport.md)
|
||||||
|
- [UavcanParameterRequest](../msg_docs/UavcanParameterRequest.md)
|
||||||
|
- [MavlinkLog](../msg_docs/MavlinkLog.md)
|
||||||
|
- [EstimatorGpsStatus](../msg_docs/EstimatorGpsStatus.md)
|
||||||
|
- [FuelTankStatus](../msg_docs/FuelTankStatus.md)
|
||||||
|
- [Mission](../msg_docs/Mission.md)
|
||||||
|
- [PositionSetpoint](../msg_docs/PositionSetpoint.md)
|
||||||
|
- [MissionResult](../msg_docs/MissionResult.md)
|
||||||
|
- [EstimatorEventFlags](../msg_docs/EstimatorEventFlags.md)
|
||||||
|
- [VehicleMagnetometer](../msg_docs/VehicleMagnetometer.md)
|
||||||
|
- [MavlinkTunnel](../msg_docs/MavlinkTunnel.md)
|
||||||
|
- [DifferentialPressure](../msg_docs/DifferentialPressure.md)
|
||||||
|
- [CellularStatus](../msg_docs/CellularStatus.md)
|
||||||
|
- [GpsDump](../msg_docs/GpsDump.md)
|
||||||
|
- [GimbalDeviceSetAttitude](../msg_docs/GimbalDeviceSetAttitude.md)
|
||||||
|
- [ArmingCheckReplyV0](../msg_docs/ArmingCheckReplyV0.md)
|
||||||
|
- [NavigatorStatus](../msg_docs/NavigatorStatus.md)
|
||||||
|
- [RoverPositionSetpoint](../msg_docs/RoverPositionSetpoint.md)
|
||||||
|
- [FollowTarget](../msg_docs/FollowTarget.md)
|
||||||
|
- [SensorsStatusImu](../msg_docs/SensorsStatusImu.md)
|
||||||
|
- [EstimatorStates](../msg_docs/EstimatorStates.md)
|
||||||
|
- [SensorGyro](../msg_docs/SensorGyro.md)
|
||||||
|
- [SensorAirflow](../msg_docs/SensorAirflow.md)
|
||||||
|
- [ButtonEvent](../msg_docs/ButtonEvent.md)
|
||||||
|
- [DebugKeyValue](../msg_docs/DebugKeyValue.md)
|
||||||
|
- [GpioConfig](../msg_docs/GpioConfig.md)
|
||||||
|
- [CameraTrigger](../msg_docs/CameraTrigger.md)
|
||||||
|
- [LandingGearWheel](../msg_docs/LandingGearWheel.md)
|
||||||
|
- [VehicleConstraints](../msg_docs/VehicleConstraints.md)
|
||||||
|
- [HealthReport](../msg_docs/HealthReport.md)
|
||||||
|
- [PowerButtonState](../msg_docs/PowerButtonState.md)
|
||||||
|
- [RadioStatus](../msg_docs/RadioStatus.md)
|
||||||
|
- [SensorGyroFifo](../msg_docs/SensorGyroFifo.md)
|
||||||
|
- [EstimatorBias](../msg_docs/EstimatorBias.md)
|
||||||
|
- [DebugVect](../msg_docs/DebugVect.md)
|
||||||
|
- [DistanceSensorModeChangeRequest](../msg_docs/DistanceSensorModeChangeRequest.md)
|
||||||
|
- [RtlTimeEstimate](../msg_docs/RtlTimeEstimate.md)
|
||||||
|
- [PpsCapture](../msg_docs/PpsCapture.md)
|
||||||
|
- [SensorSelection](../msg_docs/SensorSelection.md)
|
||||||
|
- [SystemPower](../msg_docs/SystemPower.md)
|
||||||
|
- [ActuatorControlsStatus](../msg_docs/ActuatorControlsStatus.md)
|
||||||
|
- [SensorGyroFft](../msg_docs/SensorGyroFft.md)
|
||||||
|
- [VehicleAirData](../msg_docs/VehicleAirData.md)
|
||||||
|
- [FollowTargetEstimator](../msg_docs/FollowTargetEstimator.md)
|
||||||
|
- [ParameterSetUsedRequest](../msg_docs/ParameterSetUsedRequest.md)
|
||||||
|
- [GpioRequest](../msg_docs/GpioRequest.md)
|
||||||
|
- [OpenDroneIdOperatorId](../msg_docs/OpenDroneIdOperatorId.md)
|
||||||
|
- [RtlStatus](../msg_docs/RtlStatus.md)
|
||||||
|
- [Airspeed](../msg_docs/Airspeed.md)
|
||||||
|
- [VehicleAcceleration](../msg_docs/VehicleAcceleration.md)
|
||||||
|
- [ParameterSetValueRequest](../msg_docs/ParameterSetValueRequest.md)
|
||||||
|
- [IrlockReport](../msg_docs/IrlockReport.md)
|
||||||
|
- [HeaterStatus](../msg_docs/HeaterStatus.md)
|
||||||
|
- [AdcReport](../msg_docs/AdcReport.md)
|
||||||
|
- [PwmInput](../msg_docs/PwmInput.md)
|
||||||
|
- [TiltrotorExtraControls](../msg_docs/TiltrotorExtraControls.md)
|
||||||
|
- [EstimatorAidSource1d](../msg_docs/EstimatorAidSource1d.md)
|
||||||
|
- [OrbTestMedium](../msg_docs/OrbTestMedium.md)
|
||||||
|
- [VehicleAttitudeSetpointV0](../msg_docs/VehicleAttitudeSetpointV0.md)
|
||||||
|
- [EstimatorAidSource2d](../msg_docs/EstimatorAidSource2d.md)
|
||||||
|
- [TuneControl](../msg_docs/TuneControl.md)
|
||||||
|
- [WheelEncoders](../msg_docs/WheelEncoders.md)
|
||||||
|
- [AutotuneAttitudeControlStatus](../msg_docs/AutotuneAttitudeControlStatus.md)
|
||||||
|
- [LandingTargetInnovations](../msg_docs/LandingTargetInnovations.md)
|
||||||
|
- [SensorsStatus](../msg_docs/SensorsStatus.md)
|
||||||
|
|
||||||
|
:::
|
||||||
@@ -61,12 +61,12 @@ For example the [VelocityLimits](../msg_docs/VelocityLimits.md) message definiti
|
|||||||
```text
|
```text
|
||||||
# Velocity and yaw rate limits for a multicopter position slow mode only
|
# Velocity and yaw rate limits for a multicopter position slow mode only
|
||||||
|
|
||||||
uint64 timestamp # time since system start (microseconds)
|
uint64 timestamp # [us] Time since system start.
|
||||||
|
|
||||||
# absolute speeds, NAN means use default limit
|
# absolute speeds, NAN means use default limit
|
||||||
float32 horizontal_velocity # [m/s]
|
float32 horizontal_velocity # [m/s] Horizontal velocity.
|
||||||
float32 vertical_velocity # [m/s]
|
float32 vertical_velocity # [m/s] Vertical velocity.
|
||||||
float32 yaw_rate # [rad/s]
|
float32 yaw_rate # [rad/s] Yaw rate.
|
||||||
```
|
```
|
||||||
|
|
||||||
By default this message definition will be compiled to a single topic with an id `velocity_limits`, a direct conversion from the CamelCase name to a snake_case version.
|
By default this message definition will be compiled to a single topic with an id `velocity_limits`, a direct conversion from the CamelCase name to a snake_case version.
|
||||||
@@ -92,15 +92,34 @@ To nest a message, simply include the nested message type in the parent message
|
|||||||
|
|
||||||
```text
|
```text
|
||||||
# Global position setpoint triplet in WGS84 coordinates.
|
# Global position setpoint triplet in WGS84 coordinates.
|
||||||
|
#
|
||||||
# This are the three next waypoints (or just the next two or one).
|
# This are the three next waypoints (or just the next two or one).
|
||||||
|
|
||||||
uint64 timestamp # time since system start (microseconds)
|
uint64 timestamp # [us] Time since system start.
|
||||||
|
|
||||||
PositionSetpoint previous
|
PositionSetpoint previous
|
||||||
PositionSetpoint current
|
PositionSetpoint current
|
||||||
PositionSetpoint next
|
PositionSetpoint next
|
||||||
```
|
```
|
||||||
|
|
||||||
|
### uORB Buffer Length (ORB_QUEUE_LENGTH)
|
||||||
|
|
||||||
|
uORB messages have a single-message buffer by default, which may be overwritten if the message publication rate is too high.
|
||||||
|
In most cases this does not matter: either we are only interested in the latest sample of a topic, such as a sensor value or a setpoint, or losing a few samples is not a particular problem.
|
||||||
|
For relatively few cases, such as vehicle commands, it is important that we don't drop topics.
|
||||||
|
|
||||||
|
In order to reduce the chance that messages will be dropped we can use named constant `ORB_QUEUE_LENGTH` to create a buffer of the specified length.
|
||||||
|
For example, to create a four-message queue, add the following line to your message definition:
|
||||||
|
|
||||||
|
```sh
|
||||||
|
uint8 ORB_QUEUE_LENGTH = 4
|
||||||
|
```
|
||||||
|
|
||||||
|
As long as subscribers are able to read messages out of the buffer quickly enough than it isn't ever fully filled to the queue length (by publishers), they will be able to get all messages that are sent.
|
||||||
|
Messages will still be lost they are published when the queue is filled.
|
||||||
|
|
||||||
|
Note that the queue length value must be a power of 2 (so 2, 4, 8, ...).
|
||||||
|
|
||||||
### Message/Field Deprecation {#deprecation}
|
### Message/Field Deprecation {#deprecation}
|
||||||
|
|
||||||
As there are external tools using uORB messages from log files, such as [Flight Review](https://github.com/PX4/flight_review), certain aspects need to be considered when updating existing messages:
|
As there are external tools using uORB messages from log files, such as [Flight Review](https://github.com/PX4/flight_review), certain aspects need to be considered when updating existing messages:
|
||||||
|
|||||||
@@ -38,7 +38,7 @@ The PX4 [uxrce_dds_client](../modules/modules_system.md#uxrce-dds-client) is gen
|
|||||||
Агент не залежить від клієнтського коду.
|
Агент не залежить від клієнтського коду.
|
||||||
Він може бути побудований окремо або в робочому просторі ROS 2, або встановлений як snap пакет в Ubuntu.
|
Він може бути побудований окремо або в робочому просторі ROS 2, або встановлений як snap пакет в Ubuntu.
|
||||||
|
|
||||||
When PX4 is built, a code generator uses the uORB message definitions in the source tree ([PX4-Autopilot/msg](https://github.com/PX4/PX4-Autopilot/tree/main/msg)) to compile support for the subset of uORB topics in [PX4-Autopilot/src/modules/uxrce_dds_client/dds_topics.yaml](https://github.com/PX4/PX4-Autopilot/blob/main/src/modules/uxrce_dds_client/dds_topics.yaml) into [uxrce_dds_client](../modules/modules_system.md#uxrce-dds-client).
|
When PX4 is built, a code generator uses the uORB message definitions in the source tree ([PX4-Autopilot/msg](https://github.com/PX4/PX4-Autopilot/tree/main/msg)) to compile support for the subset of uORB topics in [/src/modules/uxrce_dds_client/dds_topics.yaml](../middleware/dds_topics.md) into [uxrce_dds_client](../modules/modules_system.md#uxrce-dds-client).
|
||||||
|
|
||||||
PX4 main or release builds automatically export the set of uORB messages definitions in the build to an associated branch in [PX4/px4_msgs](https://github.com/PX4/px4_msgs).
|
PX4 main or release builds automatically export the set of uORB messages definitions in the build to an associated branch in [PX4/px4_msgs](https://github.com/PX4/px4_msgs).
|
||||||
|
|
||||||
@@ -326,13 +326,11 @@ ROS_DOMAIN_ID=3 PX4_UXRCE_DDS_PORT=9999 PX4_UXRCE_DDS_NS=drone make px4_sitl gz_
|
|||||||
|
|
||||||
## Підтримувані повідомлення uORB
|
## Підтримувані повідомлення uORB
|
||||||
|
|
||||||
The set of [PX4 uORB topics](../msg_docs/index.md) that are exposed through the client are set in [dds_topics.yaml](https://github.com/PX4/PX4-Autopilot/blob/main/src/modules/uxrce_dds_client/dds_topics.yaml).
|
The set of [PX4 uORB topics](../msg_docs/index.md) that are exposed through the client are set in [dds_topics.yaml](../middleware/dds_topics.md).
|
||||||
|
|
||||||
The topics are release specific (support is compiled into [uxrce_dds_client](../modules/modules_system.md#uxrce-dds-client) at build time).
|
The topics are release specific (support is compiled into [uxrce_dds_client](../modules/modules_system.md#uxrce-dds-client) at build time).
|
||||||
Хоча більшість випусків мають підтримувати дуже схожий набір повідомлень, щоб бути впевненими, вам слід перевірити файл yaml для вашого конкретного релізу.
|
Хоча більшість випусків мають підтримувати дуже схожий набір повідомлень, щоб бути впевненими, вам слід перевірити файл yaml для вашого конкретного релізу.
|
||||||
|
|
||||||
<!-- Jublish the set we use?: https://github.com/PX4/px4_msgs/issues/22 -->
|
|
||||||
|
|
||||||
Note that ROS 2/DDS needs to have the _same_ message definitions that were used to create the uXRCE-DDS client module in the PX4 Firmware in order to interpret the messages.
|
Note that ROS 2/DDS needs to have the _same_ message definitions that were used to create the uXRCE-DDS client module in the PX4 Firmware in order to interpret the messages.
|
||||||
The message definitions are stored in the ROS 2 interface package [PX4/px4_msgs](https://github.com/PX4/px4_msgs), and they are automatically synchronized by CI on the `main` and release branches.
|
The message definitions are stored in the ROS 2 interface package [PX4/px4_msgs](https://github.com/PX4/px4_msgs), and they are automatically synchronized by CI on the `main` and release branches.
|
||||||
Note that all the messages from PX4 source code are present in the repository, but only those listed in `dds_topics.yaml` will be available as ROS 2 topics.
|
Note that all the messages from PX4 source code are present in the repository, but only those listed in `dds_topics.yaml` will be available as ROS 2 topics.
|
||||||
@@ -349,21 +347,21 @@ Note that all the messages from PX4 source code are present in the repository, b
|
|||||||
```
|
```
|
||||||
|
|
||||||
::: info
|
::: info
|
||||||
Technically, [dds_topics.yaml](https://github.com/PX4/PX4-Autopilot/blob/main/src/modules/uxrce_dds_client/dds_topics.yaml) completely defines the relationship between PX4 uORB topics and ROS 2 messages.
|
Technically, [dds_topics.yaml](../middleware/dds_topics.md) completely defines the relationship between PX4 uORB topics and ROS 2 messages.
|
||||||
For more information see [DDS Topics YAML](#dds-topics-yaml) below.
|
For more information see [DDS Topics YAML](#dds-topics-yaml) below.
|
||||||
|
|
||||||
:::
|
:::
|
||||||
|
|
||||||
## Customizing the Namespace
|
## Customizing the Namespace
|
||||||
|
|
||||||
Custom topic and service namespaces can be applied at build time (changing [dds_topics.yaml](https://github.com/PX4/PX4-Autopilot/blob/main/src/modules/uxrce_dds_client/dds_topics.yaml)) or at runtime (which is useful for multi vehicle operations):
|
Custom topic and service namespaces can be applied at build time (changing [dds_topics.yaml](../middleware/dds_topics.md)) or at runtime (which is useful for multi vehicle operations):
|
||||||
|
|
||||||
- One possibility is to use the `-n` option when starting the [uxrce_dds_client](../modules/modules_system.md#uxrce-dds-client) from command line.
|
- One possibility is to use the `-n` option when starting the [uxrce_dds_client](../modules/modules_system.md#uxrce-dds-client) from command line.
|
||||||
Ця техніка може бути використана як у симуляторах, так і на реальних транспортних засобах.
|
Ця техніка може бути використана як у симуляторах, так і на реальних транспортних засобах.
|
||||||
- A custom namespace can be provided for simulations (only) by setting the environment variable `PX4_UXRCE_DDS_NS` before starting the simulation.
|
- A custom namespace can be provided for simulations (only) by setting the environment variable `PX4_UXRCE_DDS_NS` before starting the simulation.
|
||||||
|
|
||||||
:::info
|
:::info
|
||||||
Changing the namespace at runtime will append the desired namespace as a prefix to all `topic` fields in [dds_topics.yaml](https://github.com/PX4/PX4-Autopilot/blob/main/src/modules/uxrce_dds_client/dds_topics.yaml) and all [service servers](#dds-ros-2-services).
|
Changing the namespace at runtime will append the desired namespace as a prefix to all `topic` fields in [dds_topics.yaml](../middleware/dds_topics.md) and all [service servers](#dds-ros-2-services).
|
||||||
Отже, команди, подібні до:
|
Отже, команди, подібні до:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
@@ -385,13 +383,13 @@ PX4_UXRCE_DDS_NS=uav_1 make px4_sitl gz_x500
|
|||||||
|
|
||||||
:::
|
:::
|
||||||
|
|
||||||
## Налаштування PX4 ROS 2 QoS
|
## PX4 ROS 2 QoS Settings
|
||||||
|
|
||||||
Налаштування QoS PX4 для видавців несумісні з налаштуваннями QoS за замовчуванням для підписників ROS 2.
|
PX4 QoS settings for publishers are incompatible with the default QoS settings for ROS 2 subscribers.
|
||||||
Таким чином, якщо код ROS 2 потрібно підписатися на тему uORB, йому потрібно використовувати сумісні налаштування QoS.
|
So if ROS 2 code needs to subscribe to a uORB topic, it will need to use compatible QoS settings.
|
||||||
One example of which is shown in [ROS 2 User Guide > ROS 2 Subscriber QoS Settings](../ros2/user_guide.md#ros-2-subscriber-qos-settings).
|
One example of which is shown in [ROS 2 User Guide > ROS 2 Subscriber QoS Settings](../ros2/user_guide.md#ros-2-subscriber-qos-settings).
|
||||||
|
|
||||||
PX4 використовує наступні параметри QoS для видавців:
|
PX4 uses the following QoS settings for publishers:
|
||||||
|
|
||||||
```cpp
|
```cpp
|
||||||
uxrQoS_t qos = {
|
uxrQoS_t qos = {
|
||||||
@@ -402,7 +400,7 @@ uxrQoS_t qos = {
|
|||||||
};
|
};
|
||||||
```
|
```
|
||||||
|
|
||||||
PX4 використовує наступні параметри QoS для підписників:
|
PX4 uses the following QoS settings for subscribers:
|
||||||
|
|
||||||
```cpp
|
```cpp
|
||||||
uxrQoS_t qos = {
|
uxrQoS_t qos = {
|
||||||
@@ -413,17 +411,17 @@ uxrQoS_t qos = {
|
|||||||
};
|
};
|
||||||
```
|
```
|
||||||
|
|
||||||
ROS 2 використовує наступні налаштування QoS (за замовчуванням) для видавців та підписок: «зберігати останніми» для історії з розміром черги 10, «reliable» для надійності, «volatile» для тривалості і «system default» для життєздатності.
|
ROS 2 uses the following QoS settings (by default) for publishers and subscriptions: "keep last" for history with a queue size of 10, "reliable" for reliability, "volatile" for durability, and "system default" for liveliness.
|
||||||
Дедлайн, тривалість життя та оренда також налаштовані на "за замовчуванням".
|
Deadline, lifespan, and lease durations are also all set to "default".
|
||||||
|
|
||||||
<!-- From https://github.com/PX4/PX4-user_guide/pull/2259#discussion_r1099788316 -->
|
<!-- From https://github.com/PX4/PX4-user_guide/pull/2259#discussion_r1099788316 -->
|
||||||
|
|
||||||
## DDS теми YAML
|
## DDS Topics YAML
|
||||||
|
|
||||||
The PX4 yaml file [dds_topics.yaml](https://github.com/PX4/PX4-Autopilot/blob/main/src/modules/uxrce_dds_client/dds_topics.yaml) defines the set of PX4 uORB topics that are built into firmware and published.
|
The PX4 [dds_topics.yaml](../middleware/dds_topics.md) file defines the set of PX4 uORB topics that are built into firmware and published.
|
||||||
Точніше, він повністю визначає взаємозв'язок/сполучення між повідомленнями PX4 uORB і ROS 2.
|
More precisely, it completely defines the relationship/pairing between PX4 uORB and ROS 2 messages.
|
||||||
|
|
||||||
Файл структурований наступним чином:
|
The file is structured as follows:
|
||||||
|
|
||||||
```yaml
|
```yaml
|
||||||
publications:
|
publications:
|
||||||
@@ -471,7 +469,7 @@ Each (`topic`,`type`) pairs defines:
|
|||||||
It is identified by the last token in `topic:` that starts with `/` and does not contains any `/` in it.
|
It is identified by the last token in `topic:` that starts with `/` and does not contains any `/` in it.
|
||||||
`vehicle_odometry`, `vehicle_status` and `offboard_control_mode` are examples of base names.
|
`vehicle_odometry`, `vehicle_status` and `offboard_control_mode` are examples of base names.
|
||||||
3. The topic [namespace](https://design.ros2.org/articles/topic_and_service_names.html#namespaces).
|
3. The topic [namespace](https://design.ros2.org/articles/topic_and_service_names.html#namespaces).
|
||||||
За замовчуванням встановлено на:
|
By default it is set to:
|
||||||
- `/fmu/out/` for topics that are _published_ by PX4.
|
- `/fmu/out/` for topics that are _published_ by PX4.
|
||||||
- `/fmu/in/` for topics that are _subscribed_ by PX4.
|
- `/fmu/in/` for topics that are _subscribed_ by PX4.
|
||||||
4. The message type (`VehicleOdometry`, `VehicleStatus`, `OffboardControlMode`, etc.) and the ROS 2 package (`px4_msgs`) that is expected to provide the message definition.
|
4. The message type (`VehicleOdometry`, `VehicleStatus`, `OffboardControlMode`, etc.) and the ROS 2 package (`px4_msgs`) that is expected to provide the message definition.
|
||||||
@@ -485,22 +483,22 @@ Add a topic to the `subscriptions` section to:
|
|||||||
|
|
||||||
- Create a unidirectional route going from the ROS2 topic to the _default_ instance (instance 0) of the associated uORB topic.
|
- Create a unidirectional route going from the ROS2 topic to the _default_ instance (instance 0) of the associated uORB topic.
|
||||||
For example, it creates a ROS2 subscriber of `/fmu/in/vehicle_odometry` and a uORB publisher of `vehicle_odometry`.
|
For example, it creates a ROS2 subscriber of `/fmu/in/vehicle_odometry` and a uORB publisher of `vehicle_odometry`.
|
||||||
- Якщо інші (внутрішні) модулі PX4 вже публікують у тому ж екземплярі теми uORB, що й публікатор ROS2, підписники цього екземпляра будуть отримувати всі потоки повідомлень.
|
- If other (internal) PX4 modules are already publishing on the same uORB topic instance as the ROS2 publisher, the instance's subscribers will receive all streams of messages.
|
||||||
Підписник uORB не зможе визначити, чи вхідне повідомлення було опубліковане PX4 або ROS2.
|
The uORB subscriber will not be able to determine if an incoming message was published by PX4 or by ROS2.
|
||||||
- Це бажана поведінка, коли очікується, що ROS2-видавець буде єдиним видавцем у екземплярі теми (наприклад, для заміни внутрішнього видавця теми під час автономного керування), або коли джерело декількох потоків публікацій не має значення.
|
- This is the desired behavior when the ROS2 publisher is expected to be the sole publisher on the topic instance (for example, replacing an internal publisher to the topic during offboard control), or when the source of multiple publishing streams does not matter.
|
||||||
|
|
||||||
Add a topic to the `subscriptions_multi` section to:
|
Add a topic to the `subscriptions_multi` section to:
|
||||||
|
|
||||||
- Create a unidirectional route going from the ROS2 topic to a _new_ instance of the associated uORB topic.
|
- Create a unidirectional route going from the ROS2 topic to a _new_ instance of the associated uORB topic.
|
||||||
For example, if `vehicle_odometry` has already `2` instances, it creates a ROS2 subscriber of `/fmu/in/vehicle_odometry` and a uORB publisher on instance `3` of `vehicle_odometry`.
|
For example, if `vehicle_odometry` has already `2` instances, it creates a ROS2 subscriber of `/fmu/in/vehicle_odometry` and a uORB publisher on instance `3` of `vehicle_odometry`.
|
||||||
- Це гарантує, що жоден інший внутрішній модуль PX4 не публікуватиметься на тому самому екземплярі, що використовується uXRCE-DDS.
|
- This ensures that no other internal PX4 module will publish on the same instance used by uXRCE-DDS.
|
||||||
Підписники зможуть підписатися на потрібний екземпляр і розрізняти видавців.
|
The subscribers will be able to subscribe to the desired instance and distinguish between publishers.
|
||||||
- Зауважте, однак, що це гарантує розділення між видавцями PX4 і ROS2, а не між кількома видавцями ROS2.
|
- Note, however, that this guarantees separation between PX4 and ROS2 publishers, not among multiple ROS2 publishers.
|
||||||
У цьому випадку їхні повідомлення все одно будуть перенаправлені на той самий екземпляр.
|
In that scenario, their messages will still be routed to the same instance.
|
||||||
- Це бажана поведінка, наприклад, коли ви хочете, щоб PX4 реєстрував показання двох однакових датчиків; вони обидва публікуватимуться в одній темі, але один з них використовуватиме екземпляр 0, а інший - екземпляр 1.
|
- This is the desired behavior, for example, when you want PX4 to log the readings of two equal sensors; they will both publish on the same topic, but one will use instance 0 and the other will use instance 1.
|
||||||
|
|
||||||
Ви можете довільно змінювати конфігурацію.
|
You can arbitrarily change the configuration.
|
||||||
Наприклад, ви можете використовувати різні простори імен за замовчуванням або використовувати власний пакет для зберігання визначень повідомлень.
|
For example, you could use different default namespaces or use a custom package to store the message definitions.
|
||||||
|
|
||||||
## DDS (ROS 2) Services
|
## DDS (ROS 2) Services
|
||||||
|
|
||||||
@@ -513,62 +511,62 @@ For example, the `/fmu/vehicle_command` service server defined in [`px4_msgs::sr
|
|||||||
|
|
||||||
For a list of services, details and examples see the [service documentation](../ros2/user_guide.md#px4-ros-2-service-servers) in the ROS 2 User Guide.
|
For a list of services, details and examples see the [service documentation](../ros2/user_guide.md#px4-ros-2-service-servers) in the ROS 2 User Guide.
|
||||||
|
|
||||||
## Посібник міграції з Fast-RTPS на uXRCE-DDS
|
## Fast-RTPS to uXRCE-DDS Migration Guidelines
|
||||||
|
|
||||||
These guidelines explain how to migrate from using PX4 v1.13 [Fast-RTPS](../middleware/micrortps.md) middleware to PX4 v1.14 `uXRCE-DDS` middleware.
|
These guidelines explain how to migrate from using PX4 v1.13 [Fast-RTPS](../middleware/micrortps.md) middleware to PX4 v1.14 `uXRCE-DDS` middleware.
|
||||||
These are useful if you have [ROS 2 applications written for PX4 v1.13](https://docs.px4.io/v1.13/en/ros/ros2_comm.html), or you have used Fast-RTPS to interface your applications to PX4 [directly](https://docs.px4.io/v1.13/en/middleware/micrortps.html#agent-in-an-offboard-fast-dds-interface-ros-independent).
|
These are useful if you have [ROS 2 applications written for PX4 v1.13](https://docs.px4.io/v1.13/en/ros/ros2_comm.html), or you have used Fast-RTPS to interface your applications to PX4 [directly](https://docs.px4.io/v1.13/en/middleware/micrortps.html#agent-in-an-offboard-fast-dds-interface-ros-independent).
|
||||||
|
|
||||||
:::info
|
:::info
|
||||||
This section contains migration-specific information.
|
This section contains migration-specific information.
|
||||||
Вам також слід прочитати решту цієї сторінки, щоб правильно зрозуміти uXRCE-DDS.
|
You should also read the rest of this page to properly understand uXRCE-DDS.
|
||||||
:::
|
:::
|
||||||
|
|
||||||
#### Залежності не потрібно видаляти
|
#### Dependencies do not need to be removed
|
||||||
|
|
||||||
uXRCE-DDS does not need the dependencies that were required for Fast-RTPS, such as those installed by following the topic [Fast DDS Installation](https://docs.px4.io/v1.13/en/dev_setup/fast-dds-installation.html).
|
uXRCE-DDS does not need the dependencies that were required for Fast-RTPS, such as those installed by following the topic [Fast DDS Installation](https://docs.px4.io/v1.13/en/dev_setup/fast-dds-installation.html).
|
||||||
Ви можете зберегти їх, якщо хочете, не впливаючи на ваші додатки uXRCE-DDS.
|
You can keep them if you want, without affecting your uXRCE-DDS applications.
|
||||||
|
|
||||||
Якщо ви вирішили видалити залежності, будьте обережні, щоб не видалити нічого, що використовується програмами (наприклад, Java).
|
If you do choose to remove the dependencies, take care not to remove anything that is used by applications (for example, Java).
|
||||||
|
|
||||||
#### `_rtps` targets have been removed
|
#### `_rtps` targets have been removed
|
||||||
|
|
||||||
Anywhere you previously used a build target with extension `_rtps`, such as `px4_fmu-v5_rtps` or `px4_sitl_rtps`, you can now use the equivalent default target (for these cases `px4_fmu-v5_default` and `px4_sitl_default`).
|
Anywhere you previously used a build target with extension `_rtps`, such as `px4_fmu-v5_rtps` or `px4_sitl_rtps`, you can now use the equivalent default target (for these cases `px4_fmu-v5_default` and `px4_sitl_default`).
|
||||||
|
|
||||||
The make targets with extension `_rtps` were used to build firmware that included client side RTPS code.
|
The make targets with extension `_rtps` were used to build firmware that included client side RTPS code.
|
||||||
Проміжне програмне забезпечення uXRCE-DDS за замовчуванням включено до збірок для більшості плат, тому вам більше не потрібна спеціальна прошивка для роботи з ROS 2.
|
The uXRCE-DDS middleware is included by default in builds for most boards, so you no longer need a special firmware to work with ROS 2.
|
||||||
|
|
||||||
To check if your board has the middleware, look for `CONFIG_MODULES_UXRCE_DDS_CLIENT=y` in the `.px4board` file of your board.
|
To check if your board has the middleware, look for `CONFIG_MODULES_UXRCE_DDS_CLIENT=y` in the `.px4board` file of your board.
|
||||||
Those files are nested in [PX4-Autopilot/boards](https://github.com/PX4/PX4-Autopilot/tree/main/boards).
|
Those files are nested in [PX4-Autopilot/boards](https://github.com/PX4/PX4-Autopilot/tree/main/boards).
|
||||||
|
|
||||||
If it is not present, or if it is set to `n`, then you have to clone the PX4 repo, modify the board configuration and manually [compile](../dev_setup/building_px4.md) the firmware.
|
If it is not present, or if it is set to `n`, then you have to clone the PX4 repo, modify the board configuration and manually [compile](../dev_setup/building_px4.md) the firmware.
|
||||||
|
|
||||||
#### Новий модуль клієнта та нові параметри запуску
|
#### New client module and new start parameters
|
||||||
|
|
||||||
Оскільки клієнт реалізовано новим модулем PX4, тепер у вас є нові параметри для його запуску.
|
As the client is implemented by a new PX4 module, you now have new parameters to start it.
|
||||||
Take a look at the [client startup section](#starting-the-client) to learn how this is done.
|
Take a look at the [client startup section](#starting-the-client) to learn how this is done.
|
||||||
|
|
||||||
#### Новий файл для налаштування того, які теми публікуються
|
#### New file for setting which topics are published
|
||||||
|
|
||||||
The list of topics that are published and subscribed for a particular firmware is now managed by the [dds_topic.yaml](https://github.com/PX4/PX4-Autopilot/blob/main/src/modules/uxrce_dds_client/dds_topics.yaml) configuration file, which replaces [urtps_bridge_topics.yaml](https://github.com/PX4/PX4-Autopilot/blob/release/1.13/msg/tools/urtps_bridge_topics.yaml)
|
The list of topics that are published and subscribed for a particular firmware is now managed by the [dds_topics.yaml](../middleware/dds_topics.md) configuration file, which replaces [urtps_bridge_topics.yaml](https://github.com/PX4/PX4-Autopilot/blob/release/1.13/msg/tools/urtps_bridge_topics.yaml)
|
||||||
|
|
||||||
See [Supported uORB Messages](#supported-uorb-messages) and [DDS Topics YAML](#dds-topics-yaml) sections for more information.
|
See [Supported uORB Messages](#supported-uorb-messages) and [DDS Topics YAML](#dds-topics-yaml) sections for more information.
|
||||||
|
|
||||||
#### Теми більше не потрібно синхронізувати між клієнтом і агентом.
|
#### Topics no longer need to be synced between client and agent.
|
||||||
|
|
||||||
The list of bridged topics between agent and client no longer needs to be synced for ROS 2, so the `update_px4_ros2_bridge.sh` script is no longer needed.
|
The list of bridged topics between agent and client no longer needs to be synced for ROS 2, so the `update_px4_ros2_bridge.sh` script is no longer needed.
|
||||||
|
|
||||||
#### Налаштування назви теми за замовчуванням змінено
|
#### Default topic naming convention has changed
|
||||||
|
|
||||||
Змінився формат назв тем:
|
The topic naming format changed:
|
||||||
|
|
||||||
- Published topics: `/fmu/topic-name/out` (Fast-RTPS) to `/fmu/out/topic-name` (XRCE-DDS).
|
- Published topics: `/fmu/topic-name/out` (Fast-RTPS) to `/fmu/out/topic-name` (XRCE-DDS).
|
||||||
- Subscribed topics: `/fmu/topic-name/in`(Fast-RTPS) to `/fmu/in/topic-name` (XRCE-DDS).
|
- Subscribed topics: `/fmu/topic-name/in`(Fast-RTPS) to `/fmu/in/topic-name` (XRCE-DDS).
|
||||||
|
|
||||||
Вам слід оновити свій додаток відповідно до нової конвенції.
|
You should update your application to the new convention.
|
||||||
|
|
||||||
:::info
|
:::info
|
||||||
You might also edit [dds_topic.yaml](https://github.com/PX4/PX4-Autopilot/blob/main/src/modules/uxrce_dds_client/dds_topics.yaml) to revert to the old convention.
|
You might also edit [dds_topic.yaml](https://github.com/PX4/PX4-Autopilot/blob/main/src/modules/uxrce_dds_client/dds_topics.yaml) to revert to the old convention.
|
||||||
Це не рекомендується, оскільки це означає, що вам доведеться завжди використовувати кастомну прошивку.
|
This is not recommended because it means that you would have to always use custom firmware.
|
||||||
:::
|
:::
|
||||||
|
|
||||||
#### XRCE-DDS-Agent
|
#### XRCE-DDS-Agent
|
||||||
@@ -576,18 +574,18 @@ You might also edit [dds_topic.yaml](https://github.com/PX4/PX4-Autopilot/blob/m
|
|||||||
The XRCE-DDS agent is "generic" and independent of PX4: [micro-xrce-dds-agent](https://micro-xrce-dds.docs.eprosima.com/en/latest/agent.html).
|
The XRCE-DDS agent is "generic" and independent of PX4: [micro-xrce-dds-agent](https://micro-xrce-dds.docs.eprosima.com/en/latest/agent.html).
|
||||||
There are many ways to install it on your PC / companion computer - for more information see the [dedicated section](#micro-xrce-dds-agent-installation).
|
There are many ways to install it on your PC / companion computer - for more information see the [dedicated section](#micro-xrce-dds-agent-installation).
|
||||||
|
|
||||||
#### Зміни, що стосуються конкретних додатків
|
#### Application-Specific Changes
|
||||||
|
|
||||||
If you where not using ROS 2 alongside the agent ([Fast DDS Interface ROS-Independent](https://docs.px4.io/v1.13/en/middleware/micrortps.html#agent-in-an-offboard-fast-dds-interface-ros-independent)), then you need to migrate to [eProsima Fast DDS](https://fast-dds.docs.eprosima.com/en/latest/index.html).
|
If you where not using ROS 2 alongside the agent ([Fast DDS Interface ROS-Independent](https://docs.px4.io/v1.13/en/middleware/micrortps.html#agent-in-an-offboard-fast-dds-interface-ros-independent)), then you need to migrate to [eProsima Fast DDS](https://fast-dds.docs.eprosima.com/en/latest/index.html).
|
||||||
|
|
||||||
ROS 2 applications still need to compile alongside the PX4 messages, which you do by adding the [px4_msgs](https://github.com/PX4/px4_msgs) package to your workspace.
|
ROS 2 applications still need to compile alongside the PX4 messages, which you do by adding the [px4_msgs](https://github.com/PX4/px4_msgs) package to your workspace.
|
||||||
You can remove the [px4_ros_com](https://github.com/PX4/px4_ros_com) package as it is no longer needed, other than for example code.
|
You can remove the [px4_ros_com](https://github.com/PX4/px4_ros_com) package as it is no longer needed, other than for example code.
|
||||||
|
|
||||||
У ваших вузлах ROS 2 вам знадобиться:
|
In your ROS 2 nodes, you will need to:
|
||||||
|
|
||||||
- Update the [QoS](#px4-ros-2-qos-settings) of your publishers and subscribers as PX4 does not use the ROS 2 default settings.
|
- Update the [QoS](#px4-ros-2-qos-settings) of your publishers and subscribers as PX4 does not use the ROS 2 default settings.
|
||||||
- Change the names of your topics, unless you edited [dds_topic.yaml](https://github.com/PX4/PX4-Autopilot/blob/main/src/modules/uxrce_dds_client/dds_topics.yaml).
|
- Change the names of your topics, unless you edited [dds_topic.yaml](https://github.com/PX4/PX4-Autopilot/blob/main/src/modules/uxrce_dds_client/dds_topics.yaml).
|
||||||
- Видаліть все, що стосується синхронізації часу, оскільки XRCE-DDS автоматично піклується про синхронізацію часу агента/клієнта.
|
- Remove everything related to time synchronization, as XRCE-DDS automatically takes care of agent/client time synchronization.
|
||||||
|
|
||||||
In C++ applications you can set the `timestamp` field of your messages like this:
|
In C++ applications you can set the `timestamp` field of your messages like this:
|
||||||
|
|
||||||
@@ -601,7 +599,7 @@ You can remove the [px4_ros_com](https://github.com/PX4/px4_ros_com) package as
|
|||||||
msg.timestamp = int(self.get_clock().now().nanoseconds / 1000)
|
msg.timestamp = int(self.get_clock().now().nanoseconds / 1000)
|
||||||
```
|
```
|
||||||
|
|
||||||
## Корисні ресурси
|
## Helpful Resources
|
||||||
|
|
||||||
- [ROS 2 in PX4: Technical Details of a Seamless Transition to XRCE-DDS](https://www.youtube.com/watch?v=F5oelooT67E) - Pablo Garrido & Nuno Marques (youtube)
|
- [ROS 2 in PX4: Technical Details of a Seamless Transition to XRCE-DDS](https://www.youtube.com/watch?v=F5oelooT67E) - Pablo Garrido & Nuno Marques (youtube)
|
||||||
- [PX4 ROS 2 offboard tutorial](https://gist.github.com/julianoes/adbf76408663829cd9aed8d14c88fa29) (Github gist - JulianOes)
|
- [PX4 ROS 2 offboard tutorial](https://gist.github.com/julianoes/adbf76408663829cd9aed8d14c88fa29) (Github gist - JulianOes)
|
||||||
|
|||||||
@@ -28,7 +28,7 @@ The agent acts as a proxy for the client to publish and subscribe to topics in t
|
|||||||
|
|
||||||
The PX4 [uxrce_dds_client](../modules/modules_system.md#uxrce-dds-client) is generated at build time and included in PX4 firmware by default.
|
The PX4 [uxrce_dds_client](../modules/modules_system.md#uxrce-dds-client) is generated at build time and included in PX4 firmware by default.
|
||||||
It includes both the "generic" micro XRCE-DDS client code, and PX4-specific translation code that it uses to publish to/from uORB topics.
|
It includes both the "generic" micro XRCE-DDS client code, and PX4-specific translation code that it uses to publish to/from uORB topics.
|
||||||
The subset of uORB messages that are generated into the client are listed in [PX4-Autopilot/src/modules/uxrce_dds_client/dds_topics.yaml](https://github.com/PX4/PX4-Autopilot/blob/main/src/modules/uxrce_dds_client/dds_topics.yaml).
|
The subset of uORB messages that are generated into the client are specified in [dds_topics.yaml](../middleware/dds_topics.md).
|
||||||
The generator uses the uORB message definitions in the source tree: [PX4-Autopilot/msg](https://github.com/PX4/PX4-Autopilot/tree/main/msg) to create the code for sending ROS 2 messages.
|
The generator uses the uORB message definitions in the source tree: [PX4-Autopilot/msg](https://github.com/PX4/PX4-Autopilot/tree/main/msg) to create the code for sending ROS 2 messages.
|
||||||
|
|
||||||
ROS 2 applications need to be built in a workspace that has the _same_ message definitions that were used to create the uXRCE-DDS client module in the PX4 Firmware.
|
ROS 2 applications need to be built in a workspace that has the _same_ message definitions that were used to create the uXRCE-DDS client module in the PX4 Firmware.
|
||||||
@@ -405,7 +405,7 @@ To control applications, ROS 2 applications:
|
|||||||
- підписатися на (слухати) тематичні теми, опубліковані PX4
|
- підписатися на (слухати) тематичні теми, опубліковані PX4
|
||||||
- опублікувати у темах, які спонукають PX4 виконати певну дію.
|
- опублікувати у темах, які спонукають PX4 виконати певну дію.
|
||||||
|
|
||||||
The topics that you can use are defined in [dds_topics.yaml](https://github.com/PX4/PX4-Autopilot/blob/main/src/modules/uxrce_dds_client/dds_topics.yaml), and you can get more information about their data in the [uORB Message Reference](../msg_docs/index.md).
|
The topics that you can use are defined in [dds_topics.yaml](../middleware/dds_topics.md), and you can get more information about their data in the [uORB Message Reference](../msg_docs/index.md).
|
||||||
For example, [VehicleGlobalPosition](../msg_docs/VehicleGlobalPosition.md) can be used to get the vehicle global position, while [VehicleCommand](../msg_docs/VehicleCommand.md) can be used to command actions such as takeoff and land.
|
For example, [VehicleGlobalPosition](../msg_docs/VehicleGlobalPosition.md) can be used to get the vehicle global position, while [VehicleCommand](../msg_docs/VehicleCommand.md) can be used to command actions such as takeoff and land.
|
||||||
|
|
||||||
The [ROS 2 Example applications](#ros-2-example-applications) examples below provide concrete examples of how to use these topics.
|
The [ROS 2 Example applications](#ros-2-example-applications) examples below provide concrete examples of how to use these topics.
|
||||||
@@ -743,7 +743,7 @@ Custom topic and service namespaces can be applied at build time (changing [dds_
|
|||||||
- A custom namespace can be provided for simulations (only) by setting the environment variable `PX4_UXRCE_DDS_NS` before starting the simulation.
|
- A custom namespace can be provided for simulations (only) by setting the environment variable `PX4_UXRCE_DDS_NS` before starting the simulation.
|
||||||
|
|
||||||
:::info
|
:::info
|
||||||
Changing the namespace at runtime will append the desired namespace as a prefix to all `topic` fields in [dds_topics.yaml](https://github.com/PX4/PX4-Autopilot/blob/main/src/modules/uxrce_dds_client/dds_topics.yaml) and all [service servers](#px4-ros-2-service-servers).
|
Changing the namespace at runtime will append the desired namespace as a prefix to all `topic` fields in [dds_topics.yaml](../middleware/dds_topics.md) and all [service servers](#px4-ros-2-service-servers).
|
||||||
Отже, команди, подібні до:
|
Отже, команди, подібні до:
|
||||||
|
|
||||||
```sh
|
```sh
|
||||||
|
|||||||
Reference in New Issue
Block a user