Skip to content

Commit 27c351b

Browse files
committed
another try with out iddr
1 parent 0b3144d commit 27c351b

File tree

1 file changed

+23
-2
lines changed

1 file changed

+23
-2
lines changed

rtl/iddr.v

Lines changed: 23 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -122,8 +122,8 @@ if (TARGET == "XILINX") begin
122122
.RST(rst) // 1-bit input: Asynchronous Reset to the DELAY_VALUE
123123
);
124124

125-
126-
if (IODDR_STYLE == "IODDR") begin
125+
end
126+
/* if (IODDR_STYLE == "IODDR") begin
127127
IDDR #(
128128
.DDR_CLK_EDGE("SAME_EDGE_PIPELINED"),
129129
.SRTYPE("ASYNC")
@@ -161,7 +161,28 @@ if (TARGET == "XILINX") begin
161161
162162
assign q1[n] = q1_delay;
163163
end
164+
end*/
165+
reg [WIDTH-1:0] d_reg_1 = {WIDTH{1'b0}};
166+
reg [WIDTH-1:0] d_reg_2 = {WIDTH{1'b0}};
167+
168+
reg [WIDTH-1:0] q_reg_1 = {WIDTH{1'b0}};
169+
reg [WIDTH-1:0] q_reg_2 = {WIDTH{1'b0}};
170+
171+
always @(posedge clk) begin
172+
d_reg_1 <= delayed_data_int;
173+
end
174+
175+
always @(negedge clk) begin
176+
d_reg_2 <= delayed_data_int;
177+
end
178+
179+
always @(posedge clk) begin
180+
q_reg_1 <= d_reg_1;
181+
q_reg_2 <= d_reg_2;
164182
end
183+
184+
assign q1 = q_reg_1;
185+
assign q2 = q_reg_2;
165186
end else if (TARGET == "ALTERA") begin
166187
wire [WIDTH-1:0] q1_int;
167188
reg [WIDTH-1:0] q1_delay;

0 commit comments

Comments
 (0)