nRF51 SDK - S120 SoftDevice
 All Data Structures Functions Variables Typedefs Enumerations Enumerator Groups Pages
Random Number Generator Example

The Random Number Generator Example demonstrates the RNG peripheral by obtaining a random number and showing it on the LEDs.

The application starts by configuring the GPIO and starting the RNG peripheral. The main loop updates the LEDs to the random number and waits for 100ms.

Setup

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

LED assignments:

  • LED 0-7 is used to show a random generated number.

Testing

The Random Number Generator Example Application can be tested as follows:

  1. Compile and program the application.
  2. Observe that a random number is updated on the LEDs every 100ms.