-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathTH23.vhd
More file actions
33 lines (32 loc) · 1022 Bytes
/
TH23.vhd
File metadata and controls
33 lines (32 loc) · 1022 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
-- TH23.vhd
-- N=3 M=2
--
-- Z <= AB + AC + BC
------------------------------------------------------------
------------------------------------------------------------
------------------------------------------------------------
library ieee,work;
use ieee.std_logic_1164.all;
entity TH23 is
port(A,B,C: in std_logic;
Z: out std_logic);
end ;
architecture STRUCTURAL of TH23 is
component LUT4
generic(M : std_logic_vector(15 downto 0):="0000000000000000");
port(I: in std_logic_vector(3 downto 0);
O: out std_logic);
end component; -- LUT4
signal ZERO : std_logic;
signal FB : std_logic;
begin
------------------------------------------------------------
ZERO <= '0';
-- FB 1111111100000000
-- I2 1111000011110000
-- I1 1100110011001100
-- I0 1010101010101010
L:LUT4 generic map (M => "1111111011101000")
port map (I(0) => A,I(1) => B,I(2) => C,I(3) => FB,O => FB);
Z <= FB;
end ;