-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathTB.vhd
45 lines (36 loc) · 876 Bytes
/
TB.vhd
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
33
34
35
36
37
38
39
40
41
42
43
44
45
library ieee;
use IEEE.std_logic_1164.all;
use IEEE.std_logic_arith.all;
library work;
use work.std_logic_arithext.all;
--datapath entity
entity TB is
port(
x:out std_logic_vector(7 downto 0);
y:out std_logic_vector(7 downto 0);
start:out std_logic
);
end TB;
--signal declaration
architecture RTL of TB is
signal start_int:std_logic;
signal x_int:std_logic_vector(7 downto 0);
signal y_int:std_logic_vector(7 downto 0);
begin
--combinational logics
dpCMB: process (start_int,x_int,y_int)
begin
start_int <= '0';
x_int <= (others=>'0');
y_int <= (others=>'0');
x <= (others=>'0');
y <= (others=>'0');
start <= '0';
start <= start_int;
x <= x_int;
y <= y_int;
start_int <= '1';
x_int <= conv_std_logic_vector(14,8);
y_int <= conv_std_logic_vector(4,8);
end process dpCMB;
end RTL;