Skip to content

New scan flags mismatch #25

Open
SamihQabaha opened this issue Mar 9, 2019 · 5 comments
Open

New scan flags mismatch #25

SamihQabaha opened this issue Mar 9, 2019 · 5 comments

Comments

@SamihQabaha
Copy link

who can help fixing the following error: "New scan flags mismatch"

the logs are

request:
b'\xa5P'
descriptor:
b'\xa5Z\x14\x00\x00\x00\x04'
response:
b'\x06\x05\x01\x01\x02\x00\x01\x08\x01\x00\x02\x00\x00\x00\x00\x00\x04\x00\x01\t'
{'model': 6, 'firmware': (1, 5), 'hardware': 1, 'serialnumber': '02000108010002000000000004000109'}
request:
b'\xa5R'
descriptor:
b'\xa5Z\x03\x00\x00\x00\x06'
response:
b'\x00\x00\x00'
('Good', 0)
request:
b'\xa5R'
descriptor:
b'\xa5Z\x03\x00\x00\x00\x06'
response:
b'\x00\x00\x00'
request:
b'\xa5 '
descriptor:
b'\xa5Z\x05\x00\x00@\x81'
response:
b'\xaaU\x01\x01\x03'
response:
b'B\x03B\xabT'
response:
b'\x00\x00\xaaU\x00'
Traceback (most recent call last):
File "C:\Python\test_radar.py", line 17, in
for i, scan in enumerate(lidar.iter_scans(max_buf_meas=500, min_len=5)):
File "C:\Python\lib\site-packages\rplidar.py", line 365, in iter_scans
for new_scan, quality, angle, distance in iterator:
File "C:\Python\lib\site-packages\rplidar.py", line 341, in iter_measurments
yield _process_scan(raw)
File "C:\Python\lib\site-packages\rplidar.py", line 77, in _process_scan
raise RPLidarException('New scan flags mismatch')
rplidar.RPLidarException: New scan flags mismatch

@hhelmric
Copy link

I'm having the same issue. I'm currently trying to rotate the rplidar with a servo to create a 3D point cloud and want to grab data from a scan for every angle of the servo's rotation. After I call next(scans) more than 106-108 times, I receive either this error or the "Check bit not equal to 1" error.

@elulaelia
Copy link

I experience the same issue. @hhelmric did you discover any viable solution?

@hhelmric
Copy link

hhelmric commented Dec 6, 2020

Not sure... this was a while ago and I honestly can't remember. We stopped experimenting with the RPLiDAR over a year ago

@m3pan
Copy link

m3pan commented Apr 1, 2022

Did anyone find a solution?

@pascalpradel
Copy link

I found out that the error occurs when there is a time.sleep() inside the loop using the scanner function. After I deleted time.sleep() everything worked fine.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants