summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorroot <root@no.no.james.local>2015-09-01 14:26:57 +0100
committerroot <root@no.no.james.local>2015-09-01 14:26:57 +0100
commit4eb753e7170969c9ba9ad3d914f74f60c13836ae (patch)
tree4f80c17f421bad41c732ee358138481210235894
parent5096109676a11557d1e25707d203f75e5c10b4d5 (diff)
downloadblinky-4eb753e7170969c9ba9ad3d914f74f60c13836ae.tar.gz
blinky-4eb753e7170969c9ba9ad3d914f74f60c13836ae.tar.bz2
blinky-4eb753e7170969c9ba9ad3d914f74f60c13836ae.zip
fish
-rw-r--r--Makefile18
1 files changed, 12 insertions, 6 deletions
diff --git a/Makefile b/Makefile
index 69e038b..f258e30 100644
--- a/Makefile
+++ b/Makefile
@@ -17,6 +17,8 @@ INCLUDES=
SDK=sdk-9.0.0
+BDADDR=FD:F9:62:4A:8A:C8
+
SDKCSRCS= \
softdevice/common/softdevice_handler/softdevice_handler_appsh.c \
softdevice/common/softdevice_handler/softdevice_handler.c \
@@ -143,18 +145,22 @@ ds:
debug: ${PROG}
${GDB} -x gdb.script ${PROG}
-test.hex:test.bin
- bin2hex.py --offset=0x1c000 $< $@
-
-test.bin:
- printf '\x00\x01\x02\x03\x04\x05\x06\x07\x08\x09\x0a\x0b\x0c\x0d\x0e\x0f' > $@
- printf '\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f' >> $@
+reset:
+ ${OOCD} -f ${OOCD_CFG} \
+ -c "init" \
+ -c "reset init" \
+ -c "reset" \
+ -c "shutdown"
%.zip: %.hex
${NRFUTIL} dfu genpkg --dev-revision ${DEV_REVISION} --dev-type ${DEV_TYPE} --application-version ${APP_VERSION} --sd-req ${SD_REQ} --application $< $@
+dfu: ${PROG}.zip
+ nrfdfu -b ${BDADDR} -p ${PROG}.zip
+
+
#flash: $(MAKECMDGOALS)
# @echo Flashing: $(OUTPUT_BINARY_DIRECTORY)/$<.hex
# nrfjprog --reset --program $(OUTPUT_BINARY_DIRECTORY)/$<.hex