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

Subversion Repositories t48

[/] [t48/] [tags/] [rel_0_4_beta/] [rtl/] [vhdl/] [system/] [syn_rom-lpm-a.vhd] - Blame information for rev 303

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 7 arniml
-------------------------------------------------------------------------------
2
--
3
-- A synchronous parametrizable ROM instantiating a standard ROM from
4
-- the Altera LPM.
5
--
6
-- $Id: syn_rom-lpm-a.vhd,v 1.1 2004-03-24 21:32:27 arniml Exp $
7
--
8
-- Copyright (c) 2004, Arnim Laeuger (arniml@opencores.org)
9
--
10
-- All rights reserved
11
--
12
-- Redistribution and use in source and synthezised forms, with or without
13
-- modification, are permitted provided that the following conditions are met:
14
--
15
-- Redistributions of source code must retain the above copyright notice,
16
-- this list of conditions and the following disclaimer.
17
--
18
-- Redistributions in synthesized form must reproduce the above copyright
19
-- notice, this list of conditions and the following disclaimer in the
20
-- documentation and/or other materials provided with the distribution.
21
--
22
-- Neither the name of the author nor the names of other contributors may
23
-- be used to endorse or promote products derived from this software without
24
-- specific prior written permission.
25
--
26
-- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
27
-- AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
28
-- THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
29
-- PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE
30
-- LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
31
-- CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
32
-- SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
33
-- INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
34
-- CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
35
-- ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
36
-- POSSIBILITY OF SUCH DAMAGE.
37
--
38
-- Please report bugs to the author, but before you do so, please
39
-- make sure that this is not a derivative work and that
40
-- you have the latest version of this file.
41
--
42
-- The latest version of this file can be found at:
43
--      http://www.opencores.org/cvsweb.shtml/t48/
44
--
45
-------------------------------------------------------------------------------
46
 
47
library ieee;
48
use ieee.std_logic_1164.all;
49
 
50
architecture lpm of syn_rom is
51
 
52
  component lpm_rom
53
    generic (
54
      LPM_WIDTH           : positive;
55
      LPM_TYPE            : string    := "LPM_ROM";
56
      LPM_WIDTHAD         : positive;
57
      LPM_NUMWORDS        : natural   := 0;
58
      LPM_FILE            : string;
59
      LPM_ADDRESS_CONTROL : string    := "REGISTERED";
60
      LPM_OUTDATA         : string    := "REGISTERED";
61
      LPM_HINT            : string    := "UNUSED"
62
    );
63
    port (
64
      address             : in  std_logic_vector(LPM_WIDTHAD-1 downto 0);
65
      inclock             : in  std_logic;
66
      memenab             : in  std_logic;
67
      q                   : out std_logic_vector(LPM_WIDTH-1 downto 0)
68
    );
69
  end component;
70
 
71
  signal one_s : std_logic;
72
 
73
begin
74
 
75
  one_s <= '1';
76
 
77
  rom_b : lpm_rom
78
    generic map (
79
      LPM_WIDTH           => 8,
80
      LPM_TYPE            => "LPM_ROM",
81
      LPM_WIDTHAD         => address_width_g,
82
      LPM_NUMWORDS        => 2 ** address_width_g,
83
      LPM_FILE            => "t48_rom.hex",
84
      LPM_ADDRESS_CONTROL => "REGISTERED",
85
      LPM_OUTDATA         => "UNREGISTERED",
86
      LPM_HINT            => "UNUSED"
87
    )
88
    port map (
89
      address  => rom_addr_i,
90
      inclock  => clk_i,
91
      memenab  => one_s,
92
      q        => rom_data_o
93
    );
94
 
95
end lpm;
96
 
97
 
98
-------------------------------------------------------------------------------
99
-- File History:
100
--
101
-- $Log: not supported by cvs2svn $
102
-------------------------------------------------------------------------------

powered by: WebSVN 2.1.0

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