[Core] Add Reboot keycode to core (#15990)
This commit is contained in:
parent
425c54cf8c
commit
787a68948f
25 changed files with 124 additions and 5 deletions
|
@ -17,6 +17,7 @@
|
|||
#include "bootloader.h"
|
||||
|
||||
#include <avr/interrupt.h>
|
||||
#include <avr/wdt.h>
|
||||
#include <util/delay.h>
|
||||
|
||||
__attribute__((weak)) void bootloader_jump(void) {
|
||||
|
@ -126,3 +127,12 @@ __attribute__((weak)) void bootloader_jump(void) {
|
|||
asm volatile("jmp 0x1FC00");
|
||||
#endif
|
||||
}
|
||||
|
||||
__attribute__((weak)) void mcu_reset(void) {
|
||||
// setup watchdog timeout
|
||||
wdt_enable(WDTO_60MS);
|
||||
|
||||
// wait for watchdog timer to trigger
|
||||
while (1) {
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue