Nordic Semiconductor nRF5 AirFuel SDK  version 2.2.0
ptu_sensors.h
Go to the documentation of this file.
1 /* Copyright (c) 2013 Nordic Semiconductor. All Rights Reserved.
2  *
3  * The information contained herein is property of Nordic Semiconductor ASA.
4  * Terms and conditions of usage are described in detail in NORDIC
5  * SEMICONDUCTOR STANDARD SOFTWARE LICENSE AGREEMENT.
6  *
7  * Licensees are granted free, non-transferable use of the information. NO
8  * WARRANTY of ANY KIND is provided. This heading must NOT be removed from
9  * the file.
10  *
11  */
12 
20 #ifndef PTU_SENSORS_H__
21 #define PTU_SENSORS_H__
22 
23 #include "ptu.h"
24 #include "ptu_hw_config.h"
25 
26 #include <stdbool.h>
27 #include <stdint.h>
28 
29 /******************************************************************************/
32 /******************************************************************************/
33 
41 uint32_t ptu_sensors_init(ptu_sm_handler_t sm_handler);
42 
48 uint32_t ptu_sensors_read(void);
49 
56 uint32_t ptu_sensors_data_get(const ptu_sensor_data_t ** sensors_data);
57 
58 
62 
86 
89 #endif /* PTU_SENSORS_H__ */
90 
void(* ptu_sm_handler_t)(ptu_sm_signal_type_t signal)
Definition: ptu.h:30
uint32_t ptu_sensors_read(void)
Read sensors. This function should typically be called regularly by a timer and can generate events b...
Definition: ptu_sensors.c:303
bool ptu_sensors_valid_long_beacon_extension_load_variation_found(void)
Check if a valid PTX load variation has occured.
Definition: ptu_sensors.c:417
uint32_t ptu_sensors_init(ptu_sm_handler_t sm_handler)
Initialize PTU Sensors. This function must be called before any other PTU Sensors function can be cal...
Definition: ptu_sensors.c:284
uint32_t ptu_sensors_data_get(const ptu_sensor_data_t **sensors_data)
Get the latest data read from the PTU sensors.
Definition: ptu_sensors.c:404
void ptu_sensors_clear_long_beacon_extension_load_variation_buffer(void)
Empty buffer containing load variation sample data for Long Beacon Extension.
Definition: ptu_sensors.c:412
Definition of PTU sensor data.
Definition: ptu_hw_config.h:99