From 217fde56f967842e80da861c4c3088c078b8554f Mon Sep 17 00:00:00 2001 From: Jonathan Wakely Date: Thu, 15 Feb 2018 23:54:49 +0000 Subject: [PATCH] Check for missing bootloader port --- bin/kaleidoscope-builder | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/bin/kaleidoscope-builder b/bin/kaleidoscope-builder index 61fc7765..a6fedeaf 100755 --- a/bin/kaleidoscope-builder +++ b/bin/kaleidoscope-builder @@ -79,6 +79,10 @@ flash () { } flash_over_usb () { + if [ -z "${DEVICE_PORT_BOOTLOADER}" ]; then + echo 'DEVICE_PORT_BOOTLOADER is empty (did you hold "Prog" to enable bootloader mode?)' >&2 + return 1 + fi sleep 1s ${AVRDUDE} -q -q -C ${AVRDUDE_CONF} -p${MCU} -cavr109 -D -P ${DEVICE_PORT_BOOTLOADER} -b57600 "-Uflash:w:${HEX_FILE_PATH}:i" }