Lecture 4 - Adders

Half adder

The output is the binary representation of how many inputs are high. This can only be 0, 1 or 2, so the outputs are 00, 01, or 10. The first (leftmost) bit is the "sum" and the second bit (rightmost) is the "carry" bit.
DCABSumCarryEORAND

Full adder

The output is again the binary representation of how many inputs are high, but now we have an incomming carry bit, so there can be 0, 1, 2 or 3.
AEORSumEORCarryInBDCANDORANDCarryOut

Full adder

Same as above, but with the numbers decoded so that you can see how this actually adds numbers.
AEORSumEORCarryInDCANDORANDCarryOutB4bit7seg4bit7seg4bit7seg4bit7seg

Ripple carry adder

Adds together two 3-bit numbers A2A1A0 and B2B1B0. Outcome is stored in S3S2S1S0
A0B0A1A2B1B2DCCinABSCoutFullAdderCinABSCoutFullAdderCinABSCoutFullAdderS0S1S2S3

Ripple carry adder with number decoders

Same as above, but with extra junk to display the encoded numbers.
A0B0A1B1B2DCCinABSCoutFullAdderCinABSCoutFullAdderCinABSCoutFullAdderS0S1S2S3ABA2S

Sand box

Build your own circuits here
InOutDCLEDPushOffPushOnToggleBUFNOTANDNANDORNOREORENOROSC7seg16seg4bit7segRotaryEncoderx8BusInx8BusOut~S~RQ~QRS-FFJCLKKQ~QJK-FFTCLKQ~QT-FFDCLKQ~QD-FFTCLKD0D1D2D3D4D5D6D78bitCounterABSCHalfAdderCinABSCoutFullAdderCinA0A1A2A3B0B1B2B3S0S1S2S3Cout4bitAdderD0D1OEA0A1A2A32to4BinaryDecoderD0D1D2OEA0A1A2A3A4A5A6A73to8BinaryDecoderD0D1D2D3OEA0x8A1x84to16BinaryDecoderAEORSumEORCarryInBDCANDORANDCarryOut