ros-drivers / urg_node

ROS wrapper for the Hokuyo urg_c library.
Other
99 stars 148 forks source link

Add backwards-compatible support for the Hokuyo URG-04LX #35

Closed 2scholz closed 6 years ago

2scholz commented 6 years ago

urg_node does not support SCIP 1.1, only SCIP 2.0. However, the Hokuyo URG-04LX supports both SCIP 1.1 and SCIP 2.0 and usually defaults to SCIP 1.1. It needs to be switched to SCIP 2.0 at every startup.

For this purpose the function URGCWrapper::setToSCIP2 was added. A Hokuyo URG-04LX in SCIP 1.1 mode lead to an exception in URGCwrapper::initialize. Now, before throwing the exception an attempt to switch the sensor to SCIP 2.0 mode is made using URGCWrapper::setToSCIP2.

The hokuyo_node provides support for the URG-04LX in SCIP 1.1 mode in the same way.

I tested this patch successfully with the URG-04LX devices in our lab. It doesn't break support for other devices because it only triggers as a last resort.

Please merge and release this into kinetic.

@v4hn

Fixes #23

v4hn commented 6 years ago

+1 This enables us to migrate our robots to kinetic (finally!) without further problems. 👍

It would be great to see this change released soon!

tonybaltovski commented 6 years ago

Awesome, thanks!

tonybaltovski commented 6 years ago

@v4hn @2scholz released here https://github.com/ros/rosdistro/pull/16117.

v4hn commented 6 years ago

released here https://github.com/ros/rosdistro/pull/16117.

Wow! Thank you so much!