aboutsummaryrefslogtreecommitdiffstats
path: root/testsuite/gna/issue542/write.vhd
blob: d7c1fd12921e2d00090ddfe1cc9e172c4647b5f9 (plain)
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
library ieee;
use ieee.std_logic_1164.all;
use ieee.numeric_std.all;

entity write is
	port(
	clk   : in std_logic;
	reset : in std_logic;
	write : in std_logic;
	ack   : out std_logic
);
end write;

architecture a of write is
begin

	process (clk, reset) is
	begin
		if reset = '1' then
			ack <= '0';
		elsif rising_edge(clk) then
			if write = '1' then
				ack <= '1';
			else
				ack <= '0';
			end if;
		end if;
	end process;

end architecture;