CN111711581A - Communication method, carrier wave proxy module and station area convergence terminal - Google Patents

Communication method, carrier wave proxy module and station area convergence terminal Download PDF

Info

Publication number
CN111711581A
CN111711581A CN202010542661.2A CN202010542661A CN111711581A CN 111711581 A CN111711581 A CN 111711581A CN 202010542661 A CN202010542661 A CN 202010542661A CN 111711581 A CN111711581 A CN 111711581A
Authority
CN
China
Prior art keywords
sent
data
carrier
communication device
queue
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
Application number
CN202010542661.2A
Other languages
Chinese (zh)
Inventor
郝志飞
徐重酉
李温静
刘柱
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
State Grid Information and Telecommunication Co Ltd
State Grid Zhejiang Electric Power Co Ltd
Original Assignee
State Grid Information and Telecommunication Co Ltd
State Grid Zhejiang Electric Power Co Ltd
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by State Grid Information and Telecommunication Co Ltd, State Grid Zhejiang Electric Power Co Ltd filed Critical State Grid Information and Telecommunication Co Ltd
Priority to CN202010542661.2A priority Critical patent/CN111711581A/en
Publication of CN111711581A publication Critical patent/CN111711581A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/10Flow control; Congestion control
    • H04L47/24Traffic characterised by specific attributes, e.g. priority or QoS
    • H04L47/2425Traffic characterised by specific attributes, e.g. priority or QoS for supporting services specification, e.g. SLA
    • H04L47/2433Allocation of priorities to traffic types
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L47/00Traffic control in data switching networks
    • H04L47/50Queue scheduling
    • H04L47/62Queue scheduling characterised by scheduling criteria
    • H04L47/625Queue scheduling characterised by scheduling criteria for service slots or service orders
    • H04L47/6275Queue scheduling characterised by scheduling criteria for service slots or service orders based on priority
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L49/00Packet switching elements
    • H04L49/90Buffering arrangements
    • H04L49/9063Intermediate storage in different physical parts of a node or terminal
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L69/00Network arrangements, protocols or services independent of the application payload and not provided for in the other groups of this subclass
    • H04L69/22Parsing or analysis of headers

Abstract

The invention provides a communication method, a carrier wave agent module and a station area fusion terminal, wherein the method comprises the following steps: receiving forwarding requests sent by a plurality of carrier service applications; storing data to be sent by each carrier service application into a queue to be sent; and sending the data to be sent in the queue to be sent to the carrier communication device one by one according to the high-low sequence of the forwarding priority. In the scheme, when forwarding requests sent by a plurality of carrier service applications are received, data to be sent by each carrier service application is stored in a queue to be sent. And sending the data to be sent in the queue to be sent to the carrier communication device one by one according to the high-low sequence of the forwarding priority, so that communication conflict between a plurality of carrier service applications and the carrier communication device is avoided, and the communication stability is improved.

Description

