0% found this document useful (0 votes)
25K views

Itrac GPRS Communication Protocol

The document describes the communication protocols for a GPS tracker (Terminal) and server. It includes: 1) Three communication channels between the Terminal and server: TCP command channel, TCP data channel, and UDP data channel. 2) Command and data formats for information exchanged between the Terminal and server, including general information, location information, and command confirmation formats. 3) Definitions of the data contained in messages including location, speed, vehicle status flags and more. 4) Descriptions of commands from the server to the Terminal covering functions like locating, clearing alarms, voice monitoring, and more.

Uploaded by

culini
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
25K views

Itrac GPRS Communication Protocol

The document describes the communication protocols for a GPS tracker (Terminal) and server. It includes: 1) Three communication channels between the Terminal and server: TCP command channel, TCP data channel, and UDP data channel. 2) Command and data formats for information exchanged between the Terminal and server, including general information, location information, and command confirmation formats. 3) Definitions of the data contained in messages including location, speed, vehicle status flags and more. 4) Descriptions of commands from the server to the Terminal covering functions like locating, clearing alarms, voice monitoring, and more.

Uploaded by

culini
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 13

GTLT3 MT-1 AS2000 Plus GPRS Communication Protocol

1. The transmission mode


The Terminal (GPS tracker) and the server has 3 communication channels:
1) TCP protocol command channel: command and the corresponding reply information uses
ASCII code to transmit via TCP, the format is the same as SMS.
2) TCP protocol data channel: The uploading data by D1 Command (V1 General Information)
transmit via binary. It transmit in the same socket as TCP Protocol command.

3) UDP protocol data channel: The uploading data by S17 Command (V1 General Information)
transmit via binary code in UDP protocol. S17 commands to UDP protocol uses binary

Channel 2), 3) The V1 General Information length is 32 bytes, called a record.

V1 message with valid location data


Terminal Server

Control Command

V4 message corresponding Control


Command

Upload V1 message according to the interval


set by D1 Command

一、Command Structure Description


1. From Server to Terminal (GPS tracker)
*XX,YYYYYYYYYY,CMD,HHMMSS,PARA1,PARA2,…#
* Command Head
XX Name,2 ASCII Character
, Separator
YYYYYYYYYY Serial Number
CMD Command
HHMM Hour/Minute/Second
PARA Command Parameters
# End Mark
Remark: All the English letters of command character in uppercase, and can’t insert a space.

2. Information Replied By Terminal


General Information:
*XX,YYYYYYYYYY,V1,HHMMSS,S,latitude,D,longitude,G,speed,direction,DDMMYY,vehic
le_status#
Location Information:
*XX,YYYYYYYYYY,V2,HHMMSS,S,latitude,D,longitude,G,speed,direction,DDMMYY,vehic
le_status#
Confirm Information:
*XX,YYYYYYYYYY,V4,CMD,hhmmss,HHMMSS,S,latitude,D,longitude,G,speed,direction,D
DMMYY,vehicle_status#

*: Command Head
XX: Name,2 ASCII Character
,: Separator
YYYYYYYYYY :Serial Number
CMD:Command
Hhmmss: The time of the confirmed server command
HHMMSS : Terminal time, GMT+0 time zone
S:A/V, A means valid location, V means invalid location
latitude: DDFF.FFFF, DD:latitude degree(00 ~ 90),FF.FFFF:latitude minute(00.0000 ~ 59.9999),
keep four decimal places
D:N/S, N means north latitude, S means south Latitude
longitude: DDDFF.FFFF,DDD: longitude degree(000 ~ 180),FF.FFFF:longitude minute(00.0000
~ 59.9999), keep four decimal places
G:E/W, E means east longitude, W means west longitude
Speed:From 000.00 ~ 999.99
Direction:True north as 0 degrees, 1 degree resolution clockwise.
DDMMYY:Day/Month/Year
Vehicle_status: Refer to 3. General Data Definition

3. General Data Definition


vehicle_status ,4 bytes, about terminal status and alarm status. ASCII character represented the
hexadecimal value.
Below is the meaning of each variable.
bit uses negative logic, means bit=0 is valid.

Order The first byte The second byte The third byte The fourth byte
0 0 undefined 0 undefined 0 undefined 0 Thief alarm
1 0 undefined 1 Low battery 0 undefined 0 Rob alarm
alarm
2 0 undefined 1 undefined 0 ACC OFF 0 Over speed alarm

3 0 GPS Tracker in 0 GPS tracker is 1 undefined 0 undefined


Disable Fuel powered via
built in battery
4 0 Main power off 0 Main Power 1 undefined 0 In geo-fence alarm
Alarm disconnect
5 0 undefined 0 undefined 0 undefined 0 undefined
6 0 undefined 0 undefined 0 undefined 0 undefined
7 0 undefined 0 undefined 0 undefined 0 Out geo-fence alarm

set_flag:

Order
Value Meaning

0 Support disable fuel/electricity


0
1 Does not Support disable fuel/electricity

0 Start auto monitoring


1
1 Does not start auto monitoring

0 Support Max speed limitation


2
1 Does not support Max speed limitation

0 Support geo-fence
3
1 Does not support geo-fence

0 Disable Voice monitoring in no alarm status


4
1 Enable Voice monitoring in no alarm status

0 Open GPRS Transmit SMS


5
1 Close GPRS Transmit SMS

0 Close SMS Uploading


6
1 Open SMS Uploading

0 Open security alarm limit


7
1 Close security alarm limit

control_stat :

order
value meaning

0 Allow incoming call

1 Permit incoming call

0 Allow dial out


1 Permit dial out

0 Speed limit is valid in valid location status only

1 Speed limit is valid in both invalid and valid location status

0 GEO-FENCE does not trigger S17

1 GEO-FENCE trigger S17

0 Dynamic turn off electricity and fuel


1 Static turn off electricity and fuel
0 Close call in/out
1 Open call in/out
0 Close GPS information output
1 Open GPS information output

二、Command Content Description


Below Command can send from server to terminal via GPRS and SMS, except special
statement.

1. Confirm Command(Confirm alarm)A1


*XX,YYYYYYYYYY,A1,HHMMSS#
Terminal will stop alarm when receive command, not clear alarm, not recover fuel and
electricity.
This command sends V1 message to server, does not reply V4 message.

2. Locating Command D1
*XX,YYYYYYYYYY,D1,HHMMSS,interval,count #
interval:from 1 ~ 65535 seconds.
count:the times terminal replies to server.
Example: interval=30, count=10, then GPS tracker will gets location every 30 seconds,
and upload 10 location report every time.
Count=1 or 0, interval is invalid, means reply one time general information.
This command sends V1 message to server, does not reply V4 message.

D1 Command:
Set batch uploading mode: GPRS D1 command does not have times limit, and it does not
change SMS D1 interval.

*XX,YYYYYYYYYY,D1,HHMMSS,interval,batch#

Interval:TCP uploading interval, value is 1 ~ 65535, unit is second


batch:the record of batch loading, value is from 1-16
batch =1 means real time mode.
Example:*HQ,000,D1,130305,5,4#
Means GPS tracker will generate locating report every 5 seconds, and sends to server
once it has 4 location reports.

Terminal will reply:


*HQ,2020916012,V1,050316,A,2212.8745,N,11346.6574,E,14.28,028,220902,FFFFFBFF
#

3. Cold Start R1
*XX,YYYYYYYYYY,R1,HHMMSS#
Example:*HQ,0000000000,R1,130305#

4. Clear Alarm R7
*XX,YYYYYYYYYY,R7,HHMMSS#
Example:*HQ,0000000000,R7,130305#

5. Voice Monitoring R8
*XX,YYYYYYYYYY,R8,HHMMSS,listen_address#
listen_address: the number that terminal call for voice monitoring

6. Set authorized sms phone number S2


*XX,YYYYYYYYYY,S2,HHMMSS,mc_address#
After receive above command, terminal will send confirmative reply to the new authorized sms
phone number, the old authorized phone number will not be recognized.
Example:
*HQ,7893267561,S2,130305,13823714880# ;(do not add country code before authorized sms
phone number)
Terminal will reply below message to new authorized sms phone number 13823714880:
*HQ,7893267561,V4,S2,130305,050315,A,2212.8745,N,11346.6574,E,14.28,028,220902,
FFFFFFFF#

