You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
3.4 Lidar Data Format
By default UDP data is forwarded to Port 7502. Lidar data packets consist of 16 azimuth blocks and are always 12608 Bytes in length. The packet rate is dependent on the output mode. Words are 32 bits in length and little endian.
However, I got confused that when I tried to unpack the packets from pacp files saved by Ouster Studio, every packet was 12650 instead of 12608.
with PcapReader(pcap_path) as pcap_reader:
for pkt in pcap_reader:
unpack(bytes(pkt))
struct.error: unpack requires a buffer of 12608 bytes
The text was updated successfully, but these errors were encountered:
I'm not familiar with Ouster Studio, but It sounds like the data they are providing may be adding the IMU packet with the LIDAR packet. unpack only unpacks the LIDAR packet there is currently no support for the IMU packet (see related #8). Or they are wrapping the LIDAR packet in their own packet which adds some book keeping data for their software.
Might try just taking the last 12608 bytes out of the packet and seeing if that works.
Hi thanks for your respond,
Actually, at first I thought that the first 42 might be header and directly used [-12608:]. But I am not sure whether it is correct. I tried simply judging it by the unpacked frame ID, but it looked strange.
'''
with PcapReader(pcap_path) as pcap_reader:
for pkt in pcap_reader:
for i in range(42):
print(i,GetFrameID(bytes(pkt)[i:12608+i]))
3.4 Lidar Data Format
By default UDP data is forwarded to Port 7502. Lidar data packets consist of 16 azimuth blocks and are always 12608 Bytes in length. The packet rate is dependent on the output mode. Words are 32 bits in length and little endian.
However, I got confused that when I tried to unpack the packets from pacp files saved by Ouster Studio, every packet was 12650 instead of 12608.
with PcapReader(pcap_path) as pcap_reader:
for pkt in pcap_reader:
unpack(bytes(pkt))
struct.error: unpack requires a buffer of 12608 bytes
The text was updated successfully, but these errors were encountered: