This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

64-bit read issue on C6726 EMIF

Hello,

I'm working on porting a project from a custom C6713 board to a custom C6726 and have noticed an issue: 64-bit reads from external memory (SDRAM) don't work properly.  Some pseudocode:

{
  extern double iramVar; //allocated in IRAM
  extern double sdramVar; //allocated in external memory

  sdramVar = 0xAAAABBBB 12345678;
  iramVar = sdramVar;
}

The results of this would be:
iramVar = 0x12341234 12345678

So the lower word is being read successfully, but for some reason the upper word is being ignored and replaced by the upper two bytes of the lower word.  64-bit writes to external memory work correctly, as do reads of shorter data types.

The only thing I could think of that would cause this was an incorrect setup in the SDCR of the narrow mode bit which controls whether the EMIF is 16 or 32 bit.  I checked and it is correctly set to 16 bits.  Any suggestions of other things to check?

Thanks,
ralwood
   

  • We resolved this issue; here was the solution:

    There was a mistake on the board where the address lines A1 and A2 were switched going to the SDRAM.  Because the DSP ignores a variable number of address lines depending on the size of the read block, it only caused a problem for 64-bit reads.  We corrected the board and everything worked as normal.  Software isn't always the problem!

    Regards,

    ralwood