hi , i am having os1 64 channel.. i want to visualize the data using python .I m using os1 python library.In the same library link , there is code to save xyz points csv file, but in one csv file only 1024 data points are saving ..does this means that the lidar gave 1024 points for 360 view , or shall i need to capture more points to get all 360 degree lidara data points.?please solve my confusion.
Below is the code i m using to save lidar points.
`from os1 import OS1
import time
import numpy as np
from os1.utils import xyz_points
import os
count=0
def handler(raw_packet):
global count
print(count)
filename='points_'+str(count)+'.csv'
print(filename)
"""Takes each packet and log it to a file as xyz points"""
with open(filename, 'a') as f:
# count=count+1
# print(count)
x, y, z= xyz_points(raw_packet)
for coords in zip(x, y, z):
value=np.array(coords)
print(value)
f.write("{}\n".format(','.join(str(coords))))
count=count+1
os1 = OS1('192.168.1.67', '192.168.1.10', mode='1024x10') # OS1 sensor IP, destination IP, and resolution
Inform the sensor of the destination host and reintialize it
os1.start()
Start the loop which will handle and dispatch each packet to the handler
function for processing
os1.run_forever(handler)
`