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.

F28377D EMIF ASIZE configuration problem

Hello,

I am using a F28377D design to access an asynchronous external device. I face a problem with the configuration of EMIF using ASIZE parameter.

the data sheet of the device specifies that it can be accessesd either as a 8bits interface or 16 bits interface (using Data bits from 0 to 16). when using EMIF with ASIZE= 0 (8bits inteface). i can see 2 accesses on the bus and correct data is read or written.

if I change ASIZE to 01b upper half word becomes FF at any time even if the corresponding data bit on the bus is set to 0 by the device (i checked data with a scope)and the is only 1 access on the bus.

can someone tell me what could happen?

regards,

  • Olivier,

    Did you remember to configure the pin mux registers for the upper data bit pins?

    Regards,
    David
  • Also on following,

     (i checked data with a scope)and the is only 1 access on the bus.

    There will be only once access since ASIZE has been set to 16bit. This is expected behavior.

    Regards,

    Vivek Singh

  • Hi David,

    i checked the configuration of pinmux registers. I did it using pinmux tool to generate pinmux configuration. This is what I have:

    // Port C mux register values

    //

    // Pin B3 (GPIO95) to GPIO95 (mode 0)

    // Pin B19 (GPIO67) to GPIO67 (mode 0)

    // Pin A3 (GPIO94) to GPIO94 (mode 0)

    // Pin A4 (GPIO92) to EM1BA1 (mode 3) // GPIO92 (mode 0)

    // Pin B4 (GPIO93) to EM1BA0 (mode 3) // GPIO93 (mode 0)

    // Pin A11 (GPIO84) to MDXB (mode 6)

    // Pin C11 (GPIO86) to EM1A13 (mode 2)

    // Pin D11 (GPIO87) to EM1A14 (mode 2)

    // Pin C6 (GPIO88) to EM1A15 (mode 2)

    // Pin B11 (GPIO85) to EM1D0 (mode 2)

    // Pin C14 (GPIO83) to EM1D1 (mode 2)

    // Pin B14 (GPIO82) to EM1D2 (mode 2)

    // Pin A14 (GPIO81) to EM1D3 (mode 2)

    // Pin D15 (GPIO80) to EM1D4 (mode 2)

    // Pin C15 (GPIO79) to EM1D5 (mode 2)

    // Pin B15 (GPIO78) to EM1D6 (mode 2)

    // Pin A15 (GPIO77) to EM1D7 (mode 2)

    // Pin C16 (GPIO76) to EM1D8 (mode 2)

    // Pin D16 (GPIO75) to EM1D9 (mode 2)

    // Pin C17 (GPIO74) to EM1D10 (mode 2)

    // Pin A16 (GPIO73) to EM1D11 (mode 2)

    // Pin B16 (GPIO72) to EM1D12 (mode 2)

    // Pin B17 (GPIO71) to EM1D13 (mode 2)

    // Pin A17 (GPIO70) to EM1D14 (mode 2)

    // Pin B18 (GPIO69) to EM1D15 (mode 2)

    // Pin L17 (GPIO64) to SPISOMIB (mode 15)

    // Pin K16 (GPIO65) to SPICLKB (mode 15)

    // Pin K17 (GPIO66) to SPISTEB (mode 15)

    #define GPCMUX1_VALUE 0xaaaaa83f

    #define GPCMUX2_VALUE 0x0F02aaaa

    #define GPCGMUX1_VALUE 0x0000003f

    #define GPCGMUX2_VALUE 0x00000100

     

    I think this is correct. Moreover, the data pins from D8 to D15 are used and properly read when ASIZE = 0 with 2 accesses on the bus.

    regards,

    Olivier

  • Olivier,

    Do you have the external memory interfaced as a 16-bit device?  Normally only one of 8-bit or 16-bit configuration is going to work because of the way the memory is configured.

    - David

  • Hi Olivier,

    What do you mean by following -
    Moreover, the data pins from D8 to D15 are used and properly read when ASIZE = 0 with 2 accesses on the bus.


    When ASIZE = 0, D8 to D15 are not used at all.

    Regards,
    Vivek Singh
  • hello david,
    yes the external device is configured as a 16bit device. and data is output on data bits from D0 to D15. what is strange is that the device is always in a 16bit configuration and it works fine with ASIZE=0.
  • Vivek,
    what I mean is that the external device is always configured as a 16bit interface. as a consequence the device sends data on bus D0 to D15( checked with an oscilloscope). with ASIZE=0 i can see there are 2 accesses on the bus( chip select going down twice) and data is correctly read in the DSP. with ASIZE = 01, chip select goes down only once and data is not read correctly.

    Olivier
  • Hi Olivier,

    There is difference in address lines connection for 8bit device vs 16bit device. Please refer "Figure 25-9. EMIF to 8-bit/16-bit Memory Interface" in device manual (TRM). So not sure how are you switching between 8bit and 16bit here. Also when ASIZE = 0, data from data lines 16:8 is don't care.

    Regards,
    Vivek Singh
  • Hi Vivek,

    I know there are differences in connection between 8 and 16 bits. what is strange is that it seems data lines 16:8 are not used when ASIZE = 01 not when ASIZE = 00. could it be related to Code composer version itself?

    regards,

    Olivier

  • Hi Oliver,

    This is EMIF configuration and CCS version should not have any impact on this. Are you doing read/write access from CCS memory watch window? We have tested the ASIZE = 01 configuration and there is no issue with that. It uses data pins from 15:0 and in ASIZE = 0, 15:8 pins are not used. You can change the pinmux setting to not have EMIF function on 15:8 pins and ASIZE=0 should still work.

    Regards,
    Vivek Singh