cancel
Showing results for 
Search instead for 
Did you mean: 
Highlighted
Observer
Observer
1,287 Views
Registered: ‎10-16-2017

Apply Zynq processor preset from TCL

Jump to solution

Hi,

 

In my project I have several processor preset files (TCL-files) that I apply to the Zynq processor depending on the target I am building for. I use the Vivado Re-customize IP GUI to apply the preset files to the Zynq processor in my design.

 

This works fine, but I would like to do the same using the Vivado TCL command line interface. Is this possible? It doesn't look like I can simply "source" the preset file. 

 

/Andre

0 Kudos
1 Solution

Accepted Solutions
Highlighted
Observer
Observer
1,375 Views
Registered: ‎10-16-2017

Re: Apply Zynq processor preset from TCL

Jump to solution

I found a solution:

 

 

source processor_config.tcl
set presets [apply_preset 0] foreach {k v} $presets { if {![info exists preset_list]} { set preset_list [dict create $k $v] } else { dict set preset_list $k $v } } set_property -dict $preset_list [get_bd_cells zynq_ultra_ps_e_0]

 

View solution in original post

0 Kudos
3 Replies
Highlighted
Moderator
Moderator
1,253 Views
Registered: ‎09-12-2007

Re: Apply Zynq processor preset from TCL

Jump to solution
you Might need to parse the file slightly, but you should be able to source this from tcl console.

0 Kudos
Highlighted
Observer
Observer
1,221 Views
Registered: ‎10-16-2017

Re: Apply Zynq processor preset from TCL

Jump to solution

Hi,

 

Ok, let me rephrase my question: How specifically can you do this with TCL?

The processor configuration TCL file is created using the Vivado PS configuration GUI, under Presets->Save Configuration...

 

This TCL file gives me 3 functions:

- proc getPresetInfo

- proc validate_preset

- proc apply_preset

The apply_preset function returns the processor configuration, but I want to know how I can apply this configuration. I have tried to create a simple TCL-script that uses this function, but no luck so far:

 

source processor_config.tcl
set presets [apply_preset 0]

foreach {k v} $presets {
  if {![info exists value]} {
    set value [list $k $v]
  } else {
    lappend value [list $k $v]
  }
}
startgroup
set_property -dict $value [get_bd_cells zynq_ultra_ps_e_0]
endgroup

 

Any suggestions?

 

0 Kudos
Highlighted
Observer
Observer
1,376 Views
Registered: ‎10-16-2017

Re: Apply Zynq processor preset from TCL

Jump to solution

I found a solution:

 

 

source processor_config.tcl
set presets [apply_preset 0] foreach {k v} $presets { if {![info exists preset_list]} { set preset_list [dict create $k $v] } else { dict set preset_list $k $v } } set_property -dict $preset_list [get_bd_cells zynq_ultra_ps_e_0]

 

View solution in original post

0 Kudos