File tree Expand file tree Collapse file tree
boards/adafruit_feather_rp2040_usb_host Expand file tree Collapse file tree Original file line number Diff line number Diff line change 22#define MICROPY_HW_MCU_NAME "rp2040"
33
44#define MICROPY_HW_NEOPIXEL (&pin_GPIO21)
5+ #define CIRCUITPY_STATUS_LED_POWER (&pin_GPIO20)
56
67#define DEFAULT_I2C_BUS_SCL (&pin_GPIO3)
78#define DEFAULT_I2C_BUS_SDA (&pin_GPIO2)
Original file line number Diff line number Diff line change @@ -247,14 +247,15 @@ uint32_t *port_heap_get_top(void) {
247247 return port_stack_get_top ();
248248}
249249
250+ uint32_t __uninitialized_ram (saved_word );
250251void port_set_saved_word (uint32_t value ) {
251- // Store in a watchdog scratch register instead of RAM. 4-7 are used by the
252- // sdk. 0 is used by alarm. 1-3 are free .
253- watchdog_hw -> scratch [ 1 ] = value ;
252+ // Store in RAM because the watchdog scratch registers don't survive
253+ // resetting by pulling the RUN pin low .
254+ saved_word = value ;
254255}
255256
256257uint32_t port_get_saved_word (void ) {
257- return watchdog_hw -> scratch [ 1 ] ;
258+ return saved_word ;
258259}
259260
260261static volatile bool ticks_enabled ;
You can’t perform that action at this time.
0 commit comments