CN112769598B - Network communication system and communication implementation method thereof - Google Patents

Network communication system and communication implementation method thereof Download PDF

Info

Publication number
CN112769598B
CN112769598B CN202011568604.8A CN202011568604A CN112769598B CN 112769598 B CN112769598 B CN 112769598B CN 202011568604 A CN202011568604 A CN 202011568604A CN 112769598 B CN112769598 B CN 112769598B
Authority
CN
China
Prior art keywords
data
sending
terminal equipment
port
real
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.)
Active
Application number
CN202011568604.8A
Other languages
Chinese (zh)
Other versions
CN112769598A (en
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.)
Huazhong University of Science and Technology
Wuhan Huazhong Numerical Control Co Ltd
Original Assignee
Huazhong University of Science and Technology
Wuhan Huazhong Numerical Control 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 Huazhong University of Science and Technology, Wuhan Huazhong Numerical Control Co Ltd filed Critical Huazhong University of Science and Technology
Priority to CN202011568604.8A priority Critical patent/CN112769598B/en
Publication of CN112769598A publication Critical patent/CN112769598A/en
Application granted granted Critical
Publication of CN112769598B publication Critical patent/CN112769598B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L41/00Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
    • H04L41/14Network analysis or design
    • H04L41/145Network analysis or design involving simulating, designing, planning or modelling of a network
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L43/00Arrangements for monitoring or testing data switching networks
    • H04L43/10Active monitoring, e.g. heartbeat, ping or trace-route

Abstract

The invention provides a network communication system and a communication realization method thereof, belonging to the technical field of industrial automation, wherein the network communication system comprises an NC-Link information model, a message transmission module, an IP and a TSN; the NC-Link information model is used for acquiring sending data transmitted by the sending terminal equipment; the message transmission module is used for establishing port connection, a data channel and a consumption queue corresponding to the channel between the sending terminal equipment and the receiving terminal equipment and transmitting the sending data to each consumption queue; wherein, the number of the consumption queues is more than or equal to 1; the data channel comprises a real-time data channel and a non-real-time data channel; the message format of the transmission message comprises a terminal source port, a destination port, a data state, a timestamp, a data packet sequence number, a data packet confirmation number, a starting connection, a terminating connection, a response, a control and data. The invention is compatible with the multi-source heterogeneous numerical control system and the real-time accuracy of the transmission data.

Description

