Skip to content

Commit a9e9fa6

Browse files
committed
app: Rename AT#XGPS to AT#XGNSS
Jira: SLM-127 Signed-off-by: Juha Ylinen <juha.ylinen@nordicsemi.no>
1 parent aaf201c commit a9e9fa6

3 files changed

Lines changed: 60 additions & 60 deletions

File tree

app/src/gnss/sm_at_gnss.c

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -58,10 +58,10 @@ static struct modem_pipe *gnss_pipe;
5858
/* UTC/GPS time offset as of 1st of January 2017. */
5959
#define GPS_TO_UTC_LEAP_SECONDS (18UL)
6060

61-
/** #XGPS operations. */
61+
/** #XGNSS operations. */
6262
enum sm_gnss_operation {
63-
GPS_STOP,
64-
GPS_START,
63+
GNSS_STOP,
64+
GNSS_START,
6565
};
6666

6767
#if defined(CONFIG_SM_NRF_CLOUD)
@@ -134,7 +134,7 @@ static void gnss_status_notifier(struct k_work *)
134134
{
135135
while (!k_fifo_is_empty(&gnss_status_fifo)) {
136136
gnss_status = (enum gnss_status)k_fifo_get(&gnss_status_fifo, K_NO_WAIT);
137-
rsp_send("\r\n#XGPS: 1,%d\r\n", gnss_status);
137+
rsp_send("\r\n#XGNSS: 1,%d\r\n", gnss_status);
138138
}
139139
}
140140

@@ -569,7 +569,7 @@ static void gnss_fix_sender(struct k_work *)
569569
}
570570

571571
/* GIS accuracy: http://wiki.gis.com/wiki/index.php/Decimal_degrees, use default .6lf */
572-
rsp_send("\r\n#XGPS: %lf,%lf,%f,%f,%f,%f,\"%04u-%02u-%02u %02u:%02u:%02u\"\r\n",
572+
rsp_send("\r\n#XGNSS: %lf,%lf,%f,%f,%f,%f,\"%04u-%02u-%02u %02u:%02u:%02u\"\r\n",
573573
pvt.latitude, pvt.longitude, (double)pvt.altitude,
574574
(double)pvt.accuracy, (double)pvt.speed, (double)pvt.heading,
575575
pvt.datetime.year, pvt.datetime.month, pvt.datetime.day,
@@ -686,8 +686,8 @@ static void gnss_event_handler(int event)
686686
}
687687
}
688688

