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

The Temperature Example shows how to use a temperature sensor and print the measurement.

The application starts with configuring the temperature module and app_uart. The main loop reads the temperature sensor and prints measurement every 500 milliseconds.

The name of the example is temperature_pca10028. If you are not using the Keil Pack Installer, you can find the source code and project file of the example in the following folder: <InstallFolder>\Nordic\nrf51\examples\peripheral\temperature

Testing

Test the Temperature Example application by performing the following steps:

  1. Compile and program the application.
  2. Start a COM listener like PUTTY and connect to the used COM port with the following UART settings:
    • Baud rate: 38.400
    • 8 data bits
    • 1 stop bit
    • No parity
    • HW flow control: RTS/CTS
  3. Observe that a temperature value is printed every 500 milliseconds.