Forum Discussion

sean793's avatar
sean793
Icon for New Contributor rankNew Contributor
11 days ago
Solved

MAX10 Soft SERDES set_input_delay constraints

Hello,

I am planning on driving the MAX10 Soft SERDES input with a data rate of 720Mbps and a corresponding PLL reference input clock of 180MHz.  

I also plan on generating the serial data stream in the source FPGA device using DDR flip flops packed into IO blocks and treating the clock as a signal and generating the output clock by using DDR flip flops tied to logic '1' and '0' thereby guaranteeing that the tCO of both the serial data output and the tCO of the clock signal output are well matched with minimal skew.  I expect the skew to be no more than +/-150ps from the source device's data sheet.

I was constraining the MAX10 Soft SERDES data intput this way:

# Configured the soft serdes to run at 720Mbps input rate.

# 720/4 = 180MHz is the serdes input reference clock rate chosen

create_clock -name i_clk -period 5.555 [get_ports {i_clk}]

 

derive_pll_clocks

 

set_input_delay -clock i_clk -max 0.150 [get_ports {i_data}]

set_input_delay -clock i_clk -min -0.150 [get_ports {i_data}]

 

set_input_delay -clock i_clk -max 0.150 [get_ports {i_rst_l}]

set_input_delay -clock i_clk -min -0.150 [get_ports {i_rst_l}]

 

After timing analysis the tool reports in the Multi-Corner Timing Analysis Summary that the Worst Case Slack is as follows

Setup = -0.472, Hold = 0.195, Recovery = -2.610, and Removal = 1.149

What am I doing wrong that causes the negative Setup and Recovery slacks?

 

3 Replies

  • sean793's avatar
    sean793
    Icon for New Contributor rankNew Contributor

    After examining the Soft SERDES core parameters in the MegaWizard GUI I found that the PLL can phase shift the clock relationship between the input reference clock and the generated clock used to sample the data.  I set it to 45 degrees and recompiled and found that for the most part I meet timing.  See attached report.  However I don't meet the worst case slack for Recovery for pll clk[0].  Since Recovery Time applies only to asynchronously applied signals, does this mean that my reset input to the FPGA and hence to the PLL is failing timing?  Also, is this approach of manually adjusting the PLL phase shift until timing is met correct?  I would have thought this would be automatic by the Quartus Prime Standard Edition tool.

  • RichardT_altera's avatar
    RichardT_altera
    Icon for Super Contributor rankSuper Contributor

    Does the Recovery violation mean the PLL reset is failing timing?
    Yes — but only because it might have been constrained incorrectly.
    Is i_rst_l  an asynchronous reset? 
    Asynchronous resets are not clocked inputs and must not be constrained using set_input_delay. Applying input delay constraints to an async reset causes the timing analyzer to treat the reset as if it were data, which might lead to Recovery or Removal timing violations.
    This is what I am suspecting to be the cause.


    Additionally, you should use a virtual clock for source‑synchronous interface constraints.
    Checkout the AN 433: Constraining and Analyzing Source-Synchronous Interfaces
    https://cdrdv2-public.intel.com/653688/an433.pdf

    You may checkout this user guide on how to Applying Input Delay Constraint for LVDS SERDES Receiver
    https://docs.altera.com/r/docs/683760/24.1/max-10-high-speed-lvds-i/o-user-guide/initializing-the-soft-lvds-ip-core?tocId=qCaxGpfsxdGb1RUBaR9ShQ

    Regards,
    Richard Tan

    • sean793's avatar
      sean793
      Icon for New Contributor rankNew Contributor

      Thanks Richard,  that answered the question and by constraining the interface using a virtual clock as called out for source synchronous DDR interfaces in AN433 I was able to get a more realistic timing report.  The reset was constrained and I removed that.  I also lowered my data and clock rate from 720 to 640Mbps because I found that because the phase adjustment has a step size of 45 degrees at 720MHz, the phase couldn't be set to get a reasonable setup time.  At 640MHz the step size is 22.5 degrees and by setting the phase to 90 degrees and iteratively adjusting the input delay parameter on the IO I was able to maximize the setup time.

      Again, thank you for your help.

      Sean