Connection between desktop computer and raspberry
See original GitHub issueHello everyone. I’m using fkie multimaster for 2 machines, a desktop computer and a raspberry.
To test whether the communication used the basis of the turtlesim example. Basically I started a turtlesim node in the rasp. So, when running rostopic list
on the desktop computer I get the following result:
/master_discovery/changes
/master_discovery/linkstats
/rosout
/rosout_agg
/turtle1/cmd_vel
/turtle1/color_sensor
/turtle1/pose
This seems to suggest that communication is working. The problem is when I try to control the turtle’s movements on the desktop computer. Using something like:
rosrun turtlesim turtle_teleop_key
or
rostopic pub /turtle1/cmd_vel geometry_msgs/Twist -r 1 -- '[2.0, 0.0, 0.0]' '[0.0, 0.0, 1.8]'
When trying to execute these commands to control the turtlesim node created in rasp nothing happens: / I hoped I could control the turtle. Anyway, my question is: is what I am trying to do possible? Or is it off limits to fkie?
Issue Analytics
- State:
- Created 3 years ago
- Comments:10 (5 by maintainers)
Top GitHub Comments
This are good new 😃
I still don’t know why it didn’t work as pc1 and pc2, there must be some configuration that is making my roscore always run like otavio-desktop and otavio-To-be-filled-by-O-E-M. This is default behavior of ROS. You can overwrite it by setting ROS_HOSTNAME e.g
export ROS_HOSTNAME=pc1
I also did not realized that you used different names for the same host. But all’s well that ends well!Multiamster FKIE does not need the hostname in ROS_MASTER_URI and in most cases it works also with
localhost
. But if you have some troubles you should set it to the name of localhost, see official explanation:Great care should be taken when using localhost, as that can lead to unintended behaviors with remotely launched nodes.
Since ROS uses the hostname to communicate, you need to enter all hosts with ROS into your
/etc/host
.You can also try to set
ROS_IP
, but it has also limitation since it binds to specified device. If this device is WiFi and you lost the connection the local nodes can’t communicate, too.