7. System setting S4
*XX,YYYYYYYYYY,S4,HHMMSS,Set1,Set2#
Set1:HEX Control Word 1
Set2:HEX Control Word 2
Set1 meaning:
bit7:Security alarm control. It stores in bit7 of set_flag。 bit7=0:Open security alarm
control. If there’s theft alarm/rob alarm/password wrong alarm/illeage turn on
devie, It will close sending sms via GPRS, and open sending via sms.(Forced
bit65=11).bit7=1:Turn off Security alarm control.
bit6: The SMS sending switch control. It stores in bit6 of set_flag. bit6=0:turn off
sending via SMS. If sending sms via GPRS channel is open, it will send via GPRS, if
not, discard the message. bit6=1:open SMS sending.
bit5:Control sending SMS via GPRS , it stores in bit5 of set_flag .
bit5=0 : open sending SMS via GPRS . If GPS tracker is connected with server via
TCP,all .he SMS uploads via GPRS. bit5=1:Close sending sms via GPRS.
Default: bit765=111
bit65 meaning:

bit6 bit5
1 1 Normal Mode. SMS and GPRS are completely independent channels, SMS
information via SMS upload, GPRS information via GPRS upload; alarm
information via SMS and GPRS le uploading.

1 0 Open sending SMS via GPRS. If GPRS is online, then sends via GPRS
GPRS is busy then send via SMS.
0 1 Close SMS uploading. SMS can receive only, does not send.
The message sends via SMS cannot get reply.
0 0 Open sending sms via GPRS. Close SMS uploading channel.

bit4:GPS message output control, it stores in bit 6 of Control_stat 的 bit6, can check through
S26.
bit4=0:Open GPS message output control. bit4=1:close GPS output control.Default:bit4=1
bit3:GPS sleep control
bit3=0:open GPS sleep. ACC ON, GPS works; ACC off, GPS sleep.
bit3=1:close GPS Sleep. GPS always work. Default bit3=1
bit210:Undefined, must be 1.
Set2:bit7-0:Undefined, must be 1
Example: *HQ,0000000000,S4,130305,9F,FF#
9F=10011111,bit765=100,means close security alarm control, close sms uploading, open
GPRS uploading, close GPS message output control.

Reply:
*HQ,2020916012,V4,S4,9F,FF,130305,050315,A,2212.8745,N,11346.6574,E,14.28,028,220
902, FFFFFBFF#

8. Set incoming, outgoing phone number section condition: S5


*XX,YYYYYYYYYY,S5,HHMMSS,S,M,dial_address#
S 1-16, storage place.
M 0:virtual inquiry, igore dial_address。
1:Store dial_address to the Number S storage place, open call in/out by condition.
2 Store dial_address to the Number S storage place, close call in/out by condition.
dial_address is null, means any phone number can call in/out.
Reply:
*HQ,2020916012,V4,S5,control_stat,S,dial_address,130305,050316,A,2212.8745,N,11346.6
574,E,14.28,028,220902,FFFFFBFF#
Example::*HQ,0000000000,S5,130305,1,0,112#
Reply:
*HQ,2020916012,V4,S5,DF,1,,130305,050316,,A,2212.8745,N,11346.6574,E,14.28,028,220
902,FFFFFBFF#
Example: *HQ,0000000000,S5,130305,2,1,112#
Reply:
*HQ,2020916012,V4,S5,DF,2,112,130305,050316,A,2212.8745,N,11346.6574,E,14.28,028,2
20902,FFFFFBFF#

9. Parameters Setting S12


*XX,YYYYYYYYYY,S12,HHMMSS,set_flag#
Currently only used on S17 switch control commands, set_flag of bit1 = 0 open auto monitoring
options.
Example: *HQ,0000000000,S12,130305,60#
Reply:
*HQ,2020916012,V4,S12,130305,050316,A,2212.8745,N,11346.6574,E,14.28,028,220902,FFFFFB
FF#

10. Call Setting Command S13


*XX,YYYYYYYYYY,S13,HHMMSS, phone_flag#
phone_flag bit0=0 allow call out,bit1=0 allow answer.
Example: *HQ,0000000000,S13,130305,3D#
Reply:
*HQ,2020916012,V4,S13,130305,050316,A,2212.8745,N,11346.6574,E,14.28,028,220902,F
FF FFBFF#

