OpenCores
URL https://opencores.org/ocsvn/xenie/xenie/trunk

Subversion Repositories xenie

[/] [xenie/] [trunk/] [examples/] [Eth_example/] [src/] [tcl/] [program_xenie.tcl] - Blame information for rev 6

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 4 DFC
 
2
# This script loads resulting MCSs (both Marvell FW and FPGA bitstream)
3
# to serial configuration flash on Xenie 1.0 via JTAG cable.
4
 
5
# Open project if necessary, or use the opened one
6
if {[llength [current_project -quiet]] == 0} {
7
   # Set the reference directory to where the script is
8
   set origin_dir [file normalize [file dirname [info script]]]
9
 
10
   # Set project directory path
11
   set proj_dir [file normalize $origin_dir/../../vivado]
12
 
13
   # open project
14
   open_project $proj_dir/eth_example.xpr
15
}
16
 
17
# Set the reference directory to where the script is
18
set origin_dir [file normalize [file dirname [info script]]]
19
 
20
# open HW manager
21
open_hw
22
 
23
# Open target
24
if {[llength [get_hw_servers -quiet]] == 0} {
25
   connect_hw_server
26
}
27
 
28
open_hw_target
29
 
30
 
31 6 DFC
current_hw_device [lindex [get_hw_devices -regexp xc7k.*] 0]
32 4 DFC
refresh_hw_device -update_hw_probes false [current_hw_device]
33
 
34
 
35
 
36
# Add spi flash
37
if {[llength [get_property PROGRAM.HW_CFGMEM [current_hw_device]]] == 0} {
38
   create_hw_cfgmem -hw_device [current_hw_device] -mem_dev  [lindex [get_cfgmem_parts {s25fl256sxxxxxx0-spi-x1_x2_x4}] 0]
39
}
40
 
41
#current_hw_cfgmem [get_property PROGRAM.HW_CFGMEM [current_hw_device]]
42
 
43
set_property PROGRAM.BLANK_CHECK  0 [current_hw_cfgmem]
44
set_property PROGRAM.ERASE  1 [current_hw_cfgmem]
45
set_property PROGRAM.CFG_PROGRAM  1 [current_hw_cfgmem]
46
set_property PROGRAM.VERIFY  1 [current_hw_cfgmem]
47
set_property PROGRAM.CHECKSUM  0 [current_hw_cfgmem]
48
set_property PROGRAM.UNUSED_PIN_TERMINATION {pull-none} [current_hw_cfgmem]
49
refresh_hw_device [current_hw_device]
50
 
51
 
52
 
53
 
54
 
55
 
56
if {![string equal \
57
         [get_property PROGRAM.HW_CFGMEM_TYPE  [current_hw_device]] \
58
         [get_property MEM_TYPE [get_property CFGMEM_PART [current_hw_cfgmem]]] \
59
     ] } {
60
      create_hw_bitstream -hw_device [current_hw_device] [get_property PROGRAM.HW_CFGMEM_BITFILE [current_hw_device]];
61
      program_hw_devices [current_hw_device];
62
   };
63
 
64
 
65
set_property PROGRAM.ADDRESS_RANGE  {use_file} [current_hw_cfgmem]
66
 
67
# Program Marvell PHY FW mcs
68
set prog_file "$origin_dir/../../outputs/res/marvell_only.mcs"
69
set_property PROGRAM.FILES $prog_file [current_hw_cfgmem]
70
program_hw_cfgmem -hw_cfgmem [current_hw_cfgmem]
71
 
72
# Program Microblaze MCS
73
set prog_file "$origin_dir/../../outputs/res/xenie_eth_example_mb.mcs"
74
set_property PROGRAM.FILES $prog_file [current_hw_cfgmem]
75
 
76
program_hw_cfgmem -hw_cfgmem [current_hw_cfgmem]
77
 
78
 
79
 

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.