X-Git-Url: http://git.rot13.org/?p=goodfet;a=blobdiff_plain;f=firmware%2FMakefile;h=75ada153f0604c921ffa474d1897c85c51ce2c81;hp=8e7d7ffaff875906d72b99e048777f24cf9bb506;hb=7f43ff80b47ffc85c8078d962011024979ee6e20;hpb=3e900862cd87255c698e516c37078163ce343e77 diff --git a/firmware/Makefile b/firmware/Makefile index 8e7d7ff..75ada15 100644 --- a/firmware/Makefile +++ b/firmware/Makefile @@ -1,17 +1,19 @@ PORT=/dev/ttyUSB0 -BSL=msp430-bsl --invert-reset --invert-test -c $(PORT) --speed=38400 +BSL=../../contrib/tos-bsl --invert-reset --invert-test -c $(PORT) --speed=38400 -#mcu=msp430x1611 +#mcu=msp430x2618 mcu=msp430x1612 -#ldscript is wonky -GCCINC=-T ldscripts/161x.x -CC=msp430-gcc -g -mmcu=$(mcu) -DGCC $(GCCINC) -I include +#N.B., gcc WILL NOT BITCH if this file doesn't exist. +#GCCINC=-T ldscripts/161x.x +GCCINC=-T ldscripts/$(mcu).x + +CC=msp430-gcc -Wall -g -mmcu=$(mcu) -DGCC $(GCCINC) -I include apps= apps/monitor/monitor.o apps/spi/spi.o apps/i2c/i2c.o apps/chipcon/chipcon.o apps/jtag/jtag.o apps/jtag/jtag430.o -libs= lib/msp430f1612.o lib/command.o +libs= lib/$(mcu).o lib/command.o apps/jtag/jtag430asm.o app=goodfet all: $(app).hex @@ -22,8 +24,13 @@ run: ../client/goodfet.msp430 test install: $(app).hex - $(BSL) -e -p $(app).hex - #$(BSL) -P $(app).hex -r + $(BSL) -e + #$(BSL) -p info.txt || true #MSP430F2xx targets only, inelegant. + $(BSL) -p $(app).hex +verify: + $(BSL) -P $(app).hex -v $(app).hex +dumpinfo: + $(BSL) --dumpinfo -c /dev/ttyUSB0 $(app): $(app).c $(libs) $(apps) $(app).hex: $(app) msp430-objcopy goodfet -O ihex goodfet.hex