55 lines
1.2 KiB
C
55 lines
1.2 KiB
C
#ifndef LIBDI_INCLUDE_DI_DRV_HL854X_GPS_H_
|
|
#define LIBDI_INCLUDE_DI_DRV_HL854X_GPS_H_
|
|
|
|
#ifdef __cplusplus
|
|
extern "C" {
|
|
#endif
|
|
|
|
#include <stdbool.h>
|
|
|
|
struct di_drv_hl854x_ctx;
|
|
struct di_rpc_sensor_data_gps;
|
|
|
|
/**
|
|
* Initialize the GPS transceiver
|
|
*/
|
|
di_errno_t di_drv_hl854x_gps_init(struct di_drv_hl854x_ctx *ctx);
|
|
|
|
/**
|
|
* Start GPS transceiver
|
|
*/
|
|
di_errno_t di_drv_hl854x_gps_start(struct di_drv_hl854x_ctx *ctx);
|
|
|
|
/**
|
|
* Put GPS transceiver in sleep
|
|
*/
|
|
di_errno_t di_drv_hl854x_gps_sleep(struct di_drv_hl854x_ctx *ctx);
|
|
|
|
/**
|
|
* Stop GPS transceiver
|
|
*/
|
|
di_errno_t di_drv_hl854x_gps_stop(struct di_drv_hl854x_ctx *ctx);
|
|
|
|
/**
|
|
* Get current operating state of the GPS transceiver
|
|
*/
|
|
enum di_drv_hl854x_gps_state di_drv_hl854x_gps_get_state(struct di_drv_hl854x_ctx *ctx);
|
|
|
|
/**
|
|
* Check if last received GPS data has a 2D or 3D fix
|
|
*/
|
|
bool di_drv_hl854x_gps_has_fix(struct di_drv_hl854x_ctx *ctx);
|
|
|
|
/**
|
|
* Read last received GPS sensor data
|
|
* @param ctx Modem context
|
|
* @param data[out] Last received GPS sensor data
|
|
*/
|
|
void di_drv_hl854x_gps_get_data(struct di_drv_hl854x_ctx *ctx, struct di_rpc_sensor_data_gps *data);
|
|
|
|
#ifdef __cplusplus
|
|
}
|
|
#endif
|
|
|
|
#endif /* LIBDI_INCLUDE_DI_DRV_HL854X_GPS_H_ */
|