Trouble getting SPI to work together with BLE

Hi,

I have been working on a setup where I connect a sensor (TI ADS1299) to the nRF5340-DK 2.0.0 using an SPI connection and transmit the recorded data using BLE. I have been able to get the SPI connection and the BLE connection working separately, but when combining the functionalities a problem arises. The program builds and programs fine, but when running it, the SPI connection does not seem to be working properly. All registers that store the data are left empty, instead of containing the measured data. The BLE connection does still work but only transmits zeros, probably as the result of the SPI connection not working as it should. 

What could be the problem here? Do the nrfx_SPIM and BLE functionalities interfere with each other? 

My setup:

PC: HP Zbook G4 Studio 

OS: Windows 10

nRF Connect for Desktop v3.10.0

Does anyone have any suggestions on how to fix this issue?

Kind regards,

C

Parents Reply
  • Thank you for your response,

    In the original SPI code, I used P1.01 for the chip select. After combining the SPI code and BLE code I got the same issue I described in this post. I found somewhere that P1.01 might be used by the BLE connection, so I tried another pin (P0.02) for the chip select. I did not know about the need to short/remove the resistors from the board to use P0.02. Perhaps using another pin is more convenient in this case. I will try some others.

    I sadly do not own a scope or a logic analyzer, but I might be able to borrow one if using another pin for the chip select does not help. 

    Thanks for your help,

    C

Children
No Data
Related