diff options
author | crupest <crupest@outlook.com> | 2021-11-09 17:44:15 +0800 |
---|---|---|
committer | crupest <crupest@outlook.com> | 2021-11-09 17:44:15 +0800 |
commit | 18d160e7575374a73b4fd22ec5cc98690105aa69 (patch) | |
tree | 4c82112f0c4908895901330ea0199976e87ec90a /computer-organization-experiment/full_adder_1.vhdl | |
parent | 4474947842a39dc2497cb0156a76fadd39443d88 (diff) | |
download | life-18d160e7575374a73b4fd22ec5cc98690105aa69.tar.gz life-18d160e7575374a73b4fd22ec5cc98690105aa69.tar.bz2 life-18d160e7575374a73b4fd22ec5cc98690105aa69.zip |
...
Diffstat (limited to 'computer-organization-experiment/full_adder_1.vhdl')
-rw-r--r-- | computer-organization-experiment/full_adder_1.vhdl | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/computer-organization-experiment/full_adder_1.vhdl b/computer-organization-experiment/full_adder_1.vhdl new file mode 100644 index 0000000..9b269bf --- /dev/null +++ b/computer-organization-experiment/full_adder_1.vhdl @@ -0,0 +1,13 @@ +LIBRARY IEEE; +USE IEEE.STD_LOGIC_1164.ALL; +USE IEEE.STD_LOGIC_UNSIGNED.ALL; + +entity full_adder_1 is + port (A, B, CI:in std_logic; S, CO: out std_logic); +end full_adder_1; + +architecture behavior of full_adder_1 is +begin + S <= (A XOR B) XOR CI; + CO <= (A AND B) OR (B AND CI) OR (CI AND A); +end architecture; |