Beruflich Dokumente
Kultur Dokumente
testbench DUT
S Y
A Y
A1 M1 VDD
PMOS
A Y B NAND
NMOS
6.0V
VSS VSS
4.0V
INV
Pspice
2.0V
Simulaiton Digital Simulation (ModelSim)
0V
A0
V(5) V(6) V(4)
6.0V
A1
S
4.0V
A0,1 Y
nS
2.0V S Y M0
SEL>>
0V
M1
0.99us 1.00us 1.01us 1.02us 1.03us 1.04us
V(3) V(7) V(1) V(2)
Time
stimuli
clk : in std_logic; '1' after 400 ns;
component
declaration
rst_n : in std_logic;
en_n : in std_logic; d <= '0' after 0 ns,
d : in std_logic; '1' after 300 ns,
q : out std_logic); '0' after 600 ns;
end component;
en_n <= '0';
signal rst_n : std_logic;
signal d : std_logic; u1: proc1
port map(
signal en_n : std_logic; clk => clk, Component
signal q : std_logic; rst_n => rst_n,
signal clk : std_logic:= '1'; en_n => en_n, instantiation
d => d,
Initial value – only in simulations! q => q);
end;
ram_proc: process(clk)
...
begin Condition; if not fulfilled, the message after
... report will be printed
if we = '1' then
-- synthesis off
assert is_1_or_0(addr)
report "Attempt to write with undefined address"
severity WARNING;
-- synthesis on In the simulator it is possible to
mem_data(conv_integer(addr))<= din; mask/show the messages or to break
...
The synthesis tools generally the simulation, depending on the
ignore the assert, but this can severity (NOTE, WARNING, ERROR,
FAILURE)
be specified explicitly