11. Set Speed Limit S14


*XX,YYYYYYYYYY,S14,HHMMSS,Max_speed,Min_speed,M,countinue #
Max_speed From 1 ~ 255
Min_speed From 1 ~ 255
Max_speed=0 means cancel max speed, Min_speed=0 means cancel min speed.
Max_Speed =5-10,can be used for movement alarm.
M:Valid Condition
M = 0:Virtual setting, does not change present parameters, Terminal replies V4 message,
server can check present setting.
M = 1:Locationg data is valid(A), the speed is valid; location data is invalid(V),
it regards the speed does not exceed limit.
M = 2 or other number, speed is valid.
Countinue lasting time, from 5 ~ 65535 seconds.
Countinue = 0 means cancel speed limit function after store the new parameters, and will
set bit2=1 of set_flag.
Countinue = other number, means open speed limit, bit2 of set_flag will set as 0.
Example:*HQ,0000000000,S14,130305,100,10,1,3#
Reply:
*HQ,2020916012,V4,S14,100,10,1,3,130305,050316,A,2212.8745,N,11346.6574,E,14.28,02
8,220902,FFFFFBFF#

12. Auto Monitoring S17


*XX,YYYYYYYYYY,S17,HHMMSS,interval,batch#
Interval From 30~65535 seconds.
Batch Record by batch uploading

Example: *HQ,000,S17,130305,5,4#

Reply:

*HQ,2020916012,V4,S17,130305,050316,A,2212.8745,N,11346.6574,E,14.28,028,220902,F
FFFFBFF#
Default:Interval=30,batch=1。

13. Set Geo-fence time : S18


*XX,YYYYYYYYYY,S18,HHMMSS,countinue,K#
Countinue Lasting time, from 5 ~ 65535 seconds.
Countinue=0 , set bit 3 of set_flag as 1, and store new parameters, cancel geo-fence alarm.
Countinue= other number, open geo-fence alarm, and set bit 3 of set_flag as 0.
K:Explosion-proof function, whether trigger S17 after geo-fence alarm.
K=0:virtual setting.

14. Set custom alarms S19


*XX,YYYYYYYYYY,S19,HHMMSS,Ax,S,time,K#
Ax is defined alarm
A0: Cancel all custom alarm
A1: doors open
A2: engine running
A3: ACC open
A4: Host powered by the backup battery
A5: High Level Sensor 1 High
A6: High level sensor 2 high
A7: Low level sensor 1 Ground
A8: Low level sensor 2 Ground
A9: virtual settings, do not change any custom alarm settings for alarm monitoring center set
up custom queries
Time time , range 1-255 , in seconds , Time = 0 will not produce an alarm
S alarm trigger
0 : cancel the information to customize alarm
1 : is defined as the time in seconds to trigger the alarm information generated
2 : The second time was revoked definition information to trigger an alarm
3 : The definition of information generated and maintained seconds to trigger an alarm time
4 : revocation definition information and keep time in seconds to trigger an alarm
5: The time is defined as the information generated or revoked seconds after triggering an
alarm = 1 +2
6 : The definition of information generated or revoked and keep time in seconds to trigger an
alarm = 3 +4
K Custom S17 whether the alarm is triggered automatically trigger monitoring .
1: S17 starts automatically trigger an alarm monitoring interval from the previous S17
command definition.
0 or other numbers: the S17 does not start automatically trigger an alarm monitoring .

Example:*HQ,0000000000,S19, 130305,A3,5,3,0#
Reply:
*HQ,2020916012,V4,S19,130305,050316,A1,0,0,0,A2,1,30,1,A3,5,3,0,A4,4,10,0,A5,0,0,0,A6,
3,1,0,A7,3,10,0,A8,0,0,0#

Example:*HQ,0000000000,S19, 130305,A0,5,3,0#
Reply:
*HQ,2020916012,V4,S19,130305,050316,A1,0,0,0,A2,0,0,0,A3,0,0,0,A4,0,0,0,A5,0,0,0,A6,0,
0,0,A7,0,0,0,A8,0,0,0#

15. Open Turn off fuel/electricity S20


