A 4-bit ALU supporting 8 operations (OP 0..7: add, subtract, AND, OR, XOR, NOT A, A+1, pass A) with carry-out and zero flag.

LogicLab: p31_alu

Try this

  1. Click bus inputs A, B and OP to test addition (OP=0) and subtraction (OP=1).
  2. Try OP=1 with A equal to B to see the Zero flag light up.
Última alteração: quarta-feira, 2 de dezembro de 2026 às 21:54