PlotJuggler/plotjuggler-ros-plugins

PX4 topics can't be plotted

dakejahl opened this issue · 0 comments

Hello, thanks for the project! I've been using it with PX4 for a year or two now and it's been invaluable.

I am trying to use PlotJuggler to subscribe to an /fmu topic over the DDS bridge from a device connected on the same network, but the topic doesn't appear in the list in PJ. All of the other topics from running nodes do appear, just not the /fmu topics. Strangely if I run ros2 topic hz /fmu/out/vehicle_attitude on the device the topic appears in the list, but PJ still fails to plot it. I suspect this might be related to the QoS settings but I'm not sure.
https://docs.px4.io/main/en/middleware/uxrce_dds.html#px4-ros-2-qos-settings

PX4 uses the following QoS settings for publishers:

uxrQoS_t qos = {
  .durability = UXR_DURABILITY_TRANSIENT_LOCAL,
  .reliability = UXR_RELIABILITY_BEST_EFFORT,
  .history = UXR_HISTORY_KEEP_LAST,
  .depth = 0,
};

I added some debug printout in DataStreamROS2::subscribeToTopic and I see the QoS settings don't match the above (/camera/imu is from a realsense node and I am able to plot, it likely has default QoS settings)

subscribeToTopic:  /camera/imu
durability:  2
reliability:  1
history:  1
depth:  10

subscribeToTopic:  /fmu/out/vehicle_attitude
durability:  2
reliability:  1
history:  1
depth:  10

image