diff options
author | tmk <nobody@nowhere> | 2011-09-22 16:56:36 +0900 |
---|---|---|
committer | tmk <nobody@nowhere> | 2011-09-22 16:56:36 +0900 |
commit | e65575d4a5f03a90adfa9850cb71a5d0448098cd (patch) | |
tree | ea5cea3c3985fb3056233f6b08fa76bf409c1f57 /pjrc | |
parent | e67c988824f5ec0c965beb412f8ee5953dfd3c8c (diff) | |
download | firmware-e65575d4a5f03a90adfa9850cb71a5d0448098cd.tar.gz firmware-e65575d4a5f03a90adfa9850cb71a5d0448098cd.tar.bz2 firmware-e65575d4a5f03a90adfa9850cb71a5d0448098cd.zip |
Refactored bootloader jumping. Added USBaspLoader support.
Diffstat (limited to 'pjrc')
-rw-r--r-- | pjrc/bootloader_teensy.c (renamed from pjrc/jump_bootloader.c) | 3 | ||||
-rw-r--r-- | pjrc/jump_bootloader.h | 7 | ||||
-rw-r--r-- | pjrc/main.c | 4 |
3 files changed, 4 insertions, 10 deletions
diff --git a/pjrc/jump_bootloader.c b/pjrc/bootloader_teensy.c index 27066a1eb..9d34852f1 100644 --- a/pjrc/jump_bootloader.c +++ b/pjrc/bootloader_teensy.c @@ -2,8 +2,9 @@ #include <avr/io.h> #include <avr/interrupt.h> #include <util/delay.h> +#include "bootloader.h" -void jump_bootloader(void) { +void bootloader_jump(void) { cli(); // disable watchdog, if enabled // disable all peripherals diff --git a/pjrc/jump_bootloader.h b/pjrc/jump_bootloader.h deleted file mode 100644 index e858e3e16..000000000 --- a/pjrc/jump_bootloader.h +++ /dev/null @@ -1,7 +0,0 @@ -/* See http://www.pjrc.com/teensy/jump_to_bootloader.html */ -#ifndef JUMP_BOOTLOADER_H -#define JUMP_BOOTLOADER_H 1 - -void jump_bootloader(void); - -#endif diff --git a/pjrc/main.c b/pjrc/main.c index f84925d7f..15f14920b 100644 --- a/pjrc/main.c +++ b/pjrc/main.c @@ -31,7 +31,7 @@ #include "print.h" #include "debug.h" #include "util.h" -#include "jump_bootloader.h" +#include "bootloader.h" #ifdef PS2_MOUSE_ENABLE # include "ps2_mouse.h" #endif @@ -86,7 +86,7 @@ int main(void) if (matrix_key_count() >= 4) { print("jump to bootloader...\n"); _delay_ms(1000); - jump_bootloader(); // not return + bootloader_jump(); // not return } |