CN116455833A - EtherCAT network and link expansion method and device thereof - Google Patents

EtherCAT network and link expansion method and device thereof Download PDF

Info

Publication number
CN116455833A
CN116455833A CN202310724910.3A CN202310724910A CN116455833A CN 116455833 A CN116455833 A CN 116455833A CN 202310724910 A CN202310724910 A CN 202310724910A CN 116455833 A CN116455833 A CN 116455833A
Authority
CN
China
Prior art keywords
slave
port
frame data
ethercat network
data
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.)
Granted
Application number
CN202310724910.3A
Other languages
Chinese (zh)
Other versions
CN116455833B (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.)
Hangzhou Hexin Semiconductor Co ltd
Original Assignee
Hangzhou Hexin Semiconductor 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 Hangzhou Hexin Semiconductor Co ltd filed Critical Hangzhou Hexin Semiconductor Co ltd
Priority to CN202310724910.3A priority Critical patent/CN116455833B/en
Publication of CN116455833A publication Critical patent/CN116455833A/en
Application granted granted Critical
Publication of CN116455833B publication Critical patent/CN116455833B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • 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/6295Queue scheduling characterised by scheduling criteria using multiple queues, one for each individual QoS, connection, flow or priority
    • YGENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
    • Y02TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
    • Y02PCLIMATE CHANGE MITIGATION TECHNOLOGIES IN THE PRODUCTION OR PROCESSING OF GOODS
    • Y02P90/00Enabling technologies with a potential contribution to greenhouse gas [GHG] emissions mitigation
    • Y02P90/02Total factory control, e.g. smart factories, flexible manufacturing systems [FMS] or integrated manufacturing systems [IMS]

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Small-Scale Networks (AREA)

Abstract

The invention discloses an EtherCAT network and a link expansion method and device thereof, belonging to the field of communication and being used for expanding a data transmission link of the EtherCAT network. According to the port analysis module in the method, the corresponding target slave port can be determined according to the target MAC address in the downlink frame data, the data sending module can send the current downlink frame data through the target slave port, the uplink frame control module can send the uplink frame data received from each slave port sequentially through the master port and return the uplink frame data to the master station device according to the first-in first-out rule, and the data in the EtherCAT network can be divided into a plurality of parallel links to be transmitted through the link expansion device, so that the communication efficiency can be improved.

Description

