Forum Discussion

Altera_Forum's avatar
Altera_Forum
Icon for Honored Contributor rankHonored Contributor
9 years ago

about time quest constraints

Hi to all.

I have a little question.

I have cyclonevgt dev board.

I have to connect a D/A converter to pins of fpga.

I create a PLL clock out 100Mhz, routed at a pin of fpga.

I create a 14 bit data bus, routed at pins of fpga.

I have set timequest so that the data bus has 2ns setuptime and 2ns hold time, respect to the clock.

what are the commands to use?

Regards, Luca

10 Replies

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    Hi,

    there are two ways I could interpret your text:

    • the clock is generated with a PLL inside the FPGA, and an FPGA output brings it to the DAC, or

    • the clock is generated with a PLL outside the FPGA, and it is routed to an FPGA input pin as well as the DAC clock input

    The timing constraints are different for both cases.

    I suggest you to read a bit more about timing constraints, I recommend this https://www.altera.com/en_us/pdfs/literature/an/an433.pdf (https://www.altera.com/en_us/pdfs/literature/an/an433.pdf) and https://www.altera.com/content/dam/altera-www/global/en_us/pdfs/literature/manual/mnl_timequest_cookbook.pdf (https://www.altera.com/content/dam/altera-www/global/en_us/pdfs/literature/manual/mnl_timequest_cookbook.pdf).

    Best regards,

    GooGooCluster
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    --- Quote Start ---

    Hi,

    there are two ways I could interpret your text:

    • the clock is generated with a PLL inside the FPGA, and an FPGA output brings it to the DAC, or

    • the clock is generated with a PLL outside the FPGA, and it is routed to an FPGA input pin as well as the DAC clock input

    The timing constraints are different for both cases.

    I suggest you to read a bit more about timing constraints, I recommend this https://www.altera.com/en_us/pdfs/literature/an/an433.pdf and https://www.altera.com/content/dam/altera-www/global/en_us/pdfs/literature/manual/mnl_timequest_cookbook.pdf.

    Best regards,

    GooGooCluster

    --- Quote End ---

    Hi GooGooCluster!

    In my case

    • the clock is generated with a PLL inside the FPGA, and an FPGA output brings it to the DAC.

  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    --- Quote Start ---

    Hi GooGooCluster!

    In my case

    • the clock is generated with a PLL inside the FPGA, and an FPGA output brings it to the DAC.

    --- Quote End ---

    max output delay should be set to (+2ns) and min to (-2ns) assuming data and clock arrive at DAC with equal delay
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    --- Quote Start ---

    max output delay should be set to (+2ns) and min to (-2ns) assuming data and clock arrive at DAC with equal delay

    --- Quote End ---

    Thank you!

    Max and min delays are delays from data bus referenced to clock, right?

    I set it from timequest menu?
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    --- Quote Start ---

    Thank you!

    Max and min delays are delays from data bus referenced to clock, right?

    I set it from timequest menu?

    --- Quote End ---

    you put your constraints in sdc file(edit by hand or through timequest).

    reference clock should be output clock that goes to DAC (not input clock to PLL) so you need to declare the output clock.
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    --- Quote Start ---

    you put your constraints in sdc file(edit by hand or through timequest).

    reference clock should be output clock that goes to DAC (not input clock to PLL) so you need to declare the output clock.

    --- Quote End ---

    Can you write here the sdc command, for max and min delays?

    Regards, Luca
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    --- Quote Start ---

    Can you write here the sdc command, for max and min delays?

    Regards, Luca

    --- Quote End ---

    Come on Luca. Plenty examples around.

    set_output_delay -max 2 -clock dac_output_clock [get_ports DAC_Data*]

    set_output_delay -min -2 -clock dac_output_clock [get_ports DAC_Data*]
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    --- Quote Start ---

    Come on Luca. Plenty examples around.

    set_output_delay -max 2 -clock dac_output_clock [get_ports DAC_Data*]

    set_output_delay -min -2 -clock dac_output_clock [get_ports DAC_Data*]

    --- Quote End ---

    Thank you very much!
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    --- Quote Start ---

    Come on Luca. Plenty examples around.

    set_output_delay -max 2 -clock dac_output_clock [get_ports DAC_Data*]

    set_output_delay -min -2 -clock dac_output_clock [get_ports DAC_Data*]

    --- Quote End ---

    The external output clock pin (going to the dac) has name dac_clk, but does not appear in the clock list of timequest(get clocks).

    Must i declare the output pin of fpga as clock?

    how can I do?
  • Altera_Forum's avatar
    Altera_Forum
    Icon for Honored Contributor rankHonored Contributor

    --- Quote Start ---

    The external output clock pin (going to the dac) has name dac_clk, but does not appear in the clock list of timequest(get clocks).

    Must i declare the output pin of fpga as clock?

    how can I do?

    --- Quote End ---

    [create_generated_clock ...] and I don't remember syntax but there shoud be many examples around

    .