aboutsummaryrefslogtreecommitdiff
path: root/tcl
diff options
context:
space:
mode:
authorMarc Schink <openocd-dev@marcschink.de>2019-06-05 13:34:29 +0200
committerMatthias Welwarsky <matthias@welwarsky.de>2019-06-19 10:17:57 +0100
commit56de276d91ea47cfbcaef7abd72be898609f9207 (patch)
tree9985337257ae827b4f56618b9ca74bb65a551d0b /tcl
parent0d47d85ff5d3c8512d2475097ef8356267c57cda (diff)
downloadriscv-openocd-56de276d91ea47cfbcaef7abd72be898609f9207.zip
riscv-openocd-56de276d91ea47cfbcaef7abd72be898609f9207.tar.gz
riscv-openocd-56de276d91ea47cfbcaef7abd72be898609f9207.tar.bz2
tcl/target: Add initial Microchip SAML1x support
There is not flash bank support at the moment. Change-Id: I833c009d9d21cdeb70b57d67eb557d50ed0fb4de Signed-off-by: Marc Schink <openocd-dev@marcschink.de> Reviewed-on: http://openocd.zylin.com/5205 Tested-by: jenkins Reviewed-by: Tomas Vanek <vanekt@fbl.cz> Reviewed-by: Matthias Welwarsky <matthias@welwarsky.de>
Diffstat (limited to 'tcl')
-rw-r--r--tcl/target/atsaml1x.cfg31
1 files changed, 31 insertions, 0 deletions
diff --git a/tcl/target/atsaml1x.cfg b/tcl/target/atsaml1x.cfg
new file mode 100644
index 0000000..3486746
--- /dev/null
+++ b/tcl/target/atsaml1x.cfg
@@ -0,0 +1,31 @@
+#
+# Microchip (formerly Atmel) SAM L1x target
+#
+# Note: These devices support SWD only.
+#
+
+transport select swd
+
+if { [info exists CHIPNAME] } {
+ set _CHIPNAME $CHIPNAME
+} else {
+ set _CHIPNAME saml1x
+}
+
+if { [info exists WORKAREASIZE] } {
+ set _WORKAREASIZE $WORKAREASIZE
+} else {
+ set _WORKAREASIZE 0x800
+}
+
+swd newdap $_CHIPNAME cpu -expected-id 0x0bf11477
+dap create $_CHIPNAME.dap -chain-position $_CHIPNAME.cpu
+
+set _TARGETNAME $_CHIPNAME.cpu
+target create $_TARGETNAME cortex_m -dap $_CHIPNAME.dap
+
+$_TARGETNAME configure -work-area-phys 0x20000000 -work-area-size $_WORKAREASIZE -work-area-backup 0
+
+if {![using_hla]} {
+ cortex_m reset_config sysresetreq
+}