|
|
|
@ -31,6 +31,7 @@
|
|
|
|
|
#include "oled.h"
|
|
|
|
|
#include "rng.h"
|
|
|
|
|
#include "setup.h"
|
|
|
|
|
#include "supervise.h"
|
|
|
|
|
#include "timer.h"
|
|
|
|
|
#include "util.h"
|
|
|
|
|
|
|
|
|
@ -86,6 +87,7 @@ static void __attribute__((noinline, section(".data"))) erase_firmware(void) {
|
|
|
|
|
|
|
|
|
|
void __attribute__((noinline, noreturn, section(".data"))) reboot_device(void) {
|
|
|
|
|
__disable_irq();
|
|
|
|
|
*STAY_IN_BOOTLOADER_FLAG_ADDR = STAY_IN_BOOTLOADER_FLAG;
|
|
|
|
|
SCB_AIRCR = SCB_AIRCR_VECTKEY | SCB_AIRCR_SYSRESETREQ;
|
|
|
|
|
while (1)
|
|
|
|
|
;
|
|
|
|
|