diff options
| author | Jeff Epler <jepler@gmail.com> | 2021-02-25 11:34:03 -0600 |
|---|---|---|
| committer | Jeff Epler <jepler@gmail.com> | 2021-03-01 21:07:04 -0600 |
| commit | 4b63a8c9b4c2aca87da19bab45e7bebe3368d36c (patch) | |
| tree | 5aec820cc5fc3463662451c84c6af6ae786932d1 /ports | |
| parent | d0eab5c5615277d10eac2547c61924ff4754f0e5 (diff) | |
rp2pio: allow keyboard interrupt while waiting for tx fifo to empty (& stall)
Diffstat (limited to 'ports')
| -rw-r--r-- | ports/raspberrypi/common-hal/rp2pio/StateMachine.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/ports/raspberrypi/common-hal/rp2pio/StateMachine.c b/ports/raspberrypi/common-hal/rp2pio/StateMachine.c index 5625a1b29..54c5220e7 100644 --- a/ports/raspberrypi/common-hal/rp2pio/StateMachine.c +++ b/ports/raspberrypi/common-hal/rp2pio/StateMachine.c @@ -673,6 +673,9 @@ static bool _transfer(rp2pio_statemachine_obj_t *self, while (!pio_sm_is_tx_fifo_empty(self->pio, self->state_machine) || (self->wait_for_txstall && (self->pio->fdebug & stall_mask) == 0)) { RUN_BACKGROUND_TASKS; + if (mp_hal_is_interrupted()) { + break; + } } } return true; |
