Atmel website | ARM Community | AVR freaks | Technical Support
Banner
 FAQ •  Search •  Register •  Login 

All times are UTC + 1 hour [ DST ]




Post new topic Reply to topic  [ 7 posts ] 
Author Message
 Post subject: DDR2 Controller Adressing -- I am so confused...
PostPosted: Tue Mar 06, 2012 12:55 am 
Offline

Joined: Fri Nov 10, 2006 12:05 am
Posts: 22
Hello

DDR2SRC

Why does A0 from the cpu bus go to A0 on the DDR2 chips?
If this is the case, then how does it manage the odd / even bytes and addresses on the 16 bit bus?

Is A0 on the bus really A1 or what am I missing here???

I ask this because with the current situation, I am no able to calculate at what addresses the banks will switch.

Best regards
Bernt


Top
 Profile  
 
 Post subject: Re: DDR2 Controller Adressing -- I am so confused...
PostPosted: Tue Mar 06, 2012 11:15 pm 
Offline

Joined: Sat Oct 30, 2010 6:04 pm
Posts: 784
berntd wrote:
Why does A0 from the cpu bus go to A0 on the DDR2 chips?


Because Dynamic memories are addressed by latching ROW and then COLUMN addresses. These SHARE A[12..0]

The BANK is sent via BA[1:0]

Where the bank transition occurs depends on the bit width of the ROW and COLUMN programmed into the SDRAM/DDR Controller, and the bit width of the memory interface. Want to see how these bits stack up, search "Linear Mapping for SDRAM Configuration" in the product documentation.


Top
 Profile  
 
 Post subject: Re: DDR2 Controller Adressing -- I am so confused...
PostPosted: Wed Mar 07, 2012 12:55 am 
Offline

Joined: Fri Nov 10, 2006 12:05 am
Posts: 22
CptTitanic wrote:
berntd wrote:
Why does A0 from the cpu bus go to A0 on the DDR2 chips?


Because Dynamic memories are addressed by latching ROW and then COLUMN addresses. These SHARE A[12..0]

The BANK is sent via BA[1:0]

Where the bank transition occurs depends on the bit width of the ROW and COLUMN programmed into the SDRAM/DDR Controller, and the bit width of the memory interface. Want to see how these bits stack up, search "Linear Mapping for SDRAM Configuration" in the product documentation.


Hello and thanks for the reply!

According to that section you mentioned, Table 22-3, the DDR_A0 line is in actual fact the processor A1 line.
I thought so but the app note on the DDR2 implementation clearly states that DDR_A0 goes to the bus A0. So this is incorrect and majorly confusing.

I now see the processor A0 line is conenctod to M0. I assume this is the DQM0 line to the DDR2?
For a 16 bit bus width. Where in the cpu is M1 (DQM1? connected then)?

Best regards

Bernt


Top
 Profile  
 
 Post subject: Re: DDR2 Controller Adressing -- I am so confused...
PostPosted: Wed Mar 07, 2012 6:23 am 
Offline

Joined: Sat Oct 30, 2010 6:04 pm
Posts: 784
It's accessing the memory via ROWs and COLUMNs, not as a linear address like the static memory model you're trying to apply here.

The bit width of the ROW [A12..A0] and COLUMN [A12..A0], is defined by the SDRAM/DDRs geometry which you have to program into the controller.

The ARM memory view A1..A0 for a 32-bit access never get to the external bus. The stuff on the external bus is first the ROW# which is latched, then the COLUMN#, subsequent memory accesses automatically increment inside the memory chip so a stream of data can be burst read from the device.

The wiring of the SDRAM doesn't change for 16 or 32-bit wide implementations, you just route the data bits to the correct devices, the address bits remain the same, the controller handles the address sequencing, and the synchronous/sequential access properties. You can in fact run a board with a 32-bit memory subsystem in 16-bit mode, you just halve your memory and stop using half the chips. In a board with two chips, you could have a BOM that omitted the second chip for a lower cost/performance system, using the same board.


Top
 Profile  
 
 Post subject: Re: DDR2 Controller Adressing -- I am so confused...
PostPosted: Thu Mar 08, 2012 4:16 am 
Offline

Joined: Fri Nov 10, 2006 12:05 am
Posts: 22
Hello and thanks again!

I understand what you you wrote but I still don't understand the exact operation of the Low byte / high byte operation for the standard 2 chip (D0-D7) (D8-D15) implementation.

Both chips see the same address lines, the same RAS/CAS and the same CS.
So how does it read from odd addresses? ie 0x201,203 etc?
Even if it can only do 16 bit reads / writes then the address still has to increase in steps of 2 so A0 from the cpu still cannot be used.

It has to have A1 from the cpu conencted to A0 on the RAM and it then also has to have 2 Low /High byte control lines ?


Best regards
Bernt


Top
 Profile  
 
 Post subject: Re: DDR2 Controller Adressing -- I am so confused...
PostPosted: Thu Mar 08, 2012 2:34 pm 
Offline

Joined: Sat Oct 30, 2010 6:04 pm
Posts: 784
The DQSx and DQMx lines control specific bytes, and memories.

Odd reads are handled by the processor, and bus controller, to shift or cherry pick bytes from the data bus.

The ARM9 does not permit unaligned 32-bit reads.


Top
 Profile  
 
 Post subject: Re: DDR2 Controller Adressing -- I am so confused...
PostPosted: Fri Mar 09, 2012 12:58 am 
Offline

Joined: Fri Nov 10, 2006 12:05 am
Posts: 22
Got it! Thank you very much!


Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 7 posts ] 

All times are UTC + 1 hour [ DST ]


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to: