-
Notifications
You must be signed in to change notification settings - Fork 131
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
connection: error handling #270
connection: error handling #270
Conversation
db8d79e
to
031fa68
Compare
Mmh I'm not able to flash anymore, I'm getting a |
The `size` field for `Command::FlashDeflateBegin` is the uncompressed size of the segment. It was rounded up to the memory block size, and the stub was expecting more data when the flash ended, even though the inflator was returning successfully.
a0711aa
to
2a987d7
Compare
The |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thank you for this! Overall it looks good to me.
Sorry but there's just one small typo I'd like to see fixed please 😁
Co-authored-by: Jesse Braham <jessebraham@users.noreply.github.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for fixing that!
Since we just swapped the two fields, we need to check
error
instead ofstatus
now.I've been mainly working with the stub since I'm erasing the OTA partition when flashing.
After taking a better look at the error handling there I'm not really sure where the values from
RomErrorKind
are coming from, since they are neither in the C stub code nor thebootloader
andbootloader_support
components.I added the generic errors from the stub. There is other values used in other places in there but they are not under an enum and it would take quite a bit of time to reference all of them for now.
If anyone has any clue where those are coming from, otherwise I'd say that we can remove them at some point.