Hello engineers :-)
I have a strange issue.
I have one DDR2 memory chip with 13 address pins, 10 column pins, 8 banks and 16-bit width.
As far as I understand the manual my register configuration should be:
HW_DRAM_CTL29:
CS_MAP=0x0
COLUMN_SIZE=0x2 // 12 - 2 = 10
ADDR_PINS=0x2 // 15 - 2 =13
HW_DRAM_CTL31:
EIGHT_BANK_MODE=0x1
and of course lots of other registers, but the above are the ones i'm currently interested in. I have disabled the EMI_CE1N pin and disabled the last two address pins. The above configuration doesn't work but as soon as i change CS_MAP to 0xf it works! How come? I have one chip only. My EMI_CE0N pin is connected to the memory chip select, the EMI_CE1N pin is not connected at all. How come mapping over nonexistent chip selects works while the correct configuration doesn't, what am I missing?
Besides, i don't get it how CS_MAP allows for a value of 0xf for enabling the mapping of 4 chip selects when the i.MX28 has only two chip selects on the EMI interface?! Where are the other two chip selects?
Solved! Go to Solution.
> Which means the valid values should be 0, 2, 4 and 8.
Really : 1,2,4,8 :-)
CS_MAP should not be zero :
1 for Chip Select 0
2 for Chip Select 1
3 for both Chip Selects 11
Please use DDR Excel table :Board bring-up and DDR initialization tools
I did try setting it to 1 and to other values as well but works only when set to 0xf. By the way the reference manual says the number of selected chip selects should be a power of 2. Which makes sense since to map the chips selects as an extra address bit they should be indeed a power of two. Which means the valid values should be 0, 2, 4 and 8. I've read the programming aid you are referring to and it just adds more to the confusion how the CS_MAP value is used.
> Which means the valid values should be 0, 2, 4 and 8.
Really : 1,2,4,8 :-)
I just tried to init i.MX28 EVK with CS_MAP=0x1 - memory works !