Merge branch 'gnss-disable-after-fetch' into 'master'

gnss: disable GPS only after fetching assistance data

Closes #21

See merge request mobian1/devices/eg25-manager!32
This commit is contained in:
Arnaud Ferraris
2021-09-29 07:33:34 +00:00
2 changed files with 8 additions and 8 deletions

View File

@@ -434,6 +434,13 @@ void gnss_step(struct EG25Manager *manager)
g_message("GNSS assistance upload started..."); g_message("GNSS assistance upload started...");
/* fall-through */ /* fall-through */
case EG25_GNSS_STEP_FETCH_ASSISTANCE_DATA:
g_message("GNSS assistance upload step (%d/%d): "
"fetching assistance data",
manager->gnss_assistance_step, EG25_GNSS_STEP_LAST);
fetch_assistance_data(manager);
break;
#ifdef HAVE_MMGLIB #ifdef HAVE_MMGLIB
case EG25_GNSS_STEP_MM_GNSS_DISABLE: case EG25_GNSS_STEP_MM_GNSS_DISABLE:
if (manager->modem_iface == MODEM_IFACE_MODEMMANAGER) { if (manager->modem_iface == MODEM_IFACE_MODEMMANAGER) {
@@ -453,13 +460,6 @@ void gnss_step(struct EG25Manager *manager)
state_at_gnss(manager); state_at_gnss(manager);
break; break;
case EG25_GNSS_STEP_FETCH_ASSISTANCE_DATA:
g_message("GNSS assistance upload step (%d/%d): "
"fetching assistance data",
manager->gnss_assistance_step, EG25_GNSS_STEP_LAST);
fetch_assistance_data(manager);
break;
case EG25_GNSS_STEP_INIT_UPLOAD: case EG25_GNSS_STEP_INIT_UPLOAD:
g_message("GNSS assistance upload step (%d/%d): initiating upload", g_message("GNSS assistance upload step (%d/%d): initiating upload",
manager->gnss_assistance_step, EG25_GNSS_STEP_LAST); manager->gnss_assistance_step, EG25_GNSS_STEP_LAST);

View File

@@ -18,11 +18,11 @@
typedef enum { typedef enum {
EG25_GNSS_STEP_FIRST = 0, EG25_GNSS_STEP_FIRST = 0,
EG25_GNSS_STEP_FETCH_ASSISTANCE_DATA,
#ifdef HAVE_MMGLIB #ifdef HAVE_MMGLIB
EG25_GNSS_STEP_MM_GNSS_DISABLE, EG25_GNSS_STEP_MM_GNSS_DISABLE,
#endif #endif
EG25_GNSS_STEP_AT_GNSS_DISABLE, EG25_GNSS_STEP_AT_GNSS_DISABLE,
EG25_GNSS_STEP_FETCH_ASSISTANCE_DATA,
EG25_GNSS_STEP_INIT_UPLOAD, EG25_GNSS_STEP_INIT_UPLOAD,
EG25_GNSS_STEP_UPLOAD, EG25_GNSS_STEP_UPLOAD,
EG25_GNSS_STEP_FINISH_UPLOAD, EG25_GNSS_STEP_FINISH_UPLOAD,