ScratchData LogoScratchData
Back to popswilson's profile

Full-Adder Using XOR and AND Gates

POpopswilson•Created February 10, 2022
Full-Adder Using XOR and AND Gates
10
7
105 views
View on Scratch

Instructions

This project simulates a Full-Adder using the XOR and AND logic gates. Click on the yellow inputs to toggle between 0 and 1 and then click on the Green Flag to compute the outputs. The circuit then computes the Sum and Carry Out digits. Use the project to verify that the inputs do produce: Carry In Digit 0 1 1 1 0 0 0 1 Binary Digit 1 0 0 1 1 1 0 1 0 Binary Digit 2 0 0 0 1 1 1 0 1 ****************************************************** These outputs. Sum 0 1 0 1 0 1 1 0 Carry Out Digit 0 0 1 1 1 0 0 1 ****************************************************** A Full-Adder accepts a carry-in digit (either 0 or 1), computes the sum of two binary digits (either 0 or 1), and then outputs a carry-out digit (either a 0 or 1)

Description

I made a conscious effort to make the code as clear and logical as possible. I use Make a Block to model the XOR and AND gates. Each gate accepts two inputs. The output of each gate is then used as one or two inputs to the next logic gate in the logic chain. Press the See inside button where I have commented on the logic chain (note how short the code is). In our digital devices, logic transistors are used to make gates gates. A row of full-adders (called a register) can add two binary numbers of arbitrary length. See my other logic gates projects: XOR Gate https://scratch.mit.edu/projects/3270654/ NAND Gate https://scratch.mit.edu/projects/500283359/ Half-Adder https://scratch.mit.edu/projects/244661995/

Project Details

Project ID642224075
CreatedFebruary 10, 2022
Last ModifiedFebruary 19, 2022
SharedFebruary 18, 2022
Visibilityvisible
CommentsAllowed