1
0
mirror of https://github.com/trezor/trezor-firmware.git synced 2024-11-16 04:29:08 +00:00

bootloader: add flash target to makefile

This commit is contained in:
Pavol Rusnak 2017-03-19 15:29:48 +01:00
parent 603d980d22
commit 4f45071940
No known key found for this signature in database
GPG Key ID: 91F3B339B9A02A3D

View File

@ -3,6 +3,7 @@
JOBS=4 JOBS=4
MAKE=make -j $(JOBS) MAKE=make -j $(JOBS)
BOOTLOADER_BUILD_DIR=micropython/bootloader/build
TREZORHAL_BUILD_DIR=micropython/firmware/build TREZORHAL_BUILD_DIR=micropython/firmware/build
TREZORHAL_PORT_OPTS=FROZEN_MPY_DIR=src TREZORHAL_PORT_OPTS=FROZEN_MPY_DIR=src
@ -60,6 +61,9 @@ clean_cross: ## clean mpy-cross build
flash: ## flash firmware using st-flash flash: ## flash firmware using st-flash
st-flash write $(TREZORHAL_BUILD_DIR)/firmware.bin 0x8000000 st-flash write $(TREZORHAL_BUILD_DIR)/firmware.bin 0x8000000
flash_bootloader: ## flash bootloader using st-flash
st-flash write $(BOOTLOADER_BUILD_DIR)/bootloader.bin 0x8000000
flash_openocd: $(TREZORHAL_BUILD_DIR)/firmware.hex ## flash firmware using openocd flash_openocd: $(TREZORHAL_BUILD_DIR)/firmware.hex ## flash firmware using openocd
openocd -f interface/stlink-v2.cfg -f target/stm32f4x.cfg \ openocd -f interface/stlink-v2.cfg -f target/stm32f4x.cfg \
-c "init" \ -c "init" \