Altera_Forum
Honored Contributor
8 years agoDQS Input and Output Timing Constraints
Greetings,
I have a DDR controller which has a bidirectional DQS (data strobe) signal. In read states, the DDR device is driving DQS, as well as some data bits which have timing relationship to the input DQS. In write states, the FPGA drives DQS as well as some data bits which have a different timing relationship to the output DQS. During writes, I have the data bits being clocked out with a 0-degree clock, and the DQS line is being clocked out with a 90-degree version of the same clock. This helps center the data eye around the outgoing DQS clock. Here's what I've tried:# Input Constraints
create_clock -name CLK_ddr_ldqs_INPUT -period $DDR_CLK_PERIOD
create_clock -name virt_clk -period $DDR_CLK_PERIOD
set_multicycle_path 0 -from virt_clk -to CLK_ddr_ldqs_INPUT
set_input_delay -clock virt_clk $tDQSQ -max
set_input_delay -clock virt_clk -$tQHmin -min
set_input_delay -clock virt_clk $tDQSQ -max -clock_fall -add_delay
set_input_delay -clock virt_clk -$tQHmin -min -clock_fall -add_delay
# Output Constraints
set CLK_ddr_ldqs_n_OUTL CLK_ddr_ldqs_INPUT;
set_output_delay -clock $CLK_ddr_ldqs_n_OUTL $tDS -max
set_output_delay -clock $CLK_ddr_ldqs_n_OUTL -$tDH -min
set_output_delay -clock $CLK_ddr_ldqs_n_OUTL $tDS -max -clock_fall -add_delay
set_output_delay -clock $CLK_ddr_ldqs_n_OUTL -$tDH -min -clock_fall -add_delay
The problem is, when I look at the timing path in TimeQuest, I see the output path: From Node: inst5|altpll_component|auto_generated|pll1|clk[0] To Node: ddr_dq[12] Launch Clock: inst5|altpll_component|auto_generated|pll1|clk[0] Latch Clock: CLK_ddr_udqs_INPUT (clk[0] is the 0-degree clock) but in the "Waveform" viewer, it is showing that the Launch clock and Latch clock are the same (there is no 90-degree phase shift). i tried replacing set CLK_ddr_ldqs_n_OUTL CLK_ddr_ldqs_INPUT; with : create_generated_clock -name CLK_ddr_ldqs_n_OUTL -source { inst5|altpll_component|auto_generated|pll1|clk } (clk[3] is the 90-degree clock) But I get the warning: Warning (332049): Ignored create_generated_clock at DDRCtrlTimingConstraints.sdc(327): Incorrect assignment for clock. Source node: ddr_ldqs_n already has a clock(s) assigned to it. Use the -add option to assign multiple clocks to this node. Clock was not created or updated. which ultimately leads to an error Error (332000): can't read "CLK_ddr_ldqs_n_OUTL": no such variable. I tried doing what it said and adding the "-add" flag. While this does get rid of the warning, it still doesn't get rid of the error. What's the right move here?