Network communication system and communication implementation method thereof
Technical Field
The invention belongs to the technical field of industrial automation, and particularly relates to a network communication system and a communication implementation method thereof.
Background
As the degree of production process digitization continues to increase, industrial communications are required to be increasingly open, robust, deterministic, and flexible. Only a production line with extremely agile communication and response can ensure fast and reliable production of personalized products while meeting strict delivery schedules.
Time Sensitive Network (TSN) series standards define a uniform technical standard aiming at key services such as real-time priority, clock and the like. Because in the traditional industrial production environment, there is an urgent need for real-time communication for a large number of industrial applications (e.g., machine control, process control, etc.) to ensure an efficient and safe production process.
At present, real-time ethernet is successively introduced and put into application of respective products, and compared with a field bus, the real-time ethernet has a higher data transmission rate, which reaches hundreds of megabytes and gigabytes at present, and even some of the real-time ethernet can provide tens of megabytes of bandwidth. With standard IEEE802.3 networks, different physical media and topologies may be used. However, the real-time ethernet technology can only temporarily provide technical support for two layers of network interconnection and data intercommunication, and the technologies can only interconnect and intercommunicate respective products, and cannot be used among different products, thereby greatly limiting the development of the whole internet of things intercommunication.
The MTConnect protocol is used for interworking of machine tool equipment, but real-time transmission of industrial ethernet has not been achieved. The OPC UA over TSN implements two schemes of Client-Server and OPC UA Pub-Sub, the connection based on TCP is a 1:1 communication relationship, and in the communication process, a device may overload because of managing multiple sessions, and a Server with circuit technical responsibility and high cost is required. Although OPC UA Pub-Sub can implement 1: n, UDP is a connectionless transport protocol, and therefore the implementation of this communication cannot guarantee the quality of service explicitly.
NC-Link is the standard of the numerical control machine tool interconnection communication protocol. The NC-Link information model has flexibility and expandability, and the NC-Link can be compatible with the existing data interaction protocols of mainstream industrial interconnection, including OPC UA, MTConnect and the like.
As shown in FIG. 1, the architecture of the NC-Link includes a numerical control equipment layer, an NC-Link layer and an application system layer. In the architecture of the NC-Link, "adapter → agent → application system" three-level data intercommunication architecture can realize the compatibility of the multi-source heterogeneous numerical control system, but a set of real-time solution is not realized for a while. According to the characteristics of data transmission required, real-time data can be ensured to arrive in real time, and the accuracy of non-real-time data can be ensured. Wherein, TCP is transmission control protocol; UDP is a user datagram protocol; IP is an internetworking protocol.
Disclosure of Invention
Aiming at the defects of the prior art, the invention aims to provide a network communication system and a communication implementation method thereof, aiming at solving the problem that the existing NC-Link system structure cannot be compatible with a multi-source heterogeneous numerical control system and the real-time accuracy of data transmission at the same time.
In order to achieve the above object, an aspect of the present invention provides a transmission message model, which includes a transmission message and a temporary space;
the transmission message is used for establishing port connection between the sending terminal equipment and the receiving terminal equipment and recording transmission information of the sending data;
the temporary space is opened up when the sending terminal equipment initiates port connection; the real-time data area and the non-real-time data area are respectively used for providing a real-time data channel and a non-real-time data channel added with a consumption queue; the consumption queue is used for adding a port of the receiving terminal equipment;
wherein, the number of the consumption queues is more than or equal to 1; the message format of the transmission message comprises a terminal source port, a destination port, a data state, a timestamp, a data packet sequence number, a data packet confirmation number, a starting connection, a terminating connection, a response, a control and data.
Preferably, the receiving terminal equipment is a numerical control machine tool or a robot or a transport vehicle or a cleaning equipment or a detection equipment; the sending terminal equipment is MES, PDM, SCM, numerically controlled machine, robot, transporting vehicle, cleaning equipment or detecting equipment.
The invention provides a network communication system on the other hand, which comprises an NC-Link information model, a message transmission module, an IP and a TSN, wherein the NC-Link information model, the message transmission module, the IP and the TSN are used for sequentially carrying out data interaction;
the NC-Link (numerical Control links) information model is used for acquiring sending data transmitted by the sending terminal equipment;
the message transmission module is used for establishing port connection, a data channel and a consumption queue corresponding to the channel between the sending terminal equipment and the receiving terminal equipment and transmitting the sending data to each consumption queue; wherein, the number of the consumption queues is more than or equal to 1; the data channel comprises a real-time data channel and a non-real-time data channel;
the IP is used for encapsulating the data encapsulated by each consumption queue again; the TSN is used to transfer the IP-encapsulated data to the router for forwarding.
Preferably, the message transmission module includes a transmission message and a temporary space;
the transmission message is used for establishing port connection between the sending terminal equipment and the receiving terminal equipment and recording transmission information of the sending data;
the temporary space is opened up when the sending terminal equipment initiates port connection; the temporary space is divided into a real-time data area and a non-real-time data area, and the real-time data area and the non-real-time data area are respectively used for providing a real-time data channel and a non-real-time data channel added with a consumption queue; the consumption queue is used for adding a port of the receiving terminal equipment;
wherein, the number of the consumption queues is more than or equal to 1; the message format of the transmission message comprises a terminal source port, a destination port, a data state, a timestamp, a data packet sequence number, a data packet confirmation number, a starting connection, a terminating connection, a response, a control and data.
Preferably, the receiving terminal equipment is a numerical control machine tool or a robot or a transport vehicle or a cleaning equipment or a detection equipment; the sending terminal equipment is MES, PDM, SCM, numerically controlled machine, robot, transporting vehicle, cleaning equipment or detecting equipment.
Based on the network communication system provided by the invention, the invention provides a corresponding communication implementation method, which comprises the following steps:
filling the sending data into the data position of the first transmission message, and recording a timestamp;
when the sending data is real-time data, setting the data state of the first transmission message as 1; establishing interface contact between the sending terminal equipment and the receiving terminal equipment corresponding to each consumption queue in sequence; sequentially transmitting the sending data to the receiving terminal equipment through the data channel; releasing temporary space occupied by real-time data;
when the sending data is non-real-time data, setting the data state of the first transmission message to be 0; establishing interface contact between the sending terminal equipment and the receiving terminal equipment corresponding to each consumption queue in sequence; after copying the sending data, sending the sending data to the receiving terminal equipment through a data channel; returning a second transmission message, and releasing the temporary space occupied by the non-real-time data when the confirmation numbers of the first transmission message and the second transmission message are equal;
the consumption queue is positioned in the data channel and used for adding a port for receiving the terminal equipment; the data channels include real-time data channels and non-real-time data channels.
Preferably, the method for establishing the interface relationship between the sending terminal device and the receiving terminal device includes the following steps:
when a sending terminal device initiates port connection, a sending port is generated, a sending port is arranged at a terminal source port for transmitting a message for the first time, a destination port is provided with a fixed port for receiving the terminal device, the starting connection is set to be 1, and a control bit is set to be 1;
after the first transmission message is identified, initiating a port connection request to a fixed port of the receiving terminal equipment through the IP address of the receiving terminal equipment;
after the receiving terminal equipment acquires the request data, a receiving port is randomly generated, the receiving port is filled in a terminal source port for transmitting the message for the second time, the starting connection is set to be 1, the response bit is set to be 1, and the control bit is set to be 0;
if the sending terminal device receives the second transmission message with the response bit of 1, the sending port and the receiving port are successfully connected.
Preferably, the method of establishing a consumption queue comprises the steps of:
when the sending terminal equipment initiates port connection, a temporary space is opened up;
setting a data channel in a real-time data area or a non-real-time data area of a temporary space according to the type of data to be sent of a sending terminal device;
the receive port is added to the consumption queue of the data lane.
Preferably, the method for disconnecting the sending terminal device from the receiving terminal device includes:
the sending terminal equipment initiates a disconnection request, sets the termination connection of the first transmission message as 1 and controls to set as 1 and then transmits the message to the receiving terminal equipment;
after receiving the disconnection request, the receiving terminal device sets the termination connection of the second transmission message to 1, controls to be 0 and sets the response to be 1;
after the second transmission message is sent, the receiving terminal device automatically destroys the port;
or setting a heartbeat packet to be sent between the sending terminal equipment and the receiving terminal equipment at regular intervals; if the heartbeat packet is not received within the set time, the connection is automatically terminated;
or the receiving terminal equipment initiates a disconnection request, the termination connection of the first transmission message is set to be 1, and the control is set to be 0;
after the sending terminal equipment receives the disconnection request, setting the termination connection of the second transmission message as 1, controlling to be 1 and responding to be 1;
and after the second transmission message is sent, the receiving terminal equipment automatically destroys the port.
Preferably, the receiving terminal equipment is a numerical control machine tool or a robot or a transport vehicle or a cleaning equipment or a detection equipment; the sending terminal equipment is MES, PDM, SCM, numerically controlled machine, robot, transporting vehicle, cleaning equipment or detecting equipment.
Through the technical scheme, compared with the prior art, the invention has the following beneficial effects:
the invention redefines the message format of the transmission layer, provides a temporary space opened by the sending terminal equipment when initiating port connection, the temporary space is divided into two areas which are a real-time data area and a non-real-time data area respectively, divides the received data into real-time data and non-real-time data, opens corresponding data channels in the corresponding areas respectively, sets the port of the receiving terminal equipment needing to obtain the corresponding data in the data channels respectively in order to realize the compatibility of the multi-source heterogeneous numerical control system, realizes the data channel 1: n is connected. Meanwhile, in order to meet the real-time requirement of data transmission, when the data sent by the sending terminal equipment is real-time data, the timestamp is recorded, and the transmission of the real-time data to different receiving terminal equipment can be realized only by changing the destination end of the first transmission message facing different receiving terminal equipment; releasing temporary space occupied by real-time data after completing transmission of all receiving terminal equipment; and when the transmission data is non-real-time data, setting a confirmation instruction, and releasing the temporary space occupied by the non-real-time data when the confirmation numbers of the first transmission message and the second transmission message are equal. Real-time data and non-real-time data are transmitted in different processes, so that real-time accuracy of the transmitted data is guaranteed.
Drawings
FIG. 1 is a block diagram of a conventional NC-Link architecture provided by the present invention;
fig. 2 is a schematic structural diagram of a network communication system provided by the present invention;
FIG. 3 is a communication flow between terminal devices provided by the present invention;
FIG. 4 is a diagram illustrating a format of a transmission packet according to the present invention;
fig. 5 is a schematic diagram of establishing a connection between terminals through a temporary space according to an embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
The core of the invention is that the message format of a transmission layer is defined in a message transmission module, and the transmission data is divided into real-time data and non-real-time data according to the real-time requirement of the transmission data; in order to guarantee the multi-connection state, an active connection communication mode is adopted, and a data sending party and a data receiving party open up a temporary space for communication through an internal memory; the temporary space supports a multi-connection state; the connection between the terminal devices has a special channel, and a confirmation response mechanism is realized in the transmission of non-real-time data, so that the reliability of data transmission is guaranteed. The significance of the message sampling and transmitting module is to ensure that real-time data accurately arrives within an acceptable time and non-real-time data accurately arrives.
As shown in fig. 1, the terminal device includes an application system or a numerical control equipment connected to an adapter.
The application system layer is an information application party and a monitoring instruction issuing party, and may be one or more application systems, such as MES (manufacturing enterprise production process execution management system) or PDM (product data management), SCM (software configuration management), and the like. The numerical control equipment layer is an information provider and a controlled party and can be one or more numerical control equipment, such as a numerical control machine tool, a mechanical processing robot, an automatic handling vehicle, a cleaning device, a detection device, an automatic production line, an automatic material warehouse and the like.
In the invention, the real-time data is data which meets the requirement of millisecond level or has real-time requirement on the real-time performance of the data, such as interactive information among the control equipment and equipment state data displayed by an application system in real time. The non-real-time data is data which needs to be transmitted in addition to the real-time data.
The terminal equipment and the terminal equipment communicate by means of channels, and the connection state of the data channels supports 1: and n, managing by means of a message transmission module.
The invention provides a message transmission module, which comprises a transmission message and a temporary space;
the transmission message is used for establishing port connection between the sending terminal equipment and the receiving terminal equipment and recording transmission information of the sending data;
opening up a temporary space when the sending terminal equipment initiates port connection; the real-time data area and the non-real-time data area are respectively used for providing a real-time data channel and a non-real-time data channel added with a consumption queue; the consumption queue is used for adding a port of the receiving terminal equipment;
wherein, the number of the consumption queues is more than or equal to 1; the message format of the transmission message comprises a terminal source port, a destination port, a data state, a timestamp, a data packet sequence number, a data packet confirmation number, a starting connection, a terminating connection, a response, a control and data.
As shown in fig. 2, a network communication system includes an NC-Link information model (corresponding to an application layer), a transmission packet module (corresponding to a transmission layer), an IP (corresponding to a network layer), and a TSN (corresponding to a Link layer) that perform data interaction in sequence;
the NC-Link information model is used for acquiring sending data transmitted by the sending terminal equipment;
the message transmission module is used for establishing port connection, a data channel and a consumption queue corresponding to the channel between the sending terminal equipment and the receiving terminal equipment and transmitting the sending data to each consumption queue; wherein, the number of the consumption queues is more than or equal to 1; the data channel comprises a real-time data channel and a non-real-time data channel;
the IP is used for encapsulating the data encapsulated by each consumption queue again; the TSN is used to transmit the information data after IP encapsulation to the router for forwarding.
Preferably, the message transmission module includes a transmission message and a temporary space;
the transmission message is used for establishing port connection between the sending terminal equipment and the receiving terminal equipment and recording transmission information of the sending data;
the temporary space is opened up when the sending terminal equipment initiates port connection; the temporary space is divided into a real-time data area and a non-real-time data area, and the real-time data area and the non-real-time data area are respectively used for providing a real-time data channel and a non-real-time data channel added with a consumption queue; the consumption queue is used for adding a port of the receiving terminal equipment;
wherein, the number of the consumption queues is more than or equal to 1; as shown in fig. 4, the message format of the transmission message includes a source port of the terminal, a destination port, a data state, a timestamp, a packet sequence number, a packet acknowledgement number, a start connection, a stop connection, a response, a control, and data.
In practical application, the network communication system performs communication as shown in fig. 3, and the present invention specifically provides a corresponding communication implementation method, including the following steps:
after the sending terminal equipment acquires the sending data, filling the sending data into the data position of the first transmission message, and recording a timestamp;
when the transmitted data is real-time data, setting the data state of the first transmission message as 1; the sending terminal equipment establishes interface contact with the receiving terminal equipment corresponding to each consumption queue in sequence; sequentially transmitting the sending data to the receiving terminal equipment through the data channel; releasing temporary space occupied by real-time data;
when the sending data is non-real-time data, setting the data state of the first transmission message to be 0; the sending terminal equipment establishes interface contact with the receiving terminal equipment corresponding to each consumption queue in sequence; after copying the sending data, sending the sending data to the receiving terminal equipment through a data channel; returning a second transmission message, and releasing the temporary space occupied by the non-real-time data when the confirmation numbers of the first transmission message and the second transmission message are equal;
the consumption queue is positioned in the data channel and used for adding a port for receiving the terminal equipment; the data channels include real-time data channels and non-real-time data channels.
Preferably, the method for establishing the interface relationship between the sending terminal device and the receiving terminal device includes the following steps:
when a sending terminal device initiates port connection, a sending port is generated; a sending port is arranged at a terminal source port for transmitting the message for the first time, a fixed port for receiving terminal equipment is arranged at a destination port, the starting connection is set to be 1, and a control bit is set to be 1;
after the first transmission message is identified, initiating a port connection request to a fixed port of the receiving terminal equipment through the IP address of the receiving terminal equipment;
after the receiving terminal equipment acquires the request data, a receiving port is randomly generated, the receiving port is filled in a terminal source port for transmitting the message for the second time, the starting connection is set to be 1, the response bit is set to be 1, and the control bit is set to be 0;
if the sending terminal device receives the second transmission message with the response bit of 1, the sending port and the receiving port are successfully connected.
Preferably, the method of establishing a consumption queue comprises the steps of:
when the sending terminal equipment initiates port connection, a temporary space is opened up;
setting a data channel in a real-time data area or a non-real-time data area of a temporary space according to the type of data to be sent of a sending terminal device;
the receive port is added to the consumption queue of the data lane.
It should be noted that the data transmission in the present invention is an active transmission, so that during the connection, it must be negotiated to confirm which party is the controlling party (i.e. the party that actively transmits data) and which party is the controlled party (i.e. the party that receives data). In the transmission message, if the control bit is 1 during connection, the current terminal equipment is indicated as a control party; and if the control bit is 0 during connection, the current terminal equipment is indicated as the controlled party.
The difference between the controller and the controlled party is that the controller will open up a temporary space at its own terminal when it first transmits data, as a buffer for the connection dependency and data transmission of other terminal devices.
In the invention, the temporary space is divided into two large areas for respectively storing real-time data and non-real-time data. For the area storing the real-time data, the output adopts a first-in first-out mode, and the occupied space is released after the data is successfully consumed; and the area of non-real-time data can release the occupied space after the data packet confirmation number is consistent with the data packet confirmation number to be sent.
Preferably, there are a plurality of disconnection means in the present invention when disconnection process or termination control is required. Firstly, after the sending terminal device finishes sending the sending data, the termination connection of the first transmission message is set to be 1, and the control is set to be 1; after receiving the request of terminating the connection, the receiving terminal device returns the terminating connection setting of the second transmission message to 1, the control setting is 0, and the response setting is 1. And after the second transmission of the message is finished, the receiving terminal equipment automatically destroys the port. Secondly, the sending terminal equipment and the receiving terminal equipment can send heartbeat packets at regular intervals, and if the heartbeat packets are not received within the set time, the connection is automatically terminated. If the receiving terminal equipment initiates a disconnection request, the termination connection of the first transmission message is set to 1, the control is set to 0, after the sending terminal equipment receives the request, the termination connection of the second transmission message is set to 1, the control is set to 1, and the response is set to 1, then the resources occupied by the corresponding receiving terminal equipment in the temporary space are automatically destroyed. The three modes can destroy the port of the sending terminal device.
It should be pointed out that, in the invention, because the non-real-time data has low real-time requirement, a set of confirmation response mechanism suitable for the non-real-time data is realized, and the reliability and the correctness of the data are ensured. The real-time data in the invention generally does not start a confirmation response mechanism, and the data packet sequence number and the data packet confirmation number of the transmission message are filled as default-1 of the selectable item.
Examples
Fig. 5 is a schematic diagram of a communication implementation method between different terminals, which is specifically as follows:
(1) the process of establishing port contact between terminal device a and terminal device B, terminal device C and terminal device D is described below by taking the establishment of port contact between terminal device a and terminal device B as an example:
(1.1) according to the requirement of an application program, when a terminal device A firstly initiates connection, generating a port A and opening up a temporary space;
(1.2) a terminal source port of a first-time message transmission terminal at the terminal device A side is filled into a port A, and a destination port of the first-time message transmission terminal is a fixed port 8888 number of a terminal device B; the starting connection is set to 1, and the control bit is set to 1;
(1.3) initiating a connection request to a fixed port 8888 of the terminal device B according to the IP address of the corresponding terminal device B;
(1.4) the terminal device B receives the data of the first transmission message, randomly generates an available port B, fills the port B into a terminal source port of the second transmission message, fills a port A into a destination port of the second transmission message, sets the starting connection to be 1, sets the response bit to be 1 and sets the control bit to be 0;
(1.5) after receiving the data of the second transmission message, the terminal device A checks the message state, and if the response bit is 1, the device connection is successfully established;
the method for establishing connection between the terminal equipment C and the terminal equipment D and the terminal equipment A is the same as the method for establishing connection between the terminal equipment B and the terminal equipment A.
(2) Establishing a data channel from the terminal device A to the terminal device B, the terminal device C and the terminal device D by using the temporary space opened up by the terminal device A, which comprises the following specific steps:
suppose that terminal device a transmits Sample real-time data to terminal device B, specifically as follows: opening a channel in a real-time data buffer area of a temporary space according to the types of data to be transmitted by a program, such as Sample real-time data, and storing the data belonging to the Sample; simultaneously adding the available port B into a consumption queue of the Sample channel; at this time, the terminal device a and the terminal device B establish a data connection relationship, and the terminal device a and the terminal device B can send messages;
if the data connection between the terminal device A and the terminal device B is unsuccessful, the data connection is retried for a plurality of times automatically, and if the data connection is not attempted for a plurality of times, error information is printed out on the terminal device A.
Similarly, when the terminal device a establishes data connection with the terminal device C, when the terminal device a transmits Sample real-time data and Register non-real-time data to the terminal device C, a connection request is initiated to the fixed port 8888 of the terminal device C; the terminal device C randomly generates a portC, because the Sample real-time data already has a channel in the real-time data area of the temporary space, the number of the portC is directly added into a consumption queue of the Sample channel, and the terminal device A and the terminal device C establish data connection; because the Register belongs to non-real-time data, a Register channel is opened up in a non-real-time data area of a temporary space, a portC number is added into a consumption queue of the Register channel, and the terminal device A and the terminal device C establish data connection;
similarly, the data connection between the terminal device a and the terminal device D is also the same, and if the terminal device a sends the query and Register data to the terminal device D, after the terminal device a establishes the device contact with the terminal device D, the corresponding data mapping relationship is established in the temporary space of the terminal device a.
(3) A data transmission stage between the terminal device A and the terminal device B, and between the terminal device C and the terminal device D;
after the NC-Link information model of the terminal device A acquires data, different data transmission methods are adopted according to the inconsistency of the types of the data, and the method specifically comprises the following steps:
if the sent data belongs to real-time data, recording a timestamp in the first transmission message, setting the state to be 1, filling a portA in a terminal source port, and filling the sent data into the data position of the first transmission message. As shown in fig. 5, traversing the consumption queue of the channel to be sent, and filling the port b, the port c, and the port d into the destination port of the first-time transmission packet in sequence; in practical application, data transmission from the terminal device a to a plurality of terminal devices can be realized only by modifying the destination port of the first transmission packet sent by the terminal device a, so that the data copying times can be reduced, and the data transmission efficiency can be improved. And when all the consumption queues are traversed, releasing the space occupied by the current data.
And if the transmitted data belongs to the non-real-time data, traversing each consumption queue of the non-real-time data area, and if the non-real-time data is needed in the consumption queue, copying the non-real-time data and adding the non-real-time data into a corresponding data channel. And for the transmission of non-real-time data, filling the recorded timestamp into a first transmission message, setting the state of the first transmission message to be 0, filling a port A into a terminal source port, filling the transmitted data into the data position of the first transmission message, and filling a data receiving port into a target terminal port of the first transmission message. And when the information confirmation number of the second transmission message is equal to the confirmation number in the first transmission message, releasing the space occupied by the current data.
And after the data in each consumption queue is encapsulated, transmitting the data to an IP layer for encapsulation, transmitting the data to a TSN after the IP layer is encapsulated, and performing routing forwarding by the TSN.
Compared with the prior art, the invention has the following advantages:
the invention redefines the message format of a transmission layer, provides a temporary space opened by a sending terminal device when initiating port connection, the temporary space is divided into two large areas which are a real-time data area and a non-real-time data area respectively, the received data is divided into real-time data and non-real-time data, corresponding data channels are opened in the corresponding areas respectively, in order to realize the compatibility of a multi-source heterogeneous numerical control system, the ports of the receiving terminal device needing to obtain the corresponding data are respectively arranged in the data channels, and a data channel 1 is realized: n is connected. Meanwhile, in order to meet the real-time requirement of data transmission, when the data sent by the sending terminal equipment is real-time data, the timestamp is recorded, and the transmission of the real-time data to different receiving terminal equipment can be realized only by changing the destination end of the first transmission message facing different receiving terminal equipment; releasing temporary space occupied by real-time data after completing transmission of all receiving terminal equipment; and when the transmission data is non-real-time data, setting a confirmation instruction, and releasing the temporary space occupied by the non-real-time data when the confirmation numbers of the first transmission message and the second transmission message are equal. Real-time data and non-real-time data are transmitted in different processes, so that real-time accuracy of the transmitted data is guaranteed.
It will be understood by those skilled in the art that the foregoing is only a preferred embodiment of the present invention, and is not intended to limit the invention, and that any modification, equivalent replacement, or improvement made within the spirit and principle of the present invention should be included in the scope of the present invention.

