← ProblemsCircuits / Sequential Logic / Latches and Flip-Flops
DFF with XOR feedback
36%flip-flopsproceduresImplement this circuit: a D flip-flop whose D input is driven by an XOR gate. One XOR input is the external signal in; the other is the flip-flop's own output, fed back. The flip-flop's output is out.
In other words, at every rising edge of clk: out becomes in XOR out (the value of out just before the edge).