File tree Expand file tree Collapse file tree 2 files changed +3
-1
lines changed Expand file tree Collapse file tree 2 files changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -243,6 +243,8 @@ int rp2040_connect_onOTARequest(char const * ota_url)
243243
244244 /* Perform the reset to reboot to SFU. */
245245 mbed_watchdog_trigger_reset ();
246+ /* If watchdog is enabled we should not reach this point */
247+ NVIC_SystemReset ();
246248
247249 return static_cast <int >(OTAError::None);
248250}
Original file line number Diff line number Diff line change @@ -124,11 +124,11 @@ void mbed_watchdog_trigger_reset()
124124
125125 if (hal_watchdog_init (&cfg) == WATCHDOG_STATUS_OK) {
126126 is_watchdog_enabled = true ;
127+ while (1 ){}
127128 }
128129 else {
129130 DEBUG_WARNING (" %s: watchdog could not be reconfigured" , __FUNCTION__);
130131 }
131132
132- while (1 ){}
133133}
134134#endif /* ARDUINO_ARCH_MBED */
You can’t perform that action at this time.
0 commit comments