EtherCAT network and link expansion method and device thereof
Technical Field
The invention relates to the field of communication, in particular to a link expansion device of an EtherCAT network, and also relates to the EtherCAT network and a link expansion method thereof.
Background
EtherCAT (Ethernet for Control Automation Technology, ethernet control Automation technology) is a real-time industrial Ethernet protocol widely applied to automation and industrial control systems, and in the traditional EtherCAT network, transmission of data frames is serial link communication, so as to increase the total transmission time of data packets with the increase of the number of nodes in the EtherCAT network, thereby reducing the communication efficiency.
Therefore, how to provide a solution to the above technical problem is a problem that a person skilled in the art needs to solve at present.
Disclosure of Invention
The invention aims to provide a link expansion device of an EtherCAT network, which can divide data in the EtherCAT network into a plurality of parallel links for transmission, so that the communication efficiency can be improved; another object of the present invention is to provide an EtherCAT network and a link extension method thereof, in which data in the EtherCAT network can be divided into a plurality of parallel links for transmission by a link extension device, so that communication efficiency can be improved.
In order to solve the technical problems, the invention provides a link expansion device of an EtherCAT network, which comprises:
the port analysis module is used for determining a slave port corresponding to the downlink frame data and taking the slave port as a target slave port according to a target Media Access Control (MAC) address in the downlink frame data of the Ethernet control automation technology (EtherCAT) network received through the master port;
the data sending module is used for sending the current downlink frame data through the target slave port so that the downlink frame data is transmitted in a link of the slave station equipment corresponding to the target slave port;
the uplink frame control module is used for sequentially sending uplink frame data received from each slave port through the master port according to a first-in first-out rule so as to send the uplink frame data back to master station equipment of the EtherCAT network;
the master port and a plurality of slave ports.
Preferably, the data transmission module includes:
the enabling control module is used for enabling the target slave ports in all the slave ports so that the target slave ports send out the current downlink frame data;
and the data delay module is used for sending the current downlink frame data to each slave port while the target slave port is enabled, so that the current downlink frame data is sent out through the target slave port and is transmitted in a link of the slave station equipment corresponding to the target slave port.
Preferably, the port resolution module is specifically configured to:
determining a slave port corresponding to downlink frame data according to the front N-bit data in a target MAC address in the downlink frame data of the EtherCAT network currently received through a master port, and taking the slave port as a target slave port;
and N is a preset positive integer, and the number of the slave ports is not more than the total number of the arrangement combinations of the first N bits of data.
Preferably, the enabling control module includes:
and the slave port forwarding enabling registers are in one-to-one correspondence with the slave ports, are used for adjusting own register values under the control of the port analysis module, and sending the register values to the enabling ends of the corresponding slave ports so as to enable the target slave ports in all the slave ports and send out the current downlink frame data through the target slave ports.
Preferably, the data delay module is specifically configured to:
after buffering of the target MAC address in the current downstream frame data is completed, the current downstream frame data is sent to each of the slave ports, so that the downstream frame data is sent to each of the slave ports while the target slave port is enabled.
Preferably, the uplink frame control module is specifically configured to:
and when the main port is currently transmitting the uplink frame data, buffering the uplink frame data received from the slave port to a frame queue, and transmitting the uplink frame data in the frame queue through the main port according to a first-in first-out rule so as to transmit the uplink frame data back to a master station device of the EtherCAT network.
Preferably, the link expansion device is located downstream of a first slave station device of the EtherCAT network;
the master station device of the EtherCAT network is configured to send the downlink frame data, receive the uplink frame data, and control all slave station devices in a distributed clock synchronization mode in the EtherCAT network to perform distributed clock synchronization according to topology information of links corresponding to the slave ports, so that clocks of all slave station devices in the distributed clock synchronization mode in the EtherCAT network are synchronized with a local clock of a first slave station device in the EtherCAT network.
Preferably, the master station device is further configured to:
calculating the transmission time length from the sending of the frame data to be sent by the master station device to the receiving of the uplink by the slave port corresponding to the frame data to be sent;
and sending out the frame data to be sent after delaying for a preset time length so as to avoid that each slave port receives uplink frame data from an uplink at the same time.
In order to solve the technical problem, the invention also provides a link expansion method of the EtherCAT network, which comprises the following steps:
determining a slave port corresponding to downlink frame data according to a target MAC address in the downlink frame data of the EtherCAT network currently received through a master port and taking the slave port as a target slave port;
transmitting the current downlink frame data through the target slave port so that the downlink frame data is transmitted in a link of the slave station equipment corresponding to the target slave port;
and sending the uplink frame data received from each slave port through the master port in turn according to a first-in first-out rule so as to send the uplink frame data back to the master station equipment of the EtherCAT network.
In order to solve the technical problem, the invention also provides an EtherCAT network, which comprises the link expansion device of the EtherCAT network.
The invention provides a link expansion device of an EtherCAT network, which considers that the target MAC address in each frame of data transmitted in the EtherCAT network has available idle data bits, and can represent the corresponding slave port of the downlink frame data through the target MAC address in the downlink frame data, so as to distribute the downlink frame data to different links for transmission.
The invention also provides an EtherCAT network and a link expansion method thereof, which have the same beneficial effects as the link expansion device of the EtherCAT network.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required in the prior art and the embodiments will be briefly described below, and it is apparent that the drawings in the following description are only some embodiments of the present invention, and other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
Fig. 1 is a schematic structural diagram of a link expansion device of an EtherCAT network according to the present invention;
fig. 2 is a schematic structural diagram of an EtherCAT network in the prior art;
fig. 3 is a schematic structural diagram of another link expansion device of EtherCAT network according to the present invention;
fig. 4 is a schematic structural diagram of an EtherCAT network provided by the present invention;
fig. 5 is a flow chart of a link expansion method of an EtherCAT network provided by the present invention.
Detailed Description
The invention provides a link expansion device of an EtherCAT network, which can divide data in the EtherCAT network into a plurality of parallel links for transmission, so that the communication efficiency can be improved; the invention also provides an EtherCAT network and a link expansion method thereof, and the data in the EtherCAT network can be divided into a plurality of parallel links for transmission by the link expansion device, so that the communication efficiency can be improved.
For the purpose of making the objects, technical solutions and advantages of the embodiments of the present invention more apparent, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings in the embodiments of the present invention, and it is apparent that the described embodiments are some embodiments of the present invention, but not all embodiments of the present invention. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
Referring to fig. 1, fig. 1 is a schematic structural diagram of a link expansion device of an EtherCAT network according to the present invention, where the link expansion device of the EtherCAT network includes:
the port analysis module 2 is configured to determine, according to a target media access control address MAC address in downstream frame data of the ethernet control automation technology EtherCAT network currently received through the master port 1, a slave port 5 corresponding to the downstream frame data and use the slave port as a target slave port;
a data sending module 3, configured to send current downlink frame data through a target slave port, so that the downlink frame data is transmitted in a link of a slave station device corresponding to the target slave port;
the uplink frame control module 4 is configured to send uplink frame data received from each slave port 5 sequentially through the master port 1 according to a first-in first-out rule, so as to send the uplink frame data back to the master station device of the EtherCAT network;
a master port 1 and a plurality of slave ports 5.
For a better explanation of the embodiments of the present invention, please refer to fig. 2, fig. 2 is a schematic diagram of an EtherCAT network in the prior art, and it can be seen from fig. 2 that EtherCAT (ethernet control automation technology) is an open architecture, ethernet-based fieldbus system. EtherCAT uses a full duplex Ethernet physical layer, and each slave station has at least 2 physical communication ports, namely physical communication port A, physical communication port B and the like. The data received by the physical communication port A must pass through a frame processing unit, and then the processed frame is sent out from the physical port B; the data received by the physical port B is automatically forwarded and sent out from the physical port a. In serial communication, the delay of the slave node is generally about 1 microsecond, and the total time of the data packet is equal to the transmission time (packet byte number x 80 nanoseconds) +the station delay (station number x 1 microsecond) +the receiving time (packet byte number x 80 nanoseconds). As the number of nodes in the network increases, the total time for transmitting and receiving the data packet increases, which may reduce the communication efficiency.
Specifically, in view of the technical problems in the background art, the target MAC (Media Access Control Address ) address in each frame of data transmitted in the EtherCAT network is considered to be available, so that the slave port 5 corresponding to the downstream frame of data can be indicated by the target MAC address in the downstream frame of data, and the downstream frame of data is distributed to different links for transmission, so that the embodiment of the invention can set the target MAC address for the downstream frame of data transmitted in the EtherCAT network, and identify the target MAC address by the port analysis module 2, the port analysis module 2 can determine the slave port 5 corresponding to the downstream frame of data and take the slave port 5 as a target slave port according to the target MAC address in the downstream frame of data of the EtherCAT network currently received through the master port 1, for example, the data in the target MAC address of the downstream frame of data currently received points to a certain slave port 5, and the slave port 5 pointed by the slave port can be taken as the target slave port, and the slave port 5 can be taken as a serial slave port of the master port 1, and a serial port 1 can be connected with a slave port of the ethernet device of the ethernet control automation technology EtherCAT network, and a serial network can be connected with a slave port 1, and a parallel network interface can be connected to a slave network interface of a serial device of the ethernet 1.
After the target slave port is analyzed, in order to smoothly realize the multiplex transmission of the downlink frame data, the data transmitting module 3 in the embodiment of the present invention can send the current downlink frame data through the target slave port, so that the downlink frame data is transmitted in the link of the slave station device corresponding to the target slave port, and therefore, each downlink frame data can be distributed to the links corresponding to different slave ports 5 for transmission, and the communication efficiency is effectively improved.
Specifically, considering that after one data transmission link of the EtherCAT network is extended into parallel multiple paths, since the EtherCAT network itself still has an uplink, the link extending device needs to send the uplink frame data of each slave port 5 back to the master port 1, and in order to send each uplink frame data orderly through the master port 1 which can only process one frame of data at the same time, the uplink frame control module 4 in the embodiment of the invention can send the uplink frame data received from each slave port 5 sequentially through the master port 1 according to the first-in first-out rule so as to send the uplink frame data back to the master station device of the EtherCAT network.
Specifically, it should be noted that the link expansion device in the embodiments of the present invention may be implemented in various manners, for example, may be implemented by an FPGA (Field Programmable Gate Array ) or the like, and the embodiments of the present invention are not limited thereto.
The invention provides a link expansion device of an EtherCAT network, which considers that the target MAC address in each frame of data transmitted in the EtherCAT network has available idle data bits, and can represent the corresponding slave port 5 of the downlink frame data through the target MAC address in the downlink frame data, so as to distribute the downlink frame data to different links for transmission, therefore, a port analysis module 2 in the application can determine the corresponding target slave port according to the target MAC address in the downlink frame data, a data transmission module 3 can send the current downlink frame data through the target slave port, an uplink frame control module 4 can orderly send the uplink frame data received from each slave port 5 through a master port 1 according to a first-in first-out rule and return the uplink frame data to the master station equipment, and the communication efficiency can be improved because the data in the EtherCAT network can be divided into a plurality of links for transmission in parallel through the link expansion device.
Based on the above embodiments:
as a preferred embodiment, the data transmission module 3 includes:
the enabling control module is used for enabling the target slave ports in all the slave ports 5 so that the target slave ports send out current downlink frame data;
and the data delay module is used for sending the current downlink frame data to each slave port 5 while the target slave port is enabled, so that the current downlink frame data is sent out through the target slave port and transmitted in the link of the slave station equipment corresponding to the target slave port.
For better explanation of the embodiment of the present invention, please refer to fig. 3, fig. 3 is a schematic structural diagram of another link expansion device of EtherCAT network provided by the present invention, specifically, 16 slave PORTs 5 in fig. 3 may be slave PORTs 50-15, respectively, port_en [0] to port_en [15] represent 16 slave PORT 5 forwarding enable registers corresponding to slave PORTs 5 one by one, a port_tx bus (n corresponds to slave PORT 5) is used to transmit downlink frame data, and a port_rx bus (n corresponds to slave PORT 5) is used to transmit uplink frame data.
Specifically, after the target slave port is obtained, the present invention considers using a simple enabling control manner to control the target slave port to send out the current downlink frame data, so that the enabling control module in the embodiment of the present invention can enable all the target slave ports in the slave port 5 so that the target slave port sends out the current downlink frame data, and the enabling control module can enable only the target slave port therein at this time, but not enable other slave ports 5.
Specifically, considering that the parsing process of the target MAC address in the downstream frame data needs to take time, that is, a period of time is required from the time when the downstream frame data is received to the time when the target slave port is enabled, in order to ensure that the current downstream frame data can be successfully sent out from the target slave port, it needs to be ensured that the current downstream frame data is sent to each slave port 5 while the target slave port is enabled, so the data delay module in the embodiment of the present invention can be used to ensure this operation, so that the current downstream frame data is sent out through the target slave port and is transmitted in the link of the slave station device corresponding to the target slave port.
As a preferred embodiment, the port resolution module 2 is specifically configured to:
according to the front N-bit data in the target MAC address in the downlink frame data of the EtherCAT network currently received through the main port 1, determining a slave port 5 corresponding to the downlink frame data and taking the slave port as a target slave port;
wherein N is a preset positive integer, and the number of slave ports 5 is not greater than the total number of permutation and combination of the previous N bits of data.
Specifically, considering that the number of the slave ports 5 which can be expressed by 8 bytes is far beyond the requirement, in the embodiment of the invention, the number of the slave ports 5 is expressed by only taking the first N bits of data in the target MAC address, and the port analysis module 2 can determine the slave port 5 corresponding to the downlink frame data as the target slave port according to the first N bits of data in the target MAC address in the downlink frame data of the EtherCAT network currently received through the master port 1.
Wherein N may be set autonomously, for example, may be set to 4 to represent at most 16 slave ports No. 5, which is not limited herein.
As a preferred embodiment, the enabling control module comprises:
the slave ports 5 forwarding enable registers corresponding to the slave ports 5 one by one are used for adjusting own register values under the control of the port analysis module 2 and sending the register values to the enabling ends of the corresponding slave ports 5 so as to enable the target slave ports in all the slave ports 5 and send out current downlink frame data through the target slave ports.
Specifically, in the embodiment of the invention, the configuration of forwarding the enabling registers to the slave ports 5 corresponding to the slave ports 5 one by one can realize the enabling/disabling control to the slave ports 5 each time, the implementation mode is simple, and the enabling control speed is higher.
Of course, the enabling control module may be implemented in other ways besides this specific way, and embodiments of the present invention are not limited herein.
As a preferred embodiment, the data delay module is specifically configured to:
after buffering of the target MAC address in the current downstream frame data is completed, the current downstream frame data is transmitted to each slave port 5 so that the downstream frame data is transmitted to each slave port 5 while the target slave port is enabled.
Specifically, considering that the time consumed by the port analysis module 2 to analyze the target slave port according to the target MAC address is basically equal to the time required for buffering the target MAC address, the data delay module in the embodiment of the present invention may send the current downlink frame data to each slave port 5 after buffering the target MAC address in the current downlink frame data is completed, so that the downlink frame data is sent to each slave port 5 while the target slave port is enabled, and the delay mode is simpler.
Specifically, considering that the destination MAC address has a total of 8 bytes and 64 data bits, the data delay module may delay the beats of 8 bytes of data (8 bytes x 8 bits/4 bits=16 beats) by 16 x 40=640 ns time (40 ns per beat) by using 16 4-bit registers, so that the PORT resolution module 2 recognizes the first four bits ([ 3:0] value) of the destination MAC address after the SFD (frame start delimiter) to configure the slave PORT 5 forwarding enable register port_en [15:0], and then forwards the 16 4-bit register data to each slave PORT 5, so that the slave PORT 5 is controlled to be enabled and the time when the downstream frame data is received remains synchronized.
Referring to the following table 1, table 1 is a function definition table of forwarding enable registers from port 5:
TABLE 1
As a preferred embodiment, the uplink frame control module 4 is specifically configured to:
when the main port 1 does not send the uplink frame data currently, the uplink frame data received from the slave port 5 is sent out through the main port 1, when the main port 1 is sending the uplink frame data currently, the uplink frame data received from the slave port 5 is cached to a frame queue, and the uplink frame data in the frame queue is sent out through the main port 1 according to a first-in first-out rule so as to send the uplink frame data back to the main station equipment of the EtherCAT network.
Specifically, in order to forward the uplink frame data sent by each slave port 5 through the master port 1 in order, when the uplink frame data is received, it may be determined whether the master port 1 is currently sending the uplink frame data, when the master port 1 is not currently sending the uplink frame data, the uplink frame data currently received from the slave port 5 is sent through the master port 1, when the master port 1 is currently sending the uplink frame data, the uplink frame data currently received from the slave port 5 is cached in the frame queue, and the uplink frame data in the frame queue is sent through the master port 1 according to the first-in first-out rule, so as to send the uplink frame data back to the master station device of the EtherCAT network.
Referring to fig. 3, in the embodiment of the present invention, the uplink frame control module 4 may maintain 16 (the number of which is the same as that of the slave ports 5) frame queues, each frame queue may be at least one frame of uplink frame data, for example, 1536 bytes (maximum ethernet frame), and the data flow received by each slave port 5 may be sent to the uplink frame control module 4 for the above operation, where the buffer entry queue and the forwarding master port 1 sending in the process may be performed simultaneously.
As a preferred embodiment, the link expansion means is located downstream of the first slave station device of the EtherCAT network;
the master station device of the EtherCAT network is configured to send downlink frame data, receive uplink frame data, and control all slave station devices in a distributed clock synchronization mode in the EtherCAT network to perform distributed clock synchronization according to topology information of links corresponding to each slave port 5, so that clocks of all slave station devices in the distributed clock synchronization mode in the EtherCAT network are synchronized with a local clock of a first slave station device in the EtherCAT network.
For better explanation of the embodiments of the present invention, please refer to fig. 4, fig. 4 is a schematic structural diagram of an EtherCAT network provided by the present invention, considering that each slave station device in the EtherCAT network has a mode named DC (distributed clock) synchronization, and in order to realize control of the distributed clock synchronization, the master station device needs to know topology information of links corresponding to each slave port 5, so that the master station device in the embodiment of the present invention can control all slave station devices in the distributed clock synchronization mode in the EtherCAT network to perform distributed clock synchronization according to the topology information of links corresponding to each slave port 5, so that clocks of all slave station devices in the distributed clock synchronization mode in the EtherCAT network are synchronized with local clocks of the first slave station device in the EtherCAT network, and then a link expansion device is required to be located downstream of the first slave station device in the EtherCAT network, as shown in fig. 4.
The topology information of the links corresponding to each slave port 5 may be preset manually, or may be automatically acquired by the master station device, where the automatic acquisition process is as follows: the master station device may send a frame of data for requesting the slave station device to specify the basic information to each slave port 5, and after each slave station device on the slave port 5 receives the frame of data, the specified basic information of itself may be returned to the master station device through the frame of data, so that the master station device may receive the specified basic information of each slave station device on the link corresponding to the slave port 5, thereby obtaining the topology information of the link corresponding to the slave port 5.
As a preferred embodiment, the primary station device is further adapted to:
calculating the transmission time length from the transmission of the frame data to be transmitted from the equipment of the master station to the uplink reception of the slave port 5 corresponding to the frame data to be transmitted;
after a delay of a preset period of time, sending out frame data to be sent, so as to avoid that each slave port 5 receives uplink frame data from an uplink at the same time.
Specifically, referring to fig. 3, considering that each slave port 5 may send uplink frame data to the uplink frame control module 4 through one bus, in this case, since the bus only allows one path of data to pass through at the same time, if multiple slave ports 5 want to send data to the unique bus at the same time, an error will occur, so the master station needs to perform delay processing when sending downlink frame data, so that each slave port 5 will not receive uplink frame data at the same time, so that uplink frame data sent by each slave port 5 will not collide at the unique bus, so the master station device in the embodiment of the present invention can calculate a transmission time period from the master station device to receive uplink frame data from the slave port 5 corresponding to the frame data to be sent, and then delay sending the frame data to the unique bus for each frame data to be sent, that is, in the case of knowing the transmission time period, by controlling the sending time of each data frame to be sent, avoid that each slave port 5 will not receive uplink frame data at the same time.
For the topology shown in fig. 3, the transmission duration may include (1) a transmission time period of the first slave station device, (2) a time period of the port resolution module 2 for resolving the target MAC address in the downlink frame data, and (3) a transmission delay of the downlink frame data corresponding to the slave port 5 link (a time period taken for the slave port 5 to send the downlink frame data to the corresponding uplink frame data to return to the slave port 5 may include a line delay+a forwarding delay of each slave device in the slave port 5).
Finally, referring to fig. 2 below, table 2 is a comparison table of communication efficiency before and after link expansion:
TABLE 2
Specifically, the calculation formulas of the indexes in table 2 are specifically: the PDO frame byte number of all the slaves is the number of slaves x the PDO data size of each slave, the PDO frame byte number of each frame is the number of PDO frames per packet number of all the slaves, the byte number of each frame is the number of PDO frames per frame + the inherent length of the ethernet frame, the total delay of the plurality of slaves per frame is the number of slaves x the delay of each slave, the transmission and reception time of each frame is the number of bytes per frame x hundred megabytes transmission time x 2+ the total delay of the plurality of slaves per frame, the total frame gap time is the frame gap length x hundred megabytes transmission time x (packet number-1), the total time of multi-packet transmission and reception is the transmission and reception time of each frame x the number of packets + the total frame gap time, the number of slaves per slave is the number of slaves per slave/the number of slaves per slave port, the number of PDO frame bytes of all the secondary stations is the number of secondary stations multiplied by the PDO data size of each secondary station, the number of PDO frames of each frame is the number of PDO frames bytes of all the secondary stations/the number of subpackets, the number of bytes of each frame is the number of PDO frames of each frame multiplied by the inherent length of the ether cat frame, the total delay of the secondary stations of each frame is the number of secondary stations of each secondary port multiplied by the delay of each secondary station, the transmission and reception time of each frame is the number of bytes of each frame multiplied by hundred megabytes of transmission time multiplied by 2+ the total delay of the secondary stations of each frame, the total time of frame gaps is the total time of frame gaps, the total time of multiple subpacket transmission and reception is the total time of transmission and reception of each frame multiplied by the total time of frame gaps, and the improved efficiency is (the total time of multiple subpacket transmission and reception of traditional ESC links-the total time of multiple subpacket transmission and reception of the present patent branching link)/the total time of multiple subpacket transmission and reception of traditional ESC links.
The PDO data in the table above is PDO (Process data object ), the ESC is a slave control chip in the EtherCAT network, and the splitter is a link expansion device, as can be seen from table 2, the application of the link expansion device in the embodiment of the present invention can greatly improve the communication efficiency of the EtherCAT network.
Referring to fig. 5, fig. 5 is a flow chart of a link expansion method of an EtherCAT network, where the link expansion method of the EtherCAT network includes:
s101: determining a slave port 5 corresponding to the downlink frame data according to a target MAC address in the downlink frame data of the EtherCAT network currently received through the master port 1 and taking the slave port as a target slave port;
s102: transmitting the current downlink frame data through the target slave port so that the downlink frame data is transmitted in a link of the slave station equipment corresponding to the target slave port;
s103: the uplink frame data received from each slave port 5 is sequentially sent out through the master port 1 according to the first-in first-out rule, so that the uplink frame data is sent back to the master station device of the EtherCAT network.
For the description of the link expansion method of the EtherCAT network provided by the embodiment of the present invention, reference is made to the foregoing embodiment of the link expansion device of the EtherCAT network, and the embodiment of the present invention is not repeated herein.
The invention also provides an EtherCAT network, which comprises the link expansion device of the EtherCAT network in the embodiment.
For the description of the EtherCAT network provided by the embodiment of the present invention, reference is made to the foregoing embodiment of the link expansion device of the EtherCAT network, and the embodiment of the present invention is not repeated herein.
In the present specification, each embodiment is described in a progressive manner, and each embodiment is mainly described in a different point from other embodiments, and identical and similar parts between the embodiments are all enough to refer to each other. It should also be noted that in this specification the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
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 link expansion device of an EtherCAT network, comprising:
the port analysis module is used for determining a slave port corresponding to the downlink frame data and taking the slave port as a target slave port according to a target Media Access Control (MAC) address in the downlink frame data of the Ethernet control automation technology (EtherCAT) network received through the master port;
the data sending module is used for sending the current downlink frame data through the target slave port so that the downlink frame data is transmitted in a link of the slave station equipment corresponding to the target slave port;
the uplink frame control module is used for sequentially sending uplink frame data received from each slave port through the master port according to a first-in first-out rule so as to send the uplink frame data back to master station equipment of the EtherCAT network;
the master port and a plurality of slave ports.
2. The link expansion device of EtherCAT network according to claim 1, wherein the data transmission module comprises:
the enabling control module is used for enabling the target slave ports in all the slave ports so that the target slave ports send out the current downlink frame data;
and the data delay module is used for sending the current downlink frame data to each slave port while the target slave port is enabled, so that the current downlink frame data is sent out through the target slave port and is transmitted in a link of the slave station equipment corresponding to the target slave port.
3. The link expansion device of EtherCAT network according to claim 2, wherein the port resolution module is specifically configured to:
determining a slave port corresponding to downlink frame data according to the front N-bit data in a target MAC address in the downlink frame data of the EtherCAT network currently received through a master port, and taking the slave port as a target slave port;
and N is a preset positive integer, and the number of the slave ports is not more than the total number of the arrangement combinations of the first N bits of data.
4. A link expansion device of an EtherCAT network according to claim 3, wherein the enabling control module comprises:
and the slave port forwarding enabling registers are in one-to-one correspondence with the slave ports, are used for adjusting own register values under the control of the port analysis module, and sending the register values to the enabling ends of the corresponding slave ports so as to enable the target slave ports in all the slave ports and send out the current downlink frame data through the target slave ports.
5. The link expansion device of EtherCAT network according to claim 4, wherein the data delay module is specifically configured to:
after buffering of the target MAC address in the current downstream frame data is completed, the current downstream frame data is sent to each of the slave ports, so that the downstream frame data is sent to each of the slave ports while the target slave port is enabled.
6. The link expansion device of EtherCAT network according to claim 1, wherein the uplink frame control module is specifically configured to:
and when the main port is currently transmitting the uplink frame data, buffering the uplink frame data received from the slave port to a frame queue, and transmitting the uplink frame data in the frame queue through the main port according to a first-in first-out rule so as to transmit the uplink frame data back to a master station device of the EtherCAT network.
7. The link expansion device of an EtherCAT network according to any one of claims 1 to 6, wherein the link expansion device is located downstream of a first slave station apparatus of the EtherCAT network;
the master station device of the EtherCAT network is configured to send the downlink frame data, receive the uplink frame data, and control all slave station devices in a distributed clock synchronization mode in the EtherCAT network to perform distributed clock synchronization according to topology information of links corresponding to the slave ports, so that clocks of all slave station devices in the distributed clock synchronization mode in the EtherCAT network are synchronized with a local clock of a first slave station device in the EtherCAT network.
8. The link expansion device of EtherCAT network according to claim 7, wherein the master station apparatus is further configured to:
calculating the transmission time length from the sending of the frame data to be sent by the master station device to the receiving of the uplink by the slave port corresponding to the frame data to be sent;
and sending out the frame data to be sent after delaying for a preset time length so as to avoid that each slave port receives uplink frame data from an uplink at the same time.
9. The link expansion method of the EtherCAT network is characterized by comprising the following steps of:
determining a slave port corresponding to downlink frame data according to a target MAC address in the downlink frame data of the EtherCAT network currently received through a master port and taking the slave port as a target slave port;
transmitting the current downlink frame data through the target slave port so that the downlink frame data is transmitted in a link of the slave station equipment corresponding to the target slave port;
and sending the uplink frame data received from each slave port through the master port in turn according to a first-in first-out rule so as to send the uplink frame data back to the master station equipment of the EtherCAT network.
10. An EtherCAT network comprising a link expansion device of an EtherCAT network according to any one of claims 1 to 8.
CN202310724910.3A 2023-06-19 2023-06-19 EtherCAT network and link expansion method and device thereof Active CN116455833B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202310724910.3A CN116455833B (en) 2023-06-19 2023-06-19 EtherCAT network and link expansion method and device thereof

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202310724910.3A CN116455833B (en) 2023-06-19 2023-06-19 EtherCAT network and link expansion method and device thereof

