Skip to content

Conversation

@denniszollo
Copy link
Contributor

@denniszollo denniszollo commented Jul 15, 2020

This change is to address bug report below:

The recent console does not receive Piksi data if I power down Piksi for a some time.
Windows PC
Piksi over serial port

Procedure:
Start Piksi
connect console
power off Piksi
wait a minute
power up Piksi -> there will be no any data on console

After painful investigation, the bug was traced down to this change in the framer behavior when encountering a zero length byte array from the driver and on Windows only. 2d2d1f4#diff-f7e7ceb9c48458bb44be66283049a27bL106

Basically, since there was a 1 second timeout on the pyserial driver if it didn't get data in one second it could cause the framer to start iterating nothing to the handler which caused the handler to yield none.

As a side note, I sort of think we might need to throw an exception here: https://github.com/swift-nav/libsbp/blob/master/python/sbp/client/handler.py#L72 , so that at least the handler communicates that it is no longer iterating correctly. But I'm not sure what to do there so I left as is.

     Timeout was causing console to disconnect during Piksi Multi restart.
     Timeout made serial driver not equivalent in behavior to file driver or network driver
    extends behavior from commit 9b15928 that addressed ESD-1111
@silverjam
Copy link
Contributor

@denniszollo merge?

@denniszollo denniszollo merged commit 1c179ed into master Jul 27, 2020
@denniszollo denniszollo deleted the dzollo/pyserial_timeout_remove branch July 27, 2020 18:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants