Last summer I wrote code to talk to the YDLIDAR X4 Lidar – 360-degree Laser Range Scanner (10m). It was quite difficult to parse the data and get the correct readout of the point cloud. The X4_Lidar_Development_Manual.pdf had all the information but it was quite obscure.
I also added tracking (red cross in the screenshot) to figure out coordinates of a person moving around in a room. Nothing fancy but worked ok.
The attached code is for Unity3d and written in C#.