Nothing Publishes to MAVROS Topics

  1. Image and ArduPilot version.
    EMLID 2017-03-23 with Arducopter

  2. Detailed problem description. How does observed behavior differ from the expected one?

Nothing is being published to the MAVROS topics. I followed the instructions for setting up ROS/MAVROS and it all seems to work until I try echoing a topic - at which point nothing gets output. I can verify the topics exist but it seems nothing is being published to them

  1. Your step by step actions.
    I followed the instructions on:

https://docs.emlid.com/navio2/common/dev/ros/#running-mavros-node

Another difference is I didn’t get any of the yellow or red writing output to my screen when creating the MAVROS Node.

4)I would post a picture of my setup but it is just the Navio2/Raspi connected to a screen and keyboard. Please let me know if a picture would be helpful in any way.

I would really appreciate any help, this has had me stumped for a while.

Hi,
I think the problem is that you specified incorrect ip or port at which ardupilot is running. It would be great if you can send the contents of /etc/default/ardu[your vehicle] and the command you’re typing when trying to run mavros node.

Hello,

Thank you for the quick response!
Below is screenshot of two outputs. /etc/default/ardupilot and then _/etc/default/arducopter.

I put both here because I had a feeling one might be overwriting the other somehow - I am not sure which one gets used when I enable arducopter.

Thanks again for the help,

Chris

Hello,
It seems that you’re running mavros node with incorrect port or don’t set stream rate if you don’t use GCS. To get information from the ros topics you need to make sure that you’re specifying correct IP and port when running mavros_node.
You have 127.0.0.1:14650, so the command you need to type should be something like this:
rosrun mavros mavros_node _fcu_url:=udp://:14650@

And, if you don’t use your GCS, you should also type
rosservice call /mavros/set_stream_rate 0 10 1

If you still don’t get any data, please feel free to ask any questions

Thank you! I will try that now but I still have one question.

What is the difference between ardupilot & arducopter?

When setting up Ardupilot your docs say to edit /etc/default/arducopter and enable arducopter.

Then, when setting up ROS, your docs say to edit /etc/default/ardupilot and enable ardupilot.

Do I need to edit both, or just one? similarly, do i need to run both or just one?

If you have arducopter, you should edit /etc/default/arducopter. And if you have arduplane, your choice is /etc/default/arduplane. The same with ardurover. /etc/default/ardupilot is used for custom builds. Thank you for noticing, we’ll fix the docs.

Hello again!

Thank you for the quick reply!

It’s still not working but at least I got a different error. Below I attached a picture of my error (top) and output from /etc/default/arducopter. (bottom)

I reset my SD card and just followed the instructions again except whenever the ROS instructions said “ardupilot” I pretended it said arducopter.

The IP port is the same in the rosrun command as it is in the arducopter file so I am at a loss.

I really appreciate the help, I feel like I’m close now. Hopefully you have seen this error before.

Kind regards,

Chris

Hello again,
Try to edit /etc/default/arducopter so that it should contain only one udp endpoint. I believe it’s better to remove the TELEM2 option.

Unfortunately, I get the same error.

I just noticed I have been getting the same error ever since I tried using arducopter. Perhaps, MAVROS can only be activated with Ardupilot enabled? and not arducopter?

I will try using ardupilot instead of arducopter, as well as only one TELEM and let you know how it goes.

Any other ideas would be appreciated!

I look forward to hearing from you.

Kind regards,

Chris

This topic was automatically closed after 100 days. New replies are no longer allowed.