Skip to content

GNSS&LBS&Wi-Fi Positioning Commands

GNSS&LBS&Wi-Fi Positioning Command Overview

AT CommandDescription
AT+QIOTLOCINObtain/Report Location Data of Built-in Positioning Feature of Module
AT+QIOTLOCEXTReport Location Data Obtained from External GNSS Module

AT Command Description

AT+QIOTLOCIN (Obtain/Report Location Data of Built-in Positioning Feature of Module)

  • Description: This command obtains or reports the location data of the built-in positioning device feature.
  • Maximum Response Time: 300 ms.

Test Command

  • Issue

    c
    AT+QIOTLOCIN=?
  • Response

    Return the supported parameter range.

    c
    +QIOTLOCIN: <type>,<mode1>[,<mode2>[,...]]
    
    OK

Read Command

  • Issue

    c
    AT+QIOTLOCIN?
  • Response

    Return the current NMEA data

    c
    +QIOTLOCIN: <mode1>[,<mode2>[,...]]
    
    OK

Write Command

  • Issue

    c
    AT+QIOTLOCIN=<type>,<mode1>[,<mode2>[,...]]
  • Response

    If the command is executed successfully:

    • If <type>=1, obtain the location data of the built-in positioning feature of the device:
    c
    [+QIOTLOCIN: <nmea1>]
    [+QIOTLOCIN: <nmea2>]
    [...]
    
    OK
    • If <type>=0, report the location data of the built-in positioning feature of the device:

      • If a Package ID has been configured to respond to the uplink message:
      c
      +QIOTLOCIN: <txid>
      
      OK
      • If not:
      c
      OK

    If there is any error:

    c
    ERROR

Parameter

  • <type> Integer type. Operation type.
    • 0 : Report NMEA sentence data to Developer Center
    • 1 : Obtain current NMEA sentence data of the device
  • <modeN> String type. NMEA sentence data type.
  • <nameN> String type. NMEA sentence data.
  • <txid> Integer type. Uplink data ID. Range: 1–65535.

NOTE

  • This command is supported in SDK versions 2.1.2 and above. Parameter <txid> is not supported.

Example

Example 1 (Query location data of built-in positioning feature of device.)

c
[TX]AT+QIOTLOCIN?

[RX]+QIOTLOCIN: "AUTO","LBS"

[RX]OK

Example 2 (Obtain location data of built-in positioning feature of device.)

c
[TX]AT+QIOTLOCIN=1,"LBS"

[RX]+QIOTLOCIN: "$LBS,460,02,0,455,-113,0*71"
[RX]+QIOTLOCIN: "$LBS,460,01,0,456,-100,0*69"


[RX]OK

Example3 (Report location data of built-in positioning feature of device to Developer Center.)

c
[TX]AT+QIOTLOCIN=0,"LBS"

[RX]OK

[RX]+QIOTEVT: 4,10220

AT+QIOTLOCEXT (Report Location Data Obtained from External GNSS Module)

  • Description: This command reports the location data obtained from the external GNSS module.
  • Maximum Response Time: 300 ms.

Test Command

  • Issue

    c
    AT+QIOTLOCEXT=?
  • Response

    Return the parameter range supported to be set.

    c
    +QIOTLOCEXT: <nmea1>[,<nmea2>[,...]]
    
    OK

Write Command

  • Issue

    c
    AT+QIOTLOCEXT=<nmea1>[,<nmea2>[,...]]
  • Response

    If the command is executed successfully:

    • If a Package ID has been configured to respond to the uplink message:
    c
    +QIOTLOCEXT: <txid>
    
    OK
    • If not:
    c
    OK

    If there is any error:

    c
    ERROR

Parameter

  • <nameN> String type. NMEA sentence data.
  • <txid> Integer type. Uplink data ID. Range: 1–65535.

NOTE

  • This command is supported in SDK versions 2.1.2 and above. Parameter <txid> is not supported.

Example

Example 1 (Report location data obtained from external GNSS module to Developer Center.)

c
[TX]AT+QIOTLOCEXT="$GPGGA,042523.0,3116.552,N,12138.7385,E,1,05,2.6,438.5,M,-28.0,M,,*78"

[RX]OK

[RX]+QIOTEVT: 4,10220