get_raw_data()
  • 1 Minute to read

get_raw_data()


Article summary

Get detection information from robot's LiDAR.

Reference

Arguments

None

Return

List with lenght len = 1 + round((angle_max-angle_min)/angle_increment).

PositionValue
0Distance at angle_min
1Distance at angle_min + angle_increment
2Distance at angle_min + 2*angle_increment
......
len-1Distance at angle_max

| angle_min | Minimum detection angle. |
| angle_max | Maximum detection angle. |

Examples

...
self.lidar = self.enable_controller('lidar')
...
raw_data = self.lidar.get_raw_data()
print(f'Lenght of raw_data: {len(raw_data)}')
print('Raw Data')
print(raw_data)
...

Output

Lenght of Raw Data: 666
Raw Data: 
[0.058476246893405914, 0.05941983312368393,  ...,  0.06039609760046005, 0.05941950902342796, 0.05847584828734398]


Go back to the Lidar Controller page.


Was this article helpful?