Created
September 25, 2019 18:03
-
-
Save RyanFleck/367bddbb1c40bf82cec04d902782e964 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
--- CEG3155 Lab 2 material. | |
library IEEE; | |
use IEEE.Std_Logic_1164.all; | |
entity halfadder is | |
port ( | |
A, B : in std_logic; | |
sum, carry : out std_logic | |
); | |
end halfadder; | |
architecture halfadder_arch of halfadder is | |
begin | |
sum <= A xor B; | |
carry <= A and B; | |
end halfadder_arch; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment