mavlink / mavros

MAVLink to ROS gateway with proxy for Ground Control Station
Other
902 stars 993 forks source link

Publishing mavros/rc/in topic to mavros_msgs/RCIn #1149

Open TK1109 opened 5 years ago

TK1109 commented 5 years ago

Hello,

I am trying to get mavros/rc/in to be published as a message: mavros_msg/RCIn I have entered the following into a terminal window: $rostopic echo /mavros/rc/in | rostopic pub bar mavros_msgs/RCIn

Ultimately I want to be able to read the channel values as they change with input in MATLAB.

However, when I look in MATLAB to see if the information can be read or not, it appears that no new information is read by MATLAB from the mavros_msgs/RCIn

I am I entering the publish command line correctly? Is there a way to verify in ROS that the message is publishing? I am quite new to ROS and I am having trouble navigating this issue.

Thanks!

screenshot from 2019-01-02 08-21-03

vooon commented 5 years ago

I don't know matlab, but perhaps you mess with topic type (mavros/RCIn) and topic name? Matlab code looks like you create new empty RCIn massage (struct/class) and print it (new message are zeroed).

And why you need to republish topic? Maybe easier just remap it?

vooon commented 5 years ago

Oh, also you can use RQT to watch what topics exists and what data is published.