Hi there! Thanks for having me at the Open Lab last night - super fun and helpful.
I’m building a little rover to deliver notes - it will have a thermal receipt printer mounted on it and the idea is to click on a map to send the rover over to deliver a note.
The rover will not have lidar or camera on it - I’m going low budget and using a VL53L0X Time of Flight sensor (possibly two) [1]. I’d like to use the time of flight sensor to produce a point cloud that will feed into the SLAM Cartographer Service. (I recognize that I might be headed into danger and the ToF sensor will probably not produce nearly enough data for SLAM. 😂🤷🏼)
The ToF sensor has a Python client so I’m implementing the camera component using the Python SDK. I originally implemented it as a sensor component [2] but am trying to implement it as a Camera instead.
I’m stuck on how to implement get_point_cloud. I want to make the point cloud by hand, which will only be a single point. It looks like the bytes are encoded as a PCD. Is there a way to manually build the point cloud and encode it as a PCD?
async def get_point_cloud(self, *, timeout: Optional[float] = None, **kwargs) -> Tuple[bytes, str]:
// Return a point cloud in the form of [[range, 0, 0]] - the single sensor reading from the ToF sensor.
[1] https://learn.adafruit.com/adafruit-vl53l0x-micro-lidar-distance-sensor-breakout/overview
[2] https://github.com/ethanlook/palbot/blob/main/vl53l0x_sensor.py