Intel® Quartus® Prime Software
Intel® Quartus® Prime Design Software, Design Entry, Synthesis, Simulation, Verification, Timing Analysis, System Design (Platform Designer, formerly Qsys)
Announcements
Intel Support hours are Monday-Fridays, 8am-5pm PST, except Holidays. Thanks to our community members who provide support during our down time or before we get to your questions. We appreciate you!

Need Forum Guidance? Click here
Search our FPGA Knowledge Articles here.
14943 Discussions

get_clock_info -master_clock_pin returns nothing when the clock type is base

Diego2
Novice
158 Views

Hello

I created a base clock coming from a top-level port in the design. The problem I'm having is when I try to get the source clock pin using 'get_clock_info -master_clock_pin my_clk' it returns nothing. If I do that with a generated clock it works though.

tcl> create_clock -name "my_clk" -period 8 [get_ports clk]
tcl> create_generated_clock -name "my_clk_div2" -divide_by 2 -multiply_by 1 -source [get_ports clk] -master_clock clk_eri_sys______a_125_000k_c_p [get_nets clk_div2]
tcl> get_clock_info -master_clock_pin my_clk
<nothing>
tcl> get_clock_info -master_clock_pin my_clk_div2
clk

 Is there any step that I'm missing?

With Vivado it's a bit clunky, but it works like this and it would return either a port or a pin name

tcl> get_property SOURCE_PINS [get_clocks <CLOCK_NAME>]

 

Thanks!

0 Kudos
3 Replies
sstrell
Honored Contributor II
146 Views

A base clock would not have a master_clock_pin.  With a generated clock, you can use the -master_clock option to select a source clock if there are multiple clocks at the source. 

In your create_generated_clock command, you don't even need the -master_clock option since there's only one clock at the source.

Diego2
Novice
138 Views

I see.

If that's the case, is there any other command I could use to get the source pin/port of a base clock (or any clock)? My intent is to have an automated script that generates new clocks like this. In this case 'get_clock_source_pins' is just a dummy placeholder function.

tcl> create_generated_clock -source [get_clock_source_pins my_clk] -name ...

 

Thanks!

sstrell
Honored Contributor II
133 Views

Not that I know of.  If you've created a clock with create_clock, you targeted it to an I/O port (get_ports) so that would be the source for any generated clock you create (unless you create generated clocks based on other generated clocks).

If we're talking about PLLs, you can simply use derive_pll_clocks instead.

Reply