Open davidallen353 opened 3 years ago
I just looked at PR #10 and the separate NMEA/UBX parsing may make the timeout bug that I found difficult to replicate. I was seeing a bunch of NMEA messages come over the serial port when it missed the terminator, so it is possible that splitting NMEA and UBX would fix everything.
@edspark Is there anything that you need before considering this pull request?
This pull request includes 3 distinct changes.
spidev
module that functions natively on Mac or Windows. I added code to bypass the SPI functionality if not on a linux system. A useful warning when this bypass is triggered.core.Parse._read_until()
static method will continue to read until it finds a terminator. However this method bypasses the timeout, so if the read misses the terminator, then it will continue indefinitely. I used the timeout defined by thestream
input to act as a timeout for the read. If the timeout is reached before the terminator is found, a SerialException is raised.These changes were tested on a F9P and M8N. (Note the M8N doesn't support RAWX)