Communication method, carrier wave proxy module and station area convergence terminal
Technical Field
The invention relates to the technical field of communication, in particular to a communication method, a carrier wave agent module and a station area convergence terminal.
Background
In the station area convergence terminal, a carrier service Application (APP) communicates with a carrier communication device in a serial port and General Purpose Input/Output (GPIO) mode.
At present, the communication mode between the carrier service APP and the carrier communication apparatus is a one-master-one-slave communication mode, but when a plurality of carrier services APPs communicate with the carrier communication apparatus (a multi-master-one-slave communication mode), communication collision may be caused, and the stability of communication is poor.
Disclosure of Invention
In view of this, embodiments of the present invention provide a communication method, a carrier proxy module, and a station convergence terminal, so as to solve the problems of poor communication stability and the like in the current communication method.
In order to achieve the above purpose, the embodiments of the present invention provide the following technical solutions:
the first aspect of the embodiments of the present invention discloses a communication method, which includes:
receiving forwarding requests sent by a plurality of carrier service applications, wherein the forwarding requests at least comprise data to be sent and forwarding priorities;
storing data to be sent by each carrier service application into a queue to be sent;
and sending the data to be sent in the queue to be sent to the carrier communication device one by one according to the high-low sequence of the forwarding priority.
Preferably, the storing the data to be sent by each carrier service application into a queue to be sent includes:
analyzing the data to be sent aiming at the data to be sent by each carrier service application to obtain json data information corresponding to the data to be sent;
and storing json data information corresponding to data to be sent by each carrier service application into a queue to be sent.
Preferably, the process of sending the data to be sent in the queue to be sent to the carrier communication device includes:
for each data to be sent in the queue to be sent, packaging the data to be sent by using a preset communication protocol;
and sending the packed data to be sent to a carrier communication device according to a preset communication mode.
Preferably, after the sending the data to be sent in the queue to be sent to the carrier communication device one by one according to the high-low order of the forwarding priority, the method further includes:
for each data to be sent to the carrier communication device, receiving feedback data information corresponding to the data to be sent, which is fed back by the carrier communication device;
and aiming at each piece of feedback data information, sending the feedback data information to the carrier service application corresponding to the data to be sent corresponding to the feedback data information.
Preferably, before sending the data to be sent in the queue to be sent to the carrier communication device one by one according to the high-low order of the forwarding priority, the method further includes:
acquiring running state information of the carrier communication device, wherein the running state information is used for indicating that the running state of the carrier communication device is a normal state or an abnormal state;
and if the running state information indicates that the running state of the carrier communication device is a normal state, executing the step of sending the data to be sent in the queue to be sent to the carrier communication device one by one.
A second aspect of the present invention discloses a carrier wave proxy module, including:
the communication unit is used for receiving forwarding requests sent by a plurality of carrier service applications and storing data to be sent by each carrier service application into a queue to be sent, wherein the forwarding requests at least comprise data to be sent and forwarding priorities;
and the carrier interaction unit is used for sending the data to be sent in the queue to be sent to the carrier communication device one by one according to the high-low sequence of the forwarding priority.
Preferably, the communication unit is configured to store the data to be sent by each carrier service application in a queue to be sent, and specifically configured to: analyzing the data to be sent aiming at the data to be sent by each carrier service application to obtain json data information corresponding to the data to be sent, and storing the json data information corresponding to the data to be sent by each carrier service application into a queue to be sent.
Preferably, the carrier interaction unit is specifically configured to: and packaging the data to be sent by utilizing a preset communication protocol aiming at each data to be sent in the queue to be sent, and sending the packaged data to be sent to a carrier communication device according to a preset communication mode.
Preferably, the carrier interaction unit is further configured to: for each data to be sent to the carrier communication device, receiving feedback data information corresponding to the data to be sent, which is fed back by the carrier communication device;
correspondingly, the communication unit is further configured to: and aiming at each piece of feedback data information, sending the feedback data information to the carrier service application corresponding to the data to be sent corresponding to the feedback data information.
A third aspect of the embodiments of the present invention discloses a station area convergence terminal, where the station area convergence terminal includes: an application layer, a carrier proxy module, a driver layer and a hardware layer disclosed in the second aspect of the embodiment of the present invention;
the application layer is connected with the carrier wave proxy module, the carrier wave proxy module is connected with the drive layer, and the drive layer is connected with the hardware layer.
Based on the communication method, the carrier agent module and the station area convergence terminal provided by the embodiment of the invention, the method comprises the following steps: receiving forwarding requests sent by a plurality of carrier service applications; storing data to be sent by each carrier service application into a queue to be sent; and sending the data to be sent in the queue to be sent to the carrier communication device one by one according to the high-low sequence of the forwarding priority. In the scheme, when forwarding requests sent by a plurality of carrier service applications are received, data to be sent by each carrier service application is stored in a queue to be sent. And sending the data to be sent in the queue to be sent to the carrier communication device one by one according to the high-low sequence of the forwarding priority, so that communication conflict between a plurality of carrier service applications and the carrier communication device is avoided, and the communication stability is improved.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only embodiments of the present invention, and for those skilled in the art, other drawings can be obtained according to the provided drawings without creative efforts.
Fig. 1 is a block diagram of a station-area convergence terminal according to an embodiment of the present invention;
fig. 2 is a schematic diagram of an architecture of a station zone convergence terminal according to an embodiment of the present invention;
fig. 3 is a flowchart of a communication method according to an embodiment of the present invention;
fig. 4 is a schematic view of carrier communication between a station-area convergence terminal and other devices according to an embodiment of the present invention;
fig. 5 is another flowchart of a communication method according to an embodiment of the present invention;
fig. 6 is a block diagram of a carrier agent module according to an embodiment of the present invention.
Detailed Description
The technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are only a part of the embodiments of the present invention, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
In this application, 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 an … …" does not exclude the presence of other identical elements in a process, method, article, or apparatus that comprises the element.
As can be seen from the background art, in the station area convergence terminal, when a plurality of carrier services APP communicate with a carrier communication device, a communication collision may be caused, and the stability of communication is poor.
Therefore, the embodiment of the present invention provides a communication method, a carrier agent module, and a station area convergence terminal, which store data to be sent, sent by multiple carrier service applications, in a queue to be sent. And sending the data to be sent in the queue to be sent to the carrier communication devices one by one according to the high-low sequence of the forwarding priority, so as to avoid communication conflicts between a plurality of carrier service applications and the carrier communication devices and improve the communication stability.
The carrier communication device (also referred to as a carrier module) is a modem for power line carrier communication, and the carrier communication device in the station convergence terminal (also referred to as a station intelligent convergence terminal) performs information interaction with the carrier communication device of another device through a power line.
Referring to fig. 1, a block diagram of a station-area convergence terminal provided in an embodiment of the present invention is shown, where the station-area convergence terminal includes: the system comprises an application layer 100, a carrier proxy module 200, a driver layer 300 and a hardware layer 400, wherein the application layer 100 is connected with the carrier proxy module 200, the carrier proxy module 200 is connected with the driver layer 300, and the driver layer 300 is connected with the hardware layer 400.
It is understood that a communication interface is abstracted in the application layer 100, and the communication interface is composed of a carrier proxy module 200, and the carrier proxy module 200 performs data interaction with the application layer 100 through a Message Queue Telemetry Transport (MQTT) protocol.
The carrier agent module 200 calls the driver layer 300 and interacts data with the hardware layer 400 via 1376.2(Q/GDW 1376.2) protocol.
To better explain the specific content in the station convergence terminal of fig. 1, the architecture of the station convergence terminal shown in fig. 2 is illustrated, and it should be noted that fig. 2 is only used for illustration.
In fig. 2, the application layer 100 includes a plurality of carrier service applications (carrier services APP in fig. 2), which are carrier service APP1, carrier service APP2, and carrier service APP3, respectively.
The abstract communication interface is composed of a carrier agent module 200 (carrier agent APP200 in fig. 2), wherein the carrier agent module 200 performs data interaction with the application layer 100 through MQTT agent (MQTT Broker).
The driver layer 300 at least includes a serial port and a GPIO.
At least a carrier module (carrier communication means) is included in the hardware layer 400.
According to the content in fig. 2, the carrier agent module 200 faces each carrier service APP in the application layer 100 in the north direction, faces the driver layer 300 in the south direction, and may call an Application Programming Interface (API) of a serial port and a GPIO.
It should be noted that the above-mentioned "the carrier proxy module 200 faces the application layer 100 in the north direction" means: for example, the upper device of the carrier proxy module 200 is the application layer 100, and the above-mentioned "the carrier proxy module 200 southward faces the driver layer 300" refers to: the lower level device, such as the carrier proxy module 200, is the driver layer 300.
Referring to fig. 3, a flowchart of a communication method provided in the embodiment of the present invention is shown, where the communication method is applied to the carrier proxy module of the station-area convergence terminal in the above embodiment of the present invention shown in fig. 1, and the communication method includes the following steps:
step S301: and receiving forwarding requests sent by a plurality of carrier service applications.
It should be noted that the forwarding request includes at least, but not limited to: data to be transmitted, forwarding priority, data length, time stamp and target carrier communication device.
It can be understood from the foregoing that, the carrier communication device in the zone convergence terminal performs information interaction with the carrier communication devices of other devices through the power line, and for a carrier service application, the carrier service application sends data to be sent to the carrier communication devices of other devices (referred to as target carrier communication devices) through the carrier communication device of the zone convergence terminal where the carrier service application is located.
In the process of implementing step S301 specifically, when data concurrence occurs in multiple carrier service applications, forwarding requests sent by multiple carrier service applications are received at the same time.
It should be noted that the above-mentioned related to receiving a forwarding request sent by a plurality of carrier service applications at the same time refers to: and receiving forwarding requests sent by a plurality of carrier service applications within preset time.
Preferably, when receiving a forwarding request sent by the carrier service application, the failure state information of the carrier proxy module is obtained, if the carrier proxy module fails, an abnormal result is fed back to the carrier service application, and if the carrier proxy module fails, the subsequent process is continuously executed.
Step S302: and storing the data to be sent by each carrier service application into a queue to be sent.
It should be noted that a json format data item of data to be sent is preset, and data interaction is performed between the carrier service application and the carrier agent module in the json format, that is, the data to be sent by the carrier service application is data in the json format.
In the process of implementing step S302 specifically, for data to be sent by each carrier service application, the data to be sent is analyzed according to a preset json format data item of the data to be sent, so as to obtain json data information corresponding to the data to be sent.
And storing json data information corresponding to data to be sent by each carrier service application into a queue to be sent.
Step S303: and sending the data to be sent in the queue to be sent to the carrier communication device one by one according to the high-low sequence of the forwarding priority.
It should be noted that, as can be seen from the foregoing, a corresponding forwarding priority is set in advance for data to be sent by each carrier service application, that is, json data information corresponding to the data to be sent in a queue to be sent has a corresponding forwarding priority.
And extracting data to be sent from the queue to be sent one by one according to the sequence of the forwarding priority from high to low, and sending the extracted data to be sent to the carrier communication device.
Such as: assuming that data to be sent A, data to be sent B and data to be sent C exist in the queue to be sent, the data to be sent A, the data to be sent B and the data to be sent C are transmitted in the sequence of the forwarding priority from high to low. The method comprises the steps of firstly extracting A data to be sent from a queue to be sent, sending the A data to be sent to a carrier communication device, then extracting B data to be sent from the queue to be sent, sending the B data to be sent to the carrier communication device, finally extracting C data to be sent from the queue to be sent, and sending the C data to be sent to the carrier communication device.
It can be understood that, for data to be sent with the same forwarding priority, the data to be sent, which is stored in the queue to be sent first, is sent to the carrier communication device according to the rule of first-come first-send.
In the process of implementing step S303 specifically, for each data to be sent in the queue to be sent, the data to be sent is packaged by using a preset communication protocol, and the packaged data to be sent is sent to the carrier communication device according to a preset communication mode.
That is to say, for each piece of data to be sent to the carrier communication device in the queue to be sent, the data to be sent is packaged according to a preset communication protocol (for example, 1376.2 protocol), and then the packaged data to be sent is sent to the carrier communication device by using a preset communication mode (serial port and GPIO).
It can be understood that, after sending data to be sent to the carrier communication device, the carrier communication device sends the data to be sent to a target carrier communication device (a carrier communication device of another device) corresponding to the data to be sent.
When data to be transmitted is packaged by using the 1376.2 protocol, a destination address (address information of a target carrier communication device) is added to an address information field of a 1376.2 protocol frame format, that is, the packaged data to be transmitted carries the destination address. And after receiving the packed data to be sent, the carrier communication device sends the data to be sent to a corresponding target carrier communication device according to a destination address corresponding to the packed data to be sent.
To better explain the carrier communication device that transmits data to be transmitted to other devices through the carrier communication device in the station area convergence terminal, it is illustrated by fig. 4, and it should be noted that fig. 4 is only used for illustration.
In fig. 4, the carrier communication means in the zone convergence terminal is connected to the carrier communication means of the respective devices (device 1 to device N) through power lines. After receiving data to be sent, the carrier communication device in the region fusion terminal sends the data to be sent to a corresponding target carrier communication device according to the destination address of the data to be sent.
As can be seen from the above-mentioned steps, when a plurality of carrier service applications concurrently communicate with the carrier communication apparatuses (many-to-one communication method), the many-to-one communication method is changed to the one-to-one communication method through the above-mentioned steps S301 to S303, so that a communication collision between the plurality of carrier service applications and the carrier communication apparatuses is avoided.
Preferably, before executing step S303, operation state information of the carrier communication apparatus is acquired, where the operation state information is used to indicate that the operation state of the carrier communication apparatus is a normal state or an abnormal state.
Determining whether the operation state of the carrier communication device is a normal state or not according to the operation state information of the carrier communication device, if the operation state information indicates that the operation state of the carrier communication device is the normal state, executing step S303, and if the operation state information indicates that the operation state of the carrier communication device is a fault state, feeding back fault alarm information for indicating that the carrier communication device is in fault to the carrier service application.
Preferably, after the data to be sent in the queue to be sent is sent to the carrier communication device, the carrier communication device feeds back feedback data information corresponding to the data to be sent.
In a specific implementation, for each data to be sent to the carrier communication device, feedback data information corresponding to the data to be sent, which is fed back by the carrier communication device, is received.
For each piece of feedback data information, sending the feedback data information to the carrier service application corresponding to the data to be sent corresponding to the feedback data information, that is, after sending the data to be sent of one carrier service application to the carrier communication device, sending the feedback data information corresponding to the data to be sent, which is fed back by the carrier communication device, to the carrier service application.
It can be understood that after receiving the feedback data information sent by the carrier communication device, the feedback data information is parsed, and the parsed feedback data information is organized into a json message format according to a preset json format data item. And calling an mqtt release function, and sending the analyzed feedback data information in the json message format to the corresponding carrier service application.
For example: for meter reading application (meter reading APP), the meter reading APP acquires electric meter information in a carrier wave mode, the electric meter information (to-be-sent data) in a 645 protocol format is packaged, and then the electric meter information is packaged according to a preset json format data item. And sending the electric meter information in the json format to the carrier agent module in an mqtt mode.
And the carrier agent module analyzes the electric meter information in the 645 protocol format according to a preset json format data item, and stores the electric meter information into a queue to be sent. The carrier agent module extracts the electric meter information in 645 protocol format in the queue to be sent according to the content (sending data to be sent according to the forwarding priority) in the foregoing step S303, and packages the electric meter information in 645 protocol format into the electric meter information in 1376.2 protocol format. And the carrier agent module sends the electricity meter information in the 1376.2 protocol format to the carrier communication device, receives feedback data information corresponding to the electricity meter information and fed back by the carrier communication device, and feeds back the feedback data information to the APP for meter reading.
It should be noted that the process of feeding back the feedback data information to the meter reading APP is the reverse process of sending the electricity meter information to the carrier communication device in the above example, and is not described herein again.
In the embodiment of the invention, when forwarding requests sent by a plurality of carrier service applications are received, data to be sent by each carrier service application is stored in a queue to be sent. And sending the data to be sent in the queue to be sent to the carrier communication device one by one according to the high-low sequence of the forwarding priority, so that communication conflict between a plurality of carrier service applications and the carrier communication device is avoided, and the communication stability is improved.
According to the content of each step in fig. 3 in the embodiment of the present invention, the carrier agent module can implement serialization of data to be transmitted, thereby solving the problem that a plurality of carrier service applications cannot use a carrier communication device (a carrier communication device in a region convergence terminal) in parallel.
To better explain the contents of fig. 3 in the above embodiment of the present invention, it is illustrated by fig. 5, and it should be noted that fig. 5 is only used for illustration.
Referring to fig. 5, another flowchart of a communication method provided in an embodiment of the present invention is shown, where the communication method includes the following steps:
step S501: an operational status of the carrier communication device is determined.
It will be appreciated that the carrier proxy module communicates with the carrier communicator via the 1376.2 protocol, and that steps S501 include sub-steps S5011 through S5012.
Substep S5011: and starting the identification process of the carrier communication device and acquiring the running state information of the carrier communication device.
Substep S5012: and determining the operating state of the carrier communication device to be a normal state or an abnormal state according to the operating state information.
Step S502: and receiving a forwarding request sent by the carrier service application, and storing data to be sent included in the forwarding request into a queue to be sent.
It can be understood that the carrier agent module communicates with the carrier service application through the MQTT Broker, and the carrier agent module receives data to be sent in json format sent by the carrier service application through the MQTT Broker by subscribing to a theme related to carrier communication. Step S502 includes substeps S5021 to substep S5023.
Substep S5021: and when a forwarding request sent by the carrier service application is received, determining whether the running state of the carrier communication device is a normal state. If the operation state of the carrier communication device is a normal state, performing substep S5022, and if the operation state of the carrier communication device is an abnormal state, feeding back a response result including the failure alarm information to the carrier service application.
Substep S5022: and determining whether an idle space exists in the linked list, if so, executing a substep S5023, and if not, feeding back a response result including abnormal information for indicating insufficient space to the carrier service application.
It can be understood that the queue to be sent exists in a linked list data structure, that is, the linked list in the sub-step S5022 is the queue to be sent.
Substep S5023: and storing the data to be sent corresponding to the forwarding request into a linked list.
As can be seen from the foregoing, after sending data to be sent to the carrier communication device, feedback data information fed back by the carrier communication device needs to be sent to the carrier service application, the carrier agent module processes the feedback data information according to the 1376.2 protocol and the preset json format data item, and invokes an API function of mqtt to issue the processed feedback data information to the mqtt breaker.
Preferably, step S502 further includes a substep S5024.
Substep S5024: and sending feedback data information corresponding to the data to be sent to the carrier service application.
In specific implementation, the carrier service application receives feedback data information pushed by the mqtt breaker by subscribing to a related theme of the carrier agent module.
Step S503: and sending the data to be sent in the queue to be sent to the carrier communication device one by one according to the high-low sequence of the forwarding priority.
It can be understood that, the carrier wave proxy module calls the serial port and the API of the GPIO through the 1376.2 protocol to send the data to be sent in the queue to be sent to the carrier wave communication device one by one. Step S503 includes substeps S5031 to S5033.
Substep S5031: determining whether the linked list is idle, and if not, executing a sub-step S5032.
It can be understood that if the linked list (queue to be sent) is idle, it indicates that there is no data to be sent in the linked list, and if the linked list is not idle, it indicates that there is data to be sent in the linked list.
Substep S5032: and starting a point copy process, and sending the data to be sent in the linked list to the carrier communication device one by one.
It should be noted that the specific flow of the transcript flow can be referred to as the specific content in the 1376.2 protocol.
Substep S5033: and deleting the chain table nodes which are copied by points.
It can be understood that the queue to be sent is a linked list data structure, and when data to be sent is sent one by using a point copy process, after each piece of data to be sent is sent, linked list nodes corresponding to the data to be sent need to be deleted, so that the data to be sent is prevented from being sent repeatedly.
It should be noted that, in fig. 5, the feedback data information is transmitted in a message queue between step S502 and step S503.
In the embodiment of the invention, the carrier wave agent module communicates with the carrier wave service application through the MQTT Broker, and when a forwarding request of the carrier wave service application is received, the data to be sent corresponding to the forwarding request is stored in the linked list. And according to the high-low sequence of the forwarding priority, sending the data to be sent in the linked list to the carrier communication device one by one, and deleting the linked list nodes corresponding to the sent data to be sent, so that the communication conflict between a plurality of carrier service applications and the carrier communication device is avoided, and the communication stability is improved.
Corresponding to the communication method provided by the above embodiment of the present invention, referring to fig. 6, an embodiment of the present invention further provides a structural block diagram of a carrier wave proxy module, where the carrier wave proxy module includes: a communication unit 601 and a carrier interaction unit 602.
A communication unit 601, configured to receive forwarding requests sent by multiple carrier service applications, and store data to be sent by each carrier service application in a queue to be sent, where the forwarding requests at least include data to be sent and a forwarding priority.
Preferably, the communication unit 601 is further configured to: when receiving the forwarding request, if the carrier interaction unit 602 fails, sending abnormal failure information for indicating that the carrier interaction unit 602 fails to operate to the carrier service application.
In a specific implementation, the communication unit 601, configured to store data to be sent by each carrier service application in a queue to be sent, is specifically configured to: analyzing the data to be sent aiming at the data to be sent by each carrier service application to obtain json data information corresponding to the data to be sent, and storing the json data information corresponding to the data to be sent by each carrier service application into a queue to be sent.
A carrier interaction unit 602, configured to send data to be sent in the queue to be sent to the carrier communication device one by one according to the high-low order of the forwarding priority.
In a specific implementation, the carrier interaction unit 602 is specifically configured to: and packaging the data to be sent by utilizing a preset communication protocol aiming at each data to be sent in the queue to be sent, and sending the packaged data to be sent to the carrier communication device according to a preset communication mode.
Preferably, the carrier interaction unit 602 is further configured to: and receiving feedback data information which is fed back by the carrier communication device and corresponds to the data to be sent aiming at each data to be sent which is sent to the carrier communication device.
Correspondingly, the communication unit 601 is further configured to: and aiming at each piece of feedback data information, sending the feedback data information to the carrier service application corresponding to the corresponding data to be sent.
Preferably, the communication unit 601 is further configured to: acquiring the running state information of the carrier communication device, and if the running state information indicates that the running state of the carrier communication device is a normal state, executing a carrier interaction unit 602, where the running state information is used to indicate that the running state of the carrier communication device is a normal state or an abnormal state.
In summary, the embodiment of the present invention provides a communication method, a carrier agent module and a station area convergence terminal, where the method includes: receiving forwarding requests sent by a plurality of carrier service applications; storing data to be sent by each carrier service application into a queue to be sent; and sending the data to be sent in the queue to be sent to the carrier communication device one by one according to the high-low sequence of the forwarding priority. In the scheme, when forwarding requests sent by a plurality of carrier service applications are received, data to be sent by each carrier service application is stored in a queue to be sent. And sending the data to be sent in the queue to be sent to the carrier communication device one by one according to the high-low sequence of the forwarding priority, so that communication conflict between a plurality of carrier service applications and the carrier communication device is avoided, and the communication stability is improved.
The embodiments in the present specification are described in a progressive manner, and the same and similar parts among the embodiments are referred to each other, and each embodiment focuses on the differences from the other embodiments. In particular, the system or system embodiments are substantially similar to the method embodiments and therefore are described in a relatively simple manner, and reference may be made to some of the descriptions of the method embodiments for related points. The above-described system and system embodiments are only illustrative, wherein the units described as separate parts may or may not be physically separate, and the parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment. One of ordinary skill in the art can understand and implement it without inventive effort.
Those of skill would further appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware, computer software, or combinations of both, and that the various illustrative components and steps have been described above generally in terms of their functionality in order to clearly illustrate this interchangeability of hardware and software. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present invention.
The previous description of the disclosed embodiments is provided to enable any person skilled in the art to make or use the present invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the generic principles defined herein may be applied to other embodiments without departing from the spirit or scope of the invention. Thus, the present invention is not intended to be limited to the embodiments shown herein but is to be accorded the widest scope consistent with the principles and novel features disclosed herein.

Claims (10)

1. A method of communication, the method comprising:
receiving forwarding requests sent by a plurality of carrier service applications, wherein the forwarding requests at least comprise data to be sent and forwarding priorities;
storing data to be sent by each carrier service application into a queue to be sent;
and sending the data to be sent in the queue to be sent to the carrier communication device one by one according to the high-low sequence of the forwarding priority.
2. The method of claim 1, wherein storing data to be sent by each carrier service application in a queue to be sent comprises:
analyzing the data to be sent aiming at the data to be sent by each carrier service application to obtain json data information corresponding to the data to be sent;
and storing json data information corresponding to data to be sent by each carrier service application into a queue to be sent.
3. The method of claim 1, wherein transmitting data to be transmitted in the queue to be transmitted to a carrier communication device comprises:
for each data to be sent in the queue to be sent, packaging the data to be sent by using a preset communication protocol;
and sending the packed data to be sent to a carrier communication device according to a preset communication mode.
4. The method according to claim 1, wherein after the data to be sent in the queue to be sent is sent to the carrier communication device one by one according to the high-low order of the forwarding priority, the method further comprises:
for each data to be sent to the carrier communication device, receiving feedback data information corresponding to the data to be sent, which is fed back by the carrier communication device;
and aiming at each piece of feedback data information, sending the feedback data information to the carrier service application corresponding to the data to be sent corresponding to the feedback data information.
5. The method according to claim 1, wherein before transmitting data to be transmitted in the queue to be transmitted to the carrier communication device one by one according to the high-low order of the forwarding priority, the method further comprises:
acquiring running state information of the carrier communication device, wherein the running state information is used for indicating that the running state of the carrier communication device is a normal state or an abnormal state;
and if the running state information indicates that the running state of the carrier communication device is a normal state, executing the step of sending the data to be sent in the queue to be sent to the carrier communication device one by one.
6. A carrier proxy module, the carrier proxy module comprising:
the communication unit is used for receiving forwarding requests sent by a plurality of carrier service applications and storing data to be sent by each carrier service application into a queue to be sent, wherein the forwarding requests at least comprise data to be sent and forwarding priorities;
and the carrier interaction unit is used for sending the data to be sent in the queue to be sent to the carrier communication device one by one according to the high-low sequence of the forwarding priority.
7. The carrier agent module according to claim 6, configured to store data to be sent by each carrier service application in the communication unit in a queue to be sent, and to specifically: analyzing the data to be sent aiming at the data to be sent by each carrier service application to obtain json data information corresponding to the data to be sent, and storing the json data information corresponding to the data to be sent by each carrier service application into a queue to be sent.
8. The carrier proxy module according to claim 6, wherein the carrier interaction unit is specifically configured to: and packaging the data to be sent by utilizing a preset communication protocol aiming at each data to be sent in the queue to be sent, and sending the packaged data to be sent to a carrier communication device according to a preset communication mode.
9. The carrier proxy module of claim 6, wherein the carrier interaction unit is further configured to: for each data to be sent to the carrier communication device, receiving feedback data information corresponding to the data to be sent, which is fed back by the carrier communication device;
correspondingly, the communication unit is further configured to: and aiming at each piece of feedback data information, sending the feedback data information to the carrier service application corresponding to the data to be sent corresponding to the feedback data information.
10. A zone convergence terminal, comprising: an application layer, a carrier proxy module as claimed in any one of claims 6 to 9, a driver layer and a hardware layer;
the application layer is connected with the carrier wave proxy module, the carrier wave proxy module is connected with the drive layer, and the drive layer is connected with the hardware layer.
CN202010542661.2A 2020-06-15 2020-06-15 Communication method, carrier wave proxy module and station area convergence terminal Pending CN111711581A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010542661.2A CN111711581A (en) 2020-06-15 2020-06-15 Communication method, carrier wave proxy module and station area convergence terminal

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010542661.2A CN111711581A (en) 2020-06-15 2020-06-15 Communication method, carrier wave proxy module and station area convergence terminal

