diff options
author | Jack Humbert <jack.humb@gmail.com> | 2017-11-27 23:08:21 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-11-27 23:08:21 -0500 |
commit | 9fdc27626097ae03b767a09427efc90475d90955 (patch) | |
tree | a555c38f1b714af6e2c2c96187552757d08224b9 /keyboards | |
parent | 9113f3387a670373919fe62899b0ab27e9d89eba (diff) |
Updates bootloader settings, adds file size check (#2029)
* pull fuse settings for bootloader jump
* fix 32a chips
* make automatic bootloader selection optional
* quantify bootloaders
* fixs #164, speeds up dfu reset
* fix for chips w/o usb
* missing an n
* fix bootloader sizes, use words for addresses
* fix bmini, pearl, and [[ issue, make things quiet
* ignore avr errors on arm for now
* update settings for the light
* document bootloader stuff
* add bootloader title
Diffstat (limited to 'keyboards')
64 files changed, 225 insertions, 432 deletions
diff --git a/keyboards/atreus/rules.mk b/keyboards/atreus/rules.mk index 0a254d0e79..2c8418beb7 100644 --- a/keyboards/atreus/rules.mk +++ b/keyboards/atreus/rules.mk @@ -5,7 +5,6 @@ ifdef TEENSY2 ATREUS_UPLOAD_COMMAND = teensy_loader_cli -w -mmcu=$(MCU) $(TARGET).hex else OPT_DEFS += -DATREUS_ASTAR - OPT_DEFS += -DCATERINA_BOOTLOADER ATREUS_UPLOAD_COMMAND = while [ ! -r $(USB) ]; do sleep 1; done; \ avrdude -p $(MCU) -c avr109 -U flash:w:$(TARGET).hex -P $(USB) endif @@ -27,7 +26,6 @@ MCU = atmega32u4 # software delays. F_CPU = 16000000 - # # LUFA specific # @@ -47,19 +45,20 @@ ARCH = AVR8 # CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU. F_USB = $(F_CPU) +# Bootloader +# This definition is optional, and if your keyboard supports multiple bootloaders of +# different sizes, comment this out, and the correct address will be loaded +# automatically (+60). See bootloader.mk for all options. +ifdef TEENSY2 + BOOTLOADER = halfkay +else + BOOTLOADER = caterina +endif + # Interrupt driven control endpoint task(+60) OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT -# Boot Section Size in *bytes* -# Teensy halfKay 512 -# Teensy++ halfKay 1024 -# Atmel DFU loader 4096 -# LUFA bootloader 4096 -# USBaspLoader 2048 -OPT_DEFS += -DBOOTLOADER_SIZE=4096 - - # Build Options # comment out to disable the options. # diff --git a/keyboards/atreus62/config.h b/keyboards/atreus62/config.h index 90a4aa05a6..8d9248947c 100644 --- a/keyboards/atreus62/config.h +++ b/keyboards/atreus62/config.h @@ -38,8 +38,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. #define MATRIX_ROW_PINS { D2, D3, D1, D0, D4 } #define MATRIX_COL_PINS { F4, F5, F6, F7, B1, B3, B2, B6, B5, B4, E6, D7, C6 } -#define CATERINA_BOOTLOADER - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION ROW2COL diff --git a/keyboards/atreus62/rules.mk b/keyboards/atreus62/rules.mk index ca399e9c56..66f6660c6e 100644 --- a/keyboards/atreus62/rules.mk +++ b/keyboards/atreus62/rules.mk @@ -35,18 +35,15 @@ ARCH = AVR8 # CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU. F_USB = $(F_CPU) +# Bootloader +# This definition is optional, and if your keyboard supports multiple bootloaders of +# different sizes, comment this out, and the correct address will be loaded +# automatically (+60). See bootloader.mk for all options. +BOOTLOADER = caterina + # Interrupt driven control endpoint task(+60) OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT - -# Boot Section Size in *bytes* -# Teensy halfKay 512 -# Teensy++ halfKay 1024 -# Atmel DFU loader 4096 -# LUFA bootloader 4096 -# USBaspLoader 2048 -OPT_DEFS += -DBOOTLOADER_SIZE=4096 - # Build Options # change to "no" to disable the options, or define them in the Makefile in # the appropriate keymap folder that will get included automatically diff --git a/keyboards/bfake/config.h b/keyboards/bfake/config.h index c52d9175b8..c0e0face5a 100644 --- a/keyboards/bfake/config.h +++ b/keyboards/bfake/config.h @@ -41,7 +41,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. #define RGBLIGHT_ANIMATIONS #define NO_UART 1 -#define BOOTLOADHID_BOOTLOADER 1 /* key combination for command */ #define IS_COMMAND() (keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT))) diff --git a/keyboards/bfake/rules.mk b/keyboards/bfake/rules.mk index d089858273..9165de4248 100644 --- a/keyboards/bfake/rules.mk +++ b/keyboards/bfake/rules.mk @@ -24,6 +24,12 @@ NO_SUSPEND_POWER_DOWN = yes # processor frequency F_CPU = 12000000 +# Bootloader +# This definition is optional, and if your keyboard supports multiple bootloaders of +# different sizes, comment this out, and the correct address will be loaded +# automatically (+60). See bootloader.mk for all options. +BOOTLOADER = bootloadHID + # build options BOOTMAGIC_ENABLE = yes MOUSEKEY_ENABLE = yes @@ -35,7 +41,6 @@ RGBLIGHT_ENABLE = yes RGBLIGHT_CUSTOM_DRIVER = yes OPT_DEFS = -DDEBUG_LEVEL=0 -OPT_DEFS += -DBOOTLOADER_SIZE=2048 # custom matrix setup CUSTOM_MATRIX = yes diff --git a/keyboards/bmini/config.h b/keyboards/bmini/config.h index 90b315b7c5..b7a25e050e 100644 --- a/keyboards/bmini/config.h +++ b/keyboards/bmini/config.h @@ -34,7 +34,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. #define RGBLIGHT_ANIMATIONS #define NO_UART 1 -#define BOOTLOADHID_BOOTLOADER 1 /* key combination for command */ #define IS_COMMAND() (keyboard_report->mods == (MOD_BIT(KC_LSHIFT) | MOD_BIT(KC_RSHIFT))) diff --git a/keyboards/bmini/rules.mk b/keyboards/bmini/rules.mk index 41a87973d4..73c361e2a8 100644 --- a/keyboards/bmini/rules.mk +++ b/keyboards/bmini/rules.mk @@ -24,6 +24,12 @@ NO_SUSPEND_POWER_DOWN = yes # processor frequency F_CPU = 12000000 +# Bootloader +# This definition is optional, and if your keyboard supports multiple bootloaders of +# different sizes, comment this out, and the correct address will be loaded +# automatically (+60). See bootloader.mk for all options. +BOOTLOADER = bootloadHID + # build options BOOTMAGIC_ENABLE = yes MOUSEKEY_ENABLE = yes @@ -35,7 +41,6 @@ RGBLIGHT_ENABLE = yes RGBLIGHT_CUSTOM_DRIVER = yes OPT_DEFS = -DDEBUG_LEVEL=0 -OPT_DEFS += -DBOOTLOADER_SIZE=2048 # custom matrix setup CUSTOM_MATRIX = yes diff --git a/keyboards/chimera_ortho/rules.mk b/keyboards/chimera_ortho/rules.mk index 098bf28fa5..4f95949f9f 100644 --- a/keyboards/chimera_ortho/rules.mk +++ b/keyboards/chimera_ortho/rules.mk @@ -1,6 +1,5 @@ OPT_DEFS += -DCHIMERA_ORTHO_PROMICRO -OPT_DEFS += -DCATERINA_BOOTLOADER CHIMERA_ORTHO_UPLOAD_COMMAND = while [ ! -r $(USB) ]; do sleep 1; done; \ avrdude -p $(MCU) -c avr109 -U flash:w:$(TARGET).hex -P $(USB) @@ -45,19 +44,15 @@ ARCH = AVR8 # CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU. F_USB = $(F_CPU) +# Bootloader +# This definition is optional, and if your keyboard supports multiple bootloaders of +# different sizes, comment this out, and the correct address will be loaded +# automatically (+60). See bootloader.mk for all options. +BOOTLOADER = caterina + # Interrupt driven control endpoint task(+60) OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT - -# Boot Section Size in *bytes* -# Teensy halfKay 512 -# Teensy++ halfKay 1024 -# Atmel DFU loader 4096 -# LUFA bootloader 4096 -# USBaspLoader 2048 -OPT_DEFS += -DBOOTLOADER_SIZE=4096 - - # Build Options # comment out to disable the options. # diff --git a/keyboards/converter/usb_usb/ble/rules.mk b/keyboards/converter/usb_usb/ble/rules.mk index c951780e20..16090962d9 100644 --- a/keyboards/converter/usb_usb/ble/rules.mk +++ b/keyboards/converter/usb_usb/ble/rules.mk @@ -1,4 +1,3 @@ BLUETOOTH = AdafruitBLE ADAFRUIT_BLE_ENABLE = yes -OPT_DEFS += -DCATERINA_BOOTLOADER F_CPU = 8000000 diff --git a/keyboards/converter/usb_usb/rules.mk b/keyboards/converter/usb_usb/rules.mk index b0e07c7649..7a8f24bb49 100644 --- a/keyboards/converter/usb_usb/rules.mk +++ b/keyboards/converter/usb_usb/rules.mk @@ -43,19 +43,15 @@ ARCH = AVR8 # CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU. F_USB = $(F_CPU) +# Bootloader +# This definition is optional, and if your keyboard supports multiple bootloaders of +# different sizes, comment this out, and the correct address will be loaded +# automatically (+60). See bootloader.mk for all options. +BOOTLOADER = caterina + # Interrupt driven control endpoint task OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT - -# Boot Section Size in *bytes* -# Teensy halfKay 512 -# Teensy++ halfKay 1024 -# Atmel DFU loader 4096 -# LUFA bootloader 4096 -# USBaspLoader 2048 -OPT_DEFS += -DBOOTLOADER_SIZE=4096 - - # Build Options # comment out to disable the options. # diff --git a/keyboards/deltasplit75/rules.mk b/keyboards/deltasplit75/rules.mk index e345d61f56..2a13dbdfc6 100644 --- a/keyboards/deltasplit75/rules.mk +++ b/keyboards/deltasplit75/rules.mk @@ -39,18 +39,15 @@ ARCH = AVR8 # CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU. F_USB = $(F_CPU) +# Bootloader +# This definition is optional, and if your keyboard supports multiple bootloaders of +# different sizes, comment this out, and the correct address will be loaded +# automatically (+60). See bootloader.mk for all options. +BOOTLOADER = caterina + # Interrupt driven control endpoint task(+60) OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT - -# Boot Section Size in *bytes* -# Teensy halfKay 512 -# Teensy++ halfKay 1024 -# Atmel DFU loader 4096 -# LUFA bootloader 4096 -# USBaspLoader 2048 -OPT_DEFS += -DBOOTLOADER_SIZE=4096 - # Build Options # change to "no" to disable the options, or define them in the Makefile in # the appropriate keymap folder that will get included automatically diff --git a/keyboards/deltasplit75/v2/config.h b/keyboards/deltasplit75/v2/config.h index b677d09aa9..319a149fbc 100644 --- a/keyboards/deltasplit75/v2/config.h +++ b/keyboards/deltasplit75/v2/config.h @@ -37,8 +37,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. #define MATRIX_ROW_PINS { F4, F5, F6, F7, B1, B3, B2 } #define MATRIX_COL_PINS { B6, B5, B4, E6, D7, C6, D4, D1} -#define CATERINA_BOOTLOADER - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/dichotemy/rules.mk b/keyboards/dichotemy/rules.mk index c8a316f843..4e9db86875 100644 --- a/keyboards/dichotemy/rules.mk +++ b/keyboards/dichotemy/rules.mk @@ -1,6 +1,5 @@ OPT_DEFS += -DDICHOTEMY_PROMICRO -OPT_DEFS += -DCATERINA_BOOTLOADER DICHOTEMY_UPLOAD_COMMAND = while [ ! -r $(USB) ]; do sleep 1; done; \ avrdude -p $(MCU) -c avr109 -U flash:w:$(TARGET).hex -P $(USB) @@ -25,8 +24,6 @@ MCU = atmega32u4 # software delays. F_CPU = 16000000 - -# # LUFA specific # # Target architecture (see library "Board Types" documentation). @@ -45,19 +42,15 @@ ARCH = AVR8 # CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU. F_USB = $(F_CPU) +# Bootloader +# This definition is optional, and if your keyboard supports multiple bootloaders of +# different sizes, comment this out, and the correct address will be loaded +# automatically (+60). See bootloader.mk for all options. +BOOTLOADER = caterina + # Interrupt driven control endpoint task(+60) OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT - -# Boot Section Size in *bytes* -# Teensy halfKay 512 -# Teensy++ halfKay 1024 -# Atmel DFU loader 4096 -# LUFA bootloader 4096 -# USBaspLoader 2048 -OPT_DEFS += -DBOOTLOADER_SIZE=4096 - - # Build Options # comment out to disable the options. # diff --git a/keyboards/eco/config.h b/keyboards/eco/config.h index 99b057496f..f6b78631ea 100644 --- a/keyboards/eco/config.h +++ b/keyboards/eco/config.h @@ -31,8 +31,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. #define MATRIX_ROWS 4 #define MATRIX_COLS 14 -#define CATERINA_BOOTLOADER - /* COL2ROW or ROW2COL */ #define DIODE_DIRECTION COL2ROW diff --git a/keyboards/eco/rules.mk b/keyboards/eco/rules.mk index 6f4b4fefc4..35ee906b1e 100644 --- a/keyboards/eco/rules.mk +++ b/keyboards/eco/rules.mk @@ -34,18 +34,15 @@ ARCH = AVR8 # CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU. F_USB = $(F_CPU) +# Bootloader +# This definition is optional, and if your keyboard supports multiple bootloaders of +# different sizes, comment this out, and the correct address will be loaded +# automatically (+60). See bootloader.mk for all options. +BOOTLOADER = caterina + # Interrupt driven control endpoint task(+60) OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT - -# Boot Section Size in *bytes* -# Teensy halfKay 512 -# Teensy++ halfKay 1024 -# Atmel DFU loader 4096 -# LUFA bootloader 4096 -# USBaspLoader 2048 -OPT_DEFS += -DBOOTLOADER_SIZE=4096 - # Build Options # change to "no" to disable the options, or define them in the Makefile in # the appropriate keymap folder that will get included automatically diff --git a/keyboards/ergodox_ez/rules.mk b/keyboards/ergodox_ez/rules.mk index 3d6b18fea9..4d2c461085 100644 --- a/keyboards/ergodox_ez/rules.mk +++ b/keyboards/ergodox_ez/rules.mk @@ -54,18 +54,15 @@ ARCH = AVR8 # CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU. F_USB = $(F_CPU) +# Bootloader +# This definition is optional, and if your keyboard supports multiple bootloaders of +# different sizes, comment this out, and the correct address will be loaded +# automatically (+60). See bootloader.mk for all options. +BOOTLOADER = halfkay + # Interrupt driven control endpoint task(+60) OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT - -# Boot Section Size in *bytes* -# Teensy halfKay 512 -# Teensy++ halfKay 1024 -# Atmel DFU loader 4096 -# LUFA bootloader 4096 -# USBaspLoader 2048 -OPT_DEFS += -DBOOTLOADER_SIZE=512 - # If you have Left LEDs (see # https://geekhack.org/index.php?topic=22780.msg873819#msg873819 for # details), include the following define: diff --git a/keyboards/gherkin/keymaps/mjt/config.h b/keyboards/gherkin/keymaps/mjt/config.h index 9c9f038389..bb59ec213d 100644 --- a/keyboards/gherkin/keymaps/mjt/config.h +++ b/keyboards/gherkin/keymaps/mjt/config.h @@ -52,8 +52,6 @@ along with this program. If not, see <http://www.gnu.org/licenses/>. #define MATRIX_ROW_PINS { F7, B1, B3, B2, B6 } #define MATRIX_COL_PINS { B4, E6, D7, F6, D4, D0 } -#define CATERINA_BOOTLOADER - #define UNUSED_PINS /* COL2ROW or ROW2COL */ diff --git a/keyboards/gherkin/rules.mk b/keyboards/gherkin/rules.mk index 6bb9edb35a..530898bd78 100644 --- a/keyboards/gherkin/rules.mk +++ b/keyboards/gherkin/rules.mk @@ -33,14 +33,15 @@ ARCH = AVR8 # CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU. F_USB = $(F_CPU) +# Bootloader +# This definition is optional, and if your keyboard supports multiple bootloaders of +# different sizes, comment this out, and the correct address will be loaded +# automatically (+60). See bootloader.mk for all options. +BOOTLOADER = caterina + # Interrupt driven control endpoint task(+60) OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT - -# Boot Section Size in *bytes* -OPT_DEFS += -DBOOTLOADER_SIZE=4096 - - # Build Options # comment out to disable the options. # diff --git a/keyboards/handwired/MS_sculpt_mobile/rules.mk b/keyboards/handwired/MS_sculpt_mobile/rules.mk index 53769f81f4..680c057d36 100644 --- a/keyboards/handwired/MS_sculpt_mobile/rules.mk +++ b/keyboards/handwired/MS_sculpt_mobile/rules.mk @@ -5,21 +5,29 @@ SRC= babblePaste.c ifdef ASTAR CFLAGS=-D ASTAR - OPT_DEFS += -DBOOTLOADER_SIZE=4096 MCU = atmega32u4 - OPT_DEFS += -DCATERINA_BOOTLOADER SCULPT_UPLOAD_COMMAND = while [ ! -r $(USB) ]; do sleep 1; done ; \ avrdude -p $(MCU) -c avr109 -U flash:w:$(TARGET).hex -P $(USB) else MCU = at90usb1286 - OPT_DEFS += -DBOOTLOADER_SIZE=2048 SCULPT_UPLOAD_COMMAND = teensy_loader_cli -w -mmcu=$(MCU) $(TARGET).hex endif F_CPU = 16000000 ARCH = AVR8 F_USB = $(F_CPU) + +# Bootloader +# This definition is optional, and if your keyboard supports multiple bootloaders of +# different sizes, comment this out, and the correct address will be loaded +# automatically (+60). See bootloader.mk for all options. +ifdef ASTAR + BOOTLOADER = caterina +else + BOOTLOADER = atmel-dfu +endif + # Interrupt driven control endpoint task(+60) OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT diff --git a/keyboards/handwired/reddot/rules.mk b/keyboards/handwired/reddot/rules.mk index 4929968410..00ca06dd40 100755 --- a/keyboards/handwired/reddot/rules.mk +++ b/keyboards/handwired/reddot/rules.mk @@ -36,30 +36,25 @@ ARCH = AVR8 # CPU clock adjust registers or the clock division fuses), this will be equal to F_CPU. F_USB = $(F_CPU) - +# Bootloader +# This definition is optional, and if your keyboard supports multiple bootloaders of +# different sizes, comment this out, and the correct address will be loaded +# automatically (+60). See bootloader.mk for all options. ifdef TEENSY2 + BOOTLOADER = halfkay OPT_DEFS += -DATREUS_TEENSY2 ATREUS_UPLOAD_COMMAND = teensy_loader_cli -w -mmcu=$(MCU) $(TARGET).hex else + BOOTLOADER = caterina OPT_DEFS += -DATREUS_ASTAR - OPT_DEFS += -DCATERINA_BOOTLOADER ATREUS_UPLOAD_COMMAND = while [ ! -r $(USB) ]; do sleep 1; done; \ avrdude -p $(MCU) -c avr109 -U flash:w:$(TARGET).hex -P $(USB) endif + # Interrupt driven control endpoint task(+60) OPT_DEFS += -DINTERRUPT_CONTROL_ENDPOINT -# MCU name - -# Boot Section Size in *bytes* -# Teensy halfKay 512 -# Teensy++ halfKay 1024 -# Atmel DFU loader 4096 -# LUFA bootloader 4096 -# USBaspLoader 2048 -OPT_DEFS += -DBOOTLOADER_SIZE=4096 - # Build Options # change yes to no to disable diff --git a/keyboards/handwired/space_oddity/config.h b/keyboards/handwired/space_oddity/config.h index 88cc5ad00e..9c9361ced7 100644 --- a/keyboards/handwired/space_oddity/config.h +++ b/ke |