1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51
|
# xsdb tcl file
set m_type [lindex $argv 0]
connect
if {$m_type == "ZYNQ_PSU"} {
targets -set -filter {name =~ "PSU"}
}
if {$m_type == "ZYNQ_PS7"} {
targets -set -filter {name =~ "xc7z*"}
}
if {$m_type == "MICROBLAZE"} {
targets -set -filter {name =~ "xc*"}
}
fpga -file hw/system_top.bit
if {$m_type == "ZYNQ_PSU"} {
targets -set -filter {name =~ "APU*"}
source hw/psu_init.tcl
psu_init
psu_post_config
}
if {$m_type == "ZYNQ_PS7"} {
targets -set -filter {name =~ "APU*"}
source hw/ps7_init.tcl
ps7_init
ps7_post_config
}
if {$m_type == "ZYNQ_PSU"} {
}
if {$m_type == "ZYNQ_PS7"} {
targets -set -filter {name =~ "*Cortex-A9 MPCore #0*"}
}
if {$m_type == "MICROBLAZE"} {
after 1000
targets -set -filter {name =~ "*MicroBlaze*"}
}
dow sw/Release/sw.elf
con
disconnect
exit
|