fox32-hw/verilog-src/alu/fa.v
2024-01-12 13:44:33 +01:00

8 lines
168 B
Verilog

// One bit full-adder
module fa(input A, input B, input Cin, output O, output Cout);
assign O = A ^ B ^ Cin;
assign Cout = (A & B) | (B & Cin) | (Cin & A);
endmodule