nRF51 SDK - S120 SoftDevice
 All Data Structures Functions Variables Typedefs Enumerations Enumerator Groups Pages
SPI master example application to be used with the SPI slave example application

The SPI master example has been created specifically for verifying the SPI connectivity link for the SPI slave example application. The SPI master example can only be used with a nRF51822 Development Kit board that is running the SPI slave example application and it only tests SPI0. The application executes SPI transactions every 100 ms and uses the LEDs to indicate the status of the SPI transaction.

Setup

Instructions on how to set up the nRFgo Motherboard: nRFgo Motherboard Setup (nRF6310).

Used SPI master pin configurations:

  • MOSI0 (Pin 20, P2.4).
  • MISO0 (Pin 22, P2.6).
  • SS0 (Pin 21, P2.5).
  • SCK0 (Pin 23, P2.7).

LED assignments:

  • LED 0 is used to show that an application is running.
  • LED 1 is toggled everytime a single SPI transaction has completed successfully.
  • LED 2 is used to show if an SPI transaction error has ocurred.

Testing

The example application can be tested as follows:

  1. Compile and program the application.
  2. Observe that the LED 0 is lit and LED 1 is toggled every 100ms.