Convert to unix format. Removing trailing space.
[bertos.git] / bertos / cpu / arm / scripts / openocd_new_at91sam7_ftdi_rom.cfg
1
2 # Change the default telnet port...
3 telnet_port 4444
4
5 # Port for TCL connection.
6 tcl_port 6666
7
8 # GDB connects here
9 gdb_port 3333
10 # GDB can also flash my flash!
11 gdb_memory_map enable
12 gdb_flash_program enable
13 gdb_breakpoint_override hard
14
15 interface ft2232
16 #ft2232_device_desc "Amontec JTAGkey"
17 ft2232_layout jtagkey
18 ft2232_vid_pid 0x0403 0xcff8
19
20
21 #use combined on interfaces or targets that can't set TRST/SRST separately
22 reset_config srst_only srst_pulls_trst
23
24 if { [info exists CHIPNAME] } { 
25    set  _CHIPNAME $CHIPNAME    
26 } else {         
27    set  _CHIPNAME sam7
28 }
29
30 if { [info exists ENDIAN] } {   
31    set  _ENDIAN $ENDIAN    
32 } else {         
33    set  _ENDIAN little
34 }
35
36 if { [info exists CPUTAPID ] } {
37    set _CPUTAPID $CPUTAPID
38 } else {
39    set _CPUTAPID 0x3f0f0f0f
40 }
41
42 jtag newtap $_CHIPNAME cpu -irlen 4 -ircapture 0x1 -irmask 0xf -expected-id $_CPUTAPID
43
44 set _TARGETNAME [format "%s.cpu" $_CHIPNAME]
45 target create $_TARGETNAME arm7tdmi -endian $_ENDIAN -chain-position $_TARGETNAME -variant arm7tdmi
46
47 $_TARGETNAME configure -work-area-virt 0 -work-area-phys 0x00200000 -work-area-size 0x4000 -work-area-backup 0
48
49 #flash bank <driver> <base> <size> <chip_width> <bus_width>
50 flash bank at91sam7 0 0 0 0 0