nrfxlib API 0.1.0
Loading...
Searching...
No Matches

◆ nrf_modem_gnss_fix_interval_set()

int32_t nrf_modem_gnss_fix_interval_set ( uint16_t  fix_interval)

#include <nrf_modem/include/nrf_modem_gnss.h>

Sets the GNSS fix interval in seconds.

Single fix navigation mode is engaged by setting the fix interval to 0.

Continuous navigation mode is engaged by setting fix interval to 1.

Periodic navigation mode is engaged by setting the fix interval to value 10...65535. The unit is seconds.

Default value: 1 (continuous navigation)

Note
In periodic navigation mode, when GNSS determines it needs to download ephemerides or almanacs from the broadcast, the fix interval and fix retry parameters are temporarily ignored. GNSS will perform scheduled downloads until it has downloaded the data it needs, after which normal operation is resumed.
Parameters
[in]fix_interval0 for single fix, 1 for continuous navigation or fix interval in seconds.
Return values
0on success.
-NRF_EPERMThe Modem library is not initialized.
-NRF_EACCESGNSS is not enabled in system or functional mode.
-NRF_EINVALThe GNSS stack returned an error or the operation cannot be executed while GNSS is running.
-NRF_ENOMEMThere is not enough shared memory for this request.
-NRF_ESHUTDOWNThe modem was shut down.