http://www.wavecom.com/forum

Open AT ®  Release version:
3.13

Sample - GPS

Changes

Dependencies

This sample depends on the following libraries :

Application Description

This application allows to retrieve Q2501 module GPS chip position data.

As this application uses the MultiApp library, the following start/stop command has to be used to control the application execution.

 

  AT+GPSSTART (GPS start/stop command)
CommandAnswers
AT+GPSSTART?+GPSSTART: <state>
OK
AT+GPSSTART=?+GPSSTART: (0-1)
OK
AT+GPSSTART= <state> +CME ERROR: 3
or
OK
 
ParameterValues rangeDescriptionDefault value
state0-1The current application running state. This parameter is stored in non-volatile memory.0

The init entry point sent to the MultiApp library is the gps_init() function. The start/stop entry points linked to the +GPSSTART command are the gps_run() and gps_stop() functions.

This application provides a command set to configure the GPS chip, and to retrieve GPS data.

 

  AT+GPSCFG (GPS settings command)
CommandAnswers
AT+GPSCFG?+GPSCFG: <Autostart> , <PollingTimer> , <State>
OK
AT+GPSCFG=?+GPSCFG: (0-1) , (0-255)
OK
AT+GPSCFG= <Autostart> , <PollingTimer> +CME ERROR: 3
or
OK
 
ParameterValues rangeDescriptionDefault value
Autostart0-1ADL GPS service autostart0
PollingTimer0-255ADL GPS service polling timer (in seconds)3
State0-4ADL GPS service state (see adl_gps.h)NA

 

  AT+GPSGET (GPS data query command)
CommandAnswers
AT+GPSGET=?+GPSGET: (0-2)
OK
AT+GPSGETBehaves as AT+GPSGET=0
AT+GPSGET= <mode> +CME ERROR: 3
or
+GPSGET: <lat>,<lat_ind>,<long>,<long_ind>
OK
or
+GPSGET: <course>,<speed>
OK
or
+GPSGET: <satnb>
OK
 
ParameterValues rangeDescriptionDefault value
mode0-20 : Get Position
1 : Get Speed
2 : Get Satellite View
mandatory
lat-latitudeNA
lat_ind-latitude indicatorNA
long-longitudeNA
long_ind-longitude indicatorNA
course-course (in degrees)NA
speed-speed (in km/h)NA
satnb-satellites numberNA

If the PollingTime parameter of +GPSCFG command is greater than 0, on each polling interval, the following unsolicited result is displayed :

Where time and date parameters are read from the GPS chip.


Updated: Wed Apr 4 13:12:39 CEST 2007;