46 #ifndef SOFTDEVICE_PRESENT 52 #include "dev/temperature-sensor.h" 55 const struct sensors_sensor temperature_sensor;
66 #ifndef SOFTDEVICE_PRESENT 67 int32_t
volatile temp;
69 NRF_TEMP->TASKS_START = 1;
72 NRF_TEMP->EVENTS_DATARDY = 0;
73 temp = nrf_temp_read();
74 NRF_TEMP->TASKS_STOP = 1;
95 #ifndef SOFTDEVICE_PRESENT 96 if (type == SENSORS_HW_INIT) {
static int status(int type)
Return temperature sensor status.
#define RTIMER_BUSYWAIT_UNTIL(cond, max_time)
Busy-wait until a condition for at most max_time.
#define RTIMER_SECOND
Number of rtimer ticks for 1 second.
static int value(int type)
Returns device temperature.
static int configure(int type, int c)
Configures temperature sensor.