Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
DFU mode: improve programming robustness.
dfu.get_status() might return usb.core.USBError with errno == EPIPE, when called in quick succession. This is the case when called from dfu.block_on_state(). The next call usually works. This change tries to catch this specific error and just re-tries in case it happens. Without this change, the error (and programming abort) might get undetected, as click catches IOerror/EPIPE silently. This has significant potential to brick a device.
- Loading branch information