SDRAM Init -- Fundamental Questions

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

SDRAM Init -- Fundamental Questions

539 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by MikeSimmonds on Tue Nov 06 12:13:29 MST 2012
[FONT=Tahoma][SIZE=1]
  I have 3 very basic questions about SDRAM init on the 1778/1788.
 
  My board has two of Micron 256Mbit devices
  [16Mx16bits banks:4 rows:13 columns:9]
 
  Wired with Addr and control lines in common, one device providing
  the high 16 data bits, the other providing the low 16 data bits.
  I.e. the CPU data bus is 32bits (the devices are 16bits wide).
 
  Question 1:
  What Address Mapping should I be using?
 
  I would assume (for Row-Bank-Column):
  "1 0 011 01 = 256 Mbit (16Mx16), 4 banks, row length = 13, column length = 9"
  from table 132 in UM10470 rev 2
 
  and that the EMC controller will know I have two devices because
  the device width is half the cpu width.
 
  If this is not the case (and the cpu 'sees' a 16Mx32bit device,
  then there is no available mapping to get the correct bank/row/column
  setup! (What do I do then?)
 
  Question 2:
  What mode word shift factor should I be using?
 
  I would assume (9 columns + 2 bank bits + 2 for CPU data bus of 32bits)
  NOTE 2 = cpu data bus size which is NOT the same as the device data bus size!
  or should it be (cols+bank+1) due to the device width?
 
  Question 3:
 
  The EMC chapter in the user manual (UM10470 rev 2) defines all timings
  and delays in terms of "CCLK" I.e. the processor clock [120 MHz for me]
  and NOT in terms of "EMCCLK" [60 Mhz for me].
 
  Is this just incredibly slap-dash authoring :eek:, or do they REALLY mean the
  CPU clock -- even though this is (now) twice the speed of the EMCCLK?
 
  Anyone care to comment?
  Especially NXP Europe/USA (re the shockingly ambiguous manual!)

[/SIZE][/FONT]
0 Kudos
Reply
1 Reply

528 Views
lpcware
NXP Employee
NXP Employee
Content originally posted in LPCWare by MikeSimmonds on Fri Nov 09 12:58:14 MST 2012
[FONT=Tahoma][SIZE=1]For those of you that are in the same boat, I had a reply on the LPCWare forums:[/SIZE][/FONT]
[FONT=Tahoma][SIZE=1](I guess that's where the [I]real[/I] techies hang out. ;))
[/SIZE][/FONT]
[FONT=Tahoma][SIZE=1]
[/SIZE][/FONT]
[FONT=Tahoma][SIZE=1]Hi,[/SIZE][/FONT]
[FONT=Tahoma][SIZE=1]Q1: Yes, it's correct. Use "256 Mbit (16Mx16), 4 banks, row length =  13, column length = 9" settings. The EMC IP will know that it's 32-bits  wide memory, arranged in 16-bits upper and 16-bits lower byte, based on  that setting.[/SIZE][/FONT]
[FONT=Tahoma][SIZE=1]Q2: It's (9 columns + 2 bit of banks + 2 for 32-bits). [/SIZE][/FONT]
[FONT=Tahoma][SIZE=1]The mode is based on "address" bus, not "data" bus. Hence, whether  it's (16-bits x 2) or (32-bits x 1), it will have the same address shift  for SDRAM MODE configuration. The app note in LPC32xx have clearer  explanation on this (except that the burst rate for LPC177x must reach  128-bits..eg 16-bits x 8-burst). See http://www.nxp.com/documents/application_note/AN10935.pdf[/SIZE][/FONT]
[FONT=Tahoma][SIZE=1]Q3: I think the correct one should be based on EMCCLK, not CCLK. I will update people in documentation for this[/SIZE][/FONT]
      
                           [FONT=Tahoma][SIZE=1]Regards,
-daniel
NXP Application Support
--------------------------------------------------------
If it works for you, please post it back in the forum =)
--------------------------------------------------------[/SIZE][/FONT]
[FONT=Tahoma][SIZE=1]
[/SIZE][/FONT]
0 Kudos
Reply