Open ggjj11 opened 4 years ago
Do you try this SDK https://github.com/YDLIDAR/YDLidar-SDK
Thank you very much for your hint to the official ydlidar sdk! I did not know their project. I tried to build it, but the visual studio build failed on windows and I was not able to create a python package I could include with their repository (I submitted issues to their repo now).
If you have an idea what would need to be fixed to get the X2 working with your code, I would be happy to try it out. Otherwise, feel free to close this issue.
Hi,
thank you for sharing your code! It looks really good! I am trying to get data from my YDLidarX2 via python and found your package. Could you enable getting data from there too. I tried adapting the baudrate according to the data sheet, but I was not able to retrieve data. Running the example script, I get:
Could you help me getting the X2 to work with your code?
This is what the visual studio debugger tells me:
I am not sure whether the lidar_ans_header[2] should be as big as 9101 ? Maybe that is part of the problem.
Visual studio throws here with the exception "unpack requires a buffer of 3 bytes" (in the line device_health = unpack("<BH", temp))