Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

stage_ros clips ranger intensity values to a maximum value of 256 #31

Closed
sloretz opened this issue Dec 17, 2015 · 1 comment
Closed

Comments

@sloretz
Copy link
Contributor

sloretz commented Dec 17, 2015

The maximum intensity in a sensor_msgs::LaserScan coming from stage_ros is clipped to 256. The behavior comes from line 460 in stage_ros.cpp
msg.intensities[i] = (uint8_t)sensor.intensities[i];
By casting to a uint8_t it clips the maximum return of a ranger in stage to 256

Intensities can require more than 8 bits. Stage stores intensity values as doubles internally. On the output side the sensor_msgs::LaserScan message stores intensities as 32 bit floats. In reality the Hokuyo UTM-30LX returns 18 bit intensity values.

sloretz added a commit to sloretz/stage_ros that referenced this issue Dec 30, 2015
sloretz added a commit to sloretz/stage_ros that referenced this issue Dec 30, 2015
@gerkey
Copy link
Contributor

gerkey commented Jan 4, 2016

Fixed in #33

@gerkey gerkey closed this as completed Jan 4, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants