Browse Source

Add rule for flashing microcontroller using avrdude

pull/1138/head
Danny Nguyen 7 years ago
parent
commit
6ee823a821
1 changed files with 10 additions and 0 deletions
  1. +10
    -0
      keyboards/handwired/magicforce68/rules.mk

+ 10
- 0
keyboards/handwired/magicforce68/rules.mk View File

@ -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

Loading…
Cancel
Save