core: 'make dfu' waits for bootloader to start
authortmk <hasu@tmk-kbd.com>
Thu, 8 Sep 2016 04:52:59 +0000 (13:52 +0900)
committertmk <hasu@tmk-kbd.com>
Thu, 8 Sep 2016 04:52:59 +0000 (13:52 +0900)
jackhumbert/qmk_firmware@0b8c448

tmk_core/rules.mk

index 0ae84d912fd452b1a9a2000402b487e91569f1c7..a0a7c3e5ce01aacb59cae8b2919e15a7f9cf060e 100644 (file)
@@ -420,6 +420,10 @@ flip: $(TARGET).hex
        batchisp -hardware usb -device $(MCU) -operation start reset 0
 
 dfu: $(TARGET).hex
+       @until dfu-programmer atmega32u4 get bootloader-version > /dev/null 2>&1; do \
+               echo  -n "."; \
+               sleep 1; \
+       done
 ifneq (, $(findstring 0.7, $(shell dfu-programmer --version 2>&1)))
        dfu-programmer $(MCU) erase --force
 else
Imprint / Impressum