OpenCores
URL https://opencores.org/ocsvn/xmatchpro/xmatchpro/trunk

Subversion Repositories xmatchpro

[/] [xmatchpro/] [trunk/] [xmw4-comdec/] [xmatch_sim7/] [src/] [oda_register_d.vhd] - Blame information for rev 9

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 9 eejlny
--This library is free software; you can redistribute it and/or
2
--modify it under the terms of the GNU Lesser General Public
3
--License as published by the Free Software Foundation; either
4
--version 2.1 of the License, or (at your option) any later version.
5
 
6
--This library is distributed in the hope that it will be useful,
7
--but WITHOUT ANY WARRANTY; without even the implied warranty of
8
--MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
9
--Lesser General Public License for more details.
10
 
11
--You should have received a copy of the GNU Lesser General Public
12
--License along with this library; if not, write to the Free Software
13
--Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
14
 
15
-- e_mail : j.l.nunez-yanez@byacom.co.uk
16
 
17
---------------------------------
18
--  ENTITY       = ODA_REGISTER--
19
--  version      = 1.0         --
20
--  last update  = 19/09/99    --
21
--  author       = Jose Nunez  --
22
---------------------------------
23
 
24
 
25
-- FUNCTION
26
-- register that creates the out of order adaptation mechanism
27
 
28
-- PIN MAP
29
 
30
-- MOVE_IN : current move vector
31
-- CONTROL : decides if the vector is loaded directly or one position down
32
-- CLK : clock signal
33
-- RESET : reset signal
34
-- MOVE_OUT : previous move vector
35
 
36
library IEEE;
37
use IEEE.std_logic_1164.all;
38
 
39
entity ODA_REGISTER_D is
40
port    (
41
                        MOVE_IN : in bit_vector(15 downto 0);
42
                        MOVE_ENABLE : in bit;
43
                        CONTROL : in bit_vector(14 downto 0);
44
                        CLK : in bit;
45
                        CLEAR : in bit;
46
                        RESET : in bit;
47
                        MOVE_OUT : out bit_vector(15 downto 0)
48
                );
49
end ODA_REGISTER_D;
50
 
51
architecture STRUCTURAL of ODA_REGISTER_D is
52
 
53
component ODA_CELL_2_D_1
54
port    (
55
                        PREVIOUS : in bit;
56
                        MOVE_ENABLE : in bit;
57
                        CONTROL : in bit;
58
                        ACTUAL : in bit;
59
                        CLK : in bit;
60
                        CLEAR : in bit;
61
                        RESET : in bit;
62
                        MOVE_OUT : out bit
63
                );
64
end component;
65
 
66
component ODA_CELL_2_D
67
port    (
68
                        PREVIOUS : in bit;
69
                        MOVE_ENABLE : in bit;
70
                        CONTROL : in bit;
71
                        ACTUAL : in bit;
72
                        CLK : in bit;
73
                        CLEAR : in bit;
74
                        RESET : in bit;
75
                        MOVE_OUT : out bit
76
                );
77
end component;
78
 
79
 
80
signal zero : bit;
81
 
82
begin
83
 
84
zero <='0';
85
 
86
PRI_DEC : for I in 15 downto 0 generate
87
        FIRST : if (I=15) generate
88
        CELL_1 : ODA_CELL_2_D
89
                port map( PREVIOUS => zero,
90
                                  MOVE_ENABLE => MOVE_ENABLE,
91
                                  CONTROL => CONTROL(0),
92
                          ACTUAL => MOVE_IN(15),
93
                                  CLK => CLK,
94
                                  CLEAR => CLEAR,
95
                                  RESET => RESET,
96
                                  MOVE_OUT => MOVE_OUT(15)
97
                                  );
98
         end generate;
99
       SECOND : if (I=14) generate
100
         CELL_2 : ODA_CELL_2_D_1
101
                port map( PREVIOUS => MOVE_IN(15),
102
                                  MOVE_ENABLE => MOVE_ENABLE,
103
                                  CONTROL => CONTROL(0),
104
                          ACTUAL => MOVE_IN(14),
105
                                  CLK => CLK,
106
                                  CLEAR => CLEAR,
107
                                  RESET => RESET,
108
                                  MOVE_OUT => MOVE_OUT(14)
109
                                  );
110
         end generate;
111
         REMAINING : if (I<14) generate
112
         REST : ODA_CELL_2_D
113
                port map( PREVIOUS => MOVE_IN(I+1),
114
                                  MOVE_ENABLE => MOVE_ENABLE,
115
                                  CONTROL => CONTROL(14-I),
116
                          ACTUAL => MOVE_IN(I),
117
                                  CLK => CLK,
118
                                  CLEAR => CLEAR,
119
                                  RESET => RESET,
120
                                  MOVE_OUT => MOVE_OUT(I)
121
                                  );
122
         end generate;
123
end generate;
124
 
125
end STRUCTURAL;

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.