From 4a7cdf72dc65dd01604084d2b647c8bf4ea7adfe Mon Sep 17 00:00:00 2001 From: Vladimir Burian Date: Tue, 15 Feb 2011 18:52:55 +0100 Subject: [PATCH] RAM modified and *.bmm added. RAM is expanded to 16 KB. Template of *.bmm file is added so the content of memories can be filled with data from *.elf file using data2mem tool. --- vhdl/ram_xilinx.bmm | 30 ++++++++++++++++++++++++++++++ vhdl/ram_xilinx.vhd | 2 +- 2 files changed, 31 insertions(+), 1 deletion(-) create mode 100644 vhdl/ram_xilinx.bmm diff --git a/vhdl/ram_xilinx.bmm b/vhdl/ram_xilinx.bmm new file mode 100644 index 0000000..51bf3c9 --- /dev/null +++ b/vhdl/ram_xilinx.bmm @@ -0,0 +1,30 @@ +// Mapping of BRAMs used by Plasma MIPS +// in file "ram_xilinx.vhd" +// +// Currently 16 KB are mapped. +//================================================ +// WARNING !!! +// "???" signs must be replaced by logical path from +// the top-level desing to the Plasma MIPS instance. +// +// E.g. you have top-level with Plasma MIPS instance +// named "plasma_1". Then "???" => "plasma_1". + +ADDRESS_SPACE plasma_ram RAMB16 [0x0000:0x3fff] + + BUS_BLOCK + ???/u2_ram/block0.ram_byte3 [31:24]; + ???/u2_ram/block0.ram_byte2 [23:16]; + ???/u2_ram/block0.ram_byte1 [15:8]; + ???/u2_ram/block0.ram_byte0 [7:0]; + END_BUS_BLOCK; + + BUS_BLOCK + ???/u2_ram/block1.ram_byte3 [31:24]; + ???/u2_ram/block1.ram_byte2 [23:16]; + ???/u2_ram/block1.ram_byte1 [15:8]; + ???/u2_ram/block1.ram_byte0 [7:0]; + END_BUS_BLOCK; + +END_ADDRESS_SPACE; + diff --git a/vhdl/ram_xilinx.vhd b/vhdl/ram_xilinx.vhd index a1f2a03..6bfb3cf 100644 --- a/vhdl/ram_xilinx.vhd +++ b/vhdl/ram_xilinx.vhd @@ -44,7 +44,7 @@ use UNISIM.vcomponents.all; entity ram is generic(memory_type : string := "DEFAULT"; --Number of 8KB blocks of internal RAM, up to 64KB (1 to 8) - block_count : integer := 1); + block_count : integer := 2); port(clk : in std_logic; enable : in std_logic; write_byte_enable : in std_logic_vector(3 downto 0); -- 2.39.2