Offboard mode using ROS2 and RTPS

Good morning everyone

I am trying to create a simulation (SITL) environment by using the interface PX4-RTPS-ROS2.
My code publish, from ROS2 to PX4 using RTPS, local position and attitude setpoints via the topics /VehicleLocalPositionSetpoint_PubSubTopic and /VehicleAttitudeSetpoint_PubSubTopic.
On PX4 side, the topics are filled, but when I try to switch to Offboard mode (either on QGroundControl or in the shell), the robot refuses to do it, and no error message is displayed on the shell.
I have noticed that the topic /VehicleAttitudeSetpoint is filled by other existing scripts working on PX4 side… but I really dunno if that could be the problem or not.
Any suggestions? Did anyone of you succeed in doing something like that before?
Thanks for your time, wish you a wonderful day


1 Like

Did you fix your issue?

Please check this example:

Did you get the Attitude Setpoint working with ROS2 ? @delbesca