mirror of
https://bitbucket.org/librepilot/librepilot.git
synced 2025-01-29 14:52:12 +01:00
build: use board-specific JTAG interface for openocd
Removes hard-coding of JTAG interface config in the <board>_program make macros. This allows the use of STLINKv2 for F4 boards while continuing to use the FOSS JTAG revB on F1 boards.
This commit is contained in:
parent
f475088585
commit
b7e9c2ee2a
@ -17,6 +17,9 @@ OPENOCD_CONFIG := stm32f1x.cfg
|
||||
OPENOCD_JTAG_CONFIG := foss-jtag.revb.cfg
|
||||
OPENOCD_CONFIG := stm32f1x.cfg
|
||||
|
||||
OPENOCD_JTAG_CONFIG := foss-jtag.revb.cfg
|
||||
OPENOCD_CONFIG := stm32f1x.cfg
|
||||
|
||||
# Note: These must match the values in link_$(BOARD)_memory.ld
|
||||
BL_BANK_BASE := 0x08000000 # Start of bootloader flash
|
||||
BL_BANK_SIZE := 0x00003000 # Should include BD_INFO region
|
||||
|
@ -210,7 +210,8 @@ endef
|
||||
# $(1) = Name of binary image to write
|
||||
# $(2) = Base of flash region to write/wipe
|
||||
# $(3) = Size of flash region to write/wipe
|
||||
# $(4) = OpenOCD configuration file to use
|
||||
# $(4) = OpenOCD JTAG interface configuration file to use
|
||||
# $(5) = OpenOCD configuration file to use
|
||||
define JTAG_TEMPLATE
|
||||
# ---------------------------------------------------------------------------
|
||||
# Options for OpenOCD flash-programming
|
||||
@ -223,7 +224,7 @@ OOCD_EXE ?= openocd
|
||||
OOCD_JTAG_SETUP = -d0
|
||||
# interface and board/target settings (using the OOCD target-library here)
|
||||
OOCD_JTAG_SETUP += -s $(TOP)/flight/Project/OpenOCD
|
||||
OOCD_JTAG_SETUP += -f foss-jtag.revb.cfg -f $(4)
|
||||
OOCD_JTAG_SETUP += -f $(4) -f $(5)
|
||||
|
||||
# initialize
|
||||
OOCD_BOARD_RESET = -c init
|
||||
|
Loading…
x
Reference in New Issue
Block a user