msdarvishi
Full Member level 4
Dear all,
I have a Tcl file that generates a design including Microblaze and BRAM module. In the last part of my code as you see below, I have mapped the different address to a location. Can anyone tell me how can I define the memory locations as a function and call those funcyions in another Tcl file that sources this current Tcl file?
For more clarification, instead of the predefined memory addresses, I want to let the user to allocate his/her own memory addresses later when he/she runs a Tcl file that calls (source) this current Tcl script.
For example, how can I define the address 0xC2000000 as in a function??
Kind replies are in advance appreciated.
Regards,
I have a Tcl file that generates a design including Microblaze and BRAM module. In the last part of my code as you see below, I have mapped the different address to a location. Can anyone tell me how can I define the memory locations as a function and call those funcyions in another Tcl file that sources this current Tcl file?
For more clarification, instead of the predefined memory addresses, I want to let the user to allocate his/her own memory addresses later when he/she runs a Tcl file that calls (source) this current Tcl script.
Code:
#--------- Memory Address Assignments for hierarchy
#
#----- ublazePCIe_hier/axi_pcie_0
assign_bd_address [get_bd_addr_segs {M00_AXI_0/Reg }]
set_property offset 0xC2000000 [get_bd_addr_segs {ublazePCIe_hier/axi_pcie_0/M_AXI/SEG_M00_AXI_0_Reg}]
set_property range 8K [get_bd_addr_segs {ublazePCIe_hier/axi_pcie_0/M_AXI/SEG_M00_AXI_0_Reg}]
#
#
#----- ublazePCIe_hier/microblaze_0
#----------- Data ------------------
#-- SLMB
set_property offset 0x40000000 [get_bd_addr_segs {ublazePCIe_hier/microblaze_0/Data/SEG_dlmb_bram_if_cntlr_Mem}]
set_property range 32K [get_bd_addr_segs {ublazePCIe_hier/microblaze_0/Data/SEG_dlmb_bram_if_cntlr_Mem}]
#
#-- CTL0
assign_bd_address [get_bd_addr_segs {ublazePCIe_hier/axi_pcie_0/S_AXI_CTL/CTL0 }]
set_property offset 0x10000000 [get_bd_addr_segs {ublazePCIe_hier/microblaze_0/Data/SEG_axi_pcie_0_CTL0}]
set_property range 8K [get_bd_addr_segs {ublazePCIe_hier/microblaze_0/Data/SEG_axi_pcie_0_CTL0}]
#
#-- BAR0
assign_bd_address [get_bd_addr_segs {ublazePCIe_hier/axi_pcie_0/S_AXI/BAR0 }]
set_property range 8K [get_bd_addr_segs {ublazePCIe_hier/microblaze_0/Data/SEG_axi_pcie_0_BAR0}]
set_property offset 0x80000000 [get_bd_addr_segs {ublazePCIe_hier/microblaze_0/Data/SEG_axi_pcie_0_BAR0}]
#
#-- M00_AXI_1
assign_bd_address [get_bd_addr_segs {M00_AXI_1/Reg }]
set_property offset 0xB0000000 [get_bd_addr_segs {ublazePCIe_hier/microblaze_0/Data/SEG_M00_AXI_1_Reg}]
set_property range 8K [get_bd_addr_segs {ublazePCIe_hier/microblaze_0/Data/SEG_M00_AXI_1_Reg}]
#
#----------- Instruction -----------------
#-- SLMB
set_property offset 0x00000000 [get_bd_addr_segs {ublazePCIe_hier/microblaze_0/Instruction/SEG_ilmb_bram_if_cntlr_Mem}]
set_property range 32K [get_bd_addr_segs {ublazePCIe_hier/microblaze_0/Instruction/SEG_ilmb_bram_if_cntlr_Mem}]
For example, how can I define the address 0xC2000000 as in a function??
Kind replies are in advance appreciated.
Regards,
Last edited by a moderator: