Post Go back to editing

ADSP-21363 SPI DMA exchange issue

Category: Hardware
Product Number: ADSP-21363

I am having issue with SPI DMA data exchange. There is two ADSP-21363 connected via SPI. When sub transfers main recieves data but with SPIS=3 in SPIDMAC and RXS=1 in SPISTAT. And when main transfers in response sub does not recieves data with SPIS=3, SPIERRS=1 in SPIDMAC and ROVF=1, RXS=1 in SPISTAT.8461.attachment.zip 

How can i fix it correctly?

Any help is appreciated.

Parents
  • Hi,

    Using your code on the ADSP-21369 EZ-KIT, we successfully transferred data from the main to the sub without any issues. We made modifications to configure the sub to use SPIB. Please refer the attached project, test it on a single board, and share your results with us.

    SPI_21369.zip

    To assist you better, please let us know if the SPIOVF, SPIUNF or SPIMME bits are set when main transfers the data to Sub.
    Also, we assume the sub receiver is enabled before the main transmitter. Could you please confirm the sequence?

    Regards,
    Nandini C

  • Hi,  NandiniC.

    Thank you for quick answer.

    Using your code on the ADSP-21369 EZ-KIT, we successfully transferred data from the main to the sub without any issues. We made modifications to configure the sub to use SPIB. Please refer the attached project, test it on a single board, and share your results with us.

    Unfortunately, i dont have ADSP-21369 EZ-KIT right now. So i cannot test your code. All i have is some kind of prototype board with two ADSP-21363 on it.

    To assist you better, please let us know if the SPIOVF, SPIUNF or SPIMME bits are set when main transfers the data to Sub.

    This is how SPI Control registers look like after DMA enabled:

     

    Also, we assume the sub receiver is enabled before the main transmitter. Could you please confirm the sequence?

    Maybe that's the problem, but i dont know how to figure out. 

     

  • Hi,

    Unfortunately, i dont have ADSP-21369 EZ-KIT right now. So i cannot test your code. All i have is some kind of prototype board with two ADSP-21363 on it.
    >> You can run this project in your custom board too. Please run this project and let us know the results.

    This is how SPI Control registers look like after DMA enabled:
    >> It seems the screenshot belongs to Slave. Could you please share us for Master too.

    Maybe that's the problem, but i dont know how to figure out.
    >> Could you please place breakpoints on the functions “ConfigureDMAToReceive” and “ConfigureDMAToTransfer” in your project?
    When running the project, “ConfigureDMAToReceive” is triggered first, followed by “ConfigureDMAToTransfer.”

    Regards,
    Nandini C

  • Hi,

    This is screenshot form main. Looks like no errors thrown.

    I have two projects, one for main and another for sub. 

    I can have only one debug session for main or sub via JTAG connection, isn't it?

    So how i can figure out that “ConfigureDMAToReceive” in sub is triggered first,  followed by “ConfigureDMAToTransfer” in main?

    Sorry if its sounds stupid to you but it is all new for me.

    Thank you for your patience.

Reply
  • Hi,

    This is screenshot form main. Looks like no errors thrown.

    I have two projects, one for main and another for sub. 

    I can have only one debug session for main or sub via JTAG connection, isn't it?

    So how i can figure out that “ConfigureDMAToReceive” in sub is triggered first,  followed by “ConfigureDMAToTransfer” in main?

    Sorry if its sounds stupid to you but it is all new for me.

    Thank you for your patience.

Children
No Data