CN118118567A - Power utilization information transmission method, device and transmission system - Google Patents
Power utilization information transmission method, device and transmission system Download PDFInfo
- Publication number
- CN118118567A CN118118567A CN202410133089.2A CN202410133089A CN118118567A CN 118118567 A CN118118567 A CN 118118567A CN 202410133089 A CN202410133089 A CN 202410133089A CN 118118567 A CN118118567 A CN 118118567A
- Authority
- CN
- China
- Prior art keywords
- data
- data packet
- lost
- packet
- sending
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 230000005540 biological transmission Effects 0.000 title claims abstract description 135
- 238000000034 method Methods 0.000 title claims abstract description 76
- 230000004044 response Effects 0.000 claims abstract description 40
- 230000005611 electricity Effects 0.000 claims abstract description 38
- 239000013589 supplement Substances 0.000 claims abstract description 16
- 238000004891 communication Methods 0.000 claims description 40
- 238000012545 processing Methods 0.000 claims description 25
- 230000008569 process Effects 0.000 description 15
- 238000010586 diagram Methods 0.000 description 14
- 238000004590 computer program Methods 0.000 description 11
- 230000006870 function Effects 0.000 description 10
- 238000013500 data storage Methods 0.000 description 6
- 238000005516 engineering process Methods 0.000 description 5
- 230000002159 abnormal effect Effects 0.000 description 2
- 238000013144 data compression Methods 0.000 description 2
- 230000004048 modification Effects 0.000 description 2
- 238000012986 modification Methods 0.000 description 2
- 230000003287 optical effect Effects 0.000 description 2
- 238000004806 packaging method and process Methods 0.000 description 2
- 230000002457 bidirectional effect Effects 0.000 description 1
- 230000008859 change Effects 0.000 description 1
- 238000010276 construction Methods 0.000 description 1
- 230000007547 defect Effects 0.000 description 1
- 238000001514 detection method Methods 0.000 description 1
- 230000000694 effects Effects 0.000 description 1
- 230000006872 improvement Effects 0.000 description 1
- 238000004519 manufacturing process Methods 0.000 description 1
- 238000010295 mobile communication Methods 0.000 description 1
- 239000013307 optical fiber Substances 0.000 description 1
- 238000011160 research Methods 0.000 description 1
- 230000003068 static effect Effects 0.000 description 1
- 238000012876 topography Methods 0.000 description 1
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L69/00—Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
- H04L69/16—Implementation or adaptation of Internet protocol [IP], of transmission control protocol [TCP] or of user datagram protocol [UDP]
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L67/00—Network arrangements or protocols for supporting network services or applications
- H04L67/01—Protocols
- H04L67/12—Protocols specially adapted for proprietary or special-purpose networking environments, e.g. medical networks, sensor networks, networks in vehicles or remote metering networks
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Health & Medical Sciences (AREA)
- Computing Systems (AREA)
- General Health & Medical Sciences (AREA)
- Medical Informatics (AREA)
- Computer Security & Cryptography (AREA)
- Mobile Radio Communication Systems (AREA)
Abstract
The application provides a transmission method, a device and a transmission system of electricity information. The method comprises the following steps: receiving a data packet sent by a sending end, wherein the data packet is generated by the sending end according to the number of times of sending the ammeter data and updated ammeter data, and the data format of the data packet is a Beidou short message; determining whether the data packet is lost or not according to the related information of the data packet, wherein the related information is a sequence number and/or an end flag bit; and under the condition that the data packet is lost, transmitting a first data response packet to the transmitting end so that the transmitting end supplements the lost data, and under the condition that the data packet is not lost, uploading the data packet to the server. The method solves the problem of low transmission efficiency of the Beidou short message in the prior art.
Description
Technical Field
The application relates to the technical field of Beidou data communication, in particular to a power consumption information transmission method, a device, a computer readable storage medium and a transmission system.
Background
At present, the intelligent construction of the power grid in China is realized, the communication technologies such as optical fiber communication, GPRS, power line carrier and the like are commonly adopted in a power system, and the intelligent acquisition of resident electricity information is basically realized in cities and towns. While the requirements of full coverage, full collection and full cost control are put forward in the high-altitude areas of China, the automatic collection of resident electricity information is not completely realized at present due to the high topography and complex climate of the high-altitude areas. The power grid data acquisition in the high-altitude area has the problems of high wired network laying cost and difficult coverage of the whole area. Recent researches show that the Beidou short message communication technology is adopted as a transmission mode, and the Beidou short message communication technology has the characteristics of long transmission distance, no blind area, safety, reliability and the like, and is a feasible scheme. The Beidou satellite navigation system is a global satellite navigation system which is autonomously built in China, independently operates and is compatible with other systems, the system not only can realize functions of positioning, time service, short message communication, user detection and the like, but also can perform bidirectional data transmission, and has wide coverage range, safety and reliability.
However, the current Beidou short message is adopted for power utilization information communication in high-altitude areas to have the defect of unreliable message transmission, so that the current Beidou short message transmission efficiency is low.
Disclosure of Invention
The application mainly aims to provide a transmission method, a device, a computer readable storage medium and a transmission system for electricity information, which are used for at least solving the problem of low transmission efficiency of Beidou short messages in the prior art.
In order to achieve the above object, according to one aspect of the present application, there is provided a transmission method of electricity information, including: receiving a data packet sent by a sending end, wherein the data packet is generated by the sending end according to the number of times of ammeter data sending and updated ammeter data, and the data format of the data packet is a Beidou short message; determining whether the data packet is lost or not according to the related information of the data packet, wherein the related information is a sequence number and/or an end zone bit; and under the condition that the data packet is lost, a first data response packet is sent to the sending end, so that the sending end reissues the lost data, and under the condition that the data packet is not lost, the data packet is uploaded to a server.
Optionally, receiving the data packet sent by the sending end includes: receiving a first data packet, wherein the first data packet is a data packet when the transmitting end transmits data for the first time; and receiving a second data packet, wherein the second data packet is a data packet when the transmitting end transmits data for the nth time, the second data packet comprises incremental data, and the incremental data is the difference value between the data of the nth time and the data of the (N-1) th time, and N is more than or equal to 2.
Optionally, receiving the data packet sent by the sending end includes: receiving a plurality of data packets, wherein the data packets are sent by the sending end, the sending end sequentially collects the ammeter data of a plurality of user ends, writes the ammeter data into a first data packet to be sent under the condition that the sum of the lengths of the ammeter data is smaller than a preset length, pauses writing data into the first data packet to be sent until the sum of the lengths of the ammeter data in the first data packet to be sent is larger than or equal to the preset length, writes data into a second data packet to be sent until all ammeter data of all the user ends are collected, and writes an ending mark bit into the last data packet to be sent.
Optionally, the number of the data packets is multiple, the data packets and the sequence numbers are in one-to-one correspondence, and determining whether the data packets are lost according to the related information of the data packets includes: and under the condition that all first preset conditions are met, determining that no data packet is lost, wherein the first preset conditions comprise: the sequence numbers are ordered according to a preset ordering mode, the first difference value between the Mth sequence number and the Mth-1 sequence number is equal to the second difference value between the Mth sequence number and the Mth+1th sequence number, and the ending zone bit is obtained; and under the condition that any one of the first preset conditions is not met, determining that the data packet is lost.
Optionally, after determining whether the data packet is lost according to the related information of the data packet, the method further includes: determining whether a second preset condition is met, wherein the second preset condition comprises: the duration of the data packet which is not received is greater than or equal to the target duration, and the data packet cannot be normally analyzed; and under the condition that the second preset condition is met, sending a second response data packet to the sending end so that the sending end resends the data.
Optionally, after determining whether the data packet is lost according to the related information of the data packet, the method further includes: determining whether a third preset condition is met, wherein the third preset condition comprises: the duration of the data packet which is not received is greater than or equal to the target duration, and the ending zone bit is not acquired; and under the condition that the third preset condition is met, sending a third response data packet to the sending end, so that the sending end reissues the last data packet.
Optionally, in the case that the data packet is lost, a first data response packet is sent to the sending end, so that after the sending end reissues the lost data, the method further includes: acquiring the number of reissue times; when the reissue times are larger than or equal to the preset times, and the data packet is still lost, stopping sending the first data response packet to the sending end, executing the next collection task, and reporting the abnormity of the sending end to the server; and uploading the reissued data and the data packet to the server under the condition that the reissued times are less than or equal to the preset times and the successful reissuing of the data packet is determined.
According to another aspect of the present application, there is provided a transmission apparatus of electricity information, including: the receiving unit is used for receiving a data packet sent by a sending end, wherein the data packet is generated by the sending end according to the number of times of ammeter data sending and updated ammeter data, and the data format of the data packet is a Beidou short message; the first determining unit is used for determining whether the data packet is lost or not according to the related information of the data packet, wherein the related information is a sequence number and/or an end zone bit; and the first processing unit is used for sending a first data response packet to the sending end under the condition that the data packet is lost, so that the sending end supplements the lost data, and uploading the data packet to a server under the condition that the data packet is not lost.
According to still another aspect of the present application, there is provided a computer-readable storage medium including a stored program, wherein the program, when executed, controls a device in which the computer-readable storage medium is located to perform any one of the transmission methods of electricity consumption information.
According to yet another aspect of the present application, there is provided a transmission system including: the power consumption information transmission system comprises a sending end and a receiving end, wherein the sending end is in communication connection with the receiving end, and the receiving end is used for executing any one transmission method of the power consumption information.
By applying the technical scheme of the application, the transmitting end collects data and then transmits the data to the receiving end, the receiving end can judge the transmission state of the data, namely whether the data is lost, and if the data is lost, the transmitting end supplements the data, so that the reliability of a transmission message can be improved, the integrity of the data is ensured, and the data transmission efficiency is improved.
Drawings
The accompanying drawings, which are included to provide a further understanding of the application and are incorporated in and constitute a part of this specification, illustrate embodiments of the application and together with the description serve to explain the application. In the drawings:
fig. 1 is a block diagram showing a hardware configuration of a mobile terminal performing a transmission method of electricity consumption information provided in an embodiment according to the present application;
Fig. 2 is a schematic flow chart of a method for transmitting electricity information according to an embodiment of the present application;
fig. 3 shows a schematic structural diagram of the transmission system of the present application;
FIG. 4 shows a schematic diagram of a process flow of a transmission system;
FIG. 5 shows a schematic diagram of a processing flow at a sender;
FIG. 6 is a schematic diagram showing a processing flow of a receiving end;
Fig. 7 shows a block diagram of a power consumption information transmission device according to an embodiment of the present application.
Wherein the above figures include the following reference numerals:
102. A processor; 104. a memory; 106. a transmission device; 108. an input-output device; 10. a transmitting end; 11. a receiving end; 12. a server; 13. a user electricity meter; 14. a Beidou satellite; 15. a ground based central station.
Detailed Description
It should be noted that, without conflict, the embodiments of the present application and features of the embodiments may be combined with each other. The application will be described in detail below with reference to the drawings in connection with embodiments.
In order that those skilled in the art will better understand the present application, a technical solution in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings in which it is apparent that the described embodiments are only some embodiments of the present application, not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the present application without making any inventive effort, shall fall within the scope of the present application.
It should be noted that the terms "first," "second," and the like in the description and the claims of the present application and the above figures are used for distinguishing between similar objects and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used may be interchanged where appropriate in order to describe the embodiments of the application herein. Furthermore, the terms "comprises," "comprising," and "having," and any variations thereof, are intended to cover a non-exclusive inclusion, such that a process, method, system, article, or apparatus that comprises a list of steps or elements is not necessarily limited to those steps or elements expressly listed but may include other steps or elements not expressly listed or inherent to such process, method, article, or apparatus.
As described in the background art, the transmission efficiency of the Beidou short message in the prior art is low, and in order to solve the problems, the embodiment of the application provides a transmission method, a device, a computer readable storage medium and a transmission system of electricity information.
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention.
The method embodiments provided in the embodiments of the present application may be performed in a mobile terminal, a computer terminal or similar computing device. Taking the operation on a mobile terminal as an example, fig. 1 is a block diagram of a hardware structure of a mobile terminal according to an embodiment of the present application. As shown in fig. 1, a mobile terminal may include one or more (only one is shown in fig. 1) processors 102 (the processor 102 may include, but is not limited to, a microprocessor MCU or a processing device such as a programmable logic device FPGA) and a memory 104 for storing data, wherein the mobile terminal may also include a transmission device 106 for communication functions and an input-output device 108. It will be appreciated by those skilled in the art that the structure shown in fig. 1 is merely illustrative and not limiting of the structure of the mobile terminal described above. For example, the mobile terminal may also include more or fewer components than shown in fig. 1, or have a different configuration than shown in fig. 1.
The memory 104 may be used to store a computer program, for example, a software program of application software and a module, such as a computer program corresponding to a display method of device information in an embodiment of the present invention, and the processor 102 executes the computer program stored in the memory 104 to perform various functional applications and data processing, that is, to implement the above-described method. Memory 104 may include high-speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some examples, the memory 104 may further include memory remotely located relative to the processor 102, which may be connected to the mobile terminal via a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof. The transmission device 106 is used to receive or transmit data via a network. Specific examples of the network described above may include a wireless network provided by a communication provider of the mobile terminal. In one example, the transmission device 106 includes a network adapter (Network Interface Controller, simply referred to as a NIC) that can connect to other network devices through a base station to communicate with the internet. In one example, the transmission device 106 may be a Radio Frequency (RF) module, which is configured to communicate with the internet wirelessly.
In the present embodiment, a transmission method of power consumption information operating on a mobile terminal, a computer terminal, or a similar computing device is provided, it should be noted that the steps illustrated in the flowchart of the drawings may be performed in a computer system such as a set of computer executable instructions, and that although a logical order is illustrated in the flowchart, in some cases, the steps illustrated or described may be performed in an order different from that herein.
Fig. 2 is a flow chart of a method for transmitting electricity information according to an embodiment of the present application. As shown in fig. 2, the method comprises the steps of:
step S201, receiving a data packet sent by a sending end, wherein the data packet is generated by the sending end according to the number of times of sending the ammeter data and updated ammeter data, and the data format of the data packet is Beidou short message;
Specifically, for the stability of data transmission of the ammeter and the reliability of data transmission of the high-altitude area, a transmission system of high-altitude electricity consumption information based on Beidou short messages is designed, as shown in fig. 3, and the system mainly comprises two parts: a transmitting end 10 and a receiving end 11 of the Beidou electricity utilization data. The execution subject of the above-described transmission method of electricity information may be a receiving end.
In addition, as shown in fig. 3, the system further comprises a server 12, a user electric meter 13, a Beidou satellite 14 and a ground central station 15, wherein the server is in communication connection with a receiving end, the user electric meter is in communication connection with a transmitting end, the Beidou satellite is in communication connection with the transmitting end and the receiving end respectively, the Beidou satellite is used for transmitting data, the ground central station is in communication connection with the Beidou satellite, and the ground central station is used for controlling the Beidou satellite to operate.
Step S202, determining whether the data packet is lost or not according to the related information of the data packet, wherein the related information is a sequence number and/or an end flag bit;
Specifically, the receiving end may determine whether the data packet sent by the sending end is lost, may be determined according to the sequence number arrangement, may be determined according to whether the end flag bit is detected, or may be determined according to both the two information together.
Step S203, when the data packet is lost, a first data response packet is sent to the sending end, so that the sending end supplements the lost data, and when the data packet is not lost, the data packet is uploaded to a server.
Specifically, the transmitting end is used for collecting and transmitting ammeter data (i.e. electricity consumption data) and receiving command reissue data, and the transmitting end can be a concentrator, a transmitter or other devices.
Specifically, the receiving end is configured to receive data sent by the sending end, and send a command for repairing the sent data to the sending end.
Through the embodiment, the sending end collects data and sends the data to the receiving end, the receiving end can judge the transmission state of the data, namely whether the data is lost, if the data is lost, the sending end supplements the data, so that the reliability of a transmission message can be improved, the integrity of the data is ensured, and the data transmission efficiency is improved.
Specifically, as shown in fig. 4, the processing flow of the transmission system is that the transmitting end compresses the collected data, the collected data is sent in packets through the beidou short message, the receiving end receives the short message information and packages the short message information, the beidou protocol data is converted into electricity information, and the package is successfully uploaded to the host station. A series of functions such as interconnection and intercommunication of a transmitting end and a receiving end, remote meter reading and control are realized through a transmission system.
At present, the power consumption information transmission by adopting Beidou short message communication has the following problems: the length of a single message of Beidou short message communication is limited, for example, the length of a single message of a commonly used Beidou SIM card is 78.5Byte; the communication frequency of the Beidou short message is limited, and the civil communication frequency is 60 s/time; the Beidou communication link has certain unreliability and no communication receipt.
Specifically, aiming at the problems of limited message transmission, low transmission efficiency, unreliable and the like in the power consumption information communication by adopting the Beidou short message in the high-altitude area, the scheme of the application can solve the problem of low power consumption information transmission efficiency caused by limited single message length and communication frequency of the Beidou card, and simultaneously improve the short message transmission efficiency and the data reliability.
In the specific implementation process, the receiving of the data packet sent by the sending end can be realized by the following steps: receiving a first data packet, wherein the first data packet is a data packet when the transmitting end transmits data for the first time; and receiving a second data packet, wherein the second data packet is a data packet when the transmitting end transmits data for the nth time, the second data packet comprises incremental data, the incremental data is the difference value between the data of the nth time and the data of the (N-1) th time, and N is more than or equal to 2.
In the method, the transmitting end can determine whether to transmit data for the first time, the data is transmitted to the receiving end according to the determined result, the receiving end receives the data again, if the data is transmitted for the first time, the transmitting end transmits complete ammeter data, if the data is transmitted for the nth time, only incremental data is required to be transmitted, redundant data is not required to be transmitted, and the data transmission efficiency can be further improved.
Specifically, for example, when the first transmission of the meter data is 100 and the meter data becomes 101 before the second transmission of the meter data, incremental data is generated, 101-100=1, and only 1 is transmitted to the receiving end.
In the specific implementation process, the receiving of the data packet sent by the sending end can be realized by the following steps: and receiving a plurality of data packets, wherein the data packets are transmitted by the transmitting end, the transmitting end sequentially collects the ammeter data of a plurality of user ends, under the condition that the sum of the lengths of the ammeter data is smaller than a preset length, the ammeter data are written into a first data packet to be transmitted until the sum of the lengths of the ammeter data in the first data packet to be transmitted is larger than or equal to the preset length, writing data into the first data packet to be transmitted is suspended, writing data into a second data packet to be transmitted, and writing an ending mark bit into the last data packet to be transmitted until all the ammeter data of all the user ends are completely collected.
In the scheme, the transmitting end can determine the length of data to be transmitted, the length of the data is smaller than the preset length, the data is written into a first data packet to be transmitted, the data is continuously read, if the length of the data is still smaller than the preset length, the data is continuously read, the operation is repeated until the length of the data is larger than or equal to the preset length, the data is stopped being written into the first data packet to be transmitted, the data is written into a second data packet to be transmitted, the judging rule of the data length is consistent with the judging rule of the first data packet to be transmitted, if the data to be transmitted is completely read, the end zone bit is written, the data is packetized, and the data transmission is slow due to too much data in one data packet, so that the data transmission efficiency is further improved.
Specifically, the preset length may be 78.5 bytes, or 128 bytes, or other lengths.
Specifically, the incremental data compression transmission method is adopted to improve the data transmission efficiency, hardware coding is not relied on, the universality and portability are good, the self-adaption of the message transmission length and the message transmission frequency is carried out by reading the adopted Beidou card information, and the flexibility is achieved.
Specifically, as shown in fig. 5, the data processing flow of the transmitting end includes the following steps:
Step A1: powering up and initializing, reading Beidou SIM card information, judging the type of the SIM card, and automatically judging the maximum length X of data transmitted each time according to the type of the SIM card;
step A2: judging whether the serial port receives the data of the intelligent electric meter, and if so, performing the following operations:
(1) Judging whether the electric meter data is sent for the first time, if so, directly transmitting the complete electric meter data, and carrying out data storage backup;
(2) If the data is not transmitted for the first time, the increment value between the acquired data and the data in the data storage record is judged, if the increment value does not exceed a set threshold value, only the ammeter increment data is transmitted, and if the increment value exceeds the set threshold value (the threshold value is adjusted according to the surrounding application environment), the complete ammeter data is required to be transmitted for data storage backup;
(3) Storing data to be transmitted into a transmission buffer area;
Step A3: judging the length of data to be transmitted, if the length is less than X, directly writing the data into a transmission array (data packet to be transmitted), continuously reading the next unit, and if the sum of the data length is still less than X, continuously writing the data into the transmission array; repeating the operation until the sum of the data length is greater than X, and stopping reading; if the data to be transmitted are all fetched, writing an ending zone bit, and carrying out data subpackaging;
step A4: and (3) packaging the Beidou short message communication protocol, and performing satellite communication data transmission operation under the following conditions: the sum of the data length is greater than X, short message transmission is carried out, or And the counter reaches the SIM card sending interval to send the short message.
In order to accurately determine whether a data packet is lost, the number of the data packets is plural, the data packets correspond to the sequence numbers one by one, and whether the data packet is lost is determined according to the related information of the data packets, the method can be realized by the following steps: and under the condition that all first preset conditions are met, determining that no data packet is lost, wherein the first preset conditions comprise: the sequence numbers are ordered according to a preset ordering mode, the first difference value between the Mth sequence number and the M-1 th sequence number is equal to the second difference value between the Mth sequence number and the M+1th sequence number, and the end zone bit is obtained; and determining that the data packet is lost when any one of the first preset conditions is not met.
In this scheme, if the sequence numbers of the plurality of data packets are arranged in the order from large to small or from small to large, or the sequence number differences among the plurality of data packets are the same, or the end flag bit is detected, it can be determined that the received data packet is not lost, and if any condition is not satisfied, it is determined that the received data packet is lost, so that it can be determined more accurately whether the data packet is lost.
Specifically, the sequence numbers of the general data packets are arranged in the order of 1,2, 3, 4, 5 and 6, if the sequence number of the received data packet is 1,2, 3 and 6, it is determined that two data packets of 4 and 5 are lost in the middle, two data packets of 4 and 5 are sequentially reissued, and if the sequence number of the received data packet is 1,2, 4, 5 and 6, it is determined that 3 data packets are lost in the middle, and 3 data packets are sequentially reissued.
In some embodiments, after determining whether the data packet is lost according to the related information of the data packet, the method further includes the steps of: determining whether a second preset condition is met, wherein the second preset condition comprises: the duration of the data packet which is not received is longer than or equal to the target duration, and the data packet cannot be normally analyzed; and sending a second response data packet to the sending end under the condition that the second preset condition is met, so that the sending end resends the data.
In the scheme, if the receiving end can not always receive the data packet sent by the sending end and the time length reaches the target time length, or the receiving end finds that the data packet is abnormal after analyzing the data packet, the analyzed file is a messy code, then the receiving end can be determined to have a loss and request the sending end to resend the data packet, if the conditions are not met, then the receiving end can be determined to have no loss, thus the receiving end can accurately determine whether the data packet is lost or not, and can carry out reissue when the data packet is lost, thus the reliability of the transmission message can be further improved, the data integrity is further ensured, and the data transmission efficiency is further improved.
Specifically, the target duration may be 1h, 2h, or 1min, and may be any feasible duration.
In some embodiments, after determining whether the data packet is lost according to the related information of the data packet, the method further includes the steps of: determining whether a third preset condition is met, wherein the third preset condition comprises: the duration of the data packet which is not received is greater than or equal to the target duration, and the ending zone bit is not acquired; and sending a third response data packet to the sending end under the condition that the third preset condition is met, so that the sending end reissues the last data packet.
In the scheme, if the receiving end can not always receive the data packet sent by the sending end and the time length reaches the target time length, or the receiving end can not detect the end flag bit, the receiving end can determine that the received data packet is lost, request the sending end to resend the last data packet, and if the conditions are not met, the receiving end can determine that the received data packet is not lost, so that whether the data packet is lost can be accurately determined, and the data packet can be reissued when being lost, thereby further improving the reliability of a transmission message, further ensuring the integrity of data and further improving the data transmission efficiency.
Specifically, the receiving end receives the Beidou short message, analyzes the message content according to the Beidou short message data format, and the data processing flow of the receiving end is shown in fig. 6, and comprises the following steps:
Step B1: the receiving end receives the Beidou short message signal, analyzes the message content and assembles the message content according to the data sub-packet sequence number identified by the packet header;
step B2: detecting an end bit, analyzing successfully, finishing the data receiving, and sending a data response packet with information content of 0 to a sending end, wherein the data response packet indicates that the data packet is completely received without sub-packet loss (finishing data receiving, uploading a master station, namely a server);
Step B3: if the group of the packets fails, the sub-packets are lost, a data response packet with the information content of the sequence number of the lost data sub-packet is sent to a sending terminal, and the sending terminal (namely the acquisition terminal) is prompted to perform lost data reissue;
Step B4: if the Beidou short message signal cannot be received or the message content cannot be normally analyzed within the foreseeable time, searching the data packet of the next packet according to the number, sending a data response packet with the information content of the sequence number of the lost data sub-packet to a sending end, and prompting the sending end to carry out lost data reissue;
Step B5: if no new short message is available in the foreseeable time and the ending bit is not detected, a data response packet with the information content of-1 is sent to the sending end, the sending end is prompted to lose the ending bit, and the last packet of data is sent in a reissue mode.
Specifically, the data response packets of different types are adopted to prompt the data state of the transmitting end, the transmitting end is guided to retransmit, and the reliability of the Beidou short message transmission data is improved.
In some embodiments, in the case that the data packet is lost, the method further includes the following steps after sending a first data response packet to the sending end, so that the sending end supplements the lost data: acquiring the number of reissue times; when the number of the reissue times is greater than or equal to the preset number of times, and the data packet is still lost, stopping sending the first data response packet to the sending end, executing the next collection task, and reporting the abnormity of the sending end to the server; and uploading the reissued data and the data packet to the server under the condition that the reissued times are less than or equal to the preset times and the successful reissuing of the data packet is determined.
In the scheme, in the data reissue process, if reissue is unsuccessful, repeatedly sending a data reissue request, obtaining reissue times, repeatedly presetting times in the process, if the reissue is unsuccessful, discarding the current transmission line information acquisition task, continuously executing the next task, reporting the abnormity of a sending end, and if the reissue is successful, storing and uploading complete data to a server, so that the reissue death cycle can be avoided.
Specifically, the preset number of times is 3 times, or 5 times, or other times.
The embodiment of the application also provides a transmission device of the electricity consumption information, and the transmission device of the electricity consumption information can be used for executing the transmission method for the electricity consumption information provided by the embodiment of the application. The device is used for realizing the above embodiments and preferred embodiments, and is not described in detail. As used below, the term "module" may be a combination of software and/or hardware that implements a predetermined function. While the means described in the following embodiments are preferably implemented in software, implementation in hardware, or a combination of software and hardware, is also possible and contemplated.
The following describes a transmission device for electricity information provided by the embodiment of the application.
Fig. 7 is a block diagram of a transmission apparatus for electricity consumption according to an embodiment of the present application. As shown in fig. 7, the apparatus includes:
A receiving unit 100, configured to receive a data packet sent by a sending end, where the data packet is generated by the sending end according to the number of times of sending electric meter data and updated electric meter data, and a data format of the data packet is a beidou short message;
Specifically, for the stability of data transmission of the ammeter and the reliability of data transmission of the high-altitude area, a transmission system of high-altitude electricity consumption information based on Beidou short messages is designed, as shown in fig. 3, and the system mainly comprises two parts: a transmitting end 10 and a receiving end 11 of the Beidou electricity utilization data. The execution subject of the above-described transmission method of electricity information may be a receiving end.
In addition, as shown in fig. 3, the system further comprises a server 12, a user electric meter 13, a Beidou satellite 14 and a ground central station 15, wherein the server is in communication connection with a receiving end, the user electric meter is in communication connection with a transmitting end, the Beidou satellite is in communication connection with the transmitting end and the receiving end respectively, the Beidou satellite is used for transmitting data, the ground central station is in communication connection with the Beidou satellite, and the ground central station is used for controlling the Beidou satellite to operate.
A first determining unit 200, configured to determine whether the data packet is lost according to related information of the data packet, where the related information is a sequence number and/or an end flag bit;
Specifically, the receiving end may determine whether the data packet sent by the sending end is lost, may be determined according to the sequence number arrangement, may be determined according to whether the end flag bit is detected, or may be determined according to both the two information together.
The first processing unit 300 is configured to send a first data response packet to the sending end when the data packet is lost, so that the sending end supplements the lost data, and upload the data packet to a server when the data packet is not lost.
Specifically, the transmitting end is used for collecting and transmitting ammeter data (i.e. electricity consumption data) and receiving command reissue data, and the transmitting end can be a concentrator, a transmitter or other devices.
Specifically, the receiving end is configured to receive data sent by the sending end, and send a command for repairing the sent data to the sending end.
Through the embodiment, the sending end collects data and sends the data to the receiving end, the receiving end can judge the transmission state of the data, namely whether the data is lost, if the data is lost, the sending end supplements the data, so that the reliability of a transmission message can be improved, the integrity of the data is ensured, and the data transmission efficiency is improved.
Specifically, as shown in fig. 4, the processing flow of the transmission system is that the transmitting end compresses the collected data, the collected data is sent in packets through the beidou short message, the receiving end receives the short message information and packages the short message information, the beidou protocol data is converted into electricity information, and the package is successfully uploaded to the host station. A series of functions such as interconnection and intercommunication of a transmitting end and a receiving end, remote meter reading and control are realized through a transmission system.
At present, the power consumption information transmission by adopting Beidou short message communication has the following problems: the length of a single message of Beidou short message communication is limited, for example, the length of a single message of a commonly used Beidou SIM card is 78.5Byte; the communication frequency of the Beidou short message is limited, and the civil communication frequency is 60 s/time; the Beidou communication link has certain unreliability and no communication receipt.
Specifically, aiming at the problems of limited message transmission, low transmission efficiency, unreliable and the like in the power consumption information communication by adopting the Beidou short message in the high-altitude area, the scheme of the application can solve the problem of low power consumption information transmission efficiency caused by limited single message length and communication frequency of the Beidou card, and simultaneously improve the short message transmission efficiency and the data reliability.
In a specific implementation process, the receiving unit comprises a first receiving module and a second receiving module, wherein the first receiving module is used for receiving a first data packet, and the first data packet is a data packet when the transmitting end transmits data for the first time; the second receiving module is used for receiving a second data packet, wherein the second data packet is a data packet when the transmitting end transmits data for the nth time, the second data packet comprises incremental data, the incremental data is the difference value between the data for the nth time and the data for the N-1 time, and N is more than or equal to 2.
In the method, the transmitting end can determine whether to transmit data for the first time, the data is transmitted to the receiving end according to the determined result, the receiving end receives the data again, if the data is transmitted for the first time, the transmitting end transmits complete ammeter data, if the data is transmitted for the nth time, only incremental data is required to be transmitted, redundant data is not required to be transmitted, and the data transmission efficiency can be further improved.
Specifically, for example, when the first transmission of the meter data is 100 and the meter data becomes 101 before the second transmission of the meter data, incremental data is generated, 101-100=1, and only 1 is transmitted to the receiving end.
In a specific implementation process, the receiving unit includes a third receiving module, where the third receiving module is configured to receive a plurality of data packets, where the plurality of data packets are sent by the sending end, the sending end sequentially collects the electric meter data of the plurality of user ends, and under a condition that a sum of lengths of the plurality of electric meter data is smaller than a preset length, writes the plurality of electric meter data into a first data packet to be sent until the sum of lengths of the electric meter data in the first data packet to be sent is greater than or equal to the preset length, pauses writing data into the first data packet to be sent, writes data into a second data packet to be sent, and writes an end flag in a last data packet to be sent until all electric meter data of all the user ends are collected.
In the scheme, the transmitting end can determine the length of data to be transmitted, the length of the data is smaller than the preset length, the data is written into a first data packet to be transmitted, the data is continuously read, if the length of the data is still smaller than the preset length, the data is continuously read, the operation is repeated until the length of the data is larger than or equal to the preset length, the data is stopped being written into the first data packet to be transmitted, the data is written into a second data packet to be transmitted, the judging rule of the data length is consistent with the judging rule of the first data packet to be transmitted, if the data to be transmitted is completely read, the end zone bit is written, the data is packetized, and the data transmission is slow due to too much data in one data packet, so that the data transmission efficiency is further improved.
Specifically, the preset length may be 78.5 bytes, or 128 bytes, or other lengths.
Specifically, the incremental data compression transmission method is adopted to improve the data transmission efficiency, hardware coding is not relied on, the universality and portability are good, the self-adaption of the message transmission length and the message transmission frequency is carried out by reading the adopted Beidou card information, and the flexibility is achieved.
Specifically, as shown in fig. 5, the data processing flow of the transmitting end includes the following steps:
Step A1: powering up and initializing, reading Beidou SIM card information, judging the type of the SIM card, and automatically judging the maximum length X of data transmitted each time according to the type of the SIM card;
step A2: judging whether the serial port receives the data of the intelligent electric meter, and if so, performing the following operations:
(1) Judging whether the electric meter data is sent for the first time, if so, directly transmitting the complete electric meter data, and carrying out data storage backup;
(2) If the data is not transmitted for the first time, the increment value between the acquired data and the data in the data storage record is judged, if the increment value does not exceed a set threshold value, only the ammeter increment data is transmitted, and if the increment value exceeds the set threshold value (the threshold value is adjusted according to the surrounding application environment), the complete ammeter data is required to be transmitted for data storage backup;
(3) Storing data to be transmitted into a transmission buffer area;
Step A3: judging the length of data to be transmitted, if the length is less than X, directly writing the data into a transmission array (data packet to be transmitted), continuously reading the next unit, and if the sum of the data length is still less than X, continuously writing the data into the transmission array; repeating the operation until the sum of the data length is greater than X, and stopping reading; if the data to be transmitted are all fetched, writing an ending zone bit, and carrying out data subpackaging;
step A4: and (3) packaging the Beidou short message communication protocol, and performing satellite communication data transmission operation under the following conditions: the sum of the data length is greater than X, short message transmission is carried out, or And the counter reaches the SIM card sending interval to send the short message.
In order to determine more accurately whether a plurality of data packets are lost, where the data packets correspond to the sequence numbers one by one, the first determining unit includes a first determining module and a second determining module, where the first determining module is configured to determine that no data packet is lost when all first preset conditions are satisfied, where the first preset conditions include: the sequence numbers are ordered according to a preset ordering mode, the first difference value between the Mth sequence number and the M-1 th sequence number is equal to the second difference value between the Mth sequence number and the M+1th sequence number, and the end zone bit is obtained; the second determining module is configured to determine that the data packet is lost if any one of the first preset conditions is not satisfied.
In this scheme, if the sequence numbers of the plurality of data packets are arranged in the order from large to small or from small to large, or the sequence number differences among the plurality of data packets are the same, or the end flag bit is detected, it can be determined that the received data packet is not lost, and if any condition is not satisfied, it is determined that the received data packet is lost, so that it can be determined more accurately whether the data packet is lost.
Specifically, the sequence numbers of the general data packets are arranged in the order of 1,2, 3, 4, 5 and 6, if the sequence number of the received data packet is 1,2, 3 and 6, it is determined that two data packets of 4 and 5 are lost in the middle, two data packets of 4 and 5 are sequentially reissued, and if the sequence number of the received data packet is 1,2, 4, 5 and 6, it is determined that 3 data packets are lost in the middle, and 3 data packets are sequentially reissued.
In some embodiments, the apparatus further includes a second determining unit and a second processing unit, where the second determining unit is configured to determine whether a second preset condition is satisfied after determining whether the data packet is lost according to the related information of the data packet, where the second preset condition includes: the duration of the data packet which is not received is longer than or equal to the target duration, and the data packet cannot be normally analyzed; and the second processing unit is used for sending a second response data packet to the sending end under the condition that the second preset condition is met, so that the sending end resends the data.
In the scheme, if the receiving end can not always receive the data packet sent by the sending end and the time length reaches the target time length, or the receiving end finds that the data packet is abnormal after analyzing the data packet, the analyzed file is a messy code, then the receiving end can be determined to have a loss and request the sending end to resend the data packet, if the conditions are not met, then the receiving end can be determined to have no loss, thus the receiving end can accurately determine whether the data packet is lost or not, and can carry out reissue when the data packet is lost, thus the reliability of the transmission message can be further improved, the data integrity is further ensured, and the data transmission efficiency is further improved.
Specifically, the target duration may be 1h, 2h, or 1min, and may be any feasible duration.
In some embodiments, the apparatus further includes a third determining unit and a third processing unit, where the third determining unit is configured to determine whether a third preset condition is met after determining whether the data packet is lost according to the related information of the data packet, where the third preset condition includes: the duration of the data packet which is not received is greater than or equal to the target duration, and the ending zone bit is not acquired; and the third processing unit is used for sending a third response data packet to the sending end under the condition that the third preset condition is met, so that the sending end complements the last data packet.
In the scheme, if the receiving end can not always receive the data packet sent by the sending end and the time length reaches the target time length, or the receiving end can not detect the end flag bit, the receiving end can determine that the received data packet is lost, request the sending end to resend the last data packet, and if the conditions are not met, the receiving end can determine that the received data packet is not lost, so that whether the data packet is lost can be accurately determined, and the data packet can be reissued when being lost, thereby further improving the reliability of a transmission message, further ensuring the integrity of data and further improving the data transmission efficiency.
Specifically, the receiving end receives the Beidou short message, analyzes the message content according to the Beidou short message data format, and the data processing flow of the receiving end is shown in fig. 6, and comprises the following steps:
Step B1: the receiving end receives the Beidou short message signal, analyzes the message content and assembles the message content according to the data sub-packet sequence number identified by the packet header;
step B2: detecting an end bit, analyzing successfully, finishing the data receiving, and sending a data response packet with information content of 0 to a sending end, wherein the data response packet indicates that the data packet is completely received without sub-packet loss (finishing data receiving, uploading a master station, namely a server);
Step B3: if the group of the packets fails, the sub-packets are lost, a data response packet with the information content of the sequence number of the lost data sub-packet is sent to a sending terminal, and the sending terminal (namely the acquisition terminal) is prompted to perform lost data reissue;
Step B4: if the Beidou short message signal cannot be received or the message content cannot be normally analyzed within the foreseeable time, searching the data packet of the next packet according to the number, sending a data response packet with the information content of the sequence number of the lost data sub-packet to a sending end, and prompting the sending end to carry out lost data reissue;
Step B5: if no new short message is available in the foreseeable time and the ending bit is not detected, a data response packet with the information content of-1 is sent to the sending end, the sending end is prompted to lose the ending bit, and the last packet of data is sent in a reissue mode.
Specifically, the data response packets of different types are adopted to prompt the data state of the transmitting end, the transmitting end is guided to retransmit, and the reliability of the Beidou short message transmission data is improved.
In some embodiments, the apparatus further includes an obtaining unit, a fourth determining unit, and a fourth processing unit, where the obtaining unit is configured to send a first data response packet to the sending end in the case that the data packet is lost, so that the sending end obtains the number of times of reissuing after reissuing the lost data; the fourth determining unit is configured to stop sending the first data response packet to the sending end, execute a next collection task, and report the sending end exception to the server when it is determined that the data packet is still lost if the number of reissue times is greater than or equal to a preset number of times; the fourth processing unit is configured to upload the reissued data and the data packet to the server when it is determined that reissuing of the data packet is successful if the reissuing number is less than or equal to the preset number.
In the scheme, in the data reissue process, if reissue is unsuccessful, repeatedly sending a data reissue request, obtaining reissue times, repeatedly presetting times in the process, if the reissue is unsuccessful, discarding the current transmission line information acquisition task, continuously executing the next task, reporting the abnormity of a sending end, and if the reissue is successful, storing and uploading complete data to a server, so that the reissue death cycle can be avoided.
Specifically, the preset number of times is 3 times, or 5 times, or other times.
The power consumption information transmission device comprises a processor and a memory, wherein the receiving unit, the first determining unit, the first processing unit and the like are all stored in the memory as program units, and the processor executes the program units stored in the memory to realize corresponding functions. The modules are all located in the same processor; or the above modules may be located in different processors in any combination.
The processor includes a kernel, and the kernel fetches the corresponding program unit from the memory. The kernel can be provided with one or more than one, and the problem of lower transmission efficiency of Beidou short messages in the prior art is solved by adjusting kernel parameters.
The memory may include volatile memory, random Access Memory (RAM), and/or nonvolatile memory, such as Read Only Memory (ROM) or flash memory (flash RAM), among other forms in computer readable media, the memory including at least one memory chip.
The embodiment of the invention provides a computer readable storage medium, which comprises a stored program, wherein the program is used for controlling a device where the computer readable storage medium is located to execute the transmission method of electricity information.
Specifically, the transmission method of the electricity information comprises the following steps:
step S201, receiving a data packet sent by a sending end, wherein the data packet is generated by the sending end according to the number of times of sending the ammeter data and updated ammeter data, and the data format of the data packet is Beidou short message;
step S202, determining whether the data packet is lost or not according to the related information of the data packet, wherein the related information is a sequence number and/or an end flag bit;
step S203, when the data packet is lost, a first data response packet is sent to the sending end, so that the sending end supplements the lost data, and when the data packet is not lost, the data packet is uploaded to a server.
The embodiment of the invention provides a processor, which is used for running a program, wherein the transmission method of electricity utilization information is executed when the program runs.
Specifically, the transmission method of the electricity information comprises the following steps:
step S201, receiving a data packet sent by a sending end, wherein the data packet is generated by the sending end according to the number of times of sending the ammeter data and updated ammeter data, and the data format of the data packet is Beidou short message;
step S202, determining whether the data packet is lost or not according to the related information of the data packet, wherein the related information is a sequence number and/or an end flag bit;
step S203, when the data packet is lost, a first data response packet is sent to the sending end, so that the sending end supplements the lost data, and when the data packet is not lost, the data packet is uploaded to a server.
The application also provides a transmission system, which comprises a sending end and a receiving end, wherein the sending end is in communication connection with the receiving end, and the receiving end is used for executing any one of the transmission methods of the electricity utilization information.
Specifically, the transmission method of the electricity information comprises the following steps:
step S201, receiving a data packet sent by a sending end, wherein the data packet is generated by the sending end according to the number of times of sending the ammeter data and updated ammeter data, and the data format of the data packet is Beidou short message;
step S202, determining whether the data packet is lost or not according to the related information of the data packet, wherein the related information is a sequence number and/or an end flag bit;
step S203, when the data packet is lost, a first data response packet is sent to the sending end, so that the sending end supplements the lost data, and when the data packet is not lost, the data packet is uploaded to a server.
The embodiment of the invention provides equipment, which comprises a processor, a memory and a program stored in the memory and capable of running on the processor, wherein the processor realizes at least the following steps when executing the program:
step S201, receiving a data packet sent by a sending end, wherein the data packet is generated by the sending end according to the number of times of sending the ammeter data and updated ammeter data, and the data format of the data packet is Beidou short message;
step S202, determining whether the data packet is lost or not according to the related information of the data packet, wherein the related information is a sequence number and/or an end flag bit;
step S203, when the data packet is lost, a first data response packet is sent to the sending end, so that the sending end supplements the lost data, and when the data packet is not lost, the data packet is uploaded to a server.
The device herein may be a server, PC, PAD, cell phone, etc.
The application also provides a computer program product adapted to perform, when executed on a data processing device, a program initialized with at least the following method steps:
step S201, receiving a data packet sent by a sending end, wherein the data packet is generated by the sending end according to the number of times of sending the ammeter data and updated ammeter data, and the data format of the data packet is Beidou short message;
step S202, determining whether the data packet is lost or not according to the related information of the data packet, wherein the related information is a sequence number and/or an end flag bit;
step S203, when the data packet is lost, a first data response packet is sent to the sending end, so that the sending end supplements the lost data, and when the data packet is not lost, the data packet is uploaded to a server.
It will be appreciated by those skilled in the art that the modules or steps of the invention described above may be implemented in a general purpose computing device, they may be concentrated on a single computing device, or distributed across a network of computing devices, they may be implemented in program code executable by computing devices, so that they may be stored in a storage device for execution by computing devices, and in some cases, the steps shown or described may be performed in a different order than that shown or described herein, or they may be separately fabricated into individual integrated circuit modules, or multiple modules or steps of them may be fabricated into a single integrated circuit module. Thus, the present invention is not limited to any specific combination of hardware and software.
It will be appreciated by those skilled in the art that embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present application is described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems) and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flowchart illustrations and/or block diagrams, and combinations of flows and/or blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
In one typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
The memory may include volatile memory in a computer-readable medium, random Access Memory (RAM) and/or nonvolatile memory, etc., such as Read Only Memory (ROM) or flash RAM. Memory is an example of a computer-readable medium.
Computer readable media, including both non-transitory and non-transitory, removable and non-removable media, may implement information storage by any method or technology. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of storage media for a computer include, but are not limited to, phase change memory (PRAM), static Random Access Memory (SRAM), dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), read Only Memory (ROM), electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), digital Versatile Discs (DVD) or other optical storage, magnetic cassettes, magnetic tape magnetic disk storage or other magnetic storage devices, or any other non-transmission medium, which can be used to store information that can be accessed by a computing device. Computer-readable media, as defined herein, does not include transitory computer-readable media (transmission media), such as modulated data signals and carrier waves.
It should also be noted that the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises an element.
From the above description, it can be seen that the above embodiments of the present application achieve the following technical effects:
1) According to the transmission method of the electricity information, the sending end collects the data and sends the data to the receiving end, the receiving end can judge the transmission state of the data, namely whether the data is lost, if the data is lost, the sending end supplements the data, so that the reliability of a transmission message can be improved, the integrity of the data is ensured, and the data transmission efficiency is improved.
2) The transmitting end collects the data and then transmits the data to the receiving end, the receiving end can judge the transmission state of the data, namely whether the data is lost or not, and if the data is lost, the transmitting end supplements the data, so that the reliability of a transmission message can be improved, the integrity of the data is ensured, and the data transmission efficiency is improved.
The above description is only of the preferred embodiments of the present application and is not intended to limit the present application, but various modifications and variations can be made to the present application by those skilled in the art. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application should be included in the protection scope of the present application.
Claims (10)
1. A transmission method of electricity information, comprising:
Receiving a data packet sent by a sending end, wherein the data packet is generated by the sending end according to the number of times of ammeter data sending and updated ammeter data, and the data format of the data packet is a Beidou short message;
determining whether the data packet is lost or not according to the related information of the data packet, wherein the related information is a sequence number and/or an end zone bit;
And under the condition that the data packet is lost, a first data response packet is sent to the sending end, so that the sending end reissues the lost data, and under the condition that the data packet is not lost, the data packet is uploaded to a server.
2. The method of claim 1, wherein receiving the data packet sent by the sender comprises:
Receiving a first data packet, wherein the first data packet is a data packet when the transmitting end transmits data for the first time;
And receiving a second data packet, wherein the second data packet is a data packet when the transmitting end transmits data for the nth time, the second data packet comprises incremental data, and the incremental data is the difference value between the data of the nth time and the data of the (N-1) th time, and N is more than or equal to 2.
3. The method of claim 1, wherein receiving the data packet sent by the sender comprises:
Receiving a plurality of data packets, wherein the data packets are sent by the sending end, the sending end sequentially collects the ammeter data of a plurality of user ends, writes the ammeter data into a first data packet to be sent under the condition that the sum of the lengths of the ammeter data is smaller than a preset length, pauses writing data into the first data packet to be sent until the sum of the lengths of the ammeter data in the first data packet to be sent is larger than or equal to the preset length, writes data into a second data packet to be sent until all ammeter data of all the user ends are collected, and writes an ending mark bit into the last data packet to be sent.
4. The method of claim 1, wherein the number of the data packets is plural, the data packets and the sequence numbers are in one-to-one correspondence, and determining whether the data packets are lost based on the related information of the data packets comprises:
And under the condition that all first preset conditions are met, determining that no data packet is lost, wherein the first preset conditions comprise: the sequence numbers are ordered according to a preset ordering mode, the first difference value between the Mth sequence number and the Mth-1 sequence number is equal to the second difference value between the Mth sequence number and the Mth+1th sequence number, and the ending zone bit is obtained;
And under the condition that any one of the first preset conditions is not met, determining that the data packet is lost.
5. The method of claim 1, wherein after determining whether the data packet is lost based on the information related to the data packet, the method further comprises:
determining whether a second preset condition is met, wherein the second preset condition comprises: the duration of the data packet which is not received is greater than or equal to the target duration, and the data packet cannot be normally analyzed;
And under the condition that the second preset condition is met, sending a second response data packet to the sending end so that the sending end resends the data.
6. The method of claim 1, wherein after determining whether the data packet is lost based on the information related to the data packet, the method further comprises:
Determining whether a third preset condition is met, wherein the third preset condition comprises: the duration of the data packet which is not received is greater than or equal to the target duration, and the ending zone bit is not acquired;
and under the condition that the third preset condition is met, sending a third response data packet to the sending end, so that the sending end reissues the last data packet.
7. The method according to any one of claims 1 to 6, wherein, in the case where the data packet is lost, sending a first data response packet to the transmitting end, so that the transmitting end reissues the lost data, the method further comprises:
Acquiring the number of reissue times;
When the reissue times are larger than or equal to the preset times, and the data packet is still lost, stopping sending the first data response packet to the sending end, executing the next collection task, and reporting the abnormity of the sending end to the server;
And uploading the reissued data and the data packet to the server under the condition that the reissued times are less than or equal to the preset times and the successful reissuing of the data packet is determined.
8. A transmission device for electricity consumption information, comprising:
the receiving unit is used for receiving a data packet sent by a sending end, wherein the data packet is generated by the sending end according to the number of times of ammeter data sending and updated ammeter data, and the data format of the data packet is a Beidou short message;
the first determining unit is used for determining whether the data packet is lost or not according to the related information of the data packet, wherein the related information is a sequence number and/or an end zone bit;
and the first processing unit is used for sending a first data response packet to the sending end under the condition that the data packet is lost, so that the sending end supplements the lost data, and uploading the data packet to a server under the condition that the data packet is not lost.
9. A computer-readable storage medium, characterized in that the computer-readable storage medium comprises a stored program, wherein the program, when run, controls a device in which the computer-readable storage medium is located to perform the transmission method of electricity information according to any one of claims 1 to 7.
10. A transmission system, comprising: a transmitting end and a receiving end, the transmitting end and the receiving end are in communication connection, and the receiving end is used for executing the transmission method of electricity information according to any one of claims 1 to 7.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202410133089.2A CN118118567A (en) | 2024-01-30 | 2024-01-30 | Power utilization information transmission method, device and transmission system |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202410133089.2A CN118118567A (en) | 2024-01-30 | 2024-01-30 | Power utilization information transmission method, device and transmission system |
Publications (1)
Publication Number | Publication Date |
---|---|
CN118118567A true CN118118567A (en) | 2024-05-31 |
Family
ID=91213347
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202410133089.2A Pending CN118118567A (en) | 2024-01-30 | 2024-01-30 | Power utilization information transmission method, device and transmission system |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN118118567A (en) |
-
2024
- 2024-01-30 CN CN202410133089.2A patent/CN118118567A/en active Pending
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US20130300577A1 (en) | Collecting utility data information and conducting reconfigurations, such as demand resets, in a utility metering system | |
KR101428778B1 (en) | Apparatus and method for upgrading firmware of automatic meter reading terminal on the remote | |
CN108647131B (en) | Output system of running log | |
CN107205059B (en) | Method for managing meter equipment address, acquisition terminal and meter equipment | |
CN101739801A (en) | Wireless automatic meter reading method and system | |
CN109451443B (en) | Data transmission method, device and system based on Lora wireless | |
CN111081003A (en) | Meter reading method, device and system | |
CN115601948A (en) | Wireless control method and system for lithium ion battery pack and vehicle | |
CN118118567A (en) | Power utilization information transmission method, device and transmission system | |
CN109743703A (en) | Communication method, data acquisition terminal and monitoring system | |
CN111313933A (en) | Meter reading method, device and system | |
JP4122646B2 (en) | Meter reading transmission method, meter reading transmission system and meter reading transmitter | |
KR20190078677A (en) | Remote meter reading system, remote meter reading device and remote meter reading method | |
US9843947B2 (en) | Visual signal strength indication for a wireless device | |
WO2023175308A1 (en) | Data transmission | |
CN118118075A (en) | Beidou director-based data acquisition system and control method thereof | |
CN110430548B (en) | Data reissue method, device, collector and storage medium | |
CN101783712B (en) | Method, user terminal and network node for identifying LTE (Long Term Evolution) version | |
KR102417801B1 (en) | Remote meter reading system and its firmware upgrade method | |
CN109951309B (en) | Electric energy cloud acquisition system network node maintenance method and device | |
CN116017505A (en) | RTK joint measurement system, method, device and medium based on Bluetooth MESH | |
CN117857655B (en) | Control method, device, terminal and medium of intelligent Internet of things terminal of cable channel | |
JP5370078B2 (en) | Wireless meter reading device | |
CN112235747A (en) | Wireless communication method and system for vehicle detector | |
CN110708379A (en) | Data acquisition method, concentrator, data acquisition system and readable storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination |