reset software
Posted: Sat Jun 05, 2021 4:01 am
is it possible to reset the board (or mcu) by code, instead of pressing the connected pin "reset" button?
Everything relating to using STM32 boards with the Arduino IDE and alternatives
https://www.stm32duino.com/
Code: Select all
HAL_NVIC_SystemReset();
Code: Select all
nvic_system_reset();
The fact that it "can" be done does not mean that it is a good idea. In-code resets are not identical to hardware resets; thus, you can leave registers and I/O pins in an unknown state. Some "core" implementations do have hardware calls which simulate the hardware reset-button line but you must remember such code is chip-specific.