I have a problem with the code example from a SDK from NXP about the EMC bus to use an external SDRAM. I use the LPCXpresso 546xx/540xx demo board from NXP.
The code example works correctly when I use the demo board LPCxpresso546xx/540xx with an external SDRAM from Micron ( MT48LC8M16A2B4) but when I use the demo board LPCxpresso546xx/540xx with an external SDRAM from Winbond (W9812G6JB-6I), the program says that there is an error when it checks the written data in the external SDRAM memory.
I was able to see in the memory that there is an error during data writing step :
Normally, the program writes (from the 0xA0000000 address) data from 0 and increasing each value by 1 compared with the previous value (ex : 00000000, 00000001, ...., 0000000A, 0000000B). However, at an address the written value is not correct compared with the others (ex : 000002FC, 000002FD, 000002FE, 6B836021, 00000300, 00000301, the wrong value is at the address 0xa0000bfc but at each try, the address with the wrong value is not the same).