8e701f15639c90ac36552b24574bfc297c81e32f
[fw/openocd] / tcl / board / sifive-e31arty.cfg
1 #
2 # Be sure you include the speed and interface before this file
3 # Example:
4 # -c "adapter speed 5000" -f "interface/ftdi/olimex-arm-usb-tiny-h.cfg" -f "board/sifive-e31arty.cfg"
5
6 set _CHIPNAME riscv
7 jtag newtap $_CHIPNAME cpu -irlen 5 -expected-id 0x20000001
8
9 set _TARGETNAME $_CHIPNAME.cpu
10
11 target create $_TARGETNAME.0 riscv -chain-position $_TARGETNAME
12 $_TARGETNAME.0 configure -work-area-phys 0x80000000 -work-area-size 10000 -work-area-backup 1
13
14 flash bank spi0 fespi 0x40000000 0 0 0 $_TARGETNAME.0 0x20004000
15 init
16 if {[ info exists pulse_srst]} {
17   ftdi set_signal nSRST 0
18   ftdi set_signal nSRST z
19 }
20 halt
21 flash protect 0 64 last off
22 echo "Ready for Remote Connections"