You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Aug 11, 2023. It is now read-only.
After some strange communication problems, we found out that in the following line, the default IP that gets reported to the ROS core is always 127.0.0.1, instead of the hostname as it is normal in the ros world. We tracked the error to the following line:
Hi @amaldo,
Thanks for your comments. May I ask how you are executing the nodes? The IP address used by the node to advertise itself to the ROS master is set in the NodeConfiguration object, which is used when the node is executed. It's not related with the code of the node itself.
If I understand correctly, what you are saying is that when you use the RosRun class from the command line, the node is executed by default using the loopback address and not the hostname. Is that the case?
Sign up for freeto subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Hi!
We have some code in our laboratory called json_prolog that uses rosjava by extending the AbstractNodeMain class. The class is here:
https://github.com/knowrob/knowrob/blob/master/json_prolog/json_prolog/src/main/java/org/knowrob/json_prolog/JSONPrologNode.java
After some strange communication problems, we found out that in the following line, the default IP that gets reported to the ROS core is always 127.0.0.1, instead of the hostname as it is normal in the ros world. We tracked the error to the following line:
rosjava_core/rosjava/src/main/java/org/ros/internal/loader/CommandLineLoader.java
Line 171 in e92b7b7
String host = InetAddressFactory.newLoopback().getHostAddress();
That sets 127.0.0.1 as the default, which can get later overwritten by setting the ROS_IP environmental variable.
I suspect that it would be better to change that line to the following to follow the normal roscpp behaviour:
String host = InetAddressFactory.newNonLoopback().getHostName();
Greetings!
The text was updated successfully, but these errors were encountered: