aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorKevin O'Connor <kevin@koconnor.net>2019-03-10 14:35:25 -0400
committerKevin O'Connor <kevin@koconnor.net>2019-03-10 15:06:41 -0400
commita5aede52cbd391989aadc3b05ef3a60e0d1dcd8f (patch)
tree382dfce77c7d6bea10086ac3c01ed683f1dbdea6 /src
parentd3f6dad85383c2435f15700dfaf685938fa3f367 (diff)
downloadkutter-a5aede52cbd391989aadc3b05ef3a60e0d1dcd8f.tar.gz
kutter-a5aede52cbd391989aadc3b05ef3a60e0d1dcd8f.tar.xz
kutter-a5aede52cbd391989aadc3b05ef3a60e0d1dcd8f.zip
flash_usb: Try to make the bossac atsam reboot logic more stable
Signed-off-by: Kevin O'Connor <kevin@koconnor.net>
Diffstat (limited to 'src')
-rw-r--r--src/atsam/Makefile5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/atsam/Makefile b/src/atsam/Makefile
index 3bafd20f..780a478a 100644
--- a/src/atsam/Makefile
+++ b/src/atsam/Makefile
@@ -58,6 +58,9 @@ lib/bossac/bin/bossac:
@echo " Building bossac"
$(Q)make -C lib/bossac bin/bossac
+FLASH_TYPE-$(CONFIG_MACH_SAM3X) := atsam3
+FLASH_TYPE-$(CONFIG_MACH_SAM4) := atsam4
+
flash: $(OUT)klipper.bin lib/bossac/bin/bossac
@echo " Flashing $< to $(FLASH_DEVICE)"
- $(Q)$(PYTHON) ./scripts/flash_usb.py -t atsam -d "$(FLASH_DEVICE)" $(OUT)klipper.bin
+ $(Q)$(PYTHON) ./scripts/flash_usb.py -t $(FLASH_TYPE-y) -d "$(FLASH_DEVICE)" $(OUT)klipper.bin