diff options
author | Danny Nguyen <danny@80pct.com> | 2017-02-26 16:16:24 +0100 |
---|---|---|
committer | Danny Nguyen <danny@80pct.com> | 2017-03-07 18:20:52 +0100 |
commit | 6ee823a821d9c89a67c53f65ecf4d745223694a0 (patch) | |
tree | 9bc6824594bd673415693010d8ab6c3b8bff8824 | |
parent | 1023a47be6b91282b92b9a44f4492aa88375bf8e (diff) | |
download | qmk_firmware-6ee823a821d9c89a67c53f65ecf4d745223694a0.tar.gz qmk_firmware-6ee823a821d9c89a67c53f65ecf4d745223694a0.tar.xz |
Add rule for flashing microcontroller using avrdude
-rw-r--r-- | keyboards/handwired/magicforce68/rules.mk | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/keyboards/handwired/magicforce68/rules.mk b/keyboards/handwired/magicforce68/rules.mk index 711759917..e897ef252 100644 --- a/keyboards/handwired/magicforce68/rules.mk +++ b/keyboards/handwired/magicforce68/rules.mk @@ -70,4 +70,14 @@ ifndef QUANTUM_DIR include ../../../Makefile endif +avrdude: build + ls /dev/tty* > /tmp/1; \ + echo "Reset your Pro Micro now"; \ + while [[ -z $$USB ]]; do \ + sleep 1; \ + ls /dev/tty* > /tmp/2; \ + USB=`diff /tmp/1 /tmp/2 | grep -o '/dev/tty.*'`; \ + done; \ + avrdude -p $(MCU) -c avr109 -P $$USB -U flash:w:$(BUILD_DIR)/$(TARGET).hex +.PHONY: avrdude |