nRF52840 SPIS semaphore acquire and release

Hi All,

I am using the nRF52840, with SDK140 v15.0. I have configured the nRF52840 to be a SPI slave to a NXP processor. When I connect the logic analyzer I see signals on the SCK line and MOSI lines as well as the CS line going low. I also see the expected data on the MOSI line which the NXP SPI Master is sending, but the MISO line is always set to the DEF character which is 255 or HIGH. After reading the other posts and debugging my code I find that the issue is related to semaphore Aquire/ release. In my code the nRF52840 always gets stuck at the nrfx_spis_buffers_set function call. After putting in printfs for debugging I am able to trace the code all the way down to  nrf_spis_task_trigger(p_spis, NRF_SPIS_TASK_ACQUIRE); The code gets stuck at nrf_spis_task_trigger.

I have made sure that there are no hardware issues here at all.

Can anyone please explain what is happening here? Why is the SPI slave unable to acquire the semaphore at all?


Parents Reply Children