0
$\begingroup$

Rosanswers logo

Good day fellow members, I have the following problem:

I'm using two computers, a laptop and a raspberry pi2. Both are running Ubuntu 14.04 and ROS Indigo. My laptop is my master. I make sure to define the hostname and master uri to the IP in this computer. In the Rpi2 I'm defining the hostname with Rpi2's IP and the master uri with the laptop's IP. Therefore, I can run the roscore in the laptop, run hokuyo_node in the Rpi2 and rviz it in the laptop. My network is not a problem at this point that I can think of. I even use ssh for everything up to here.

In a single computer setup, I'm use HectorSLAM with my own launch file. Everything works fine. The problem comes when I'm in the network setup, and I start the hokuyo node in the Rpi2. I check the rostopic list and in both setups I've got the same topics. Everything is exactly the same but the physical connection of the LRF. I receive the following error message:

lookupTransform base_link to laser timed out. Could not transform laser scan into base_frame

Therefore, I cannot SLAM. Do you have any ideas or suggestions? My sole objective is to use the Rpi2 to launch the LRF remotely, while on the laptop perform the "heavy" processing. Please all the help is much appreciated.


Originally posted by Victor Gomez on ROS Answers with karma: 50 on 2015-07-22

Post score: 0

$\endgroup$

2 Answers 2

0
$\begingroup$

Rosanswers logo

First, verify that your topics (particularly /tf) are connected as they should be. The easiest way to do that is with rqt_graph.

If the topics are all connected properly, next check out your tf tree using tf view_frames. Make sure you have a TF from base_link to laser. If you aren't publishing that TF, you'll need to publish it with a tf static_transform_publisher or with a robot_state_publisher state_publisher and a URDF description of your robot.

Finally, if your ROS graph and TF tree are complete, then your problem is probably timing. If the system clock on the laptop isn't synced with the system clock on the RPi, then lookupTransform may fail. You can manually sync the clocks, but a better solution is to use chrony.

Further info here: http://wiki.ros.org/ROS/NetworkSetup


Originally posted by Ed Venator with karma: 1185 on 2015-07-22

This answer was ACCEPTED on the original site

Post score: 0


Original comments

Comment by Victor Gomez on 2015-07-24:
Thank you so much! I did as you said... at the end, the error was the simplest one. The clock sync. Thanks!

$\endgroup$
0
$\begingroup$

Rosanswers logo

Could you try and do this. On the master (you can add this to the ~/.bashrc file and then source the file) define - export ROS_IP= ${your_laptop_ip}** and on the RasPi define these two parameters - **export ROS_IP= ${Raspi_ip} and export ROS_MASTER_URI=http://${your_laptop_ip}:11311 . You can define this in the bashrc as well. Try and see if this solves the issue. If it still gives the error you may want to look at this previous post - http://answers.ros.org/question/38402/lookuptransform-base_link-to-laser0_frame-timed-out-could-not-transform-laser-scan-into-base_frame/


Originally posted by mpai227 with karma: 21 on 2015-07-22

This answer was NOT ACCEPTED on the original site

Post score: 1

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.