devices.vhd

来自「The GRLIB IP Library is an integrated se」· VHDL 代码 · 共 131 行

VHD
131
字号
------------------------------------------------------------------------------- Entity: 	devices-- File:	devices.vhd-- Author:	Jiri Gaisler, Gaisler Research-- Description:	Vendor and devices id's for amba plug&play------------------------------------------------------------------------------library ieee;use ieee.std_logic_1164.all;library amba;use amba.types.all;-- pragma translate_offuse std.textio.all;-- pragma translate_onpackage devices is-- Vendor codes  constant VENDOR_GAISLER   : amba_vendor_type := 16#01#;  constant VENDOR_PENDER    : amba_vendor_type := 16#02#;  constant VENDOR_ESA       : amba_vendor_type := 16#04#;  constant VENDOR_OPENCORES : amba_vendor_type := 16#08#;constant VENDOR_EXAMPLE : amba_vendor_type := 16#1F#;
-- Gaisler Research device id's  constant GAISLER_LEON3     : amba_device_type := 16#003#;  constant GAISLER_LEON3DSU  : amba_device_type := 16#004#;  constant GAISLER_APBMST    : amba_device_type := 16#006#;  constant GAISLER_AHBUART   : amba_device_type := 16#007#;  constant GAISLER_SRCTRL    : amba_device_type := 16#008#;  constant GAISLER_SDCTRL    : amba_device_type := 16#009#;  constant GAISLER_APBUART   : amba_device_type := 16#00C#;  constant GAISLER_IRQMP     : amba_device_type := 16#00D#;  constant GAISLER_AHBRAM    : amba_device_type := 16#00E#;  constant GAISLER_GPTIMER   : amba_device_type := 16#011#;  constant GAISLER_PCITRG    : amba_device_type := 16#012#;  constant GAISLER_PCISBRG   : amba_device_type := 16#013#;  constant GAISLER_PCIFBRG   : amba_device_type := 16#014#;  constant GAISLER_PCITRACE  : amba_device_type := 16#015#;  constant GAISLER_DMACTRL   : amba_device_type := 16#016#;  constant GAISLER_AHBTRACE  : amba_device_type := 16#017#;  constant GAISLER_DSUCTRL   : amba_device_type := 16#018#;  constant GAISLER_AHBMST_EM : amba_device_type := 16#040#;  constant GAISLER_AHBSLV_EM : amba_device_type := 16#041#;
constant EXAMPLE_AHB    : amba_device_type := 16#001#;
-- European Space Agency device id's  constant ESA_LEON2        : amba_device_type := 16#002#;  constant ESA_MCTRL        : amba_device_type := 16#00F#;-- Opencores device id's  constant OPENCORES_PCIBR  : amba_device_type := 16#004#;  constant OPENCORES_ETHMAC : amba_device_type := 16#005#;-- pragma translate_off  subtype vendor_description is string(1 to 24);  type vendor_table_type is array (0 to 31) of vendor_description;
constant vendor_table : vendor_table_type := (
  VENDOR_GAISLER   => "Gaisler Research        ",
  VENDOR_PENDER    => "Pender Electronic Design",
  VENDOR_ESA       => "European Space Agency   ",
  VENDOR_OPENCORES => "Opencores               ",
  VENDOR_EXAMPLE   => "Example Company Name    ",
  others           => "Unknown Vendor          ");

  subtype device_description is string(1 to 31);  type device_table_type is array (0 to 1023) of device_description;  type device_vendor_type is array (0 to 31) of device_table_type;  constant gaisler_device_table : device_table_type := (   GAISLER_LEON3     => "Leon3 SPARC V8 Processor       ",   GAISLER_LEON3DSU  => "Leon3 Debug Support Unit       ",   GAISLER_AHBRAM    => "Generic AHB SRAM module        ",   GAISLER_APBMST    => "AHB/APB Bridge                 ",   GAISLER_AHBUART   => "AHB Debug UART                 ",   GAISLER_SRCTRL    => "Simple SRAM Controller         ",   GAISLER_SDCTRL    => "PC133 SDRAM Controller         ",   GAISLER_APBUART   => "Generic UART                   ",   GAISLER_IRQMP     => "Multi-processor Interrupt Ctrl.",   GAISLER_GPTIMER   => "Modular Timer Unit             ",   GAISLER_PCITRG    => "Simple 32-bit PCI Target       ",   GAISLER_PCISBRG   => "Simple 32-bit PCI Bridge       ",   GAISLER_PCIFBRG   => "Fast 32-bit PCI Bridge         ",   GAISLER_PCITRACE  => "32-bit PCI Trace Buffer        ",   GAISLER_DMACTRL   => "AMBA DMA controller            ",   GAISLER_AHBTRACE  => "AMBA Trace Buffer              ",   GAISLER_DSUCTRL   => "DSU/ETH controller             ",   GAISLER_AHBMST_EM => "AMBA Master Emulator           ",   GAISLER_AHBSLV_EM => "AMBA Slave Emulator            ",   others            => "Unknown Device                 ");  constant esa_device_table : device_table_type := (   ESA_LEON2        => "Leon2 SPARC V8 Processor       ",   ESA_MCTRL        => "Leon2 Memory Controller        ",   others           => "Unknown Device                 ");  constant opencores_device_table : device_table_type := (   OPENCORES_PCIBR  => "32-bit PCI Bridge              ",   OPENCORES_ETHMAC => "10/100-Mbit Ethernet MAC       ",   others           => "Unknown Device                 ");  constant unknown_device_table : device_table_type := (   others           => "Unknown Vendor/Device          ");constant example_device_table : device_table_type := (
  EXAMPLE_AHB      => "AHB memory example             ",
  others           => "Unknown Vendor/Device          ");

constant amba_device_table : device_vendor_type := (
  VENDOR_GAISLER   => gaisler_device_table,
  VENDOR_ESA       => esa_device_table,
  VENDOR_OPENCORES => opencores_device_table,
  VENDOR_EXAMPLE   => example_device_table,
  others           => unknown_device_table);-- pragma translate_onend;

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?