C
Chris Waugh
Guest
Can anyone please tell me how to give one clock cycle in VHDL testbench? The output result some come with one clock cycle. How can I do that?
Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
clk_processrocess
begin
clk <= '0';
wait for clk_period/2;
clk <= '1';
wait for clk_period/2;
end process;
-- Stimulus process
stim_proc: process
begin
-- hold reset state for 100 ns.
wait for 5 ns;
reset <= '1';
wait for 10 ns;
reset <= '0';
wait for 10 ns;
a <= "1011011111101110000001010101111111100001101010000111111000000111100000011110101010101100111010011100101010111101011110001010111100101011000010101101011010101111010";
-- insert stimulus here
wait;
end process;
------
This is the testbench. I am using a 163-bit data to get a result of 163-bit output. But the whole output result must take only one clock cycle. Could you please tell me what are the modification I need here?
clk_processrocess
begin
clk <= '0';
wait for clk_period/2;
clk <= '1';
wait for clk_period/2;
end process;
-- Stimulus process
stim_proc: process
begin
-- hold reset state for 100 ns.
wait for 5 ns;
reset <= '1';
wait for 10 ns;
reset <= '0';
wait for 10 ns;
a <= "1011011111101110000001010101111111100001101010000111111000000111100000011110101010101100111010011100101010111101011110001010111100101011000010101101011010101111010";
-- insert stimulus here
wait;
end process;
------
This is the testbench. I am using a 163-bit data to get a result of 163-bit output. But the whole output result must take only one clock cycle. Could you please tell me what are the modification I need here?