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

Subversion Repositories xmatchpro

[/] [xmatchpro/] [trunk/] [xmw4-comdec/] [src/] [cam_byte_first.vhd] - Blame information for rev 8

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 8 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       = CAM_BYTE    --
19
--  version      = 1.0         --
20
--  last update  = 14/06/98    --
21
--  author       = Jose Nunez  --
22
---------------------------------
23
 
24
 
25
-- FUNCTION
26
-- single byte CAM element
27
 
28
 
29
--  PIN LIST
30
--  SEARCH   = input search data byte
31
--  PREVIOUS = data from the previous location in the array
32
--  CLEAR    = asynchronous clear of the data latches (active LOW)
33
--  CLK      = master clock
34
--  DOUT     = output of the data latches
35
--  MATCH    = indicates a match between search byte and data byte (active LOW)
36
 
37
 
38
library ieee;
39
use ieee.std_logic_1164.all;
40
 
41
entity CAM_BYTE_FIRST is
42
port
43
(
44
        SEARCH : in bit_vector(7 downto 0);
45
        PREVIOUS : in bit_vector(7 downto 0);
46
        CLEAR : in bit ;
47
        RESET: in bit;
48
        CLK : in bit ;
49
        DOUT : out bit_vector(7 downto 0);
50
        MATCH : out bit
51
);
52
end CAM_BYTE_FIRST;
53
 
54
architecture BYTE1 of CAM_BYTE_FIRST is
55
 
56
component CAM_BIT_FIRST
57
port
58
(
59
        SEARCH : in bit;
60
        PREVIOUS : in bit;
61
        CLEAR : in bit ;
62
        RESET: in bit;
63
        CLK : in bit ;
64
        DOUT : out bit;
65
        MATCH : out bit
66
);
67
end component;
68
 
69
signal MATCH_BITS : bit_vector(7 downto 0);
70
 
71
begin
72
 
73
GEN_BYTE : for I in 0 to 7 generate
74
    BIT : CAM_BIT_FIRST port map (SEARCH => SEARCH(I),
75
                            PREVIOUS => PREVIOUS(I),
76
                            CLEAR => CLEAR,
77
                                RESET=>RESET,
78
                            CLK => CLK,
79
                            DOUT => DOUT(I),
80
                            MATCH => MATCH_BITS(I));
81
end generate;
82
 
83
MATCH <= MATCH_BITS(7) or MATCH_BITS(6) or
84
         MATCH_BITS(5) or MATCH_BITS(4) or
85
         MATCH_BITS(3) or MATCH_BITS(2) or
86
         MATCH_BITS(1) or MATCH_BITS(0);
87
 
88
end BYTE1;
89
 

powered by: WebSVN 2.1.0

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