*XX,YYYYYYYYYY,S20,HHMMSS,C,time1,time2,…time30#
C:Final turn off electricity mode
C=0:dynamic turn off electricity/fuel, detect engine Instantaneous operation, cut
electricity/fuel for 5 seconds, force engine stops.
C=1 or other number: static cut fuel/electricity, not detect engine. Always pull off the relay,
disconnect the circuit.
time:lasting time from 1 ~ 30 seconds.
time1=0 Recover fuel/electricity
Example:
*HQ,0000000000,S20,130305,1,3,10,3,5,5,3,5,3,5,3,5#
Reply:
*HQ,2020916012,V4,S20,ERROR,130305,050316,A,2212.8745,N,11346.6574,E,14.28,028,
220902,FFFFFBFF#
Reply:
*HQ,2020916012,V4,S20,DONE,130305,050316,A,2212.8745,N,11346.6574,E,14.28,028,22
0902,F7FFFBFF#

16. Set geo-fence S21


*XX,YYYYYYYYYY,S21,HHMMSS,Lx,M,D,Minlatitude,Maxlatitude,G,Minlongitude,Maxlo
ngitude#
Lx:x = 1-64 geo-fence number,x=other number: disable all geo-fence
M:valid condition
M = 0:invalid, forbid this geo-fence, ignore all following data
M = 1 : valid when locating data is valid(A), forbid out geo-fence; Locating data is
invalid(V) , regards as no geo-fence.
M = 2:No matter locating data is valid or invalid, forbid out geo-fence.
M = 3:valid when locating data is valid(A), forbid in(enter) geo-fence; Locating data is
invalid(V) , regards as no geo-fence.
M = 4:不No matter locating data is valid or invalid, forbid in geo-fence.。
M = 5 or other number, virtual setting

D:N/S: N: North Latitude, S: South Latitude


Minlatitude: Minimum Latitude ,format DDFF.FFF, DD:degree(00 ~ 90),FF.FFF:minute
(00.0000~ 59.999) ,3 decimals.
Maxlatitude: Maximum Latitude ,format DDFF.FFF, DD:degree(00 ~ 90),FF.FFF:minute
(00.0000~ 59.999) ,3 decimals.

G:E/W, E: East Longitude, W:West Longitude


Minlongitude:Minimum longitude ,format DDFF.FFF, DD:degree(000 ~ 180),FF.FFF:
minute(00.0000~ 59.999),3 decimals.
Maxlongitude:Maximum longitude ,format DDFF.FFF, DD:degree(000 ~ 180),FF.FFF:
minute(00.0000~ 59.999),3 decimals.
Example:
*HQ,2020916012,S21,130305,17,1,N,2245.318,2246.452,E,11233.232,11365.175#
Reply:
*HQ,2020916012,V4,S21,17,1,130305,050316,N,2245.318,2246.452,E,11233.232,11365.17
5,FFFFFBFF#

Cancel number 17 geo-fence :


*HQ,2020916012,V4,S21,17,0, 130305,050316, FFFFFBFF#
Cancel all geo-fence:
*HQ,2020916012,V4,S21,0,0, 130305,050316, FFFFFBFF#

17. Grouping commands S22


*XX,YYYYYYYYYY,S22,HHMMSS,Group_id#
Group_id:0-65535, Grouping numbers
Group_id=0 means public group, vehicles in public group belongs to all groups. Default is
public group.
Reply:
*HQ,2020916012,V4,S22,group_id,130305,050316,A,2212.8745,N,11346.6574,E,14.28,028,
220902,FFFFFBFF#

18. set server IP, port, alarm :S23


*XX,YYYYYYYYYY,S23,HHMMSS,IP_addr,Port,Redial_Times #
IP_addr :server IP
Port :server port
Redial_Times:redial time, from 5-254,minimum Redial_Times is 5, Redial_Times =255
means unlimited times; more than 255, will use 256.
Note: IP address separator is a comma, not a dot, between the IP address and port number must
also be a comma; If IP address is all 0 means cancel IP setting
Example:*HQ,0000000000,S23,130305,165,165,33,250,8800,5#
Reply:
*HQ,2020916012,V4,S23,165.165.33.250:8800,130305,050316,A,2212.8745,N,11346.6574,
E,14.28,028,220902,FFFFFBFF#

19. Set APN: S24