Publications (1)

Publication Number Publication Date
CN111711581A true CN111711581A (en) 2020-09-25

Family

ID=72540200

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010542661.2A Pending CN111711581A (en) 2020-06-15 2020-06-15 Communication method, carrier wave proxy module and station area convergence terminal

Country Status (1)

Country Link
CN (1) CN111711581A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114760373A (en) * 2022-06-13 2022-07-15 北京智芯微电子科技有限公司 Data transmission method and device, computer readable storage medium and convergence terminal

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114760373A (en) * 2022-06-13 2022-07-15 北京智芯微电子科技有限公司 Data transmission method and device, computer readable storage medium and convergence terminal

Similar Documents

Publication Publication Date Title
CN101272302B (en) System and method for pushing information from a host system to a mobile data communication device
EP1730929B1 (en) Method and apparatus for communicating data between computer devices
US20090030917A1 (en) Multimedia messaging service-based database synchronization
CN109451032B (en) Message transmission system
US11889255B2 (en) Communication method between earphones and charging box, charging box, earphones and readable storage medium
CN101567861B (en) Data synchronization method and application system between heterogeneous application systems
CN110413425B (en) Third-party message callback method, device, server and storage medium
CN1863336A (en) Reliable short messaging service
US20070094414A1 (en) Mail-based web application and document delivery
US7366505B2 (en) Apparatus and method for delivering messages to a mobile information terminal
WO2001067263A1 (en) Messaging system for computers
CN106385382B (en) Data synchronization method, device and system
CN111435947A (en) Electronic message control
CN111711581A (en) Communication method, carrier wave proxy module and station area convergence terminal
US11245567B2 (en) Electronic message adaptation
Narita et al. Reliable cloud-based robot services
CN114816785A (en) Service data processing method and device, electronic equipment and storage medium
CN113722126A (en) Request processing method and device
JP5577140B2 (en) Information processing system and information processing method
CN110691002B (en) Interrupt detection method and device
EP1182892B1 (en) A short message method and system
CN113542324A (en) Message pushing method and device
CN113204436A (en) Message processing method, device, equipment and computer readable storage medium
CN114584525B (en) Message processing method, system, terminal equipment and storage medium
CN115190124B (en) Message transmission method and device based on distributed industrial control system, storage medium and scheduling server

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