From 633373d0054f551158cdf668c464646bb9e6af27 Mon Sep 17 00:00:00 2001 From: Patrick Lehmann Date: Mon, 19 Dec 2022 22:11:44 +0100 Subject: Added StopWatch example for DOM and documentation testing. --- .../dom/examples/StopWatch/StopWatch.pkg.vhdl | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 testsuite/pyunit/dom/examples/StopWatch/StopWatch.pkg.vhdl (limited to 'testsuite/pyunit/dom/examples/StopWatch/StopWatch.pkg.vhdl') diff --git a/testsuite/pyunit/dom/examples/StopWatch/StopWatch.pkg.vhdl b/testsuite/pyunit/dom/examples/StopWatch/StopWatch.pkg.vhdl new file mode 100644 index 000000000..3bcafdd6d --- /dev/null +++ b/testsuite/pyunit/dom/examples/StopWatch/StopWatch.pkg.vhdl @@ -0,0 +1,21 @@ +-- Author: Patrick Lehmann +-- License: MIT +-- +-- A generic counter module used in the StopWatch example. +-- +library IEEE; +use IEEE.std_logic_1164.all; +use IEEE.numeric_std.all; + + +package StopWatch_pkg is + subtype T_BCD is unsigned(3 downto 0); + type T_BCD_Vector is array(natural range <>) of T_BCD; + + type T_DIGIT_CONFIGURATION is record + Modulo : positive; + Dot : std_logic; + end record; + + type T_STOPWATCH_CONFIGURATION is array(natural range <>) of T_DIGIT_CONFIGURATION; +end package; -- cgit v1.2.3