Claims (8)

1. A network communication system is characterized by comprising an NC-Link information model, a message transmission module, an IP layer and a TSN, wherein the NC-Link information model, the message transmission module, the IP layer and the TSN are used for carrying out data interaction in sequence;
the NC-Link information model is used for acquiring sending data transmitted by sending terminal equipment;
the message transmission module is used for establishing port connection, a data channel and a consumption queue corresponding to the channel between the sending terminal equipment and the receiving terminal equipment and transmitting the sending data to each consumption queue; wherein, the number of the consumption queues is more than or equal to 1; the data channel comprises a real-time data channel and a non-real-time data channel;
the IP layer is used for encapsulating the data encapsulated by each consumption queue again; the TSN is used for transmitting the data encapsulated by the IP layer to the router for forwarding;
the message format of the message transmitted in the message transmission module comprises a terminal source port, a destination port, a data state, a timestamp, a data packet sequence number and a data packet confirmation number, and connection starting, connection stopping, response, control and data are started;
the NC-Link information model corresponds to an application layer; the transmission message module corresponds to a transmission layer; the IP layer corresponds to a network layer; the TSN corresponds to a link layer.
2. The network communication system of claim 1, wherein the transport message module comprises a transport message and a temporary space;
the transmission message is used for establishing port connection between the sending terminal equipment and the receiving terminal equipment and recording transmission information of the sending data;
the temporary space is opened up when the sending terminal equipment initiates port connection; the temporary space is divided into a real-time data area and a non-real-time data area, and the real-time data area and the non-real-time data area are respectively used for providing a real-time data channel and a non-real-time data channel added with a consumption queue; the consumption queue is used for adding a port of the receiving terminal equipment;
and the number of the consumption queues is more than or equal to 1.
3. Network communication system according to claim 1 or 2, wherein the receiving terminal device is a numerical control machine or a robot or a transport vehicle or a cleaning device or a detection device; the sending terminal equipment is MES, PDM, SCM, numerically-controlled machine tool, robot, carrier, cleaning equipment or detection equipment.
4. A communication implementation method of the network communication system according to claim 1, comprising the following steps:
filling the sending data into the data position of the first transmission message, and recording a timestamp;
when the sending data is real-time data, setting the data state of the first transmission message as 1; establishing interface contact between the sending terminal equipment and the receiving terminal equipment corresponding to each consumption queue in sequence; sequentially transmitting the sending data to the receiving terminal equipment through the data channel; releasing temporary space occupied by real-time data;
when the sending data is non-real-time data, setting the data state of the first transmission message to be 0; establishing interface contact between the sending terminal equipment and the receiving terminal equipment corresponding to each consumption queue in sequence; after copying the sending data, sending the sending data to the receiving terminal equipment through a data channel; returning a second transmission message, and releasing the temporary space occupied by the non-real-time data when the confirmation numbers of the first transmission message and the second transmission message are equal;
the consumption queue is positioned in the data channel and used for adding a port for receiving the terminal equipment; the data channels include real-time data channels and non-real-time data channels.
5. The method of claim 4, wherein the method of establishing the interface between the sending terminal device and the receiving terminal device comprises the following steps:
when the sending terminal equipment initiates port connection, a sending port is generated, a sending port is arranged at a terminal source port for transmitting a message for the first time, a destination port of the sending port is provided with a fixed port of receiving terminal equipment, the starting connection of the sending port is set to be 1, and a control bit of the sending port is set to be 1;
after the first transmission message is identified, initiating a port connection request to a fixed port of the receiving terminal equipment through the IP address of the receiving terminal equipment;
after the receiving terminal equipment acquires the request data, a receiving port is randomly generated, the receiving port is filled in a terminal source port for transmitting the message for the second time, the starting connection is set to be 1, the response bit is set to be 1, and the control bit is set to be 0;
if the sending terminal device receives the second transmission message with the response bit of 1, the sending port and the receiving port are successfully connected.
6. The communication implementation method of claim 5, wherein the method for establishing the consumption queue comprises the following steps:
when the sending terminal equipment initiates port connection, a temporary space is opened up;
setting a data channel in a real-time data area or a non-real-time data area of a temporary space according to the type of data to be sent of a sending terminal device;
the receive port is added to the consumption queue of the data lane.
7. The communication implementation method according to any one of claims 4 to 6, wherein the method for disconnecting the sending terminal device from the receiving terminal device is:
the sending terminal equipment initiates a disconnection request, sets the termination connection of the first transmission message as 1 and controls to set as 1 and then transmits the message to the receiving terminal equipment;
after receiving the disconnection request, the receiving terminal device sets the termination connection of the second transmission message to 1, controls to be 0 and sets the response to be 1;
after the second transmission message is sent, the receiving terminal device automatically destroys the port;
or setting a heartbeat packet to be sent between the sending terminal equipment and the receiving terminal equipment at regular intervals; if the heartbeat packet is not received within the set time, the connection is automatically terminated;
or the receiving terminal equipment initiates a disconnection request, the termination connection of the first transmission message is set to be 1, and the control is set to be 0;
after the sending terminal equipment receives the disconnection request, setting the termination connection of the second transmission message as 1, controlling to be 1 and responding to be 1;
and after the second transmission message is sent, the receiving terminal equipment automatically destroys the port.
8. The communication implementation method of any one of claims 4 to 6, wherein the receiving terminal device is a numerical control machine or a robot or a transport vehicle or a cleaning device or a detection device; the sending terminal equipment is MES, PDM, SCM, numerically-controlled machine tool, robot, carrier, cleaning equipment or detection equipment.
CN202011568604.8A 2020-12-25 2020-12-25 Network communication system and communication implementation method thereof Active CN112769598B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011568604.8A CN112769598B (en) 2020-12-25 2020-12-25 Network communication system and communication implementation method thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011568604.8A CN112769598B (en) 2020-12-25 2020-12-25 Network communication system and communication implementation method thereof

