Ep 057: Latch and Flip-Flop Operation

Ep 058: Timing Diagrams of Flip-Flops and Latches

Ep 060: D Flip-Flop Divide-by-Two Circuit

Ep 061: D Flip-Flop Binary Counter/Timer Circuit

Edge Triggered

module Dff(input D, clock, output Q);
	neg Q;
	always @ (posedge clock)
		Q <= D; // assignment used for edged triggered memory (non blocking)
endmodule

Blocking

neg Q1, Q2
always @ (posedge CLK)
	begin
		Q1 = W;
		Q2 = Q1;
	end

Untitled

Non Blocking

neg Q1, Q2;
always @ (posedge clock)
	begin
		Q1 <= W;
		Q2 <= Q1;
	end

Untitled

Dff with clear and preset