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.

PROCESSOR-SDK-J721S2: j721s2 8.6 SDk version

Part Number: PROCESSOR-SDK-J721S2

Hi, 

We are using the J721s2 device in our application. In we are working on the R5F (MCU2_1). In this we are facing an issue with SDK 8.6. In sdk8.4 its working fine but sdk8.6 we are not able to send more than 3 16bits of data. in that we are using free RTOS.

  • Hi,

    Can you please elaborate more on this? What interface are you using? Also, are you referring to any existing example in PDK or is it a custom example?

    Regards,
    Parth

  • Hi Partha,

    We are using the SPI interface. we are using the custom example in pdk. We are able to send only 3 16bit words .

  • Hi,

    Can you please share the changes done in the existing example?
    Also, did you try the out of box demo? Are you facing issue with that as well?

    Regards,
    Parth

  • I used following initialization sequence.

    MCSPI_init();
    //SPI_socGetInitCfg(USS1_SPI_INST, &spi_cfg);
    SPI_socGetInitCfg(domain,USS1_SPI_INST, &spi_cfg);
    spi_cfg.baseAddr = (uint32_t)CSL_MCU_MCSPI0_CFG_BASE;
    spi_cfg.chNum = USS1_SPI_CH;
    spi_cfg.chnCfg[USS1_SPI_CH].tcs = MCSPI_CH0CONF_TCS0_ONECYCLEDLY;
    spi_cfg.chnCfg[USS1_SPI_CH].dataLineCommMode = MCSPI_DATA_LINE_COMM_MODE_6;
    // spi_cfg.chnCfg[USS1_SPI_CH].enableFIFO = 0u;
    spi_cfg.chnCfg[USS1_SPI_CH].trMode = MCSPI_TX_RX_MODE;
    spi_cfg.initDelay = MCSPI_INITDLY_0;
    spi_cfg.rxTrigLvl = 2; // MCSPI_RX_TX_FIFO_SIZE;
    spi_cfg.txTrigLvl = 2; // MCSPI_RX_TX_FIFO_SIZE;
    spi_cfg.edmaHandle = NULL;
    spi_cfg.dmaMode = FALSE;
    spi_cfg.enableIntr = FALSE;
    spi_cfg.chMode = MCSPI_MULTI_CH;
    //spi_cfg.chnCfg[USS1_SPI_CH].dmaInfo = NULL;
    SPI_socSetInitCfg(domain,USS1_SPI_INST, &spi_cfg);

    SPI_socGetInitCfg(domain,USS2_SPI_INST, &spi_cfg);
    spi_cfg.baseAddr = (uint32_t)CSL_MCU_MCSPI1_CFG_BASE;
    spi_cfg.chNum = USS2_SPI_CH;
    spi_cfg.chnCfg[USS2_SPI_CH].tcs = MCSPI_CH0CONF_TCS0_ONECYCLEDLY;
    spi_cfg.chnCfg[USS2_SPI_CH].dataLineCommMode = MCSPI_DATA_LINE_COMM_MODE_6;
    // spi_cfg.chnCfg[USS2_SPI_CH].enableFIFO = 0u;
    spi_cfg.chnCfg[USS2_SPI_CH].trMode = MCSPI_TX_RX_MODE;
    spi_cfg.initDelay = MCSPI_INITDLY_0;
    spi_cfg.rxTrigLvl = 2; // MCSPI_RX_TX_FIFO_SIZE;
    spi_cfg.txTrigLvl = 2; // MCSPI_RX_TX_FIFO_SIZE;
    spi_cfg.edmaHandle = NULL;
    spi_cfg.dmaMode = FALSE;
    spi_cfg.enableIntr = FALSE;
    spi_cfg.chMode = MCSPI_MULTI_CH;
    // spi_cfg.chnCfg[USS2_SPI_CH].dmaInfo = NULL;
    SPI_socSetInitCfg(domain,USS2_SPI_INST, &spi_cfg);

    MCSPI_Params_init(&spiParamsUSS1);
    spiParamsUSS1.mode = SPI_MASTER;
    spiParamsUSS1.bitRate = 250000;//16000000;
    spiParamsUSS1.transferMode = SPI_MODE_BLOCKING;
    spiParamsUSS1.transferCallbackFxn = NULL;
    spiParamsUSS1.transferTimeout = 0xFFFFFFFF;
    spiParamsUSS1.frameFormat = (SPI_FrameFormat)frameFormatEVS[1];
    spiParamsUSS1.dataSize = 16;

    MCSPI_Params_init(&spiParamsUSS2);
    spiParamsUSS2.mode = SPI_MASTER;
    spiParamsUSS2.bitRate = 250000;//16000000;
    spiParamsUSS2.transferMode = SPI_MODE_BLOCKING;
    spiParamsUSS2.transferCallbackFxn = NULL;
    spiParamsUSS2.transferTimeout = 0xFFFFFFFF;
    spiParamsUSS2.frameFormat = (SPI_FrameFormat)frameFormatEVS[1];
    spiParamsUSS2.dataSize = 16;

    i didn't referred any example but i was using the spi in 8.4 sdk same thing i am trying on the sdk 8.6.

  • Hi,

    Let me review the changes done in SPI driver from 8.4 to 8.6 and get back.

    Regards,
    Parth

  • Hi,

    I reviewed the changes from 8.4 to 8.6 and I don't see any change that could cause this issue.
    Can you please take a dump of McSPI registers in 8.4 and 8.6, right before you initiate the transfer and compare to see if there are any differences?

    Regards,
    Parth