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.

TDA4VM: Reading from OSPI flash memory using Fls Mcal driver

Part Number: TDA4VM
Other Parts Discussed in Thread: PROCESSOR-SDK-J721E

Tool/software:

Dear Ti support,
When using the Fls driver from pdk_jacinto_08_06_00_31 delivery we have seen an non wanted behavior.
There is actually two different behaviors. Both are related to reading from the S28HS01GTGZBHM03 that we have on the VCM board.
1) When reading from the flash, starting from an odd address. We realize that the flash is actually reading from the targeted address but with the LSb cleared.
- We could also read this behavior from the datasheet "The LSb of the address always be zero in any Octal DDR transactions with the address input."
This behavior is not handled by the Fls Mcal driver from the PDK.
2) When reading single byte next and all following transactions to the flash give incorrect response.
Here we do not really understand what is going on. Perhaps the single byte read is not completed correctly and all following accesses fail due to this.

We are trying to work around this issue to move forward in our testing but would need to highlight this as a erroneous driver implementation.

  • Hi,

    Does PDK driver works fine for you?

    I see this is a custom flash, not supported by default in PDK. Did you validate the flash with OSPI driver example?

    When reading from the flash, starting from an odd address. We realize that the flash is actually reading from the targeted address but with the LSb cleared.

    I am not really clear on this? Can you please elaborate with an example?

    Regards,
    Parth

  • Hello Parth,

    The driver from the PDK works fine (We have done a few patches). It is possible to both write and read from the flash. Patch was created after earlier issue "PROCESSOR-SDK-J721E: Flash mcal driver for J721".

    When we put the PDK flash driver into the context of a total Autosar system with a NvM and a Fee module connected to the flash driver we get the problem as described.

    We have setup a test where we try to read from the flash as follow.

    uint8 flashTestBuffer[256];
    uint32 flashAddress = 0x31BFF00;
    Fls_Read(flashAddress, flashTestBuffer, 1);

    When this code is run it will read the byte correctly!

    But if the code is run again next byte in memory is returned and it looks like we lost any proper way of communicating with the OSPI flash.

    The flash driver do not handle the fact that it is not possible to read from odd address. If following code is issued:

    uint8 flashTestBuffer[256];
    uint32 flashAddress = 0x31BFF01;
    Fls_Read(flashAddress, flashTestBuffer, 2);

    The result is that we read two bytes starting from 0x31BFF00.

    BR
    Magnus

  • Hello,

    When we put the PDK flash driver into the context of a total Autosar system with a NvM and a Fee module connected to the flash driver we get the problem as described.

    PDK flash driver is not intended to use with AUTOSAR, we have FLS driver in  MCAL which should be used along with AUTOSAR OS.

    Regards

    Tarun Mukesh