Use C # For text message CMPP3.0/2.0 protocol

Source: Internet
Author: User

The CMPP3.0/CMPP2.0 text message sending program previously implemented by C # supports long messages and can be automatically reconnected.

Implementation of long SMS:

When the length of a short message exceeds the maximum length specified in the Protocol, it can be split and sent.
The CMPP protocol specifies that the maximum length of a short message is 140 (when the DCS is not 0)
The UDHI field of the split message must be set to 1, indicating that the message content has a header structure.
The header structure for long message splitting is as follows:
05 00 03 00 04 01 ...............................
1 2 3 4 5 6
1, indicating the length of the subsequent header, excluding itself
3, indicating that the header structure is a split continuous short message.
5 indicates the total number of shards.
6 indicates the number of entries.
For more information, see specifications.
The following is the encoded Short Message content.
The short message length is the length of the header structure.
For example, after a short message is encoded, it must be split into three
AAAAAABBBBBBCCCCCC

DCS is 8
The three items are:
05 00 03 00 03 01 00 41 00 41 00 41 00 41 00 41 00 41

05 00 03 00 03 02 00 42 00 42 00 42 00 42 00 42 00 42 00 42

05 00 03 00 03 03 00 43 00 43 00 43 00 43 00 43 00 43

Each of the three messages has 1 UDHI.

 

Test applet interface:

Interface 2:

CMPP2.0 Protocol documentation CMPP3.0 Protocol documentation

At the same time, there are instance documents that provide gateway simulators, packet capture tools, long text message implementation methods, and how to fill in parameters, and use the code to test the applet source code. Promised to help debug the application.

This program does not provide free download. If necessary, please contact y QQ: 271963990.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.