Commit 079c50f9 authored by Jeremy Swerdlow's avatar Jeremy Swerdlow
Browse files

adds check for if scanning params fails, tries different range

parent 1cbf1fb1
......@@ -102,10 +102,13 @@ int main(int argc, char *argv[]) {
urg_deg2step(&urg, -1 * set_angle),
urg_deg2step(&urg, +1 * set_angle), 0);
*/
urg_set_scanning_parameter(&urg,
urg_deg2step(&urg, -135), // limiting to 45 degrees
urg_deg2step(&urg, 135), // on either side of bottom
1); // step, TODO: look at increasing this to reduce num samples
if(urg_set_scanning_parameter(&urg,
urg_deg2step(&urg, -45), // limiting to 45 degrees
urg_deg2step(&urg, 45), // on either side of bottom
1) != 0) { // step, TODO: look at increasing this to reduce num samples
perror("urg_set_scanning_parameter failed.");
return 1;
}
urg_start_measurement(&urg, URG_DISTANCE_INTENSITY, URG_SCAN_INFINITY, 0);
fprintf(stderr, "z,y,time stamp from lidar,intensity,length,radian,");
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment