Changes

2,004 bytes added ,  10:37, 2 November 2018
Line 1,016: Line 1,016:     
[[Image:qqq.png|qqq.png]]
 
[[Image:qqq.png|qqq.png]]
 +
<small>Figure 3 CRC calculation algorithm</small>
 +
 +
 +
 +
*'''Command coding table'''
 +
 +
Command has to be convert from ASCII characters (char) to hexadecimal (Hex)
 +
 +
Table 2 ASCII conversion table
 +
 +
[[Image:asa.png|asa.png]]
 +
 +
 +
*'''Command parsing example'''
 +
 +
Hexadecimal stream of command and answer in this example are given in hexadecimal form. The different fields of message are highlighted in gray and yellow for better readability and command is converted in ASCII for better understanding.
 +
 +
'''Server command'''
 +
 +
Hexadecimal stream:
 +
 +
[[Image:sx.png|sx.png]]
 +
 +
Parsed:
 +
 +
Preamble: 0x00000000
 +
 +
Packet Length: 0x00000018
 +
 +
Codec: 0x0C
 +
 +
Quantity of commands: 0x01
 +
 +
Command type: 0x05
 +
 +
Command size: 0x00000010
 +
 +
Command in ASCII after conversion: #GET DATAORDER<CR><LF>
 +
 +
Quantity of commands: 0x01
 +
 +
CRC: 0x00004990
 +
 +
 +
'''Device answer'''
 +
 +
Hexadecimal stream:
 +
 +
[[Image:sds.png|sds.png]]
 +
 +
Parsed:
 +
 +
Preamble: 0x00000000
 +
 +
Packet Length: 0x00000016
 +
 +
Codec: 0x0C
 +
 +
Quantity of commands: 0x01
 +
 +
Command type: 0x06
 +
 +
Command size: 0x0000000E
 +
 +
Command response is in ASCII after conversion: #DATAORDER=1<CR><LF>
 +
 +
Quantity of commands: 0x01
 +
 +
CRC: 0x00000095
 +
 +
 +
 +
*'''Codec12 GPRS commands examples'''
 +
 +
The example commands given in hexadecimal form separated by dollar signs are suitable to be sent from TCP server during data exchange session between FMXXXX device and server (for more details see Figure 1 Command session) The command can be sent from a terminal program such as Hercules (in TCP server mode). Simply write command as explained below into Hercules Send field and click Send button. The TCP server must be listening on specified port (see field Port and button Listen in Figure 4).
 +
 +
[[Image:he.png|he.png]]
 +
 +
<small>Figure 4 Hercules terminal GUI</small>
 +
 +
 +
*'''SMS over GPRS in Codec12 examples'''
 +
 +
In case of sending SMS commands over GPRS, do not use SMS logins set during configuration or do not leave empty spaces before command. Devices and firmware versions that support SMS over GPRS are listed in Table1.
    
== <big>Codec 13 Nebaigta</big> ==
 
== <big>Codec 13 Nebaigta</big> ==