*XX,YYYYYYYYYY,S24,HHMMSS,M,APN# M
M=0:VIRTUAL Inquiring
M=1 or other number: set APN
Example:*HQ,0000000000,S24,130305,0,ABCD.BJ#
Repply:
*HQ,2020916012,V4,S24,CMNET,130305,050316,A,2212.8745,N,11346.6574,E,14.28,028,2
20902,FFFFFBFF#

Example:*HQ,0000000000,S24,130305,2,HQit.gd#
Reply:
*HQ,2020916012,V4,S24,HQit.gd,130305,050316,A,2212.8745,N,11346.6574,E,14.28,028,2
20902,FFFFFBFF#

20. Reset to factory: S25


*XX,YYYYYYYYYY,S25,HHMMSS#
Example:*HQ,7893267561,S25,130305#
Terminal reply:
*HQ,7893267561,V4,S25,130305,050316,A,2212.8745,N,11346.6574,E,14.28,028,2
20902,FFFFFFFF#

*XX,YYYYYYYYYY,S25,HHMMSS#
Default:
Automatic monitoring: Disable
Automatic monitoring interval: 0 (65,536 seconds)
Group number: 0 (public )
Speed limit: Cancel
Turn off electricity and oil function: prohibit
Geo-fence: cancel
Cancel user-defined alarm
Allow call comes in
APN:CMNET
21. Read Vehicle Status S26
*XX,YYYYYYYYYY,S26,HHMMSS#
Reply:
*XX,YYYYYYYYYY,V4,S26,hhmmss,HHMMSS,Set_flag,S17_time,Group_id,Max_speed,Min
_speed,Speed_continue,Bound_continue,Control_stat,Usr_def_flag,Block_flag1,Block_flag2,
…Block_flag8,IP_addr, vehicle_status#
(,Usr_alarm_flag#)
S17_time:Uploading interval
Group_id:Grouping number
Max_speed:Maximum speed
Min_speed:Minimum speed
Speed_continue:Lasting time of limit speed alarm
Bound_continue:geo-fence alarm lasting time
User_def_flag:whether user customize alarm ,bit0-bit7 corresponding to A1-A8

Block_flag2:bit0-bit7 corresponding to geo-fence 9-16 definition



Block_flag8:bit0-bit7 corresponding to geo-fence 57-64 definition
IP_addr: IP address

Example:*HQ,0000000000,S26,130305#
Reply:
*HQ,2020916012,V4,S26,130305,050316,FF,0,0,0,0,0,0,E0,FF,FF,FF,FF,FF,FF,FF,FF,FF,0.0.
0.0,FFFFFBFF#,FE#

22. Set the secondary (downstream) monitoring centers SMS numbers


S28
*XX,YYYYYYYYYY,S28,HHMMSS,mc_address2#
Example:*HQ,0000000000,S28,130305,13823714888#
Reply:
*HQ,2020916012,V4,S28,13823714888,130305,050315,A,2212.8745,N,11346.6574,E,14.28,
028,220902,FFFFFBFF#
23. Set custom message S30
*XX,YYYYYYYYYY,S30,HHMMSS,Ax#
Ax: custom information to be defined
A0: cancel all custom information
A1: door opening / closing
A2: engine run / stop
A3: ACC ON / OFF
A4: Host powered by the backup battery / battery
A5: High level sensor 1 high / (low or unconnected)
A6: High level sensor 2 high / (low or unconnected)
A7: Low level sensor 1 Ground / (floating or high)
A8: Low level sensor 2 Ground / (floating or high)
A9: virtual settings, do not change any custom settings, the control center for information on
setting custom queries
The meaning of this command is to notify server if the terminal customize information is
changed.it does not change any of the text messages or alarm.

24. Mileage inquiry S32


*XX,YYYYYYYYYY,S32,HHMMSS,M#
M=0:Mileage counter is cleared
M=1 Or other: check mileage
Example:*HQ,0000000000,S32,130305,1#
Reply:
*HQ,2020916012,V4,S32,0000130502.35,130305,050316,A,2212.8745,N,11346.6574,E,14.
28,028,220902,FFFFFBFF#
0000130502.35:Mileage,unit:0.51444 meter,130502.35 is 67136.2 meters

You might also like