This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

SPI implementation difference between SDK

Hi teams,

I am trying to implement Decawave DW3000 functions to nRF52833DK as host.

Decawave provides some APIs for nRF52840DK, and I have succeeded make it working on nRF52833 with nRF5 SDK.

During migrating those APIs to nRFConnect SDK, I have suffered from some inconsistency between each SPI implementations.

  1. In nRF52 SDK, it works with NRFX_SPIM driver and uses SPI_MODE0. But In nRFConnect 1.5.1 SDK, I should use NRFX_SPIM driver and NRF_SPI_MODE_1 to make it work correctly. All the hardware configuration is exaclty the same, and I downloaded firmwares from two different SDK, i.e. nRF5 SDK 17.0.0.2, and nRFConnect 1.5.1. Any ideas why this happens?
  2. I tried to use zephyr standard SPI functions. It seems that a single write or write-then-read operation is working, but during several operations, some different behaviour happens, and eventually, the chip initialization/configuration has failed. Is there any information/guideline regarding this issue?
Parents Reply
  • I have found the cause of the first problem.

    uart1 device node is affecting to the setting, and after disabling it, it works well as expected.

    Thanks for your advice.

    But still the whole communication via zephyr SPI is not working, and I am investigating each communication process.

    Is there any advice regarding difference between NRFX_SPIM and zephyr-ported SPI?

    And, BTW, SPI3 is defined in DTS, but not exists in nRF52 SDK. SPI3 is different from SPI0/1/2?

Children
Related