A file transmission method and system based on satellite short message
By introducing a credit flow control mechanism in the Beidou satellite system, the files are divided and encapsulated into short messages to transmit, the problem of lack of file transfer solutions in the Beidou satellite system is solved, and the secure transmission and integrity verification of files are achieved. The storage space of the receiver ensures transmission security and traffic control.
Patent Information
- Application Number
- CN202410434831.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-04-11
- Publication Date
- 2024-11-12
- Estimated Expiration
- 2044-04-11
AI Technical Summary
The existing Beidou satellite system lacks file transfer solutions, which cannot meet the needs of transferring files through satellites.
By improving the credit flow control mechanism, the file is divided into multiple strings and encapsulated into short messages based on the Beidou protocol. The receiver consumes credit credit according to the string size and order to achieve file integrity checksum Flow control.
It realizes the secure transmission of files, makes full use of the receiver's storage space, ensures transmission security and file integrity, avoids traffic being occupied, and determines the delivery of short messages through the credit credit mechanism.
Smart Images

Figure CN118158215B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of Beidou satellite short message, and in particular to a file transmission method and system based on satellite short message. Background Art
[0002] The short message transmission protocol mainly used by the Beidou satellite system is BDTP (Beidou Data Transmission Protocol), also known as the Beidou data transmission protocol. This protocol is designed to meet the short data transmission needs of the Beidou satellite system and is mainly used for the transmission of short text messages and data in the Beidou satellite network.
[0003] With the development of technology, people need to transmit files through the Beidou satellite system, not just short messages. Currently, there is no relevant solution for transmitting files.
[0004] In view of this, the present invention is proposed. Summary of the invention
[0005] In order to solve the above technical problems, the present invention provides a file transmission method and system based on satellite short messages, which realizes the transmission of files through short messages and realizes the flow control, transmission security and integrity verification of files by improving the credit flow control mechanism.
[0006] In a first aspect, an embodiment of the present invention provides a file transmission method based on satellite short messages, comprising:
[0007] The sender encodes and divides the file to be sent to obtain multiple character strings; each character string expresses the content and the format of the content;
[0008] The sender determines the corresponding amount of credit according to the number of character strings, and uses the size and order of the character strings as additional attributes of the credit, and transmits the credit information to the receiver;
[0009] The sender encapsulates each character string into a corresponding short message based on the Beidou protocol and sends the short message to the receiver;
[0010] The receiving party performs protocol parsing on the short message to obtain a character string, and consumes corresponding credits according to the size and order of the character string until all credits are consumed and the file integrity check is passed;
[0011] The receiver reads the contents and formats of the multiple character strings and synthesizes the file.
[0012] Optionally, the sender encodes and splits the file to be sent to obtain multiple strings, including:
[0013] The sender encodes the content in the file to be sent into hexadecimal data, divides the hexadecimal data into a plurality of first character strings, and encodes the format of the content corresponding to each first character string into a second character string;
[0014] The sender concatenates the first character string with the corresponding second character string.
[0015] Optionally, the format includes at least a paragraph format, a background image format and a font format;
[0016] The files include at least text files, pictures and videos;
[0017] The encoding methods include at least text encoding, pixel-based encoding and streaming media protocol-based encoding.
[0018] Optionally, corresponding credits are consumed according to the size and order of the strings, including:
[0019] Get the size and order of the string;
[0020] Search for the information of corresponding size and order in all credit information and delete it.
[0021] Optionally, after the sender encapsulates each character string into a corresponding short message based on the Beidou protocol and sends it to the receiver, the method further includes:
[0022] If there are unconsumed credits within the set time, it is determined that a short message is lost and the file integrity check fails.
[0023] Optionally, after the sender encapsulates each character string into a corresponding short message based on the Beidou protocol and sends it to the receiver, the method further includes:
[0024] If the information of the corresponding size and order is not found in all the credit information, the corresponding string will be discarded.
[0025] Optionally, after the sender encapsulates each character string into a corresponding short message based on the Beidou protocol and sends it to the receiver, the method further includes:
[0026] The sender receives the information of consumed credits fed back by the receiver and deletes the corresponding credit information locally.
[0027] Optionally, transmitting the credit information to a recipient includes:
[0028] Based on the BDTP protocol, the credit information is encrypted and transmitted to the recipient.
[0029] Optionally, after transmitting the credit information to the recipient, the method further includes:
[0030] The receiving party determines the amount of data allowed to be received according to the current storage space;
[0031] If the data amount is greater than or equal to the sum of the data amounts represented by all credits, notify the sender to send the data;
[0032] If the data volume is less than the sum of the data volumes represented by all credits, the local credit information is reset according to the data volume and fed back to the sender, so that the sender can send according to the reset credit. When the next sending cycle arrives, the remaining credit information is sent to the receiver, and the sender encapsulates each character string into the corresponding short message based on the Beidou protocol and sends it to the receiver.
[0033] The remaining credit is the total credit minus the reset credit.
[0034] In a second aspect, an embodiment of the present invention provides a file transmission system based on satellite short messages, including a sender and a receiver;
[0035] The sender encodes and divides the file to be sent to obtain multiple character strings; each character string expresses the content and the format of the content;
[0036] The sender determines the corresponding amount of credit according to the number of character strings, and uses the size and order of the character strings as additional attributes of the credit, and transmits the credit information to the receiver;
[0037] The sender encapsulates each character string into a corresponding short message based on the Beidou protocol and sends the short message to the receiver;
[0038] The receiving party performs protocol parsing on the short message to obtain a character string, and consumes corresponding credits according to the size and order of the character string until all credits are consumed and the file integrity check is passed;
[0039] The receiver reads the contents and formats of the multiple character strings and synthesizes the file.
[0040] The embodiments of the present invention have the following technical effects:
[0041] 1. The transmission of files via short messages is achieved by segmenting and encapsulating files into short messages, parsing and synthesizing them.
[0042] 2. Introduce the credit-based traffic control mechanism into the application scenario of file transfer. The sender preliminarily determines the credit information, and the receiver further verifies it based on the data volume, making full use of the receiver's storage space. Credit is used to achieve the three functions of traffic control, transmission security and file integrity verification.
[0043] 3. If the information of the corresponding size and order is not found in all the credit information, the corresponding string will be discarded, which ensures the transmission security and avoids the traffic of the file being occupied.
[0044] 4. The sender receives the information about the consumed credits from the receiver and deletes the corresponding local credit information, thereby confirming the delivery of the short message through the information about the exchanged credits without the need for additional information.
[0045] 5. Based on the BDTP protocol, the credit information is encrypted and transmitted to the recipient to ensure information security. BRIEF DESCRIPTION OF THE DRAWINGS
[0046] In order to more clearly illustrate the specific implementation methods of the present invention or the technical solutions in the prior art, the drawings required for use in the specific implementation methods or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are some implementation methods of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0047] Figure 1 It is a flow chart of a file transmission method based on satellite short message provided by an embodiment of the present invention;
[0048] Figure 2 A schematic structural diagram of a file transmission system based on satellite short messages provided in an embodiment of the present invention. DETAILED DESCRIPTION
[0049] In order to make the purpose, technical solution and advantages of the present invention clearer, the technical solution of the present invention will be described clearly and completely below. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work belong to the scope of protection of the present invention.
[0050] Embodiment 1
[0051] This embodiment provides a file transmission method based on satellite short messages, which is suitable for scenarios where a sender sends files to a receiver based on the Beidou protocol. It should be noted that the method provided by the present invention can be used as a supplement to the Beidou satellite BDTP protocol and RDSS protocol. Among them, the Beidou BDTP (Beidou Data Transmission Protocol) protocol is a communication protocol for data transmission in China's Beidou satellite navigation system. It defines specifications such as data transmission format, communication process and error handling to ensure the reliability and accuracy of data communication in the Beidou satellite system. The Beidou RDSS (Return Data Service System) protocol is a communication protocol for the data return service system in the Beidou satellite navigation system. The protocol specifies specifications such as data transmission format, communication process and error handling to ensure the reliability and accuracy of data return service in the Beidou system.
[0052] Figure 1 1 is a flowchart of a file transmission method based on satellite short messages provided by an embodiment of the present invention, comprising the following steps:
[0053] S10. The sender encodes and divides the file to be sent to obtain multiple character strings; each character string expresses the content and the format of the content.
[0054] The files in the present invention include at least text files, pictures and videos. The formats include at least paragraph formats, background pictures and font formats. The encoding methods include at least text encoding, pixel-based encoding and streaming media protocol-based encoding.
[0055] Encode the content in the file to be sent into hexadecimal data, divide the hexadecimal data into multiple first character strings, encode the format of the content corresponding to each first character string into a second character string; and splice the first character string with the corresponding second character string. Optionally, the segmentation unit can be determined according to the percentage of the capacity of a short message. For example, after encoding a picture based on pixels, each A byte of hexadecimal data (assuming it corresponds to 200 pixels) is divided into a first character string, then the RGB values of the 200 pixels and the positions in the picture are encoded into a second character string, and the second character string is spliced behind the first character string and filled into the short message. For another example, after encoding a text file based on text, each B byte of hexadecimal data (assuming it corresponds to 10 Chinese characters) is divided into a first character string, and the font format of the 10 Chinese characters, the paragraph format, the RGB value of the pixel of the background picture (if any), etc. are encoded into a second character string, and the second character string is spliced behind the first character string and filled into the short message. For another example, after a video is encoded based on a streaming media protocol, each C byte of hexadecimal data (assuming it corresponds to n video frames) is divided into a first string, the format of the n video frames (such as mp4 format) is encoded into a second string, and the second string is spliced after the first string and filled into the short message. The splicing point should be marked for the receiver to use when parsing.
[0056] S20. The sender determines the corresponding amount of credit according to the amount of character strings, and uses the size and order of the character strings as additional attributes of the credit, and transmits the credit information to the receiver.
[0057] Assume that a total of M strings are obtained by segmentation, and the size of each string can be the same or different. The order of the file content is used as the order of the strings so that the receiver can synthesize the file according to this order.
[0058] The innovation of the present invention is to introduce a credit-based flow control mechanism and improve the mechanism and apply it to file transfer, so as to achieve file integrity verification and flow control at the same time, so as to improve the security of transmission. Specifically, unlike the prior art in which the receiver defines the size of the credit by itself, the present invention is applied in the field of file transfer technology, and the sender of the file determines the number of credits according to the number of strings, and the receiver needs to verify the number of credits if necessary. In addition, in addition to the size, the string size and order are also used as additional attributes of the credit.
[0059] In the specific implementation process, assuming that there are M strings, there are also M credits. One credit is allocated several bytes of space. For example, if the size of a string is 300 bytes and the order is 5, then 300, 5 is written in the corresponding credit. In this way, the information of M credits (i.e., the size and order information stored in M credits) is sent to the receiver. Optionally, in order to ensure the security of information during transmission, the credit information is encrypted based on the BDTP protocol and then transmitted to the receiver. Common encryption methods in the BDTP protocol include: symmetric encryption algorithm, asymmetric encryption algorithm, hash algorithm and hybrid encryption algorithm.
[0060] Preferably, in order to avoid data overflow on the receiving end due to excessive and too fast file transfer, after the credit information is transmitted to the receiving end, the receiving end determines the amount of data allowed to be received based on the current storage space. Specifically, it is assumed that according to the receiving end's memory capacity and its data processing rate (when processing a data, it releases the corresponding space in the memory), there is still 1000 bytes of space available for receiving files within the set time. The set time here is the time required for file transmission agreed in advance by both parties, which can be considered as the timeout threshold. If the set time exceeds the threshold, it means that the file may be intercepted and needs to be retransmitted. The sender can send 1000 bytes of data within the set time, which is the amount of data allowed to be received. Assuming that the sum of the data amounts represented by all credits is 1100 bytes, the amount of data allowed to be received is less than the sum of the data amounts represented by all credits. The local credit information is reset according to the data amount and fed back to the receiving end. For example, select some credits from all credits, the sum of their data volumes should be less than or equal to 1000 bytes. Assuming that M-3 credits are selected, the information of M-3 credits is sent to the sender, so that the sender can send according to the reset credits. The information of the remaining 3 credits (the remaining credits are all credits minus the reset credits) can be sent to the receiver when the next sending cycle (set time) arrives, and the operation of S30 is performed. If the data volume is greater than or equal to the sum of the data volumes represented by all credits, 9000 bytes, the sender is notified to send the data.
[0061] S30: The sender encapsulates each character string into a corresponding short message based on the Beidou protocol and sends it to the receiver.
[0062] Optionally, encapsulate each string into a short message based on the Beidou RDSS protocol. For example, send a short message: $CCTXA,0242286,1,2.A468656C6C6FB1B1B6B7*7F
[0063] Among them, "CCTXA" represents the instruction keyword; "0242286" represents the recipient address ID; "1": 1 represents ordinary communication, 0 represents express communication; "2": 2 represents mixed encoding, 1 represents code encoding; 0 represents Chinese character encoding; "A468656C6C6FB1B1B6B7" represents a string obtained by encoding and segmentation, and "7F" represents the XOR check byte.
[0064] S40: The receiver performs protocol parsing on the short message to obtain a character string, and consumes corresponding credits according to the size and order of the character string until all credits are consumed and the file integrity check is passed.
[0065] The receiver parses the string A468656C6C6FB1B1B6B7 based on the Beidou RDSS protocol, and obtains the size and order of the string (the order of reception); for example, if the size is 100 bytes and the order is 5, the corresponding size and order information is searched and deleted from all credit information, thereby consuming one credit. Similarly, each time the receiver receives a short message, the corresponding credit will be consumed. When all short messages of the file are sent, all credits are consumed, and the file integrity check is passed.
[0066] The receiver will also send the information of consumed credits to the sender as a notification of successful short message delivery. Furthermore, the sender receives the information of consumed credits from the receiver and deletes the corresponding credit information locally. When all local credit information is deleted, the file is sent.
[0067] There are also some special cases. If there are unconsumed credits within the set time, it means that the short message corresponding to the unconsumed credits has not been received, and it is determined that a short message is lost and the file integrity check has not passed. Later, the sender can be notified to retransmit the short message corresponding to the unconsumed credits, or the sender can be chosen not to be trusted anymore.
[0068] If the corresponding size and order are not found in all the credit information, the corresponding string will be discarded. According to the credit flow mechanism, the sender can only send according to the information specified by the credit, which is conducive to flow control and data security. If the string size or order is incorrect, it means that the short message may be tampered with, or the sender uses the flow allocated by the receiver for the file to send other content, which does not meet the requirements of flow control, and the corresponding string will be discarded. The sender can be further notified for inspection.
[0069] S50: The receiver reads the contents and formats of the multiple character strings and synthesizes the file.
[0070] The receiver divides the character string into a first character string and a second character string according to the identifier of the splicing position, and parses out the content and format respectively, and synthesizes the file according to the order of receipt.
[0071] This embodiment has the following technical effects:
[0072] 1. The transmission of files via short messages is achieved by segmenting and encapsulating files into short messages, parsing and synthesizing them.
[0073] 2. Introduce the credit-based traffic control mechanism into the application scenario of file transfer. The sender preliminarily determines the credit information, and the receiver further verifies it based on the data volume, making full use of the receiver's storage space. Credit is used to achieve the three functions of traffic control, transmission security and file integrity verification.
[0074] 3. If the information of the corresponding size and order is not found in all the credit information, the corresponding string will be discarded, which ensures the transmission security and avoids the traffic of the file being occupied.
[0075] 4. The sender receives the information about the consumed credits from the receiver and deletes the corresponding local credit information, thereby confirming the delivery of the short message through the information about the exchanged credits without the need for additional information.
[0076] 5. Based on the BDTP protocol, the credit information is encrypted and transmitted to the recipient to ensure information security.
[0077] Embodiment 2
[0078] This embodiment provides a file transmission system based on satellite short messages. Figure 2 , including sender and receiver.
[0079] The sender encodes and divides the file to be sent to obtain multiple character strings; each character string expresses the content and the format of the content;
[0080] The sender determines the corresponding amount of credit according to the number of character strings, and uses the size and order of the character strings as additional attributes of the credit, and transmits the credit information to the receiver;
[0081] The sender encapsulates each character string into a corresponding short message based on the Beidou protocol and sends the short message to the receiver;
[0082] The receiving party performs protocol parsing on the short message to obtain a character string, and consumes corresponding credits according to the size and order of the character string until all credits are consumed and the file integrity check is passed;
[0083] The receiver reads the contents and formats of the multiple character strings and synthesizes the file.
[0084] The specific operations and technical effects of the sender and receiver in this embodiment refer to the description of Embodiment 1 and will not be repeated here.
[0085] It should be noted that the terms used in the present invention are only for describing specific embodiments, rather than limiting the scope of the present application. As shown in the present specification, unless the context clearly indicates an exception, the words "one", "a", "a kind of" and / or "the" do not specifically refer to the singular, but may also include the plural. The terms "include", "comprise" or any other variant thereof are intended to cover non-exclusive inclusion, so that the process, method or device including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method or device. In the absence of further restrictions, the elements defined by the sentence "include one..." do not exclude the presence of other identical elements in the process, method or device including the elements.
[0086] It should also be noted that the terms "center", "up", "down", "left", "right", "vertical", "horizontal", "inside", "outside", etc., indicating the orientation or positional relationship, are based on the orientation or positional relationship shown in the drawings, and are only for the convenience of describing the present invention and simplifying the description, rather than indicating or implying that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation, and therefore cannot be understood as a limitation on the present invention. Unless otherwise clearly specified and limited, the terms "installed", "connected", "connected", etc. should be understood in a broad sense, for example, it can be a fixed connection, a detachable connection, or an integral connection; it can be a mechanical connection or an electrical connection; it can be a direct connection, or it can be an indirect connection through an intermediate medium, or it can be a connection between the two elements. For those of ordinary skill in the art, the specific meanings of the above terms in the present invention can be understood according to specific circumstances.
[0087] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention, rather than to limit it. Although the present invention has been described in detail with reference to the aforementioned embodiments, those skilled in the art should understand that they can still modify the technical solutions described in the aforementioned embodiments, or replace some or all of the technical features therein by equivalents. However, these modifications or replacements do not deviate the essence of the corresponding technical solutions from the technical solutions of the embodiments of the present invention.
Claims
1. A file transmission method based on satellite short messages, characterized in that: include: The sender encodes and divides the file to be sent to obtain multiple character strings; each character string expresses the content and the format of the content; The sender determines the corresponding amount of credit according to the number of character strings, and uses the size and order of the character strings as additional attributes of the credit, and transmits the credit information to the receiver; The receiving party determines the amount of data allowed to be received according to the current storage space; If the data amount is greater than or equal to the sum of the data amounts represented by all credits, notify the sender to send the data; If the data volume is less than the sum of the data volumes represented by all credits, the local credit information is reset according to the data volume and fed back to the sender, so that the sender can send according to the reset credit. When the next sending cycle arrives, the remaining credit information is sent to the receiver. The sender encapsulates each character string into a corresponding short message based on the Beidou protocol and sends it to the receiver. The remaining credit is the total credit minus the reset credit. The receiving party performs protocol parsing on the short message to obtain a character string, and consumes corresponding credits according to the size and order of the character string until all credits are consumed and the file integrity check is passed; The receiver reads the contents and formats of the multiple character strings and synthesizes the file.
2. The method according to claim 1, characterized in that The sender encodes and splits the file to be sent to obtain multiple strings, including: The sender encodes the content in the file to be sent into hexadecimal data, divides the hexadecimal data into a plurality of first character strings, and encodes the format of the content corresponding to each first character string into a second character string; The sender concatenates the first character string with the corresponding second character string.
3. The method according to claim 2, characterized in that The format at least includes paragraph format, background image format and font format; The files include at least text files, pictures and videos; The encoding methods include at least text encoding, pixel-based encoding and streaming media protocol-based encoding.
4. The method according to claim 1, characterized in that The corresponding credits are consumed according to the size and order of the strings, including: Get the size and order of the string; Search for the information of corresponding size and order in all credit information and delete it.
5. The method according to claim 4, characterized in that After the sender encapsulates each character string into a corresponding short message based on the Beidou protocol and sends it to the receiver, the method further includes: If there are unconsumed credits within the set time, it is determined that a short message is lost and the file integrity check fails.
6. The method according to claim 4, characterized in that After the sender encapsulates each character string into a corresponding short message based on the Beidou protocol and sends it to the receiver, the method further includes: If the information of the corresponding size and order is not found in all the credit information, the corresponding string will be discarded.
7. The method according to claim 1, characterized in that After the sender encapsulates each character string into a corresponding short message based on the Beidou protocol and sends the short message to the receiver, the method further includes: The sender receives the information of consumed credits fed back by the receiver and deletes the corresponding credit information locally.
8. The method according to claim 1, characterized in that Transmitting the credit information to the recipient includes: Based on the BDTP protocol, the credit information is encrypted and transmitted to the recipient.
9. A file transmission system based on satellite short messages, characterized in that: Includes sender and receiver; The sender encodes and divides the file to be sent to obtain multiple character strings; each character string expresses the content and the format of the content; The sender determines the corresponding amount of credit according to the number of character strings, and uses the size and order of the character strings as additional attributes of the credit, and transmits the credit information to the receiver; The receiving party determines the amount of data allowed to be received according to the current storage space; If the data amount is greater than or equal to the sum of the data amounts represented by all credits, notify the sender to send the data; If the data volume is less than the sum of the data volumes represented by all credits, the local credit information is reset according to the data volume and fed back to the sender, so that the sender can send according to the reset credits. When the next sending cycle arrives, the remaining credit information is sent to the receiver; the sender encapsulates each character string into a corresponding short message based on the Beidou protocol and sends it to the receiver; the remaining credit is the total credit minus the reset credit; The receiving party performs protocol parsing on the short message to obtain a character string, and consumes corresponding credits according to the size and order of the character string until all credits are consumed and the file integrity check is passed; The receiver reads the contents and formats of the multiple character strings and synthesizes the file.