689-
SM_AT_CMD_CUSTOM(xgps, "AT#XGPS", handle_at_gps);
690-
static int handle_at_gps(enum at_parser_cmd_type cmd_type, struct at_parser *parser,
689+
SM_AT_CMD_CUSTOM(xgnss, "AT#XGNSS", handle_at_gnss);
690+
static int handle_at_gnss(enum at_parser_cmd_type cmd_type, struct at_parser *parser,
691691
uint32_t param_count)
692692
{
693693
int err = 0;
@@ -708,7 +708,7 @@ static int handle_at_gps(enum at_parser_cmd_type cmd_type, struct at_parser *par
708708
if (err) {
709709
return err;
710710
}
711-
if (op == GPS_START) {
711+
if (op == GNSS_START) {
712712
if (gnss_running) {
713713
LOG_ERR("GNSS is already running. Stop it first.");
714714
return -EBUSY;
@@ -787,7 +787,7 @@ static int handle_at_gps(enum at_parser_cmd_type cmd_type, struct at_parser *par
787787
}
788788

789789
err = gnss_startup();
790-
} else if (op == GPS_STOP && param_count == 2) {
790+
} else if (op == GNSS_STOP && param_count == 2) {
791791
if (gnss_running) {
792792
err = gnss_shutdown();
793793
} else {
@@ -799,12 +799,12 @@ static int handle_at_gps(enum at_parser_cmd_type cmd_type, struct at_parser *par
799799
break;
800800

801801
case AT_PARSER_CMD_TYPE_READ:
802-
rsp_send("\r\n#XGPS: %d,%d\r\n", (int)is_gnss_activated(), gnss_status);
802+
rsp_send("\r\n#XGNSS: %d,%d\r\n", (int)is_gnss_activated(), gnss_status);
803803
break;
804804

805805
case AT_PARSER_CMD_TYPE_TEST:
806-
rsp_send("\r\n#XGPS: (%d,%d),(0,1),<interval>,<timeout>\r\n",
807-
GPS_STOP, GPS_START);
806+
rsp_send("\r\n#XGNSS: (%d,%d),(0,1),<interval>,<timeout>\r\n",
807+
GNSS_STOP, GNSS_START);
808808
break;
809809

810810
default:
@@ -815,8 +815,8 @@ static int handle_at_gps(enum at_parser_cmd_type cmd_type, struct at_parser *par
815815
return err;
816816
}
817817

818-
SM_AT_CMD_CUSTOM(xgpsdel, "AT#XGPSDEL", handle_at_gps_delete);
819-
static int handle_at_gps_delete(enum at_parser_cmd_type cmd_type, struct at_parser *parser,
818+
SM_AT_CMD_CUSTOM(xgnssdel, "AT#XGNSSDEL", handle_at_gnss_delete);
819+
static int handle_at_gnss_delete(enum at_parser_cmd_type cmd_type, struct at_parser *parser,
820820
uint32_t)
821821
{
822822
int err = -EINVAL;
@@ -832,7 +832,7 @@ static int handle_at_gps_delete(enum at_parser_cmd_type cmd_type, struct at_pars
832832
break;
833833

834834
case AT_PARSER_CMD_TYPE_TEST:
835-
rsp_send("\r\n#XGPSDEL: <mask>\r\n");
835+
rsp_send("\r\n#XGNSSDEL: <mask>\r\n");
836836
err = 0;
837837
break;
838838

doc/app/GNSS_AT_commands.rst

Lines changed: 44 additions & 44 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ This page describes GNSS-related AT commands.
1212
Control GNSS
1313
============
1414

15-
The ``#XGPS`` command controls the GNSS.
15+
The ``#XGNSS`` command controls the GNSS.
1616

1717
Set command
1818
-----------
@@ -35,7 +35,7 @@ Syntax
3535

3636
::
3737

38-
#XGPS=<op>,<cloud_assistance>,<interval>[,<timeout>]
38+
#XGNSS=<op>,<cloud_assistance>,<interval>[,<timeout>]
3939

4040
The ``<op>`` parameter can have the following integer values:
4141

@@ -104,7 +104,7 @@ Unsolicited notification
104104

105105
.. code-block::
106106
107-
#XGPS: <latitude>,<longitude>,<altitude>,<accuracy>,<speed>,<heading>,<datetime>
107+
#XGNSS: <latitude>,<longitude>,<altitude>,<accuracy>,<speed>,<heading>,<datetime>
108108
109109
* The ``<latitude>`` value represents the latitude in degrees.
110110
* The ``<longitude>`` value represents the longitude in degrees.
@@ -118,7 +118,7 @@ Unsolicited notification
118118
119119
.. code-block::
120120
121-
#XGPS: <gnss_service>,<gnss_status>
121+
#XGNSS: <gnss_service>,<gnss_status>
122122
123123
* The ``<gnss_service>`` parameter is an integer.
124124
When it has the value ``1``, it means that GNSS is supported in ``%XSYSTEMMODE`` and activated in ``+CFUN``.
@@ -145,15 +145,15 @@ Example
145145
AT+CFUN=31
146146

147147
OK
148-
AT#XGPS=1,0,0,0
148+
AT#XGNSS=1,0,0,0
149149

150-
#XGPS: 1,1
150+
#XGNSS: 1,1
151151

152152
OK
153153

154-
#XGPS: 1,4
154+
#XGNSS: 1,4
155155

156-
#XGPS: 35.457576,139.625090,121.473785,22.199919,0.442868,0.000000,"2021-06-02 06:25:48"
156+
#XGNSS: 35.457576,139.625090,121.473785,22.199919,0.442868,0.000000,"2021-06-02 06:25:48"
157157

158158
::
159159

@@ -176,22 +176,22 @@ Example
176176

177177
OK
178178
#XNRFCLOUD: 1,0
179-
AT#XGPS=1,1,0,1
179+
AT#XGNSS=1,1,0,1
180180

181-
#XGPS: 1,1
181+
#XGNSS: 1,1
182182

183183
OK
184184

185-
#XGPS: 35.457417,139.625211,162.850952,15.621976,1.418092,0.000000,"2021-06-02 05:21:31"
185+
#XGNSS: 35.457417,139.625211,162.850952,15.621976,1.418092,0.000000,"2021-06-02 05:21:31"
186186

187-
#XGPS: 35.457435,139.625348,176.104797,14.245458,1.598184,69.148659,"2021-06-02 05:21:32"
187+
#XGNSS: 35.457435,139.625348,176.104797,14.245458,1.598184,69.148659,"2021-06-02 05:21:32"
188188

189-
#XGPS: 35.457417,139.625415,179.132980,13.318132,1.235241,69.148659,"2021-06-02 05:21:33"
189+
#XGNSS: 35.457417,139.625415,179.132980,13.318132,1.235241,69.148659,"2021-06-02 05:21:33"
190190

191-
#XGPS: 35.457410,139.625469,181.223541,12.667312,0.803951,69.148659,"2021-06-02 05:21:34"
192-
AT#XGPS=0
191+
#XGNSS: 35.457410,139.625469,181.223541,12.667312,0.803951,69.148659,"2021-06-02 05:21:34"
192+
AT#XGNSS=0
193193

194-
#XGPS: 1,0
194+
#XGNSS: 1,0
195195

196196
OK
197197

@@ -213,38 +213,38 @@ Example
213213

214214
OK
215215
#XNRFCLOUD: 1,0
216-
AT#XGPS=1,0,1,30
216+
AT#XGNSS=1,0,1,30
217217

218-
#XGPS: 1,1
218+
#XGNSS: 1,1
219219

220220
OK
221221

222-
#XGPS: 1,2
222+
#XGNSS: 1,2
223223

224-
#XGPS: 1,4
224+
#XGNSS: 1,4
225225

226-
#XGPS: 35.457243,139.625435,149.005020,28.184258,10.431827,281.446014,"2021-06-24 04:35:52"
226+
#XGNSS: 35.457243,139.625435,149.005020,28.184258,10.431827,281.446014,"2021-06-24 04:35:52"
227227

228-
#XGPS: 1,2
228+
#XGNSS: 1,2
229229

230-
#XGPS: 1,4
230+
#XGNSS: 1,4
231231

232-
#XGPS: 35.457189,139.625602,176.811203,43.015198,0.601837,281.446014,"2021-06-24 04:36:32"
232+
#XGNSS: 35.457189,139.625602,176.811203,43.015198,0.601837,281.446014,"2021-06-24 04:36:32"
233233

234-
#XGPS: 1,2
234+
#XGNSS: 1,2
235235

236-
#XGPS: 1,4
236+
#XGNSS: 1,4
237237

238-
#XGPS: 35.457498,139.625422,168.243591,31.753956,0.191195,281.446014,"2021-06-24 04:37:12"
238+
#XGNSS: 35.457498,139.625422,168.243591,31.753956,0.191195,281.446014,"2021-06-24 04:37:12"
239239

240-
#XGPS: 1,2
240+
#XGNSS: 1,2
241241

242-
#XGPS: 1,4
242+
#XGNSS: 1,4
243243

244-
#XGPS: 35.457524,139.624667,100.745979,25.324850,6.347160,94.699837,"2021-06-24 04:37:52"
245-
AT#XGPS=0
244+
#XGNSS: 35.457524,139.624667,100.745979,25.324850,6.347160,94.699837,"2021-06-24 04:37:52"
245+
AT#XGNSS=0
246246

247-
#XGPS: 1,0
247+
#XGNSS: 1,0
248248

249249
OK
250250

@@ -258,7 +258,7 @@ Syntax
258258

259259
::
260260

261-
#XGPS?
261+
#XGNSS?
262262

263263
Response syntax
264264
~~~~~~~~~~~~~~~
@@ -272,9 +272,9 @@ Example
272272

273273
::
274274

275-
AT#XGPS?
275+
AT#XGNSS?
276276

277-
#XGPS: 1,1
277+
#XGNSS: 1,1
278278

279279
OK
280280

@@ -288,23 +288,23 @@ Syntax
288288

289289
::
290290

291-
#XGPS=?
291+
#XGNSS=?
292292

293293
Example
294294
~~~~~~~
295295

296296
::
297297

298-
AT#XGPS=?
298+
AT#XGNSS=?
299299

300-
#XGPS: (0,1),(0,1),<interval>,<timeout>
300+
#XGNSS: (0,1),(0,1),<interval>,<timeout>
301301

302302
OK
303303

304304
Delete GNSS data
305305
================
306306

307-
The ``#XGPSDEL`` command deletes GNSS data from non-volatile memory.
307+
The ``#XGNSSDEL`` command deletes GNSS data from non-volatile memory.
308308
This command should be issued when GNSS is activated but not started yet.
309309

310310
.. note::
@@ -322,7 +322,7 @@ Syntax
322322

323323
::
324324

325-
#XGPSDEL=<mask>
325+
#XGNSSDEL=<mask>
326326

327327
The ``<mask>`` parameter accepts an integer that is the ``OR`` value of the following bitmasks :
328328

@@ -345,7 +345,7 @@ Example
345345
OK
346346
AT+CFUN=31
347347
OK
348-
AT#XGPSDEL=511
348+
AT#XGNSSDEL=511
349349
OK
350350
AT+CFUN=0
351351
OK
@@ -365,15 +365,15 @@ Syntax
365365

366366
::
367367

368-
#XGPSDEL=?
368+
#XGNSSDEL=?
369369

370370
Example
371371
~~~~~~~
372372

373373
::
374374

375-
AT#XGPSDEL=?
375+
AT#XGNSSDEL=?
376376

377-
#XGPSDEL: <mask>
377+
#XGNSSDEL: <mask>
378378

379379
OK

doc/app/Generic_AT_commands.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,7 @@ Example
109109
AT#XSENDTO
110110
AT#XRECVFROM
111111
AT#XPING
112-
AT#XGPS
112+
AT#XGNSS
113113
OK
114114

115115
Read command

0 commit comments

Comments
 (0)