Skip to content

Commit e64082d

Browse files
authored
Merge pull request #9008 from tannewt/debug_rgbmatrix_crash
Improve RGBMatrix reliability
2 parents d8bd26c + 12b4ac1 commit e64082d

File tree

8 files changed

+15
-4
lines changed

8 files changed

+15
-4
lines changed

.gitmodules

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,7 @@
143143
[submodule "ports/espressif/esp-idf"]
144144
path = ports/espressif/esp-idf
145145
url = https://github.com/adafruit/esp-idf.git
146-
branch = circuitpython-v5.1.2
146+
branch = circuitpython-v5.1.3
147147
[submodule "ports/espressif/esp-protocols"]
148148
path = ports/espressif/esp-protocols
149149
url = https://github.com/espressif/esp-protocols.git

ports/espressif/boards/espressif_esp32_eye/mpconfigboard.mk

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@ CIRCUITPY_ESP_PSRAM_SIZE = 8MB
1111
CIRCUITPY_ESP_PSRAM_MODE = qio
1212
CIRCUITPY_ESP_PSRAM_FREQ = 40m
1313

14+
CIRCUITPY_CANIO = 0
1415
CIRCUITPY_NEOPIXEL_WRITE = 0
1516
CIRCUITPY_PS2IO = 0
1617
CIRCUITPY_ROTARYIO = 0

ports/espressif/esp-idf

Submodule esp-idf updated 981 files

ports/espressif/esp-idf-config/sdkconfig-debug.defaults

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@ CONFIG_COMPILER_OPTIMIZATION_SIZE=y
1414
# ESP System Settings
1515
#
1616
CONFIG_ESP_SYSTEM_PANIC_PRINT_HALT=y
17+
CONFIG_ESP_PANIC_HANDLER_IRAM=y
1718
# end of ESP System Settings
1819

1920
# end of Component config

ports/espressif/mphalport.c

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,11 @@
4444
#error Unknown CONFIG_IDF_TARGET_xxx
4545
#endif
4646

47-
void mp_hal_delay_us(mp_uint_t delay) {
47+
#include "esp_attr.h"
48+
49+
// This is used by ProtoMatter's interrupt so make sure it is available when
50+
// flash isn't.
51+
void IRAM_ATTR mp_hal_delay_us(mp_uint_t delay) {
4852
ets_delay_us(delay);
4953
}
5054

ports/espressif/supervisor/port.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -270,7 +270,7 @@ safe_mode_t port_init(void) {
270270
#endif
271271

272272
#ifndef ENABLE_JTAG
273-
#define ENABLE_JTAG (defined(DEBUG) && DEBUG)
273+
#define ENABLE_JTAG (0)
274274
#endif
275275

276276
#if ENABLE_JTAG

ports/espressif/tools/update_sdkconfig.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,7 @@
2525
"CONFIG_HAL_DEFAULT_ASSERTION_LEVEL",
2626
"CONFIG_BOOTLOADER_LOG_LEVEL",
2727
"LOG_DEFAULT_LEVEL",
28+
"CONFIG_ESP_PANIC_HANDLER_IRAM",
2829
]
2930

3031
TARGET_SETTINGS = [

supervisor/shared/usb/usb.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -171,6 +171,10 @@ void usb_background(void) {
171171
#if CIRCUITPY_USB_HOST
172172
tuh_task();
173173
#endif
174+
#elif CFG_TUSB_OS == OPT_OS_FREERTOS
175+
// Yield to FreeRTOS in case TinyUSB runs in a separate task. Don't use
176+
// port_yield() because it has a longer delay.
177+
vTaskDelay(0);
174178
#endif
175179
// No need to flush if there's no REPL.
176180
#if CIRCUITPY_USB_CDC

0 commit comments

Comments
 (0)