nRF Cloud cellular positioning¶
The nRF Cloud cellular positioning library enables applications to request cellular positioning data from nRF Cloud to be used with the nRF9160 SiP. This library is an enhancement to the nRF Cloud library.
To use the nRF Cloud cellular positioning service, an nRF Cloud account is needed, and the device needs to be associated with a user’s account.
Configure the following options to enable or disable the use of this library:
nrf_cloud_cell_pos_request() function is used to request the cellular location of the device.
When nRF Cloud responds with the requested cellular positioning data, the
nrf_cloud_cell_pos_process() function processes the received data.
The function parses the data and returns the location information if it is found.
nrf_cloud_cell_pos_process(const char *buf, struct nrf_cloud_cell_pos_result *result)¶
Processes cellular positioning data received from nRF Cloud via MQTT or REST.
buf – Pointer to data received from nRF Cloud.
result – Pointer to buffer for parsing result.
0 – If processed successfully and cell-based location found.
1 – If processed successfully but no cell-based location found. Otherwise, a (negative) error code is returned.
- #include <nrf_cloud_cell_pos.h>
Cellular positioning request result.