Dec 13, 2009 #1 S spartanthewarrior Full Member level 2 Joined Jun 13, 2007 Messages 122 Helped 0 Reputation 0 Reaction score 0 Trophy points 1,296 Activity points 2,142 Hi all, How can i create 4 clock cycle delay in my design.
Dec 14, 2009 #2 S skyfaye Member level 5 Joined Feb 25, 2008 Messages 82 Helped 25 Reputation 50 Reaction score 11 Trophy points 1,288 Activity points 1,876 Is this what you wanted? Note, you don't really need reset in the delay FFs. always @(posedge clk) begin wr_d1 <= #1 wr; // wr is the signal you want to delay wr_d2 <= #1 wr_d1; wr_d3 <= #1 wr_d2; wr_d4 <= #1 wr_d3; end
Is this what you wanted? Note, you don't really need reset in the delay FFs. always @(posedge clk) begin wr_d1 <= #1 wr; // wr is the signal you want to delay wr_d2 <= #1 wr_d1; wr_d3 <= #1 wr_d2; wr_d4 <= #1 wr_d3; end
Dec 14, 2009 #3 AdvaRes Advanced Member level 4 Joined Feb 14, 2008 Messages 1,163 Helped 113 Reputation 220 Reaction score 51 Trophy points 1,328 Location At home Activity points 7,442 spartanthewarrior said: Hi all, How can i create 4 clock cycle delay in my design. Click to expand... Use a simple counter.
spartanthewarrior said: Hi all, How can i create 4 clock cycle delay in my design. Click to expand... Use a simple counter.