ROS_DOMAIN_ID with microROS
Hi Everyone,
New to ROS but not to embedded systems.
I installed ROS2 Foxy on Ubuntu 20.04 in a virtualbox VM with a bridged network adapter.
Completed this tutorial successfully: https://micro-ros.github.io/docs/tutorials/core/first_application_linux/
Tried the next tutorial but modified for freertos on ESP32: https://micro-ros.github.io/docs/tutorials/core/first_application_rtos/freertos/
Unable to complete succesfully until I realized that the ROSDOMAINID setting had an impact on the microROS setup.
I had originally set up my foxy with ROSDOMAINID = 7 and also foxy on a raspberry pi 4 with ROSDOMAINID = 7 and there was no trouble. However, the microROS on the esp32 would not report the /microROS/ping and /microROS/pong when ROSDOMAINID = 7. It reports correctly when ROSDOMAINID = 0.
Please see the attached pic for a graphical highlight of the situation.
I think this is a feature, but is documented or undocumented? :)
Looking forward to answers. Thanks.
Regards, F
PS: Just found out I don't have enough points to upload the image......you're gonna have to take my word for it. :) PS2: Here's the pic: https://imgur.com/a/CXn3ZUG
Asked by Francis Zaato on 2020-11-29 19:06:02 UTC
Answers
Found a solution! You need to compile the ROS Domain ID into the microROS node's options. Tested this on my end and it works. The example I found was here: https://github.com/micro-ROS/micro-ROS-Agent/issues/49#issuecomment-769208313
Asked by Bhavesh on 2021-10-01 14:07:59 UTC
Comments
I've given you sufficient karma to post images, but: it appears your screenshot shows terminal text.
There is no need to post screenshots of text, as it's text. Just copy-paste it into your question, select it and press the Preformatted Text button (the one with
101010
on it) to format it properly.Asked by gvdhoorn on 2020-11-30 03:03:07 UTC
Thanks for the karma and suggestion! :)
Asked by Francis Zaato on 2020-11-30 03:25:37 UTC
I am facing the same issue. Please do share if you have found a solution
Asked by Bhavesh on 2021-10-01 09:01:17 UTC
I suspect it has to do with the message:
No LSB module available
since you are using a Virtual machine. One thing that may work:sudo apt-get install lsb-core
Asked by osilva on 2021-10-01 14:00:39 UTC