tcl/target: add SPDX tag
[fw/openocd] / tcl / target / is5114.cfg
1 # SPDX-License-Identifier: GPL-2.0-or-later
2
3 # script for Insilica IS-5114
4 # AKA: Atmel AT76C114 - an ARM946 chip
5 # ATMEL sold his product line to Insilica...
6
7 if { [info exists CHIPNAME] } {
8    set _CHIPNAME $CHIPNAME
9 } else {
10    set _CHIPNAME is5114
11 }
12
13 if { [info exists ENDIAN] } {
14    set _ENDIAN $ENDIAN
15 } else {
16   # this defaults to a little endian
17    set _ENDIAN little
18 }
19
20 if { [info exists CPUTAPID] } {
21    set _CPUTAPID $CPUTAPID
22 } else {
23    # Force an error until we get a good number.
24    set _CPUTAPID 0xffffffff
25 }
26
27 # jtag speed. We need to stick to 16kHz until we've finished reset.
28 adapter speed 16
29
30 reset_config trst_and_srst
31
32 # Do not specify a tap id here...
33 jtag newtap $_CHIPNAME unknown1 -irlen 8 -ircapture 0x01 -irmask 1
34 # This is the "arm946" chip.
35 jtag newtap $_CHIPNAME cpu      -irlen 4 -ircapture 0x0e -irmask 0xf
36 jtag newtap $_CHIPNAME unknown2 -irlen 5 -ircapture 1 -irmask 1
37
38
39 #arm946e-s and
40 set _TARGETNAME $_CHIPNAME.cpu
41 target create $_TARGETNAME arm966e -endian $_ENDIAN -chain-position $_TARGETNAME
42
43 $_TARGETNAME configure -event reset-start { adapter speed 16 }
44 $_TARGETNAME configure -event reset-init {
45         # We can increase speed now that we know the target is halted.
46         adapter speed 3000
47 }
48 $_TARGETNAME configure -work-area-phys 0x50000000 -work-area-size 16384 -work-area-backup 1