#
# OpenOCD configuration for JTAG debugging on the Kinetis K20.
#
# Use the OpenOCD patch from:
#   https://forum.sparkfun.com/viewtopic.php?f=18&t=36393
#
#   # checkout code from OpenOCD master branch
#   git clone git://git.code.sf.net/p/openocd/code openocd
#
#   # apply patch, this info is given on the gerrit page for the patch.
#   git fetch http://openocd.zylin.com/openocd refs/changes/08/1508/1 && git checkout FETCH_HEAD
#
#   ./bootstrap
#   ./configure --enable-ftdi
#   make
#

source [find interface/ftdi/olimex-arm-usb-ocd-h.cfg]

# Freescale Kinetis K20 device. Should be compatible with K40,
# just set a custom name.
set CHIPNAME k20
source [find target/k40.cfg]

adapter_khz 1000
reset_config srst_only

# One 128K flash bank
flash bank pflash.0 kinetis 0x00000000 0x20000 0 4 $_TARGETNAME

Add a working OpenOCD config for JTAG debugging
Add a working OpenOCD config for JTAG debugging
