Send Mavros StatusText to QGC

Hey guys,

I want to send strings to QGC. I am using a companion computer that is running MAVROS connected to TELM2 of Pixhawk. QGC is connected over Telemetry (TELM1 on pixhawk) on a different computer. I would like to send messages (best would be short srings) from my companion computer over Telemetry to the ground station.

I found the mavros_msgs::StatusText would be a good choice. However, I dont receive statustext messages in GQC. What am I might doing wrong?

Is mavros/statustext/send the right message in order to send the message? However, I also tried mavros/statustext/recv but it didnt work either.

_pub_statusText = nodeHandle.advertise<mavros_msgs::StatusText> ("/mavros/statustext/send", 10);

This is my send function:

void UAV_controller:: send_statusText(std::string status_)
  mavros_msgs::StatusText send_status;

  send_status.header.stamp = ros::Time::now();

  send_status.severity = send_status.CRITICAL;
  send_status.text = status_;


On the companion computer I do:
roslaunch mavros px4.launch fcu_url:="/dev/ttyUSB0:921600"
and afterwards I start my code.

Please help! Any hints are highly appreciated.

I did find the solution by myself. I had to set the MAV_X_FORWARD parameter. Now it is working properly.

1 Like