Publications (2)

Publication Number Publication Date
CN112769598A CN112769598A (en) 2021-05-07
CN112769598B true CN112769598B (en) 2022-06-07

Family

ID=75695728

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011568604.8A Active CN112769598B (en) 2020-12-25 2020-12-25 Network communication system and communication implementation method thereof

Country Status (1)

Country Link
CN (1) CN112769598B (en)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113037685B (en) * 2019-12-24 2022-08-30 中国移动通信集团四川有限公司 Data transmission method and electronic equipment
CN113259244B (en) * 2021-05-27 2021-10-08 中国人民解放军国防科技大学 Traffic mapping method for time-sensitive network
CN113746574B (en) * 2021-07-30 2023-01-24 苏州浪潮智能科技有限公司 Information interaction method, system and equipment
CN113766015B (en) * 2021-08-23 2024-04-05 武汉华中数控股份有限公司 Communication system and method based on NC-Link protocol
CN113965608A (en) * 2021-08-31 2022-01-21 艾普工华科技(武汉)有限公司 Data collection and instruction issuing system of numerical control equipment

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20030043382A (en) * 2001-11-28 2003-06-02 학교법인 선문학원 Embedded web server system for monitoring/control of industrial controller
CN102014057A (en) * 2010-11-25 2011-04-13 重庆邮电大学 EPA protocol-based industrial Ethernet communication method supporting real-time and non-real-time application
CN102158435A (en) * 2011-04-13 2011-08-17 北京航空航天大学 Virtual connection supporting real-time embedded gateway based on controller area network (CAN) bus and Ethernet
CN104135359A (en) * 2014-07-22 2014-11-05 南京磐能电力科技股份有限公司 Hard real-time cascading multi-node synchronous sampling and data transmission method
CN108667870A (en) * 2017-03-30 2018-10-16 华为技术有限公司 A kind of methods, devices and systems that IoT data report
CN111726809A (en) * 2020-06-17 2020-09-29 华中科技大学 Network security auditing method and system under numerical control environment

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20030043382A (en) * 2001-11-28 2003-06-02 학교법인 선문학원 Embedded web server system for monitoring/control of industrial controller
CN102014057A (en) * 2010-11-25 2011-04-13 重庆邮电大学 EPA protocol-based industrial Ethernet communication method supporting real-time and non-real-time application
CN102158435A (en) * 2011-04-13 2011-08-17 北京航空航天大学 Virtual connection supporting real-time embedded gateway based on controller area network (CAN) bus and Ethernet
CN104135359A (en) * 2014-07-22 2014-11-05 南京磐能电力科技股份有限公司 Hard real-time cascading multi-node synchronous sampling and data transmission method
CN108667870A (en) * 2017-03-30 2018-10-16 华为技术有限公司 A kind of methods, devices and systems that IoT data report
CN111726809A (en) * 2020-06-17 2020-09-29 华中科技大学 Network security auditing method and system under numerical control environment

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
Yongkweon Jeon ; Jaeyoon Yoo ; Jongsun Lee ; Sungroh Yoon.NC-Link: A New Linkage Method for Efficient Hierarchical Clustering of Large-Scale Data.《IEEE Access》.2017, *
江哲夫,刘涛.基于NC-Link协议的数控系统适配器设计.《现代机械》.2017, *

Also Published As

Publication number Publication date
CN112769598A (en) 2021-05-07

Similar Documents

Publication Publication Date Title
CN112769598B (en) Network communication system and communication implementation method thereof
US6765889B1 (en) Communication method and system
CN111083161A (en) Data transmission processing method and device and Internet of things equipment
US7900115B2 (en) Replacement messages for identifying and preventing errors during the transmission of realtime-critical data
CN109995675B (en) Self-adaptive industrial Ethernet gateway system and method based on software definition
US7852857B2 (en) Coupler for a ring topology network and an ethernet-based network
CN102821050A (en) Processing method for applying rapid spanning tree protocol to monocyclic network topology
WO2004040819A2 (en) An apparatus and method for receive transport protocol termination
CN114301995B (en) Conversion switching and intercommunication fusion system and method of real-time industrial Ethernet protocol
CN114338274B (en) Heterogeneous industrial field bus fusion method and system
CN108809949A (en) The method converted and dispatched between profinet, FF H1, CAN and profibus agreements
KR102438173B1 (en) Semiconductor equipment communication protocol layer structure based on iot, gateway and transmission method
CN115150207B (en) Industrial network equipment identification method and device, terminal equipment and storage medium
WO2020024183A1 (en) Interconnection device, communication method and system comprising robot
CN108462537A (en) A kind of implementation method of one master and multiple slaves communication
US20220137604A1 (en) Coordination Device and Method for Providing Control Applications via a Communication Network for Transmitting Time-Critical Data
CN115174370B (en) Distributed mixed data deterministic transmission device and method
US20230078505A1 (en) Synchronization for backplane communication
CN116346944A (en) UDP-based communication method and system
CN116055420A (en) Information transmission method and control device after integrating office network and industrial network
CN117459521A (en) Flow control transmission method and device for communication data, host equipment and storage medium
CN116527780A (en) UDP-based communication method, device and system
Sousa et al. Repeater-Based Hybrid Wired/Wireless PROFIBUS Network Simulator
CN116668560A (en) Semi-physical simulation communication method supporting dynamic creation
CN116880281A (en) Fusion control system based on deterministic network

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
GR01 Patent grant
GR01 Patent grant