Post Go back to editing

Host readback appstatus though cmd4 on ADSP21565

Category: Software
Product Number: ADSP21565
Software Version: SoftwareModules\SigmaStudioForSHARC-SH-Rel4.6.0\Target\Examples\Demo\ADSP-2156x


adsp21565 is connected to our soc by spi1, Currently, the demo software of sigmastudioforsharc is running on adsp21565.

First of all, at present, the spi writing and reading on my side are normal,

At present, I want to read appstatus through cmd4 mentioned in hostcontrol documentation。

The specific process is as follows:

1. I sent parameters 0x4 and 0x77777777 by cmd4

2. i read the data by spi  

result: I checked the cmd4 callback function adi_ss_comm_callback_cmd4 of the demo software,can be called back normally, But I don't get any data in soc,

and I confirmed through the oscilloscope that the spi clk is sending normally, but there is no data back.

I doubt there is something wrong with adi_ss_connection_Reconfigure function, Because I can't see the concrete implementation of this function,can you help confirm it.

Or is it caused by other problems. please let me know.

  • Hi,

    The cmd4 callback is for customer target applications which uses MCU as Host. Since we are using DMA for transferring the data over SPI, you may try changing adi_ss_comm_callback_cmd4 code like below,

    /* Packetize the back-channel data for transmission */
    if(adi_ss_comm_Packetize(pAppSharcCore0Info->hCommHandle, pCommBackchInfo, &nBkChnlPacketSzInWords) == ADI_SS_COMM_SUCCESS)
    /* Populate the reconfigurable items of ADI_SS_CONNECTION_CONFIG structure */
    pConnCfg->pTxAddr = adi_ss_address_translation((uint32_t)&aBkChnlPacket[0],pAppSharcCore0Info->eCoreID,false); /* Transmit address */
    // pConnCfg->pTxAddr = &aBkChnlPacket[0];
    pConnCfg->nTxPayloadCnt = nBkChnlPacketSzInWords; /* Transmit payload count */

    /* Re-configure and enable SPI TX DMA. */
    adi_ss_connection_Reconfigure(pAppSharcCore0Info->hConnHandle, ADI_SS_CONFIG_SPI_TX_DMA, pConnCfg);


  • ok, thanks, This problem has been solved in this way.