nRF51 SDK - S310 SoftDevice
 All Data Structures Functions Variables Typedefs Enumerations Enumerator Groups Pages
Timer Example

The Timer Example demonstrate the use of the Timer peripherals. The timers are used to toggle pin 8 (LED 0) every 100ms. This example replaces the less accurate busy delay in blinky example with a more accurate hardware timer based delay.

The application starts with configuring the GPIO. The LED is toggled and the application waits for Timer0 to reach the capture/compare (CC[0]) value. This is done for all three timers in order.

Setup

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

LED assignments:

  • LED 0 is toggled every 100ms.

Testing

The Timer Example Application can be tested as follows:

  1. Compile and program the application.
  2. Observe that LED 0 toggles every 100ms.