Publications (2)

Publication Number Publication Date
CN116455833A true CN116455833A (en) 2023-07-18
CN116455833B CN116455833B (en) 2023-09-01

Family

ID=87136053

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202310724910.3A Active CN116455833B (en) 2023-06-19 2023-06-19 EtherCAT network and link expansion method and device thereof

Country Status (1)

Country Link
CN (1) CN116455833B (en)

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106656714A (en) * 2017-02-10 2017-05-10 广东工业大学 Communication protocol method and system based on EtherCAT bus
CN107276711A (en) * 2017-07-21 2017-10-20 上海新时达机器人有限公司 EtherCAT master station devices
CN110177013A (en) * 2019-05-16 2019-08-27 浙江理工大学 A kind of EtherCAT master-salve station design and implementation methods based on FPGA
WO2020173190A1 (en) * 2019-02-28 2020-09-03 华为技术有限公司 Data transmission method and network device
CN111786862A (en) * 2019-04-04 2020-10-16 赛格威科技有限公司 Control system and control method thereof and all-terrain vehicle
CN211791563U (en) * 2020-03-22 2020-10-27 深圳戴普森新能源技术有限公司 EtherCAT slave station controller
CN114205263A (en) * 2021-12-08 2022-03-18 中国信息通信研究院 Communication method, system and storage medium for Ether CAT network
CN115915384A (en) * 2022-12-05 2023-04-04 深圳市汇川技术股份有限公司 Communication method, module, device, terminal equipment and medium of master station and slave station

