diff options
| author | Dan Halbert <halbert@adafruit.com> | 2019-08-19 17:15:20 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2019-08-19 17:15:20 -0400 |
| commit | 0ddfbb0c20432458cc8020ab5ad7538e6813b60b (patch) | |
| tree | 2aac829585c9508d899e98ceea44e457be7d4f05 /shared-module | |
| parent | 6b54e6749e110674634143e38d3b6eb598b18ce0 (diff) | |
| parent | fc7ae2aa6f21046d58f59143752bbd5c7bc038db (diff) | |
Merge pull request #2055 from jepler/run-background-tasks
Implement and use RUN_BACKGROUND_TASKS in place of MICROPY_VM_HOOK_LOOP
Diffstat (limited to 'shared-module')
| -rw-r--r-- | shared-module/displayio/Display.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/shared-module/displayio/Display.c b/shared-module/displayio/Display.c index aa36ee982..c23c66b8b 100644 --- a/shared-module/displayio/Display.c +++ b/shared-module/displayio/Display.c @@ -85,9 +85,7 @@ void common_hal_displayio_display_construct(displayio_display_obj_t* self, uint32_t i = 0; while (!self->begin_transaction(self->bus)) { -#ifdef MICROPY_VM_HOOK_LOOP - MICROPY_VM_HOOK_LOOP ; -#endif + RUN_BACKGROUND_TASKS; } while (i < init_sequence_len) { uint8_t *cmd = init_sequence + i; @@ -242,7 +240,7 @@ int32_t common_hal_displayio_display_wait_for_frame(displayio_display_obj_t* sel uint64_t last_refresh = self->last_refresh; // Don't try to refresh if we got an exception. while (last_refresh == self->last_refresh && MP_STATE_VM(mp_pending_exception) == NULL) { - MICROPY_VM_HOOK_LOOP + RUN_BACKGROUND_TASKS; } return 0; } |
