Two modes of SMS: TXT (1) and PDU (0)
Length (PDU) = Length (SMSC) Length (TPDU)
SMSC: Short Message Service Center Short Message Service Center
Example 01:
08 91 683108501505F0 11 00 0B 81 3106656930F1 0000A7 0BE8329BFD06DDDF723619
Subsection
Subparagm
Interpretation of subsequences
(01)
08
The length of the short message center address is byte, which is equal to the total number of bytes of the three subsections (02,03 length bytes plus 1).
(02)
91
Short message center number, 91 is Ton / NPI. Ton / NPI complies with the International / E.164 standard, refers to the number of ' ' before the number; there can be other values, but 91 is most common.
(03)
683108501505F0
Short message numbers are the service center address used. Due to the slightly processing, the actual number should be: 8613805515500 (the letter F means the length is 1), which is the number of the author's GSM Short Message Center.
(04)
11
The file header byte (Header Byte is a bitmask). Here 11 refers to normal transmission of short information.
(05)
00
Information type.
(06)
0B
The called number length (11-bit length).
(07)
81
Called number type
(08)
3106656930F1
The called number has also been displaced, and the actual number is 13605696031.
(08)
0000A7
Short message encoding type GSM Default alphabet, 000010 is 000010, for example, in Chinese.
(10)
0B
Short message length. (Code previous length 11 ???)
(11)
E8329BFD06DDDF723619
Short message "Hello World!"
Example 02 - Read SMS:
0891683108100005F0040D91683119111797F6000040609260452223037ABD19
08 91 683108100005F0 04 0D 91 683119111797F6 0000406092 60452223 037ABD19
08 91 683108100005F0 040D91 683119111797F6 0000 406092 6045223 03 7ABD19
Z 7a 0111 1010 è 0111 1010 è7a
Z 7a 0111 1010 è 1011 1101 èbd
F 66 0110 0110 è 0001 1001 è19
Subsection
Subparagm
Interpretation of subsequences
(01)
08
The length of the short message center address is byte, which is equal to the total number of bytes of the three subsections (02,03 length bytes plus 1). (02)
91
Short message center number, 91 is Ton / NPI. Ton / NPI complies with the International / E.164 standard, refers to the number of ' ' before the number; there can be other values, but 91 is most common.
(03)
683108501505F0
Short message numbers are the service center address used. Due to the slightly processing, the actual number should be: 8613805515500 (the letter F means the length is 1), which is the number of the author's GSM Short Message Center.
(04)
04
The first byte in the TPDU. 04: No Moew Messages Are Waiting for MS in this SC indicates that the Short Message Service Center is not
(05)
0D 91 683119111797F6
Information type.
(06)
00
TP-PID: TP-Protocol-Identifier
(07)
00
TP-DCS: TP-DATA-CODING-Schema
(08)
406092 60452223
040629 06542232 "04/06/29, 06: 54: 22 32"
(09)
03
TP-UDL: TP-User-Data-LENGTH
(10)
7ABD19 TP-UD: TP-User Data 7Abd19è After decoding, "ZZF"
Send
08 91 683108501505F0 11 00 0B 81 3106656930F1 0000A7 0BE8329BFD06DDDF723619
Receive
0891683108100005F0040D91683119111797F6000040609260452223037ABD19
08 91 683108100005F0 04 0D 91 683119111797F6 0000406092 60452223 037ABD19
New send short message
08 91 683108100005F0 11 00 0B 81 3119111797f6 0000A7 0BE8329BFD06DDDF723619
0891683108100005F011000B813119111797F60000A70BE8329BFD06DDDF723619
13911171796F
3119111797F6
08:
Short message center address length
91:
Short message center number, 91 is Ton / NPI. Ton / NPI complies with the International / E.164 standard, refers to the number of ' ' before the number; there can be other values, but 91 is most common.
683108100005f0:
Short message numbers are the service center address used. Due to its slightly processing, the actual number should be: 8613800100500 (the letter F means less than 1), which is the number of the author's GSM Short Message Center.
OK
AT CMGF = 1
OK
AT CMGR = 2