test bench D_ff in VHDL
salve a tutti volevo chiedervi se secondo voi un test bench cosi va bene in VHDL per un flip flop di tipo D con ingresso D,segnale di clock CLK e un RESET ed uscita Q
- Codice: Seleziona tutto
entity testbench is
end testbench;
architecture behavior of testbench is
component D_ff
port(D,CLK,RESET:in bit;
Q:out bit);
end component;
signal a,b,c,d:bit;
constant c_period:=10ns
begin
UUT: D_ff port map (
D=>a,
RESET=>b,
Q=>d
);
a_pr:process
begin
a<='0' ;
wait for 15 ns;
a<='1';
wait for 10 ns;
end process;
b_pr:process
begin
b<='1';
wait for 50 ns;
b<='0';
wait for 200 ns;
end proces;
end behavior;