Open main menu

DAVE Developer's Wiki β

BELK-AN-003: Interfacing DDR3 SDRAM to PL

Revision as of 15:05, 28 August 2015 by U0003 (talk | contribs)

Info Box
Bora5-small.jpg Applies to Bora

Contents

IntroductionEdit

Even if PL can share main SDRAM with PS, several applications need a dedicated bank for FPGA IPs in order to have exclusive access and to maximize bandwidth. In any case, since this additional SDRAM bank is accessible via AXI bus, it is mapped in the processor's memory space and thus it can be accessed by PS as well.

BoraEVB can optionally be populated with a 16-bit 512MB SDRAM chip that is directly connected to PL (1). This application note describes how to enable the support for this additional memory bank. An example Vivado design is released along with this application note, based on BELK 2.1.0 (http://wiki.dave.eu/index.php/Bora_Embedded_Linux_Kit_%28BELK%29#BELK_software_components).


(1) For more information about this option, please contact technical support (support-bora@dave.eu).

Physical interfacingEdit

The following picture shows logical connection of the SDRAM bank.

 

Please note that the BANK #35 of Zynq must be powered at 1.5V to interface DDR3 SDRAM. To do that J11.1-2 must be opened and J11.3-4 must be shorted.

Integrating memory controllerEdit

As depicted in the block diagram below, a memory controller has to be instantiated in PL to access SDRAM. This block has been generated with Memory Interface Generator (MIG) tool (http://www.xilinx.com/products/intellectual-property/mig.html).

Memory Interface Generator (MIG) is configured properly to work with Micron MT41K64M16JT-15E DDR3 memory chip at the frequency of 400MHz. It needs a precise external reference clock of 200MHz provided by an active LVDS oscillator connected on BANK #34 pins. The MIG is then connected to the PS through the AXI GP0 interface to allow user to access the external memory.


 

The Vivado example project can be downloaded from the following URL:

AN-BELK-003 Vivado project (without synthesis and implementation results)

This project requires a 200 MHz clock source. It has been tested with

  • Silicon Labs Si511BBA200M000BAG active ocillator populating reference XO1 on BoraEVB
  • Micron MT41K64M16JT-15E DDR3 chip running at 400 MHz.

The bitstream and boot binaries can be downloaded from the following URL:

AN-BELK-003 binaries

SDRAM bank mappingEdit

SDRAM bank is mapped in the PS's addressable space at physical address range 0x48000000-0x4FFFFFFF, as shown in the following picture:

 


It's possible to extend Linux kernel memory with the external memory adding a second memory in the device tree:

	axi_ddr: memory@48000000 {
		device_type = "memory";
		reg = < 0x48000000 0x08000000 >;
	} ;

The kernel patch can be downloaded from the following URL:

AN-BELK-003 Linux patch

HistoryEdit

Version Date Notes
1.0.0 August 2015