00001 --**************************************************************
00002 --* *
00003 --* The source code for the ATLAS BCM "AAA" FPGA is made *
00004 --* available via the GNU General Public License (GPL) *
00005 --* unless otherwise stated below. *
00006 --* *
00007 --* In case of problems/questions/bug reports etc. please *
00008 --* contact michael.niegl@cern.ch *
00009 --* *
00010 --**************************************************************
00011
00012 --**************************************************************
00013 --* *
00014 --* $Source: /local/reps/bcmfpga/bcm_aaa/bcm_aaa/rio/delay_adj.vhd,v $*
00015 --* $Revision: 1.8.2.4 $ *
00016 --* $Name: dev $ *
00017 --* $Author: mniegl $ *
00018 --* $Date: 2008/11/03 17:57:47 $ *
00019
00020
00021 --* *
00022 --**************************************************************
00023
00024 library ieee;
00025
00026 use ieee.std_logic_1164.all;
00027
00028 use ieee.std_logic_arith.all;
00029
00030 use ieee.std_logic_unsigned.all;
00031
00032
00033
00034
00035 entity delay_adj is
00036 port (
00037 CLK : in ;
00038 A : in (31 downto 0);
00039 B : in (31 downto 0);
00040 X : out (31 downto 0);
00041 Y : out (31 downto 0);
00042 ADJ_TIME_1 : in range 0 to 32;
00043 ADJ_TIME_2 : in range 0 to 32
00044 );
00045 end delay_adj;
00046
00047
00048
00049
00050 architecture delay_adj_arc of delay_adj is
00051
00052 signal a_i : (63 downto 0) := (others => '0');
00053 signal b_i : (63 downto 0) := (others => '0');
00054
00055 begin
00056
00057
00058 process(CLK)
00059 begin
00060 if CLK'event and CLK = '1' then
00061 a_i <= A & a_i(63 downto 32);
00062 b_i <= B & b_i(63 downto 32);
00063 X <= a_i(63-ADJ_TIME_1 downto 32-ADJ_TIME_1);
00064 Y <= b_i(63-ADJ_TIME_2 downto 32-ADJ_TIME_2);
00065 end if;
00066 end process;
00067
00068 end delay_adj_arc;