ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

Can't subscribe message from SICK LMS151 at 25 Hz

asked 2018-07-18 19:18:20 -0500

yoshiros gravatar image

updated 2018-07-19 10:48:37 -0500

Hi all,

I am using the LMS1xx pkg to obtain laser measurements from a sick LMS-151 laser. The pkg works good at 50 Hz frequency. However, if I change it to 25 Hz by SOPAS ET, message never comes out. Also, "stop" lamp and "OK" lamp on the laser it self alternately flashes.

I found below from the source code.

if (cfg.scaningFrequency != 5000)
{  
    laser.disconnect();  
    ROS_WARN("Unable to get laser output range. Retrying.");  
    ros::Duration(1).sleep();   continue;
}

I thought this is the reason why it does not work good at 25 Hz. So, I changed 5000 to 2500. However, now the program stopped by some kind of memory Error.

Does any one have an idea to solve this problem?

Best

Yoshi

UPDATE 7/19/18
The source I am using is this.Thanks to tonybaltovski.
https://github.com/clearpathrobotics/...
The reason why I use source code instead of apt-get was to change range_max from 20.0 to 50.0 and to change angle resolution from 0.5 deg to 0.25 deg. This problem is for the latter.

The memory error which I wrote above disappeared once I restarted the computer. Sorry for the confusing information. It won't stop with error, just publishing no message forever.

I checked the sensor with SOPAS which is SICK software. There are some Monitor system and it looks no problem in both 50Hz and 25Hz. The lamp on the sensor was lighting up only "OK" continuously at that time. Also, "STOP" lamp never flashes while I read the message beyond ROS at 50Hz.

Thank you

edit retag flag offensive close merge delete

Comments

as there are some lms drivers around, maybe at least link to the code you used? Also, please post any error output, e.g. the "some kind of memory error"...

mgruhler gravatar image mgruhler  ( 2018-07-19 01:32:16 -0500 )edit

Just changing 5000 to 2500 to try and fix this is probably not a good idea. There is probably a good reason why the driver checks the frequency if 5000. Also the flashing LEDs you describe sound like a sensor error. I recommend using the SICK software to check the lidar is working at this speed.

PeteBlackerThe3rd gravatar image PeteBlackerThe3rd  ( 2018-07-19 06:43:12 -0500 )edit

Thank you for your comments. I updated information as above. Please let me know if you need more information. Thanks.

yoshiros gravatar image yoshiros  ( 2018-07-19 10:50:03 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2018-07-25 16:32:07 -0500

yoshiros gravatar image

I have found a solution!
Just clone and build the source below. Thanks to muhrix.
https://github.com/muhrix/lms1xx

Thank you

edit flag offensive delete link more

Question Tools

Stats

Asked: 2018-07-18 19:18:20 -0500

Seen: 281 times

Last updated: Jul 25 '18