mirror of
https://github.com/qmk/qmk_firmware
synced 2024-11-14 07:55:28 +00:00
Check for a new serial port every second
This commit is contained in:
parent
d4c88626bd
commit
3dbdd15304
1 changed files with 6 additions and 4 deletions
|
@ -76,10 +76,12 @@ CUSTOM_MATRIX = yes
|
||||||
|
|
||||||
avrdude: build
|
avrdude: build
|
||||||
ls /dev/tty* > /tmp/1; \
|
ls /dev/tty* > /tmp/1; \
|
||||||
echo "Reset your Pro Micro then hit any key to continue..."; \
|
echo "Reset your Pro Micro now"; \
|
||||||
read -n 1 -s; \
|
while [[ -z $$USB ]]; do \
|
||||||
ls /dev/tty* > /tmp/2; \
|
sleep 1; \
|
||||||
USB=`diff /tmp/1 /tmp/2 | grep '>' | sed -e 's/> //'`; \
|
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
|
avrdude -p $(MCU) -c avr109 -P $$USB -U flash:w:$(BUILD_DIR)/$(TARGET).hex
|
||||||
|
|
||||||
.PHONY: avrdude
|
.PHONY: avrdude
|
||||||
|
|
Loading…
Reference in a new issue