Patent Citations (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106656714A (en) * 2017-02-10 2017-05-10 广东工业大学 Communication protocol method and system based on EtherCAT bus
CN107276711A (en) * 2017-07-21 2017-10-20 上海新时达机器人有限公司 EtherCAT master station devices
WO2020173190A1 (en) * 2019-02-28 2020-09-03 华为技术有限公司 Data transmission method and network device
CN111628957A (en) * 2019-02-28 2020-09-04 华为技术有限公司 Data transmission method and network equipment
CN111786862A (en) * 2019-04-04 2020-10-16 赛格威科技有限公司 Control system and control method thereof and all-terrain vehicle
CN110177013A (en) * 2019-05-16 2019-08-27 浙江理工大学 A kind of EtherCAT master-salve station design and implementation methods based on FPGA
CN211791563U (en) * 2020-03-22 2020-10-27 深圳戴普森新能源技术有限公司 EtherCAT slave station controller
CN114205263A (en) * 2021-12-08 2022-03-18 中国信息通信研究院 Communication method, system and storage medium for Ether CAT network
CN115915384A (en) * 2022-12-05 2023-04-04 深圳市汇川技术股份有限公司 Communication method, module, device, terminal equipment and medium of master station and slave station

Also Published As

Publication number Publication date
CN116455833B (en) 2023-09-01

Similar Documents

Publication Publication Date Title
US9246835B2 (en) Method and apparatus for deblocking and blocking transmission of frames from a network device
EP2817902B1 (en) Method and network node for processing a precision time protocol
Alderisi et al. Introducing support for scheduled traffic over IEEE audio video bridging networks
CN110870285B (en) Method for high-performance data transmission in data networks with partial real-time requirements and device for carrying out said method
CN1668020B (en) Method, apparatus and system for guaranteed packet delivery times in asynchronous networks
JP4972206B2 (en) Packet switching device and local communication network comprising such a packet switching device
US9036654B2 (en) Packet sharing data transmission system and relay to lower latency
CN109639560B (en) Method for improving availability of real-time computer network
US11940943B2 (en) Low complexity ethernet node (LEN) one port
JP2006180510A (en) Method for controlling transfer of short data telegram
CN112769514A (en) Time-sensitive based communication device
CN105553795A (en) Method for transmitting standard Ethernet data in industrial Ethernet
CN113315668B (en) Method, node device and storage medium for adaptively adjusting network configuration
US20210351882A1 (en) Transmitting and Receiving Packets Wirelessly
CN108199822B (en) Bus synchronization method and device of EtherCAT-NCUC
CN116991121A (en) EPA scheduling method and device compatible with multiple protocols
US20230090803A1 (en) Network Infrastructure Device, Communication Terminal and Method for Synchronizing Control Applications via a Communication Network for Transferring Time-Critical Data
CN110492960A (en) Synchronized communication method based on Ethernet
US11442432B2 (en) Communication device and method for data transmission within an industrial communication network
CN116455833B (en) EtherCAT network and link expansion method and device thereof
CN114531943B (en) Data transmission method and automation communication network
CN110855540B (en) 485 multi-master communication method and system based on single-ring network
CN113238537A (en) High-speed industrial field bus based on Ethernet and data transmission method thereof
Scharbarg et al. Interconnecting can busses via an ethernet backbone
CN111131134A (en) Vehicle-mounted Ethernet data exchange device for rail transit train

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