File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change 1111#include <stdarg.h>
1212#include <stdio.h>
1313
14+ #include "hardware/structs/scb.h"
15+
1416#include "pico/bootrom.h"
1517#include "pico/stdio.h"
1618#include "pico/stdlib.h"
@@ -759,16 +761,14 @@ static void vi_cmd(void) {
759761 vi (argc - 1 , argv + 1 );
760762}
761763
762- #define AIRCR (*((volatile uint32_t*)(PPB_BASE + 0x0ED0C)))
763-
764764static void reboot_cmd (void ) {
765765 // release any resources we were using
766766 if (mounted ) {
767767 savehist ();
768768 fs_unmount ();
769769 }
770770 sleep_ms (500 );
771- AIRCR = 0x5FA0004 ;
771+ scb_hw -> aircr = 0x5FA0004 ;
772772 for (;;)
773773 ;
774774}
@@ -951,7 +951,7 @@ static void Fault_Handler(void) {
951951 ;
952952#endif
953953 sleep_ms (3000 );
954- AIRCR = 0x5FA0004 ;
954+ scb_hw -> aircr = 0x5FA0004 ;
955955 for (;;)
956956 ;
957957}
You can’t perform that action at this time.
0 commit comments