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.

RTOS/CC2640: SPI Is getting hanged when reading large amounts of data.

Part Number: CC2640
Other Parts Discussed in Thread: BLE-STACK

Tool/software: TI-RTOS

HI,

I'm reading 1020 bytes of data from SPI slave(CC2640 is SPI Master) but randonly this spi transaction is getting hung and because of this watchdog is triggering a warm reset.

Setup:  IAR 7.40.3, BLE stack 2.1, TIRTOS 2.13.00.06.

I'm using the SPI in Blocking mode.

    /*  Configure SPI as master, 1 mHz bit rate*/
    SPI_Params_init(&spiParams);
    spiParams.bitRate = SPI_Bitrate;
    spiParams.frameFormat = SPI_Format;
    spiParams.mode = SPI_MASTER;
    spiParams.transferMode = SPI_MODE_BLOCKING;

    /* Attempt to open SPI. */
   handle.Spi_handle = SPI_open((uint32_t) BOARD_SPI0, &spiParams);

and for chipselect instead of using SPI_Control I use normal Pin_setconfig to make it low for every SPI transaction.

SPI Logic Analyser output confirms that SPI transaction got hung after reading 16 bytes when it was supposed to read 1020 bytes.

can you help me with some scenarios that this can happen?