debouncing example
[hwmod.git] / debouncing / src / event_counter_pkg.vhd
diff --git a/debouncing/src/event_counter_pkg.vhd b/debouncing/src/event_counter_pkg.vhd
new file mode 100644 (file)
index 0000000..bf0c2f7
--- /dev/null
@@ -0,0 +1,19 @@
+library ieee;\r
+use ieee.std_logic_1164.all;\r
+\r
+package event_counter_pkg is\r
+  component event_counter is\r
+    generic\r
+    (\r
+      CNT_WIDTH : integer range 4 to integer'high;\r
+      RESET_VALUE : std_logic\r
+    );\r
+    port\r
+    (\r
+      sys_clk : in std_logic;\r
+      sys_res_n : in std_logic;\r
+      sense : in std_logic;\r
+      cnt : out std_logic_vector(CNT_WIDTH - 1 downto 0)\r
+    );\r
+  end component event_counter;\r
+end package event_counter_pkg;
\ No newline at end of file