From: hadaq Date: Wed, 27 Mar 2013 08:06:57 +0000 (+0000) Subject: new entity for rising edge detection - cu X-Git-Url: https://jspc29.x-matter.uni-frankfurt.de/git/?a=commitdiff_plain;h=a3c355e28a0ad5bc2ec99813725836dfaa10fed1;p=trb3.git new entity for rising edge detection - cu --- diff --git a/tdc_releases/tdc_v1.1.1/risingEdgeDetect.vhd b/tdc_releases/tdc_v1.1.1/risingEdgeDetect.vhd new file mode 100644 index 0000000..8f46a48 --- /dev/null +++ b/tdc_releases/tdc_v1.1.1/risingEdgeDetect.vhd @@ -0,0 +1,18 @@ +library IEEE; +use IEEE.STD_LOGIC_1164.all; + +entity risingEdgeDetect is + port ( + CLK : in std_logic; + SIGNAL_IN : in std_logic; + PULSE_OUT : out std_logic); +end risingEdgeDetect; + +architecture Behavioral of risingEdgeDetect is + + signal signal_d : std_logic; + +begin + signal_d <= SIGNAL_IN when rising_edge(CLK); + PULSE_OUT <= (not signal_d) and SIGNAL_IN when rising_edge(CLK); +end Behavioral;