|
@ -151,13 +151,15 @@ $(PROJECT).elf: $(OBJS) $(LDSCRIPT) |
|
|
%.flash: %.elf |
|
|
%.flash: %.elf |
|
|
@printf " FLASH\t$<\n" |
|
|
@printf " FLASH\t$<\n" |
|
|
ifeq (,$(OOCD_FILE)) |
|
|
ifeq (,$(OOCD_FILE)) |
|
|
$(Q)$(OOCD) -f interface/$(OOCD_INTERFACE).cfg \
|
|
|
$(Q)(echo "halt; program $(realpath $(*).elf) verify reset" | nc -4 localhost 4444 2>/dev/null) || \
|
|
|
|
|
|
$(OOCD) -f interface/$(OOCD_INTERFACE).cfg \
|
|
|
-f target/$(OOCD_TARGET).cfg \
|
|
|
-f target/$(OOCD_TARGET).cfg \
|
|
|
-c "program $(*).elf verify reset exit" \
|
|
|
-c "program $(realpath $(*).elf) verify reset exit" \
|
|
|
$(NULL) |
|
|
$(NULL) |
|
|
else |
|
|
else |
|
|
$(Q)$(OOCD) -f $(OOCD_FILE) \
|
|
|
$(Q)(echo "halt; program $(realpath $(*).elf) verify reset" | nc -4 localhost 4444 2>/dev/null) || \
|
|
|
-c "program $(*).elf verify reset exit" \
|
|
|
$(Q)$(OOCD) -f $(OOCD_FILE) \
|
|
|
|
|
|
-c "program $(realpath $(*).elf) verify reset exit" \
|
|
|
$(NULL) |
|
|
$(NULL) |
|
|
endif |
|
|
endif |
|
|
|
|
|
|
|
|