A method for transmitting unmanned aerial vehicle patrol data
By setting up 5G terminals between the drone and the cloud for multi-link aggregation and data cache, the problem of low communication reliability of drones in complex network environments is solved, and data transmission with high reliability, low latency and high security is achieved.
Patent Information
- Application Number
- CN202411365524.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-09-29
- Publication Date
- 2025-05-13
- Estimated Expiration
- 2044-09-29
AI Technical Summary
UAVs have low communication reliability in complex network environments, and the transmission delay, coverage and penetration capabilities of 4G networks are limited, which affects flight experience and mission efficiency.
By setting up a 5G terminal between the drone and the cloud as a communication relay, multi-link aggregation and data cache are performed, and dynamic keys are generated to improve the security of data transmission.
It improves the reliability of data communication between the drone and the cloud in a weak network environment, reduces transmission delay, and enhances the security and continuity of data transmission.
Smart Images

Figure CN118870350B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of UAV communications, and more specifically, to a method for transmitting UAV patrol data. Background Art
[0002] With the rapid development of drone technology, drones have been widely used in power inspection, emergency communications, security monitoring and other fields. In practical applications, drones usually need to perform tasks in complex network environments, such as field environments with unstable signal coverage and urban canyons with tall buildings. These complex environments pose severe challenges to the remote communication capabilities of drones.
[0003] Currently, most drone systems use traditional 4G mobile communication networks for data transmission and remote control. Although the 4G network can meet general communication needs, it has exposed many shortcomings in the actual application of drones. First, the transmission delay of the 4G network is relatively large, which makes it difficult to meet the needs of real-time control and data return of drones, affecting the flight experience and mission efficiency. Secondly, the coverage and penetration capabilities of the 4G network are limited. In complex environments such as mountains, forests, and canyons, the communication link between the drone and the ground station is prone to interruption, posing a safety hazard.
[0004] The Chinese patent application, application number CN202011155667.0, published on December 11, 2020, discloses a method for communicating identity authentication between drones and base stations based on elliptic curve encryption, including: during the system initialization phase, the trusted center generates system parameters and broadcasts them to the drone network; each drone in the drone fleet is authenticated and registered by the trusted center; the road base station and the drone initiate an authentication request; after successful authentication, the road base station sends a command packet to the drone, and the drone receives the command and executes the command task. However, although the solution introduces a trusted center for identity registration in the initial stage, there are still many deficiencies in the subsequent authentication process, resulting in low communication reliability of drones in complex network environments. Summary of the invention
[0005] 1. Technical problems to be solved
[0006] In response to the problem of low communication reliability of drones in complex network environments in the prior art, the present application provides a method for transmitting drone patrol data. By setting a 5G terminal as a communication relay between the drone and the cloud, multi-link aggregation and data caching are performed to improve the reliability of data communication between the drone and the cloud in a weak network environment. At the same time, a dynamic key is generated based on the timestamp and device serial number, thereby improving the security of data transmission.
[0007] 2. Technical solution
[0008] The purpose of this application is achieved through the following technical solutions.
[0009] The present application provides a method for transmitting drone patrol data, including: concatenating a 5G terminal serial number SN and a timestamp TS to obtain a random number seed S; extracting the drone device ID and the 5G communication unit IMEI number, and obtaining an N-bit ASCII string as a constant secret key through an exclusive OR operation; using the random number seed S as plain text and the constant secret key as a secret key, and using the AES-ECB mode to generate an encryption key MK, the secret key MK includes a public key PUK and a private key PRK; using the RSA asymmetric encryption algorithm, using the public key PUK as an encryption key, encrypting the drone status data or control instructions to obtain a ciphertext C; encapsulating the ciphertext C into a data frame according to a preset data structure; the data frame includes a unique identifier, a timestamp, a data type, a data length, a ciphertext, metadata, and a CRC check code; performing an integrity check on the encapsulated data frame; after the check is passed, scheduling the data frame to P candidate 5G links through multi-link data scheduling, and sending the data frame in a parallel transmission mode; decrypting the encrypted data frame to obtain plaintext data, and verifying the integrity of the decrypted plaintext data.
[0010] Furthermore, the preset data structure includes: Header, Payload and Footer; the unique identifier BID, timestamp Timestamp, data type Type and data length Length of the data frame are set in sequence in the Header; wherein, the unique identifier BID adopts the GUID generated based on the drone device identification ID and timestamp Timestamp; the data type Type is used to identify that the data frame carries the drone status data; the encrypted status data C and metadata Metadata are set in sequence in the Payload; wherein, the metadata Metadata includes the GPS location coordinate information of the drone; the CRC check, Checksum and SHA256 hash value hash of the data frame are set in the Footer; the Checksum is obtained by performing CRC calculation on the data of the Header and Payload of the data frame, and is used to verify the integrity of the data frame; the SHA256 hash value hash is calculated by the sender using the SHA256 algorithm on the plaintext data of the Header and Payload, and is used to verify the integrity of the decrypted plaintext.
[0011] Furthermore, an integrity check is performed on the encapsulated data frame, including: receiving the data frame and extracting the Header and Payload fields; using the same CRC algorithm as the sender to calculate the received Header and Payload data to obtain the checksum value CRC_Value; comparing the calculated checksum value CRC_Value with the checksum Checksum carried in the Footer field of the data frame. If CRC_Value is equal to Checksum, it indicates that no bit error or loss occurs in the data frame during transmission and the check passes, otherwise the check fails.
[0012] Furthermore, the encrypted data frame is decrypted to obtain plaintext data, including: receiving the encrypted data frame; parsing the Header, Payload and Footer fields according to the preset data frame structure; judging whether the ciphertext data in the Payload field is drone status data or control instructions according to the data type identifier Type in the Header field; performing AES symmetric decryption on the ciphertext data in the Payload of the received data frame using the private key PRK; if the Type is drone status data, the decryption result is the drone status data plaintext; if the Type is control instructions, the decryption result is the control instruction plaintext; the drone status data plaintext includes the drone position coordinates, flight speed and altitude; the control instruction plaintext includes path planning and obstacle avoidance strategies.
[0013] Further, verify the integrity of the decrypted plaintext data: extract the hash value in the Footer field of the received data frame as the first hash value Hash1; divide the padded plaintext data into Q groups, and each group into W sub-groups; perform E cycles of compression on each group to generate Hashi; perform bitwise XOR on the Hashi of all groups to obtain the final hash value Hash2 of the plaintext data; compare the first hash values Hash1 and Hash2. If they are consistent, it indicates that the plaintext data decrypted by the receiving end is completely consistent with the plaintext data before encryption by the sending end, and no tampering or loss has occurred. The integrity check passes, otherwise it fails.
[0014] Further, the data frame is scheduled to P candidate 5G links through multi-link data scheduling, including: obtaining the Reference Signal Receiving Power indicator and the Reference Signal Receiving Quality indicator, and comparing RSRP and RSRQ with the preset RSRP and RSRQ thresholds respectively; when RSRP is lower than the RSRP threshold or RSRQ is lower than the RSRQ threshold, link quality assessment is performed: a detection frame containing a detection sequence number and a timestamp is sent to the base station at a preset period; the round-trip time RTT and the number of losses of the detection frame are counted, and the delay, jitter and packet loss rate of each 5G link are calculated; the RSRP standardized value and RSRQ standardized value of each link are calculated respectively: RSRP standardized value = (RSRP measurement value - RSRP minimum value) / (RSRP maximum value - RSRP minimum value) ;RSRQ standardized value = (RSRQ measured value - RSRQ minimum value) / (RSRQ maximum value - RSRQ minimum value); wherein, RSRP maximum value, RSRP minimum value, RSRQ maximum value and RSRQ minimum value are preset theoretical thresholds of RSRP and RSRQ; based on RSRP standardized value and RSRQ standardized value, calculate the comprehensive quality score of each link: comprehensive quality score = RSRP standardized value × RSRP weight + RSRQ standardized value × RSRQ weight; sort all links according to the comprehensive quality score, and select the top P links with the highest comprehensive quality scores as candidate links.
[0015] Furthermore, obtaining the RSRP indicator includes: receiving a measurement reference signal SRS modulated by a Gold sequence and sent by a base station on a preset physical resource block PRB; demodulating the received SRS signal using the same Gold sequence as the SRS to obtain an SRS symbol; measuring the power of the SRS symbol and calculating the average power W of multiple SRS symbols; converting the average power W into an RSRP indicator: RSRP=10lg(W×1000); wherein lg is a logarithmic function with a base of 10, and the RSRP indicator is used to evaluate the downlink signal strength of the current 5G link.
[0016] Furthermore, obtaining the RSRQ indicator includes: receiving a downlink signal sent by a base station, the downlink signal including an SRS signal and a control signaling; performing power measurement on the received SRS signal and control signaling respectively: calculating the average power of multiple SRS symbols to obtain the SRS signal power PSRS; calculating the average power of multiple control signaling to obtain the control signaling power PCTRL; adding the SRS signal power PSRS and the control signaling power PCTRL to obtain the total received power RSSI; calculating the RSRQ indicator: RSRQ=10lg(NPRB×RSRP / RSSI); wherein NPRB is the number of physical resource blocks occupied by the SRS signal, and RSRQ is used to evaluate the downlink signal quality of the current 5G link.
[0017] Furthermore, a parallel transmission method is adopted to send data frames, including: numbering the selected P candidate links from 1 to P, setting polling pointers respectively, with the initial value being equal to the number; establishing a control instruction queue and a status data queue, with the control instruction queue having a higher priority than the status data queue; extracting control instruction data packets to be transmitted from the head of the control instruction queue in turn; traversing the polling pointers of the candidate links to obtain the candidate link with the smallest current pointer value; allocating the extracted control instruction data packets to the obtained candidate link; increasing the polling pointer of the allocated link by P to point to the next candidate link; repeating the control instruction scheduling process until all the data packets in the control instruction queue are allocated; extracting the status data packets to be transmitted from the head of the status data queue in turn, and using the same polling strategy as the control instruction scheduling to allocate the status data packets to the candidate link with the smallest polling pointer; repeating the above status data scheduling process until all the data packets in the status data queue are allocated.
[0018] Furthermore, sending data frames in parallel transmission mode also includes: for each candidate link, after completing the data packet allocation of a scheduling cycle, marking the corresponding link as ready; for all candidate links marked as ready, starting parallel data transmission at the same time; the candidate links in the ready state work independently and establish logical transmission channels with the base station respectively; through handshake negotiation with the base station, establishing connection-oriented logical links and transmission sessions at the link layer and the transport layer respectively; each candidate link in the ready state transmits in parallel and only transmits data packets allocated to the corresponding link; data transmission on candidate links in different ready states is concurrent with each other; after all candidate links in the current scheduling cycle complete their respective data transmission, the ready state marks of all links are cleared.
[0019] 3. Beneficial effects
[0020] Compared with the prior art, the advantages of this application are:
[0021] The 5G terminal integrates a link quality assessment subunit, which measures and calculates the RSRP, RSRQ and other indicators of multiple 5G links between the 5G terminal and the base station in real time, and combines factors such as link delay, jitter, and packet loss rate to obtain a comprehensive link quality score. This link quality assessment mechanism can dynamically reflect the current communication status of each 5G link and provide a basis for subsequent multi-link aggregation transmission. When the drone flies to an area with weak 5G network signals, the link quality assessment subunit can promptly detect links with reduced signal quality, and select the relatively optimal link combination through an algorithm to ensure the effectiveness and stability of the communication link.
[0022] Based on the link quality assessment, the multi-link aggregation subunit of the 5G terminal can divide the drone status data and control instructions into data queues of different priorities, and use a polling scheduling algorithm to dynamically allocate data packets to multiple optimal links for parallel transmission. This multi-link aggregation transmission mechanism can make full use of the bandwidth resources of multiple 5G links, improve data throughput and reduce transmission latency through concurrent transmission. At the same time, differentiated scheduling strategies are adopted for data of different priorities to ensure that high-priority control instructions can be transmitted first, thereby improving the real-time performance of the system. In a weak network environment, even if individual 5G links are briefly interrupted, other links can be relied on to continue transmitting data, thereby improving the continuity and reliability of communication as a whole.
[0023] Taking into account the volatility of 5G link quality in a weak network environment, the 5G terminal also integrates a hierarchical data caching mechanism. The data cache subunit adopts a two-level cache structure, local cache and cloud storage. When the combined signal quality of all 5G links is lower than the preset threshold, the data cache subunit will temporarily store the drone status data and control instructions locally in the 5G terminal and start the data synchronization timer; once the link quality recovers above the threshold, the cached data will be immediately uploaded to the cloud to complete data synchronization and avoid data loss. The collaboration of local cache and cloud storage can maximize the protection of data integrity and provide end-to-end reliable data transmission.
[0024] The transmission characteristics in a weak network environment are also fully considered in the design of the data frame structure. The data processing unit encapsulates the status data and control instructions into a unified data frame format, including a frame header, a payload, and a frame tail. Key fields such as the frame sequence number, timestamp, and data type are designed in the frame header to facilitate the identification, sequencing, and retransmission control of the data frame. The data payload adopts a private protocol format and can be flexibly expanded according to actual needs. The CRC check mechanism is introduced in the frame tail, so that the receiving end can quickly determine whether the data frame is erroneous, discard the erroneous frame in time, and request retransmission. A reasonable data frame structure can reduce the probability of data errors and improve data transmission efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0025] Figure 1 This is an exemplary flow chart of a method for transmitting UAV patrol data of the present application;
[0026] Figure 2 A schematic diagram of a method for transmitting UAV patrol data of the present application;
[0027] Figure 3 This is the system data communication link timing diagram of this application. DETAILED DESCRIPTION
[0028] The present application is described in detail below in conjunction with the accompanying drawings and specific embodiments.
[0029] Figure 1 This is an exemplary flow chart of a method for transmitting drone patrol data of the present application, including: concatenating a 5G terminal serial number SN and a timestamp TS to obtain a random number seed S; extracting the drone device ID and the 5G communication unit IMEI number, and obtaining an N-bit ASCII string as a constant secret key through an XOR operation; using the random number seed S as plain text and the constant secret key as the secret key, and using the AES-ECB mode to generate an encryption key MK, the secret key MK includes a public key PUK and a private key PRK; using the RSA asymmetric encryption algorithm, using the public key PUK as the encryption key, encrypting the drone status data or control instructions to obtain a ciphertext C; encapsulating the ciphertext C into a data frame according to a preset data structure; the data frame includes a unique identifier, a timestamp, a data type, a data length, a ciphertext, metadata, and a CRC check code; performing an integrity check on the encapsulated data frame; after the check passes, scheduling the data frame to P candidate 5G links through multi-link data scheduling, and sending the data frame using a parallel transmission method; decrypting the encrypted data frame to obtain plaintext data, and verifying the integrity of the decrypted plaintext data.
[0030] A certain drone patrol system uses the drone patrol data transmission method of the present application. Figure 2A schematic diagram of a method for transmitting patrol flight data of a drone of the present application, comprising: a drone, a base station, a 5G terminal and a cloud; the drone executes a flight mission and feeds back the collected status data to the 5G terminal for encryption processing; wherein the status data includes the location coordinates, flight speed and flight altitude of the drone; the 5G terminal communicates with the base station through the 5G network, receives the status data sent by the drone and sends it to the base station after encryption processing, and receives the encrypted control instructions from the base station and sends them to the drone after decryption; the base station is connected to the 5G terminal through a 5G communication link, receives the encrypted control instructions sent by the cloud and forwards them to the 5G terminal, and receives the encrypted status data sent by the 5G terminal and forwards them to the cloud; the cloud comprises a key unit and a control unit; the key unit generates a key according to the serial number and timestamp of the 5G terminal, and sends it to the 5G terminal and the control unit; the control unit generates a control instruction using the key encryption, and sends it to the base station;
[0031] Specifically, on the drone side, obtain the serial number SN, which is the factory unique identifier of the 5G communication module, usually burned into the non-volatile memory of the module. The drone side obtains the value of SN by reading the specified memory address; SN is generally a string composed of visible characters such as letters and numbers, with a length of 16 to 32 bytes. Obtain the timestamp TS. The drone side obtains the current date and time by calling the system time function, and formats the date and time into a timestamp string accurate to milliseconds, such as "YYYY-MM-DD HH:mm:ss.SSS". The timestamp length is fixed to 23 bytes (excluding the end character). Splice SN and TS, splice SN and TS into a random number seed S according to a predetermined format. The splicing format can be "SN+TS", that is, SN in front and TS in the back, connected by "+" in the middle, or TS can be placed before SN, using the "TS+SN" format. Regardless of the format, it is necessary to ensure that there is a clear separator between SN and TS.
[0032] Preferably, SN and TS are used as inputs, and hash operations are performed respectively to obtain two hash values H_SN and H_TS, and then H_SN and H_TS are concatenated or XORed to generate the final random number seed S. By introducing the hash function, the complexity and irreversibility of the seed generation process are increased to prevent the seed from being easily deduced. Common hash algorithms include MD5, SHA-1, SHA-256, etc. According to the requirements of security strength and computing performance, a suitable hash algorithm is selected. Here, SHA-256 is taken as an example, and the output is a 256-bit (32-byte) hash value. Read the device serial number SN from the 5G communication module, assuming it is a 16-byte string, call the system time function, obtain the current timestamp TS, and format it as a 23-byte string. Convert SN to a byte array as the input of SHA-256, call the SHA-256 function, and calculate the hash value H_SN of SN. H_SN is 32 bytes of binary data. Convert TS to a byte array as the input of SHA-256, call the SHA-256 function, and calculate the hash value H_TS of TS. H_TS is 32 bytes of binary data. Concatenate or XOR H_SN and H_TS to generate a 64-byte random number seed S. The concatenation method can be to put H_SN in front and H_TS in the back. The XOR method can be to XOR the corresponding bytes of H_SN and H_TS in sequence to obtain S.
[0033] Extract the device identification ID of the drone device and the international mobile equipment identity code IMEI of the 5G communication unit. Extract the device identification ID. The ID is the factory identification of the drone device, which is usually burned in the ROM or EEPROM of the device. After the drone is powered on, read the specified memory address to obtain the value of the ID. The ID is generally a string of letters and numbers with a length of 16 to 32 bytes. Extract IMEI. IMEI is the international mobile equipment identity code of the 5G communication unit, which is used to identify the identity of the mobile device. Query IMEI through the AT command "AT+CGSN". The return value is a string of 15 digits. According to the 3GPP TS 23.003 specification, IMEI has a total of 15 digits, the first 14 digits are the identification code, and the last digit is the check digit. Convert the ID to binary and convert the ID string to a byte array. Each byte contains 8 binary bits. Bytes with less than 8 bits are filled with 0 in the high position to ensure that each byte is 8 bits. All bytes are spliced together to obtain the binary representation of the ID, recorded as ID_bin. Convert the IMEI string into a byte array. Each byte contains 8 binary bits. Bytes with less than 8 bits are padded with 0 in the high bit to ensure that each byte is 8 bits. All bytes are concatenated together to obtain the binary representation of IMEI, recorded as IMEI_bin. Calculate the length of ID_bin and IMEI_bin, recorded as len_ID and len_IMEI respectively, calculate the maximum length max_len = max(len_ID, len_IMEI), padded with 0 in the high bit of the shorter binary string to make its length equal to max_len, and obtain ID_bin_pad and IMEI_bin_pad of equal length, both of which are binary strings of max_len bits. Perform bit-by-bit XOR operation on ID_bin_pad and IMEI_bin_pad to generate a binary string of length max_len. XOR rule: when the corresponding bits are all 0 or all 1, the result is 0; when one is 0 and the other is 1, the result is 1, and the XOR result binary string xor_result is obtained. According to the required random number seed length N, the first N bits are intercepted from xor_result, and the intercepted N-bit binary string is recorded as seed_bin as the final random number seed.
[0034] Convert the obtained N-bit binary string into the corresponding N-bit ASCII string as the constant secret key. When converting the binary string into an ASCII string, each 8-bit binary string corresponds to an ASCII character, and if the string is less than 8 bits, add 0 at the beginning. You can directly use the ASCII code table for conversion. For example, the binary "01100001" corresponds to the decimal 97, which is converted to the ASCII character "a". Use the random number seed S as the plaintext and the constant secret key key as the secret key, and use the AES-ECB mode to execute the encryption algorithm to generate a fixed-length encryption key MK. The random number seed S is used as the plaintext input of the AES encryption algorithm, and the constant secret key key is used as the secret key input of the AES encryption algorithm; in the AES-ECB mode, the plaintext and ciphertext lengths of the encryption algorithm must be integer multiples of 16 bytes. If the length of S is less than 16 bytes, padding is required; after the encryption is completed, the fixed-length ciphertext is output as the encryption key MK, and the length of MK is generally 128 bits, 192 bits, or 256 bits. The encryption key MK is divided into two parts, the first half is used as the public key PUK, and the second half is used as the private key PRK.
[0035] The public key is used on the drone side to encrypt the data and encapsulate the data frame. The drone side collects the drone's status data, including flight speed, attitude angle, altitude, heading and other information, or generates control instructions for the drone, such as route modification, obstacle avoidance strategy, etc. The collected or generated status data or control instructions are used as plaintext data M. The RSA asymmetric encryption algorithm is used to encrypt the plaintext data M with the public key PUK generated and saved by the drone side as the encryption key. When RSA encryption is performed, the PUK is first converted to an RSA public key object, and then the RSA encryption interface is called to pass in the plaintext data M to obtain the encrypted ciphertext data C; RSA encryption can use the PKCS#1 v1.5 padding scheme or the OAEP padding scheme to ensure encryption strength; the length of the ciphertext data C is consistent with the length of the PUK. For example, when the PUK is 1024 bits, C is also 1024 bits.
[0036] The encrypted ciphertext data C is encapsulated into a data frame Frame according to the preset data structure. The data frame consists of three parts: Header, Payload and Footer. The Header part sets the following fields in sequence: Unique identifier BID: A globally unique identifier GUID generated based on the drone device ID and timestamp Timestamp. The GUID generation algorithm can use version 1 or version 4 of the UUID algorithm to ensure that the generated BID is unique globally. Timestamp Timestamp: The generation time of the data frame, generally Greenwich time, accurate to milliseconds, used to identify the timeliness of the data frame. Data type Type: Used to identify the data type carried in the Payload, for example, 0x01 represents drone status data, and 0x02 represents control instruction data. Data length Length: Indicates the length of the Payload part, in bytes. The Payload part sets the following fields in sequence: Encrypted status data C: Ciphertext data C, which is the length specified by the Length field in the Header. Metadata Metadata: Used to carry additional information, such as the GPS location coordinates of the drone. Metadata is expressed in the form of "field name: field value", and different fields are separated by semicolons. The following fields are set in the Footer section: CRC Checksum: Perform CRC calculation on all data in the Header and Payload sections to generate a Checksum. The sender and receiver use the same CRC polynomial and initial value. SHA256 hash value: The sender uses the SHA256 algorithm to calculate the hash value of the plaintext data in the Header and Payload as the basis for the receiver to verify the data integrity.
[0037] The sender places the plaintext data of Header, Payload and Footer in the order of Header first, Payload second and Footer last to form a complete data frame. The Header and Payload in the Frame are plaintext, and the Checksum and hash in the Footer are calculated from the plaintext. Perform an integrity check on the encapsulated data frame, use the CRC algorithm to calculate the checksum CRC_Value of the Header and Payload data, and compare it with the Checksum in the Footer to verify whether the data frame is correctly encapsulated on the drone side.
[0038] Link quality assessment is performed on the drone side, and the base station sends a measurement reference signal SRS (Sounding Reference Signal) on the preset physical resource block PRB. The base station determines the time-frequency resource location for sending SRS based on the preset SRS configuration parameters, including the subframe, symbol, frequency domain starting position and frequency domain length where the SRS is located. The base station modulates the SRS using the Gold sequence. The Gold sequence is a pseudo-random sequence with good correlation characteristics, which can reduce the interference of SRS between different base stations. The base station maps the modulated SRS to the preset PRB and sends it to the drone through the downlink physical channel.
[0039] The drone receives the SRS signal sent by the base station and demodulates it. The drone determines the time-frequency resource location for receiving the SRS according to the preset SRS configuration parameters, which is the same as the time-frequency resource location for sending the SRS by the base station. The drone uses the same Gold sequence as the base station to demodulate the received SRS signal and obtain the SRS symbol. The drone stores the demodulated SRS symbol in the cache for subsequent power measurement. The drone measures the power of the SRS symbol and calculates the RSRP index. The drone sums the power of multiple SRS symbols in the cache to obtain the total power Wsum. The drone calculates the average power W of the SRS symbol, W = Wsum / N, where N is the number of SRS symbols. The drone converts the average power W into the RSRP index in dBm, and the conversion formula is: RSRP = 10lg (W×1000). Among them, lg is a logarithmic function with a base of 10, W×1000 means converting the unit of W from watts to milliwatts, and the unit of RSRP is dBm.
[0040] The drone receives downlink signals sent by the base station, including SRS signals and control signaling. The SRS signal is a measurement reference signal sent by the base station on the preset physical resource block PRB, which is used by the drone to measure the downlink signal strength, namely RSRP. Control signaling is control plane information sent by the base station for drone access, mobility management, resource allocation and other functions, including synchronization signals, broadcast information, paging information, etc. The drone receives SRS signals and control signaling through the downlink physical channel and stores them in the cache for subsequent power measurement.
[0041] The drone measures the power of the SRS signal and the control signaling respectively. For the SRS signal, the drone reads multiple SRS symbols from the cache, calculates their average power, and obtains the SRS signal power PSRS. The drone sums the power of multiple SRS symbols to obtain the total power Wsum_SRS. The drone calculates the average power PSRS of the SRS symbol, PSRS = Wsum_SRS / NSRS, where NSRS is the number of SRS symbols. For the control signaling, the drone reads multiple control signaling from the cache, calculates their average power, and obtains the control signaling power PCTRL. The drone sums the power of multiple control signaling to obtain the total power Wsum_CTRL. The drone calculates the average power PCTRL of the control signaling, PCTRL = Wsum_CTRL / NCTRL, where NCTRL is the number of control signaling. The drone adds the SRS signal power PSRS and the control signaling power PCTRL to obtain the total received power RSSI. RSSI reflects the overall strength of the base station downlink signal received by the drone, including the useful signal (i.e., SRS signal) and the interference signal (i.e., control signaling). The calculation formula of RSSI is: RSSI = PSRS + PCTRL, in watts. The drone calculates the RSRQ index. The drone calculates the RSRQ index based on the number of physical resource blocks NPRB occupied by the SRS signal, the RSRP index and RSSI. The calculation formula of RSRQ is: RSRQ = 10lg (NPRB × RSRP / RSSI), in dB. Among them, NPRB is a constant determined by the base station according to the SRS configuration parameters; RSRP is the downlink reference signal received power measured by the drone, in watts; RSSI is the total received power measured by the drone, in watts.
[0042] The drone compares the measured RSRP and RSRQ indicators with the preset RSRP threshold and RSRQ threshold, respectively. If RSRP is lower than the RSRP threshold or RSRQ is lower than the RSRQ threshold, the current link quality is considered to be poor and link switching is required. If RSRP is higher than or equal to the RSRP threshold and RSRQ is higher than or equal to the RSRQ threshold, the current link quality is considered to be good and no switching is required. When the link quality is poor, the drone starts the link quality assessment procedure: the drone sends a detection frame to the base station of the current link and the alternative link according to a preset period (such as 200 milliseconds). The detection frame contains the detection sequence number and the sending timestamp. The drone counts the round-trip time RTT and the number of losses of the detection frame on each link, and calculates the delay, jitter and packet loss rate of each link respectively. Latency = average value of RTT; Jitter = standard deviation of RTT; Packet loss rate = number of lost detection frames / total number of sent detection frames; The drone calculates the RSRP standardized value and RSRQ standardized value of each link respectively: RSRP standardized value = (RSRP measured value - RSRP minimum value) / (RSRP maximum value - RSRP minimum value); RSRQ standardized value = (RSRQ measured value - RSRQ minimum value) / (RSRQ maximum value - RSRQ minimum value); Among them, RSRP maximum value, minimum value and RSRQ maximum value, minimum value are preset theoretical thresholds, reflecting the theoretical variation range of RSRP and RSRQ. Based on RSRP standardized value and RSRQ standardized value, the drone calculates the comprehensive quality score of each link: Comprehensive quality score = RSRP standardized value × RSRP weight + RSRQ standardized value × RSRQ weight; Among them, RSRP weight and RSRQ weight are preset constants, reflecting the importance of RSRP and RSRQ to link quality, and the sum of weights is 1. The drone sorts the comprehensive quality scores of all candidate links and selects the top P links with the highest scores as candidate links, where P is a preset constant. The drone encapsulates the relevant information of the candidate links (such as base station ID, comprehensive quality score, latency, jitter, packet loss rate, etc.) together with the relevant information of the current link into a link switching request message and sends it to the central server. The central server decides whether to approve the link switching based on the information in the link switching request message, the flight trajectory of the drone, business needs and other factors, and sends the decision result to the drone through a link switching response message. If the central server approves the link switching, the drone establishes a new 5G connection with the base station with the highest comprehensive quality score in the candidate link, and disconnects from the original base station to complete the link switching.
[0043] Figure 3The system data communication link timing diagram of the present application is as follows: the data frame is scheduled through multi-link data, the selected P candidate links are numbered from 1 to P, and the polling pointers are set respectively, with the initial value equal to the number; a control instruction queue and a status data queue are established, and the control instruction queue has a higher priority than the status data queue; the control instruction data packets to be transmitted are extracted from the head of the control instruction queue in sequence; the polling pointers of the candidate links are traversed to obtain the candidate link with the smallest current pointer value; the extracted control instruction data packets are assigned to the obtained candidate links; the polling pointer of the assigned link is increased by P to point to the next candidate link; the control instruction scheduling process is repeated until all the data packets in the control instruction queue are assigned; the status data packets to be transmitted are extracted from the head of the status data queue in sequence, and the same polling strategy as the control instruction scheduling is adopted to assign the status data packets to the candidate link with the smallest polling pointer; the above status data scheduling process is repeated until all the data packets in the status data queue are assigned.
[0044] For all candidate links assigned to data frames, for each candidate link, after completing the data packet allocation of a scheduling cycle, the corresponding link will be marked as ready; for all candidate links marked as ready, parallel data transmission is started at the same time; the candidate links in the ready state work independently and establish logical transmission channels with the base station respectively; through handshake negotiation with the base station, connection-oriented logical links and transmission sessions are established at the link layer and transport layer respectively; each candidate link in the ready state transmits in parallel and only transmits data packets assigned to the corresponding link; data transmission on candidate links in different ready states is concurrent with each other; after all candidate links in the current scheduling cycle complete their respective data transmission, the ready state marks of all links are cleared.
[0045] The receiving end receives the encrypted data frame sent by the drone. The drone sends the encrypted data frame to the receiving end through the 5G network uplink. The receiving end receives the encrypted data frame sent by the drone through the 5G network downlink. The receiving end stores the received encrypted data frame in the receiving buffer and waits for subsequent processing. The receiving end performs CRC check on the received encrypted data frame. The receiving end reads the encrypted data frame from the receiving buffer and extracts the Header, Payload and Footer fields therein. The receiving end uses the same CRC algorithm as the sending end to calculate the received Header and Payload data to obtain the checksum value CRC_Value. The receiving end compares the calculated checksum value CRC_Value with the checksum Checksum carried in the Footer field of the data frame. If CRC_Value is equal to Checksum, it indicates that the data frame has no bit error or loss during transmission, and the CRC check passes. If CRC_Value is not equal to Checksum, it indicates that the data frame has a bit error or loss during transmission, the CRC check fails, and the receiving end discards the data frame.
[0046] Preferably, when the data frame is long, you can consider dividing the Payload into blocks, and calculate the CRC for each data block separately. The sending end processes: determine the appropriate block size, such as 256 bytes or 1024 bytes, set to B; divide the Payload of the data frame into N blocks, each block size is B, and the last block may be smaller than B; perform CRC calculation on each data block to generate N CRC values, set as CRC_1, CRC_2, ..., CRC_N; append these N CRC values after the Payload to form a new Payload. The receiving end processes: after receiving the data frame, first extract the Payload part; according to the agreed block size B, divide the Payload into N blocks and N CRC values; recalculate the CRC for each data block to obtain CRC'_1, CRC'_2, ..., CRC'_N; compare the calculated CRC'_i with the received CRC_i (i=1, 2, ..., N); if all CRC values are consistent, the Payload check passes, otherwise the block is retransmitted or error correction is performed. Retransmission or error correction processing: After receiving the NACK message, the sender retransmits the data block that failed the verification; or the receiver requests the retransmission of the data block that failed the verification; when the bit error rate is low, error correction coding can also be used for recovery to reduce retransmission overhead.
[0047] Error correction coding: Taking RS code as an example, the error correction coding process is explained. The sending end processes: Divide the payload into blocks, set the block size to B, and a total of N blocks; RS encode each data block to generate n coded symbols, of which k are original data symbols and nk are redundant check symbols; package the original data symbols and check symbols into a new payload, and calculate the CRC value; attach the CRC value after the payload to form a complete data frame. The receiving end processes: After receiving the data frame, extract the payload and CRC parts; perform CRC check on the payload, and if it passes, directly extract the original data; if the CRC check fails, perform RS decoding; extract the n coded symbols in the payload, perform RS decoding, and recover the original k data symbols; if the decoding is successful, use the recovered data as the original payload; if the decoding fails, request to retransmit the data block or the entire data frame. RS encoding and decoding principle, RS encoding is a linear block code that is encoded and decoded over the finite field GF (2^m); the transmitter maps k original data symbols to the information polynomial f (x) in the GF (2^m) field; based on the RS code generator polynomial g (x), nk check symbols are calculated to form the coding polynomial c (x); the receiver receives the possibly erroneous coding polynomial r (x), r (x) = c (x) + e (x); the error position and error value are determined by calculating the syndrome and the error location polynomial; e (x) is subtracted from r (x) to restore the original coding polynomial c (x), thereby recovering the original data f (x).
[0048] The receiving end decrypts the encrypted data frame that passes the CRC check. The receiving end parses the Header, Payload, and Footer fields of the encrypted data frame according to the preset data frame structure. The receiving end determines whether the ciphertext data in the Payload field is drone status data or control instructions based on the data type identifier Type in the Header field. The receiving end uses the preset private key PRK to perform AES symmetric decryption on the ciphertext data in the Payload field of the received data frame. If the Type is drone status data, the decryption result is the plaintext drone status data, including information such as the drone's position coordinates, flight speed, and altitude. If the Type is a control instruction, the decryption result is the plaintext control instruction, including information such as path planning and obstacle avoidance strategies.
[0049] The receiving end performs an integrity check on the decrypted plaintext data. The receiving end extracts the hash value in the Footer field of the received data frame as the first hash value Hash1. The receiving end pads the decrypted plaintext data so that its length becomes an integer multiple of the packet size. The receiving end divides the padded plaintext data into Q groups, and each group is divided into W sub-packets. The receiving end performs E cycles of compression on each packet to generate the hash value Hashi of the packet. The receiving end performs bitwise XOR on the hash values Hashi of all packets to obtain the final hash value Hash2 of the plaintext data. The receiving end compares the first hash value Hash1 and the final hash value Hash2. If Hash1 and Hash2 are consistent, it means that the plaintext data decrypted by the receiving end is completely consistent with the plaintext data before encryption by the sending end, no tampering or loss has occurred, and the integrity check passes. If Hash1 and Hash2 are inconsistent, it means that the plaintext data decrypted by the receiving end is inconsistent with the plaintext data before encryption by the sending end, tampering or loss has occurred, the integrity check fails, and the receiving end discards the data frame. After the integrity verification is passed, the decrypted plaintext data will be sent to the subsequent business process for processing.
[0050] The invention of the present application and its implementation methods are described schematically above. The description is not restrictive. Without departing from the spirit or basic features of the present application, the present application can be implemented in other specific forms. If a person of ordinary skill in the art is inspired by it, and without departing from the purpose of the present invention, designs a structural method and an implementation method similar to the technical solution without creativity, they should all fall within the scope of protection of this patent. In addition, the word "including" does not exclude other elements or steps, and the word "one" before an element does not exclude the inclusion of "multiple" elements. The multiple elements stated in the product claim can also be implemented by one element through software or hardware. The words first, second, etc. are used to indicate names, and do not indicate any specific order.
Claims
1. A method for transmitting UAV patrol data, characterized in that: Concatenate the 5G terminal serial number SN and the timestamp TS to obtain the random number seed S; Extract the drone device ID and 5G terminal IMEI number, and use XOR operation to obtain an N-bit ASCII string as the constant key; The random number seed S is used as plaintext, the constant key key is used as the secret key, and the encryption key MK is generated in AES-ECB mode. The secret key MK contains the public key PUK and the private key PRK. Use the RSA asymmetric encryption algorithm and the public key PUK as the encryption key to encrypt the drone status data or control instructions to obtain the ciphertext C; Encapsulate the ciphertext C into a data frame according to a preset data structure; The data frame contains a unique identifier, timestamp, data type, data length, ciphertext, metadata, and CRC checksum; Perform integrity check on the encapsulated data frame; After verification, based on the comprehensive quality score of each link, the data frame is scheduled to P candidate 5G links through multi-link data scheduling, and the data frame is sent in parallel transmission mode; Decrypt the encrypted data frame to obtain the plaintext data, and verify the integrity of the decrypted plaintext data; The data frame is sent in parallel transmission mode, including: The selected P candidate links are numbered from 1 to P, and the polling pointers are set respectively, with the initial value being equal to the number; Establish a control instruction queue and a status data queue. The priority of the control instruction queue is higher than that of the status data queue. Extract the control instruction data packets to be transmitted from the head of the control instruction queue in sequence; traverse the polling pointers of the candidate links to obtain the candidate link with the smallest current pointer value; assign the extracted control instruction data packets to the obtained candidate links; increase the polling pointer of the assigned link by P to point to the next candidate link; repeat the control instruction scheduling process until all the data packets in the control instruction queue are assigned; The status data packets to be transmitted are extracted from the head of the status data queue in turn, and the same polling strategy as the control instruction scheduling is adopted to allocate the status data packets to the candidate link with the smallest polling pointer; the status data scheduling process is repeated until all the data packets in the status data queue are allocated.
2. The method for transmitting the UAV patrol data according to claim 1, characterized in that: The preset data structure includes: Header, Payload and Footer; In the Header, the unique identifier BID, timestamp Timestamp, data type identifier Type and data length Length of the data frame are set in sequence; the unique identifier BID adopts the GUID generated based on the drone device identifier ID and timestamp Timestamp; the data type identifier Type is used to identify that the data frame carries the drone status data; The encrypted state data C and metadata Metadata are set in Payload in sequence; wherein the metadata Metadata includes the GPS location coordinate information of the drone; In the Footer, set the CRC check, Checksum and SHA256 hash value of the data frame; the Checksum is obtained by CRC calculation of the Header and Payload data of the data frame, which is used to verify the integrity of the data frame; the SHA256 hash value is calculated by the sender using the SHA256 algorithm on the plaintext data of the Header and Payload, which is used to verify the integrity of the decrypted plaintext.
3. The method for transmitting the UAV patrol data according to claim 2, characterized in that: Perform integrity check on the encapsulated data frame, including: Receive data frames and extract the Header and Payload fields; Use the same CRC algorithm as the sender to calculate the received Header and Payload data to obtain the checksum value CRC_Value; The calculated checksum value CRC_Value is compared with the checksum carried in the Footer field of the data frame. If CRC_Value is equal to Checksum, it indicates that no bit error or loss occurs in the data frame during transmission and the check passes. Otherwise, the check fails.
4. The method for transmitting the UAV patrol data according to claim 3 is characterized in that: Decrypt the encrypted data frame to obtain the plaintext data, including: Receive encrypted data frame; According to the preset data frame structure, parse out the Header, Payload and Footer fields; According to the data type identifier Type in the Header field, it is determined whether the ciphertext data in the Payload field is drone status data or control instructions; Use the private key PRK to perform AES symmetric decryption on the ciphertext data in the Payload of the received data frame; if the Type is drone status data, the decryption result is the plaintext of the drone status data; if the Type is control command, the decryption result is the plaintext of the control command; The drone status data in plain text includes the drone’s location coordinates, flight speed, and altitude; The control instructions contain path planning and obstacle avoidance strategies in plain text.
5. The method for transmitting the UAV patrol data according to claim 4, characterized in that: Verify the integrity of the decrypted plaintext data: Extract the hash value in the Footer field of the received data frame as the first hash value Hash1; After padding, the plaintext data is divided into Q groups, and each group is divided into W sub-groups; For each of the W subgroups, perform E cycles of compression to generate Hashi; Perform bitwise XOR on the Hashi of all groups to get the final hash value Hash2 of the plaintext data; Compare the first hash value Hash1 and Hash2. If they are consistent, it means that the plaintext data after decryption by the receiving end is completely consistent with the plaintext data before encryption by the sending end, and no tampering or loss has occurred. The integrity check passes, otherwise it fails.
6. The method for transmitting the UAV patrol data according to claim 1, characterized in that: The data frame is sent in parallel transmission mode, and also includes: For each candidate link, after completing the data packet allocation of a scheduling cycle, the corresponding link is marked as ready; For all candidate links marked as ready, parallel data transmission is started simultaneously; The candidate links in the ready state work independently and establish logical transmission channels with the base station respectively. Through handshake negotiation with the base station, connection-oriented logical links and transmission sessions are established at the link layer and transport layer respectively. Each candidate link in the ready state transmits in parallel and only transmits the data packets assigned to the corresponding link; Data transmission on candidate links in different readiness states is concurrent with each other; After all candidate links of the current scheduling period complete their respective data transmission, the ready state flags of all links are cleared.
Citation Information
Patent Citations
Elliptic curve encryption-based unmanned aerial vehicle and base station communication identity authentication method
CN112073964A
System and method for transmitting data between mobile terminals
CN102118710A
Lightweight power transaction private network communication encryption method based on dynamic key
CN116321129A