displayio: Pause rgbmatrix during soft-reset
We can't handle rgbmatrix's interrupts from here until the display is reinitialized, so set the display as paused. With this change, I can survive multiple cycles with wifi+rgbmatrix on an esp32s2. Before, it usually failed.
This commit is contained in:
parent
4de8fa09ab
commit
0d7f257eae
@ -185,6 +185,8 @@ void reset_displays(void) {
|
|||||||
rgbmatrix_rgbmatrix_obj_t *pm = &displays[i].rgbmatrix;
|
rgbmatrix_rgbmatrix_obj_t *pm = &displays[i].rgbmatrix;
|
||||||
if (!any_display_uses_this_framebuffer(&pm->base)) {
|
if (!any_display_uses_this_framebuffer(&pm->base)) {
|
||||||
common_hal_rgbmatrix_rgbmatrix_deinit(pm);
|
common_hal_rgbmatrix_rgbmatrix_deinit(pm);
|
||||||
|
} else {
|
||||||
|
common_hal_rgbmatrix_rgbmatrix_set_paused(pm, true);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
#if CIRCUITPY_SHARPDISPLAY
|
#if CIRCUITPY_SHARPDISPLAY
|
||||||
|
Loading…
x
Reference in New Issue
Block a user