Ethercat remote io distributed frame loss compensation system and method

CN122661040BActive Publication Date: 2026-09-25SHENZHEN DUOHE ELECTRIC CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202611160328.9
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2026-08-03
Publication Date
2026-09-25
Estimated Expiration
2046-08-03

AI Technical Summary

Technical Problem

主站侧故障处理需要经过异常确认和后续通信周期,难以及时覆盖瞬态丢帧期间的输出空缺;统一保持方式也未结合多个IO子模块的拓扑顺序、背板通信时隙和输出通道映射关系,难以把不同输出通道的补偿数据准确写入对应子模块

Benefits of technology

[0017]与现有技术相比,本申请至少具有以下有益效果:EtherCAT耦合器通过自动拓扑识别建立主站输出过程数据项、子模块逻辑标识、背板通信时隙和输出通道之间的对应关系,使丢帧期间生成的通道级补偿数据能够写入准确的背板时隙并由对应IO子模块提取;按输出通道维护历史数据队列并根据通道类型选择补偿方式,使开关量通道和模拟量输出通道采用与其输出特性匹配的处理;连续丢帧达到阈值后切换安全输出,通信恢复时根据差值控制接管速度,可以减少短时丢帧引起的输出突变,并限制持续通信异常期间的输出风险;通道诊断结果参与补偿决策,故障通道由硬件保护路径及时关断,能够避免通信补偿继续驱动已经发生电气故障的输出通道。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122661040B_ABST
    Figure CN122661040B_ABST
Patent Text Reader

Abstract

The embodiment of the application relates to the technical field of industrial real-time Ethernet control, in particular to an EtherCAT remote IO distributed frame loss compensation system and method. The system comprises an EtherCAT coupler and multiple IO sub-modules connected through a backplane communication bus. The coupler identifies the topology sequence and channel configuration of each IO sub-module, allocates logical identification and backplane communication time slots, and establishes a mapping relationship between output process data items, backplane communication time slots and output channels. When no valid output process data is received in the current communication cycle, compensation data is generated according to the historical valid output process data of each output channel, and is sent to the IO sub-module through the corresponding backplane communication time slot to update the output channel. After valid output process data is recovered, the output is recovered according to the mapping relationship. The scheme can maintain the output continuity of multiple IO sub-modules during short frame loss, and improve the reliability of compensation data directional delivery and communication recovery.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] Embodiments of this application relate to the field of industrial real-time Ethernet control technology; in particular, an EtherCAT remote IO distributed frame loss compensation system and method. Background Technology

[0002] EtherCAT (Ethernet for Control Automation Technology) employs a communication method where the master station periodically sends Ethernet frames, and the slave station reads output process data and writes input process data as the frames pass through. A remote I / O system typically consists of an EtherCAT coupler and multiple input / output (IO) submodules. The EtherCAT coupler converts the master station's process data into backplane communication data, and each IO submodule extracts output data and acquires input data according to its own channel configuration.

[0003] In high-speed control equipment, robots, and flexible production lines, EtherCAT communication cycles can be in the microsecond range. Field electromagnetic interference, transient connector contact anomalies, or communication link verification failures may prevent the output process data of a particular communication cycle from being effectively received by the EtherCAT coupler. For remote I / O systems comprising multiple I / O submodules, each submodule has different module types, number of channels, and data lengths. Furthermore, there are backplane addressing and time slot mapping relationships between the master station process data items and the output channels of specific I / O submodules.

[0004] Current methods typically involve the master station uniformly switching the output state after detecting a communication anomaly, or the slave station maintaining the most recent output. Fault handling on the master station side requires anomaly confirmation and subsequent communication cycles, making it difficult to promptly cover output gaps during transient frame drops. The uniform maintenance method also fails to consider the topological order of multiple IO submodules, backplane communication time slots, and output channel mapping relationships, making it difficult to accurately write compensation data for different output channels into the corresponding submodules. After communication is restored, there may still be a significant difference between the restored data and the current compensated output; direct switching could cause abrupt changes in analog output or motion control quantities.

[0005] Therefore, a remote IO distributed frame loss compensation scheme for multiple IO submodules is needed, which enables the EtherCAT coupler to establish process data mapping based on the automatically identified submodule topology and channel configuration. When no valid output process data is received in the current communication cycle, compensation data is generated according to the output channel and sent to the corresponding IO submodule through the backplane communication time slot. At the same time, it performs safe handling of continuous frame loss, channel failure and communication recovery. Summary of the Invention

[0006] The technical problem to be solved by this application is: in a remote IO system including an EtherCAT coupler and multiple IO sub-modules, how to accurately send the compensation data generated by each channel to the corresponding IO sub-module by utilizing the mapping relationship between the sub-module topology, backplane communication time slots and output channels when no valid output process data is received in the current communication cycle, and maintain controllable changes in the output state during continuous frame loss or communication recovery.

[0007] To address the aforementioned technical problems, this application provides an EtherCAT remote I / O distributed frame loss compensation system, comprising an EtherCAT coupler and multiple I / O sub-modules connected via a backplane communication bus. The EtherCAT coupler identifies the topological order and channel configuration of each I / O sub-module, assigns logical identifiers and backplane communication time slots to each I / O sub-module, and establishes a mapping relationship between output process data items, logical identifiers, backplane communication time slots, and output channels.

[0008] The EtherCAT coupler receives output process data from the EtherCAT master station according to the communication cycle and caches historical valid output process data for each output channel. When no valid output process data is received in the current communication cycle, the EtherCAT coupler generates compensation data based on the historical valid output process data corresponding to each output channel, writes the compensation data into the corresponding backplane communication time slot, and sends it via the backplane communication bus. Each IO submodule extracts the compensation data from the corresponding backplane communication time slot and updates the corresponding output channel. When valid output process data is received again, the EtherCAT coupler writes it into the corresponding backplane communication time slot and sends it via the backplane communication bus, and each IO submodule updates the corresponding output channel based on the valid output process data.

[0009] In some embodiments, the EtherCAT coupler sends an enumeration frame including a current address field and a module information area during the initialization phase. Each IO submodule receives the enumeration frame in topological order, stores the current address field value at the time of reception as its own logical identifier, writes a module information record including the logical identifier, module type, and number of channels in the module information area, increments the current address field value, and forwards the enumeration frame. The EtherCAT coupler determines the topological order and channel configuration of each IO submodule based on the returned module information record, and allocates backplane communication time slots according to the topological order and number of channels.

[0010] In some embodiments, each IO submodule is provided with a first backplane interface and a second backplane interface, and the second backplane interface of one IO submodule is detachably connected to the first backplane interface of the adjacent IO submodule. The first backplane interface and the second backplane interface respectively include a power terminal, a ground terminal and a differential data terminal to transmit power supply, enumeration frames and backplane communication frames, and maintain the mechanical connection between adjacent IO submodules through a detachable locking structure.

[0011] In some embodiments, the backplane communication bus is a differential ring backplane bus, and the backplane communication frame includes time slot data areas corresponding to each logical identifier. Each time slot data area includes an output data field and an input data field. Each IO submodule extracts output process data or compensation data from its corresponding output data field, writes the collected input data into its corresponding input data field, and transmits the data in other time slot data areas transparently.

[0012] In some embodiments, the EtherCAT coupler determines whether valid output process data has been received in the current communication cycle based on at least one of the following: the cyclic redundancy check result of the received frame, the communication cycle timeout status, the EtherCAT working counter, and the process data update flag. The EtherCAT coupler establishes a historical data queue for each output channel, associates valid output process data with the corresponding communication cycle identifier, and updates the historical data queue using a sliding window method.

[0013] In some embodiments, the EtherCAT coupler selects a compensation method based on the output channel type and the number of valid data in the historical data queue. For analog output channels, compensation data is calculated based on the change in valid output process data across multiple consecutive communication cycles, and limited according to the output range and the maximum allowable change. For digital output channels, or output channels where the number of historical data does not reach the preset window length, the most recent valid output process data is determined as the compensation data.

[0014] In some embodiments, each IO submodule is equipped with a channel diagnostic unit and an output control unit. The channel diagnostic unit collects the voltage, current, or impedance of the IO channel and determines the fault state of open circuit, short circuit, or overload. The IO submodule writes the fault state into the corresponding backplane communication time slot. The EtherCAT coupler stops generating compensation data based on historical data for the faulty output channel and writes preset safety output data into the corresponding time slot. When the channel diagnostic unit detects a short circuit or overload, it causes the output control unit to shut down the corresponding output channel through a hardware protection path.

[0015] This application also provides a distributed frame loss compensation method for EtherCAT remote I / O. The method includes: identifying the topology order and channel configuration of each I / O submodule, allocating logical identifiers and backplane communication time slots, and establishing a mapping relationship between output process data items, logical identifiers, backplane communication time slots, and output channels; receiving output process data from the EtherCAT master station according to the communication cycle, and caching historical valid output process data according to the output channel; when no valid output process data is received in the current communication cycle, generating compensation data based on the historical valid output process data corresponding to each output channel, writing the compensation data into the corresponding backplane communication time slot, and sending it through the backplane communication bus; each I / O submodule extracting the compensation data from the corresponding backplane communication time slot and updating the corresponding output channel according to the compensation data; when valid output process data is received again, writing the valid output process data into the corresponding backplane communication time slot and sending it through the backplane communication bus, and updating the corresponding output channel by each I / O submodule according to the valid output process data.

[0016] In some embodiments, the method further includes counting the number of communication cycles in which no valid output process data is received consecutively. When this number is less than a preset frame loss threshold, data is generated and amplitude-limited compensation data is continued; when this number reaches the preset frame loss threshold, short-term prediction compensation is stopped, and preset safe output data is written to the affected backplane communication time slots; after receiving valid output process data, direct takeover or adjustment according to the maximum allowable change is determined based on the difference between the recovered data and the current output data.

[0017] Compared with existing technologies, this application has at least the following advantages: The EtherCAT coupler establishes the correspondence between master station output process data items, submodule logic identifiers, backplane communication time slots, and output channels through automatic topology identification, enabling channel-level compensation data generated during frame loss to be written to the accurate backplane time slot and extracted by the corresponding IO submodule; it maintains a historical data queue according to the output channel and selects the compensation method according to the channel type, so that the digital and analog output channels adopt processing that matches their output characteristics; after continuous frame loss reaches the threshold, it switches to safe output, and when communication is restored, it controls the takeover speed according to the difference, which can reduce the output mutation caused by short-term frame loss and limit the output risk during continuous communication anomalies; the channel diagnosis results participate in the compensation decision, and the faulty channel is shut down in time by the hardware protection path, which can prevent communication compensation from continuing to drive the output channel that has already experienced electrical faults. Attached Figure Description

[0018] Figure 1 The overall structure diagram of the EtherCAT remote IO distributed frame loss compensation system provided in the embodiments of this application is shown.

[0019] Figure 2This is a diagram illustrating the internal functional structure of the EtherCAT coupler provided in an embodiment of this application.

[0020] Figure 3 A flowchart illustrating the automatic topology identification and backplane communication time slot allocation provided in the embodiments of this application.

[0021] Figure 4 This is a schematic diagram of backplane communication frame and time slot processing provided in an embodiment of this application.

[0022] Figure 5 This is a diagram showing the internal structure of the IO submodule provided in an embodiment of this application.

[0023] Figure 6 A flowchart of the EtherCAT remote IO distributed frame loss compensation method provided in the embodiments of this application.

[0024] Figure 7 Timing diagrams for frame loss compensation, secure output, and recovery processing provided in embodiments of this application.

[0025] Explanation of reference numerals in the attached diagram: 100, EtherCAT master station; 110, EtherCAT coupler; 111, EtherCAT communication unit; 112, topology management unit; 113, backplane communication unit; 114, compensation processing unit; 115, historical data storage unit; 116, event logging unit; 120, backplane communication bus; 130, IO submodule; 131, first backplane interface; 132, second backplane interface; 133, submodule control unit; 134, channel diagnostic unit; 135, input isolation unit; 136, output control unit; 137, status storage unit; 200, controlled device. Detailed Implementation

[0026] The technical solution will be further described below with reference to embodiments of this application. The described embodiments are used to illustrate the technical principles and possible implementation methods of this application. Unless otherwise specified, the technical features in the various embodiments can be combined with each other.

[0027] To facilitate a precise understanding by those skilled in the art of the system composition, data objects, and processing logic involved in the subsequent embodiments, a general description of the main functional objects, process data transmission relationships, output process data validity judgment, backplane communication time slots, and basic processing procedures for distributed frame loss compensation in the EtherCAT remote I / O system is provided before detailing the specific embodiments. The following description serves to unify the technical terminology used in subsequent embodiments and to clarify the signal paths and data processing relationships between various technical objects; the specific composition, connection methods, and processing steps of each functional module will be further explained in conjunction with the accompanying drawings in the corresponding embodiments.

[0028] The EtherCAT master station sends EtherCAT frames according to a preset communication cycle. The PDO (Process Data Object) within the frame carries periodic input and output process data. Output process data is sent by the EtherCAT master station to a remote I / O system to control the output channels; input process data is collected by the I / O submodule and written back to the EtherCAT frame via the EtherCAT coupler. A communication cycle is the time interval between two consecutive periodic process data exchanges.

[0029] In this application, valid output process data is data that meets preset validity conditions. These validity conditions may include a correct CRC (Cyclic Redundancy Check), reception within the allowed communication cycle time, a WKC (Working Counter) meeting expectations, and a valid process data update flag. If valid output process data is not received in the current communication cycle, it could be due to a lack of EtherCAT frames received in that cycle, a checksum error in the received frame, an abnormal working counter, or the output process data not being updated.

[0030] A backplane communication timeslot is a data location within a backplane communication frame allocated to an IO submodule or a set of channels for that IO submodule. The timeslot can be allocated in bits, bytes, or words as the smallest unit. Logical identifiers are used to distinguish different IO submodules, and the topology order indicates the arrangement of the IO submodules in the backplane transmission direction starting from the EtherCAT coupler. Output process data items can be a bit, a byte, a word, or multiple consecutive bytes in the master station process image area.

[0031] Compensation data is replacement output data generated by the EtherCAT coupler based on previously received historical valid output data and provided to the corresponding output channel when no valid output process data is received in the current communication cycle. Distributed frame loss compensation means that the coupler side generates, encapsulates, and distributes compensation data separately for different IO sub-modules and their output channels. Each IO sub-module only extracts the data corresponding to its own logical identifier and backplane communication time slot.

[0032] The term "digital output channel" as used in this application refers to an I / O channel that controls the output terminal to be in an on, off, or other preset discrete state based on output process data. The output process data of the digital output channel can be a binary state value or a discrete state code. The output control unit controls the high-side switch, low-side switch, transistor output circuit, or relay drive circuit to switch the output state based on the output process data. The term "digital output channel" as used in this application has the same technical meaning as "digital output channel" in the art, and will be used consistently as "digital output channel" below.

[0033] The analog output channel referred to in this application is an I / O channel that outputs a corresponding voltage or current value within a preset range based on the output process data. The output process data of the analog output channel is numerical data used to determine the output amplitude. The output control unit converts the numerical data into a corresponding analog output signal through a digital-to-analog converter circuit, a voltage output drive circuit, or a current output drive circuit. For example, the analog output signal can be a voltage or current signal of 0–10V, ±10V, 0–20mA, or 4–20mA.

[0034] The first embodiment of this application addresses the problem that an EtherCAT coupler needs to manage multiple IO sub-modules, and that compensation data during frame loss needs to be accurately sent to the corresponding output channel. It provides an EtherCAT remote IO distributed frame loss compensation system. This system includes an EtherCAT coupler and multiple IO sub-modules connected via a backplane communication bus. The EtherCAT coupler identifies the topological order and channel configuration of each IO submodule, assigns logical identifiers and backplane communication time slots to each IO submodule, and establishes a mapping relationship between output process data items, logical identifiers, backplane communication time slots and output channels. The EtherCAT coupler receives output process data from the EtherCAT master station according to the communication cycle, and caches historical valid output process data according to the output channel. When no valid output process data is received in the current communication cycle, compensation data is generated according to the historical valid output process data corresponding to each output channel, the compensation data is written into the corresponding backplane communication time slot and sent through the backplane communication bus. Each IO submodule extracts compensation data from the corresponding backplane communication time slot and updates the corresponding output channel; when valid output process data is received, the EtherCAT coupler writes it into the corresponding backplane communication time slot and sends it through the backplane communication bus, and each IO submodule updates the corresponding output channel according to the valid output process data.

[0035] like Figure 1 As shown, the EtherCAT master station 100 is connected to the EtherCAT coupler 110 via a standard Ethernet link. The EtherCAT coupler 110 is sequentially connected to multiple I / O submodules 130 via a backplane communication bus 120. The I / O submodules 130 may include digital input modules, switch output modules, analog input modules, analog output modules, pulse input modules, or pulse output modules. The number of channels and the data length occupied by each channel of different I / O submodules 130 may vary. The controlled device 200 is connected to the output channels of one or more I / O submodules 130.

[0036] like Figure 2 As shown, the EtherCAT coupler 110 may include an EtherCAT communication unit 111, a topology management unit 112, a backplane communication unit 113, a compensation processing unit 114, a historical data storage unit 115, and an event logging unit 116. The EtherCAT communication unit 111 is connected to the topology management unit 112, and the topology management unit 112 is connected to the backplane communication unit 113. The topology management unit 112 provides the established process data mapping relationship to the EtherCAT communication unit 111 and the backplane communication unit 113. The EtherCAT communication unit 111 receives frames sent by the EtherCAT master station 100, reads the output process data, and writes the input data and status data received by the backplane communication unit 113 into the input process data area. The backplane communication unit 113 generates and sends backplane communication frames and receives backplane communication frames returned after processing by each IO submodule 130.

[0037] The compensation processing unit 114 is connected to the EtherCAT communication unit 111, the topology management unit 112, the backplane communication unit 113, the historical data storage unit 115, and the event recording unit 116. The EtherCAT communication unit 111 sends data validity results and communication recovery status to the compensation processing unit 114. The topology management unit 112 provides the compensation processing unit 114 with the output channel type and process data mapping relationship. The compensation processing unit 114 bidirectionally interacts with the backplane communication unit 113 to exchange compensation data, safe output data, and channel status information, and reads the historical valid output process data of the corresponding output channel from the historical data storage unit 115. The compensation processing unit 114 constitutes the short-term predictor built into the EtherCAT coupler 110, generating compensation data corresponding to the current missing communication cycle based on the historical valid output process data, and sending the frame loss start period, consecutive frame loss number, channel performing compensation, compensation method, safe output status, and recovery cycle to the event recording unit 116.

[0038] During the normal communication cycle, combined with Figure 1 , Figure 2 and Figure 5 The EtherCAT communication unit 111 extracts output process data from valid EtherCAT frames. The topology management unit 112 determines the corresponding IO submodule 130, backplane communication time slot, and output channel for each output process data item according to the mapping relationship. The backplane communication unit 113 writes the output process data into the corresponding time slot and sends the backplane communication frame. Each IO submodule 130 receives the backplane communication frame sequentially, extracts the output data from the time slot corresponding to its own logical identifier, and the submodule control unit 133 sends a channel update command to the output control unit 136.

[0039] The output control unit 136 may include a high-side switch, a low-side switch, a relay drive circuit, a digital-to-analog converter circuit, a pulse output circuit, or a drive circuit matched to the output type. For digital output channels, the channel update instruction is used to set the on or off state; for analog output channels, the channel update instruction is used to update the target voltage or target current value; for pulse output channels, the channel update instruction can be used to update the pulse frequency, duty cycle, or number of pulses.

[0040] After the output process data is deemed valid, the EtherCAT communication unit 111 sends the output process data and its communication cycle identifier to the historical data storage unit 115. The historical data storage unit 115 stores data separately according to the output channel, so that data from one output channel is not mixed with data from another output channel. Each historical data record includes at least a logical identifier, a channel identifier, a communication cycle identifier, and an output value.

[0041] When no valid output process data is received in the current communication cycle, the EtherCAT communication unit 111 sends a frame loss status to the compensation processing unit 114. The compensation processing unit 114 determines the output channels affected by the missing current output process data according to the mapping relationship, reads the historical valid output process data of the corresponding channel from the historical data storage unit 115, and generates compensation data for the current communication cycle. This processing is completed on a channel-by-channel basis; therefore, different output channels in the same IO submodule 130 can have different compensation values, and different IO submodules 130 can also use different compensation methods.

[0042] The compensation processing unit 114 sends the correspondence between the compensation data and the output channel to the backplane communication unit 113. The backplane communication unit 113, based on the mapping relationship stored in the topology management unit 112, writes the compensation data for each channel into the backplane communication time slot that matches the corresponding logical identifier and output channel, and sends the backplane communication frame. Each IO submodule 130 only reads the time slot allocated to itself; therefore, the compensation data will not be used as output by other IO submodules 130.

[0043] During the frame loss communication cycle, the backplane communication frames received by the IO submodule 130 use the same backplane frame format as those in the normal communication cycle. The backplane communication frames can be configured with a data source status field to indicate whether the corresponding output data belongs to the normal output process or compensation data. This data source status field is transmitted in the backplane communication link between the EtherCAT coupler 110 and the IO submodule 130, allowing the IO submodule 130 to execute and record channel update status. The EtherCAT link continues to use periodic communication initiated by the EtherCAT master station 100. Compensation events are saved by the event recording unit 116 and available for the EtherCAT master station 100 to read in subsequent valid EtherCAT communication cycles.

[0044] When the EtherCAT communication unit 111 receives valid output process data again in a subsequent communication cycle, the compensation processing unit 114 ends the current frame loss state. The EtherCAT coupler 110 writes the recovered valid output process data into the corresponding backplane communication time slot according to the same mapping relationship. Each IO submodule 130 extracts the recovered data from the time slot and updates the output channel according to the recovery method of direct takeover or restricted change. The event recording unit 116 completes the recording of this compensation event.

[0045] The above processing ensures that the mapping between the master station process data items and the backplane output position remains consistent across the three stages of normal transmission, frame loss compensation, and recovery transmission. Compensation data is sent along the normal backplane path, and each IO submodule 130 does not need to wait for the EtherCAT master station 100 to complete the abnormal confirmation, nor does it need to change the update interface of the original output channel. It can obtain the replacement output data of the corresponding channel within one backplane communication cycle.

[0046] The second embodiment of this application, based on the first embodiment, further addresses the problem that the master station process data items and backplane time slots are difficult to automatically correspond when the number, arrangement order, and channel configuration of IO submodules change. For example... Figure 3 As shown, and in combination Figure 1 , Figure 2 and Figure 5 During the initialization phase, the EtherCAT coupler 110 completes topology identification and time slot allocation by enumerating frames.

[0047] An enumeration frame includes at least a frame type field, a current address field, a module information area, and a checksum field. The frame type field indicates that the current frame belongs to the topology enumeration frame. The current address field carries the logical identifier to be allocated. The module information area stores the module information records written sequentially by each IO submodule 130. The checksum field checks the integrity of the enumeration frame transmission on the backplane communication bus 120.

[0048] The topology management unit 112 can initialize the current address field to a preset starting value, such as 1. After receiving the enumeration frame, the first IO submodule 130 adjacent to the EtherCAT coupler 110 stores the current address field value in its own state storage unit 137 as a logical identifier for the IO submodule 130. Subsequently, the IO submodule 130 writes a module information record to the module information area. The module information record may include a logical identifier, module type code, number of input channels, number of output channels, data length of each input channel, data length of each output channel, and diagnostic data length.

[0049] After completing the module information recording, the IO submodule 130 increments the current address field value and forwards the enumeration frame to the next IO submodule 130 via the second backplane interface 132. Subsequent IO submodules 130 repeat the above operation. Since each IO submodule 130 stores the address field value when receiving the enumeration frame and increments this value before forwarding, each IO submodule 130 obtains a logical identifier that is distinct and consistent with the topology order.

[0050] After passing through the last IO submodule 130, the enumeration frame is transmitted to the EtherCAT coupler 110 along the return path. The topology management unit 112 reads the module information records in the module information area, records the order of logical identifiers, and determines the required output data length, input data length, and diagnostic data length of each IO submodule 130 according to the module type code and the number of channels.

[0051] Backplane communication time slots can be allocated using consecutive addresses. The topology management unit 112 starts from the preset start offset of the backplane communication frame and accumulates the data length of each IO submodule 130 according to the logical identifier order. For an IO submodule 130 with eight digital output channels, the output data field can occupy one byte; for an IO submodule 130 with four 16-bit analog output channels, the output data field can occupy eight bytes. Input data fields and diagnostic data fields can be allocated in the same way.

[0052] The topology management unit 112 simultaneously obtains the process image area information configured by the EtherCAT master station 100. Each output process data item has a process data offset, data length, and channel purpose. Based on the module type, logical identifier, and channel number, the topology management unit 112 associates an output process data item with an output data location in a backplane communication timeslot, establishing a mapping relationship between the output process data item, logical identifier, backplane communication timeslot, and output channel.

[0053] The mapping relationship can be stored as a mapping table. Each record in the mapping table includes at least the process data area offset, data length, logical identifier, backplane time slot offset, and channel number. Both normal output process data and compensation data are encapsulated using the same mapping table, so the two types of data correspond to the same output channel after arriving at the IO submodule 130.

[0054] After the system is powered on again, the IO submodule 130 is replaced, or maintenance personnel change the module arrangement order, the EtherCAT coupler 110 can resend the enumeration frame. The topology management unit 112 compares the new module information record with the original mapping table and updates the logical identifiers, backplane communication time slots, and process data mappings affected by the changes. For modules that have not changed, the mapping record can continue to be used; for modules that are added, removed, or whose type has changed, the mapping record is reconfigured according to the new module information.

[0055] The third embodiment of this application, based on the second embodiment, further illustrates the engineering implementation of the detachable splicing interface and differential ring backplane communication. For example... Figure 4 and Figure 5 As shown, and in combination Figure 1 and Figure 2 Each IO submodule 130 has a first backplane interface 131 and a second backplane interface 132. The first backplane interface 131 faces the EtherCAT coupler 110, and the second backplane interface 132 faces the next IO submodule 130. Adjacent interfaces cooperate with each other.

[0056] The first backplane interface 131 and the second backplane interface 132 can employ standardized multi-pin connectors. For example, the connector can have twenty pins, including a 24V power supply terminal, a ground terminal, at least one pair of differential transmit terminals, at least one pair of differential receive terminals, and reserved control terminals. Mechanical connections can employ snap-fit, locking, or magnetic positioning combined with a rigid limiting structure. The power supply and ground terminals provide backplane power to each IO submodule 130, while the differential data terminals transmit enumeration frames and backplane communication frames.

[0057] The differential data terminals can use an LVDS (Low-Voltage Differential Signaling) electrical interface. Differential transmission and reception represent logic states through the voltage difference between two wires, which can reduce the impact of common-mode interference on backplane communication. Each IO submodule 130's backplane communication interface receives upstream differential signals, processes them, and then transmits them from the downstream interface; the return direction can use another pair of differential lines, so that the backplane communication frame is returned to the EtherCAT coupler 110 after being processed by the last IO submodule 130.

[0058] like Figure 4As shown, a backplane communication frame may include a frame header, a period identifier, multiple timeslot data areas, and a frame check field. Each timeslot data area corresponds to a logical identifier and includes an output data field, an input data field, and a status field. The length of the timeslot data area can be fixed or dynamically allocated based on module information. Dynamic length reduces unused data locations, while fixed length simplifies offset calculations for the IO submodule 130. Both methods can be selected based on backplane bandwidth and the number of modules.

[0059] After a backplane communication frame arrives at an IO submodule 130, the submodule control unit 133 reads the frame header and cycle identifier to determine that the frame is complete and belongs to the current backplane communication cycle; it locates its own time slot according to the logical identifier in the status storage unit 137; it reads the output process data or compensation data from the output data field; it writes the input data collected by the input isolation unit 135 into the input data field; it writes the status data generated by the channel diagnostic unit 134 into the status field; and after completion, it sends the updated backplane communication frame to the next IO submodule 130.

[0060] For time slot data areas that do not belong to itself, the IO submodule 130 retains the data content therein and continues transmission. Thus, each IO submodule 130 completes the extraction and writing of its own data within the same backplane communication frame. After receiving the return frame, the EtherCAT coupler 110 can map each input data field to the EtherCAT input process data area and read each status field for diagnostics and event logging.

[0061] In some embodiments, the backplane communication bus 120 operates in an asynchronous time-slice polling mode. The EtherCAT coupler 110 initiates one or more backplane communication cycles within each EtherCAT communication cycle. The total duration of the backplane communication cycle is less than the EtherCAT communication cycle, ensuring that normal or compensation data arrives at each IO submodule 130 before the next EtherCAT process data update. For example, in a 125-microsecond EtherCAT communication cycle, the round-trip time of the backplane communication frame can be controlled to within 2 microseconds. This value is used to illustrate an engineering configuration and does not constitute a limitation on the scope of protection.

[0062] The fourth embodiment of this application, based on the first embodiment, further solves the problems of a single criterion for frame loss determination and the need for different compensation methods for different output channels. Combined with... Figure 1 , Figure 2 and Figure 5 The EtherCAT communication unit 111, the compensation processing unit 114, and the historical data storage unit 115 work together to complete the validity judgment, historical data management, and compensation data generation.

[0063] Upon receiving an EtherCAT frame, the EtherCAT communication unit 111 first performs a CRC check. If the CRC check is correct, it continues to check whether the frame arrived within the allowed receive window of the current communication cycle. For EtherCAT datagrams containing a WKC (Write-in-Card), the EtherCAT communication unit 111 also compares the actual WKC with the expected WKC to determine whether the number of slaves participating in process data exchange and the read / write operations conform to the configuration. For systems with a process data update flag, it also checks whether the flag indicates that the output process data has been updated.

[0064] When any of the following conditions are met: CRC check error, receive window timeout, WKC anomaly, or invalid process data update flag, the current communication cycle can be determined as no valid output process data has been received. To avoid misjudgment based on a single state, two or more of these conditions can be combined into a validity rule. For example, if a frame does not arrive within the receive window, frame loss processing can be initiated directly; if a frame has arrived but WKC is abnormal, compensation is only performed on the affected data items.

[0065] The historical data storage unit 115 establishes historical data queues according to the output channels. Whenever valid output process data is received, the data and a communication cycle identifier are written to the corresponding queue. Once the queue reaches a preset window length, new data is written while the oldest data is deleted. For example, the preset window length can be three communication cycles, and the compensation processing unit 114 calculates short-term change trends using the three most recent valid output values. The preset window length is predetermined by the channel configuration, and the corresponding queues are maintained according to this configuration during system operation.

[0066] The compensation processing unit 114 first determines the type of the channel to be compensated based on the mapping relationship. For switch output channels, the output value represents the on or off state. The compensation processing unit 114 typically selects the most recent valid value retention method to avoid changing the switch state without a new master station instruction. For switch channels that need to meet safety logic, the configured safety value can also be used directly.

[0067] For the analog output channel, the compensation processing unit 114 reads the output values ​​of multiple consecutive communication cycles from the historical data queue, calculates the change between adjacent output values, and then calculates the average of these changes. The most recent valid output value is added to this average change to obtain the initial compensation value for the current communication cycle. This processing corresponds to linear extrapolation and can continue the short-term change trend before frame loss.

[0068] In this embodiment, both analog output channels and digital output channels represent the operating states of the same physical I / O channel under different functional mode configuration values. Specifically, when the functional mode configuration value corresponding to the physical I / O channel is an analog output mode configuration value, the physical I / O channel operates as an analog output channel and outputs analog voltage signals or analog current signals based on the output drive state. When the functional mode configuration value corresponding to the physical I / O channel is a digital output mode configuration value, the physical I / O channel operates as a digital output channel and outputs digital drive signals based on the output drive state. Thus, analog output channels and digital output channels are the channel operating states formed by the physical I / O channel after functional mode configuration.

[0069] After obtaining the initial compensation value, the compensation processing unit 114 performs output range limiting and maximum allowable change limiting. Output range limiting ensures that the compensation value does not exceed the minimum and maximum output values ​​allowed by the channel; maximum allowable change limiting ensures that the change in the compensation value relative to the most recent actual output value does not exceed the maximum increment or maximum decrement allowed in one communication cycle. The limited value is used as compensation data sent to the IO submodule 130.

[0070] When the amount of historical data does not reach the preset window length, the reliability of the trend is insufficient, and the compensation processing unit 114 adopts the method of keeping the most recent valid value. For cases where out-of-bounds values, values ​​corresponding to diagnostic faults, or invalid cycle identifiers appear in the historical data, the compensation processing unit 114 excludes the relevant records before calculating the change; when the remaining records are insufficient, it also switches to keeping the most recent valid value.

[0071] For example, the output values ​​of an analog speed setting channel for the most recent three valid communication cycles are 100, 120, and 140, respectively, with an average change of 20. When a frame is lost in the current cycle, the initial compensation value is 160. If the maximum allowable change per cycle for this channel is 15, the output compensation value is limited to 155. This compensation value is sent to the corresponding IO submodule 130 via the backplane communication time slot to update the controlled device 200 connected to this speed setting channel.

[0072] For pulse output channels, the channel type can be further divided into frequency parameters, duty cycle parameters, and pulse count parameters. Frequency and duty cycle parameters can be linearly extrapolated and limited; pulse count parameters can either continue to accumulate based on the most recent valid period increment or remain paused during frame drops. The specific method is determined by the compensation strategy field in the channel configuration.

[0073] The fifth embodiment of this application, based on the foregoing embodiments, further addresses the problem that historical data compensation may continue to drive the faulty channel when the IO channel itself experiences a disconnection, short circuit, or overload. For example... Figure 5 As shown, and in combination Figure 1 and Figure 2 The IO submodule 130 includes a channel diagnostic unit 134, an input isolation unit 135, an output control unit 136, and a status storage unit 137.

[0074] For the input channel, the field signal is sent to the submodule control unit 133 and the channel diagnostic unit 134 via the input isolation unit 135. The channel diagnostic unit 134 can collect the input terminal voltage, current, or equivalent impedance. When the input current is lower than the disconnection threshold, the terminal voltage is in the open circuit characteristic range, or the equivalent impedance exceeds the preset range, the corresponding input channel is determined to be in a disconnection state.

[0075] For the output channel, the output control unit 136 provides digital, analog, or pulse outputs to the controlled device 200. The channel diagnostic unit 134 acquires the output current and output terminal voltage. An overload condition is determined when the output current continuously exceeds the overload threshold; a short circuit condition is determined when the output current exceeds the short circuit threshold for a short period of time and the output terminal voltage drops to the short circuit characteristic range. The thresholds can be configured according to the module's rated current and load type.

[0076] The protection output terminal of the channel diagnostic unit 134 is connected to the enable terminal of the output control unit 136. When a short circuit or overload is detected, the channel diagnostic unit 134 directly sends a protection signal to the enable terminal, causing the corresponding output drive circuit to shut down. This hardware protection path does not wait for new output process data to be sent by the EtherCAT coupler 110, nor does it rely on the submodule control unit 133 to complete the software judgment, which can shorten the shutdown time of the faulty channel.

[0077] The status storage unit 137 stores a channel fault bitmap and fault type information. For an IO submodule 130 with eight channels, a one-byte channel fault bitmap can be used to indicate whether a fault exists in each channel, while an extended diagnostic field records the fault channel number, open circuit type, short circuit type, or overload type. This data structure can distinguish specific fault causes while keeping the periodic status data compact.

[0078] The submodule control unit 133 writes the channel fault bitmap and extended diagnostic fields into the status field of its own backplane communication timeslot. After receiving the returned backplane communication frame, the EtherCAT coupler 110 updates the channel status table according to the logical identifier and channel number. Before generating compensation data, the compensation processing unit 114 queries the channel status table, performs historical data compensation for normal output channels, stops short-term predictive compensation for faulty output channels, and writes preset safe output data.

[0079] When a short circuit or overload triggers hardware shutdown, preset safety output data is used to maintain consistency between the upper-layer state and the hardware state, and to prevent subsequent backplane communication frames from re-enabling the channel. After the fault is cleared, the EtherCAT master station 100 can send a reset command, which is transmitted to the corresponding IO submodule 130 via the EtherCAT coupler 110 and the backplane communication bus 120; the IO submodule 130 releases the fault latch after confirming that the electrical parameters have returned to the allowable range.

[0080] Channel diagnostic results can also be uploaded to the EtherCAT master station 100 via EtherCAT process data or a CoE (CANopen over EtherCAT) object dictionary. Periodic channel fault bitmaps are suitable for real-time uploading along with process data, while event records containing fault time, peak current, duration, and compensation status are suitable for on-demand reading by the master station.

[0081] The sixth embodiment of this application provides a distributed frame loss compensation method for EtherCAT remote I / O. This method is applied to... Figures 1 to 5 The EtherCAT remote I / O system shown. For example... Figure 6 As shown, and in combination Figures 1 to 5 The method includes topology identification and mapping establishment, historical valid output process data caching, compensation data generation and backplane communication time slot transmission, IO submodule output update, and valid output process data recovery processing, specifically including: S1. The EtherCAT coupler identifies the topology order and channel configuration of each IO submodule, assigns logical identifiers and backplane communication time slots to each IO submodule, and establishes a mapping relationship between output process data items, logical identifiers, backplane communication time slots and output channels. S2. The EtherCAT coupler receives output process data from the EtherCAT master station according to the communication cycle, and caches historical valid output process data according to the output channel. S3. When no valid output process data is received in the current communication cycle, the EtherCAT coupler generates compensation data based on the historical valid output process data corresponding to each output channel, writes the compensation data into the corresponding backplane communication time slot, and sends it through the backplane communication bus. S4. Each IO submodule extracts the compensation data from the corresponding backplane communication time slot and updates the corresponding output channel according to the compensation data; S5. When the EtherCAT coupler recovers and receives valid output process data, the valid output process data is written into the corresponding backplane communication time slot and sent through the backplane communication bus. Each IO submodule updates the corresponding output channel according to the valid output process data.

[0082] in: Step S1 identifies the topology order and channel configuration of each IO submodule, assigns logical identifiers and backplane communication time slots to each IO submodule, and establishes the mapping relationship between output process data items, logical identifiers, backplane communication time slots and output channels.

[0083] Specifically, the EtherCAT coupler sends an enumeration frame. Each IO submodule stores its current address field value, writes it to the module information record, and increments the address field according to the topology order. The EtherCAT coupler calculates the required data length and time slot offset for each module based on the returned module information record. Subsequently, the output data offset in the master station process image area is mapped to the logical identifier, time slot offset, and channel number. The output of step S1 is a mapping relationship used by both subsequent normal data encapsulation and compensation data encapsulation.

[0084] Step S2 receives output process data from the EtherCAT master station according to the communication cycle, and caches historical valid output process data according to the output channel.

[0085] Specifically, the received frame is checked for verification, timeout, working counter, and update status. When valid, the output process data is split into data items for each output channel according to the mapping relationship, and each data item, along with the communication cycle identifier, is stored in the corresponding historical data queue. When invalid, the current data is not written to the historical data queue to avoid erroneous data from participating in subsequent compensation calculations.

[0086] Step S3: When no valid output process data is received in the current communication cycle, compensation data is generated based on the historical valid output process data corresponding to each output channel. The compensation data is written into the corresponding backplane communication time slot and sent through the backplane communication bus.

[0087] Specifically, first, the output channels affected by the current data loss are identified; then, based on the output channel type, the most recent valid value is retained or linear extrapolation based on historical changes is selected; output range limiting and maximum allowable change limiting are applied to the extrapolation results; finally, the compensation data for each channel is written to the corresponding time slot according to the mapping relationship. Step S3 outputs a backplane communication frame containing compensation data from multiple IO submodules.

[0088] Step S4 extracts compensation data from the corresponding backplane communication time slot for each IO submodule and updates the corresponding output channel based on the compensation data.

[0089] Specifically, each IO submodule reads the time slot data area corresponding to its own logical identifier and sends the compensation data to each output channel according to the channel data offset. The IO submodule also writes the compensation status to the status storage area so that the EtherCAT coupler can confirm in the returned backplane communication frame that each module has processed the compensation data.

[0090] Step S5: When the EtherCAT coupler recovers and receives valid output process data, the valid output process data is written into the corresponding backplane communication time slot and sent via the backplane communication bus. Each IO submodule updates the corresponding output channel according to the valid output process data.

[0091] Specifically, upon arrival of the recovered data, a validity check is performed first, followed by a comparison of the difference between the recovered data and the current output data. If the difference is within the allowable direct handover range, the recovered data is written in the current backplane communication cycle; if the difference exceeds the allowable range, it is adjusted cycle by cycle according to the maximum allowable change until the output value matches the recovered data. After the takeover is completed, the compensation status is cleared and the frame loss event is recorded.

[0092] The seventh embodiment of this application, based on the sixth embodiment, further illustrates the compensation process, secure output process, and recovery takeover process during continuous frame loss. For example... Figure 7 As shown, and in combination Figure 1 , Figure 2 , Figure 5 and Figure 6 The execution states of the method include normal processing state, compensation processing state, safe output processing state, and recovery processing state.

[0093] Under normal processing conditions, valid output process data is received in each communication cycle, and the historical data queue is continuously updated. When no valid output process data is detected for the first time in the current communication cycle, the continuous frame loss count is updated from zero to one, and the method enters the compensation processing state. As long as the continuous frame loss count is less than the preset frame loss threshold, the compensation processing unit 114 continues to generate compensation data per channel.

[0094] The preset frame loss threshold can be set according to the device's allowed open-loop duration, communication cycle, and channel type. For example, with a threshold of three communication cycles, historical data compensation is performed during the first and second consecutive frame loss cycles, and a safe output state is entered during the third consecutive frame loss cycle. For a 125-microsecond communication cycle, this configuration can maintain continuous output for one or two frame loss cycles caused by short-term interference, while limiting the duration of short-term predictive compensation during longer communication interruptions.

[0095] Safety output data can be configured separately for each channel. Digital output channels can maintain the most recently valid state or switch to a preset off state; analog output channels can maintain the most recently valid value, decrease to zero at a limited slope, or switch to a preset safe value; pulse output channels can stop outputting new pulses or maintain the lowest permissible frequency. The compensation processing unit stops extrapolating based on historical trends and writes the safety output data to the corresponding backplane communication time slot.

[0096] During the compensation processing state or the safe output processing state, the EtherCAT communication unit 111 continues to check each subsequent communication cycle. Upon receiving valid output process data again, the EtherCAT coupler 110 performs recovery takeover processing and resets the consecutive frame loss count. The compensation processing unit 114 reads the currently used output data of each output channel and compares it with the recovered output process data.

[0097] When the difference between the two values ​​does not exceed a preset switching threshold, the recovered data can directly take over the output channel. The preset switching threshold can be set according to the proportion of the channel's full scale, an absolute value, or the maximum allowable change in a single cycle. When the difference exceeds the preset switching threshold, starting from the current output data, the recovered data will move closer to the recovered data in each communication cycle by an increment or decrement not exceeding the maximum allowable change.

[0098] During cycle-by-cycle recovery, if the EtherCAT master station 100 continues to send new valid output process data, the latest recovered data can be used as the target value, causing the output channels to follow the master station's target under the constraint of the rate of change. Once the target value is reached, the recovery status is cleared, and the output channels and historical data queues are updated again according to the normal output process data.

[0099] The event logging unit 116 can record the start time of this anomaly, the number of consecutive frame loss cycles, the logic identifier and channel number involved in compensation, the channel that entered the safe output, the duration of the recovery takeover, and whether the channel hardware protection was triggered. The EtherCAT master station 100 can read the event summary in subsequent valid communication cycles, or it can read the complete event record through the CoE object dictionary.

[0100] Taking the three servo auxiliary output channels of a high-speed milling machine as an example, the EtherCAT communication cycle is 125 microseconds. During normal communication, the output process data of the three channels are mapped to two analog output submodules and one pulse output submodule, respectively. When a communication cycle fails to receive valid output process data due to electromagnetic interference, the EtherCAT coupler generates analog compensation values ​​and pulse frequency compensation values ​​according to its respective historical data queue and writes them into the three corresponding time slots. Each IO submodule extracts its own data in the same backplane communication cycle, ensuring that the three output channels maintain coordinated updates during periods of temporary data loss from the master station.

[0101] When valid data is restored in the next communication cycle and the difference between the restored value and the current compensation value is small, each IO submodule directly uses the restored data; when the difference is large, the EtherCAT coupler generates transition data according to the maximum allowable change of the channel. This process can reduce the situation where multiple submodules generate different magnitude abrupt changes during restoration, and enable the relevant output channels distributed on different IO submodules to return to the master station control according to the same communication cycle and their respective change constraints.

[0102] The EtherCAT coupler 110 in this embodiment can perform topology management, mapping, validity judgment, and compensation processing using a processor, programmable logic device, application-specific integrated circuit, or a combination thereof. The historical data storage unit 115 can employ random access memory, a dual-port memory, or a first-in-first-out queue. The backplane communication unit 113 can consist of a differential transceiver and programmable logic. The specific devices described above can be selected based on the communication cycle, the number of submodules, and the data length.

[0103] Those skilled in the art can adjust the historical window length, frame loss threshold, compensation method, output range, maximum allowable variation, direct switching threshold, and secure output data according to the device type. The adjusted parameters are still saved according to the output channel configuration and are applied to the corresponding IO submodule by the same topology mapping and backplane time slot transmission mechanism.

[0104] The above embodiments illustrate the technical solution of this application. Equivalent substitutions or combinations made by those skilled in the art based on the topology mapping, channel-level historical data compensation, backplane time slot directional transmission, secure output, and recovery of takeover relationships described in this application can all be implemented using the processing methods disclosed in this application.

Claims

1. An EtherCAT remote I / O distributed frame loss compensation system, characterized in that, This includes an EtherCAT coupler and multiple IO sub-modules connected via a backplane communication bus; The EtherCAT coupler identifies the topological order and channel configuration of each IO submodule, assigns logical identifiers and backplane communication time slots to each IO submodule, and establishes a mapping relationship between output process data items, logical identifiers, backplane communication time slots and output channels. The EtherCAT coupler receives output process data from the EtherCAT master station according to the communication cycle, and caches historical valid output process data according to the output channel. When no valid output process data is received in the current communication cycle, compensation data is generated according to the historical valid output process data corresponding to each output channel, the compensation data is written into the corresponding backplane communication time slot and sent through the backplane communication bus. Each IO submodule extracts compensation data from the corresponding backplane communication time slot and updates the corresponding output channel; when valid output process data is received, the EtherCAT coupler writes it into the corresponding backplane communication time slot and sends it through the backplane communication bus, and each IO submodule updates the corresponding output channel according to the valid output process data. The backplane communication bus is a differential ring backplane bus. The backplane communication frame transmitted along the differential ring backplane bus includes a time slot data area corresponding to each logical identifier. The time slot data area includes an output data field and an input data field. Each IO submodule receives and forwards the backplane communication frames in topological order, extracts output process data or compensation data from the output data field corresponding to its own logical identifier, writes the input data collected from its own input channel into the input data field corresponding to its own logical identifier, and transmits the data in other time slot data areas transparently. The EtherCAT coupler receives the backplane communication frames returned after being processed sequentially by each IO submodule.

2. The EtherCAT remote I / O distributed frame loss compensation system according to claim 1, characterized in that, During the initialization phase, the EtherCAT coupler sends an enumeration frame that includes a current address field and a module information area. Each IO submodule receives the enumeration frame in topological order, stores the current address field value when receiving the enumeration frame as its own logical identifier, writes a module information record including the logical identifier, module type and channel number in the module information area, and forwards the enumeration frame after incrementing the current address field value. The EtherCAT coupler receives the enumeration frames returned after being processed sequentially by each IO submodule, determines the topology order and channel configuration of each IO submodule based on the module information record, and allocates the backplane communication time slots according to the topology order and the number of channels.

3. The EtherCAT remote I / O distributed frame loss compensation system according to claim 2, characterized in that, Each IO submodule is provided with a first backplane interface and a second backplane interface. The second backplane interface of one IO submodule is detachably connected to the first backplane interface of the adjacent IO submodule. The first backplane interface and the second backplane interface respectively include a power terminal, a ground terminal and a differential data terminal. Adjacent IO submodules transmit power through the power terminal and the ground terminal, transmit the enumeration frame and the backplane communication frame through the differential data terminal, and maintain the mechanical connection between adjacent IO submodules through a detachable locking structure.

4. The EtherCAT remote I / O distributed frame loss compensation system according to claim 1, characterized in that, The EtherCAT coupler determines whether valid output process data has been received in the current communication cycle based on at least one of the following: the cyclic redundancy check result of the received frame, the communication cycle timeout status, the EtherCAT working counter, and the process data update flag. The EtherCAT coupler establishes a historical data queue according to the output channel, associates the received valid output process data with the corresponding communication cycle identifier and stores it in the historical data queue, and deletes the earliest data in the historical data queue when new valid output process data is received.

5. The EtherCAT remote I / O distributed frame loss compensation system according to claim 4, characterized in that, The EtherCAT coupler selects the compensation method based on the output channel type and the number of valid output process data in the historical data queue. For analog output channels, when the historical data queue includes valid output process data for multiple consecutive communication cycles, the average change is determined based on the difference between valid output process data for adjacent communication cycles. The sum of the most recent valid output process data and the average change is determined as compensation data, and the compensation data is limited according to the output range and maximum allowable change of the analog output channel. For switch output channels, or output channels where the number of valid output process data in the historical data queue does not reach the preset window length, the most recent valid output process data is determined as compensation data.

6. The EtherCAT remote I / O distributed frame loss compensation system according to claim 1, characterized in that, Each IO submodule is equipped with a channel diagnostic unit and an output control unit. The sampling terminal of the channel diagnostic unit is connected to the corresponding IO channel, and the protection output terminal of the channel diagnostic unit is connected to the enable terminal of the corresponding output control unit. The channel diagnostic unit collects the voltage, current or impedance of each IO channel, and determines the fault status of open circuit, short circuit or overload based on the collection results. Each IO submodule writes the fault status into the corresponding backplane communication time slot. The EtherCAT coupler determines the fault output channel based on the fault status, stops generating compensation data for the fault output channel based on historical valid output process data, and writes preset safe output data into the backplane communication time slot corresponding to the fault output channel. When the channel diagnostic unit detects a short circuit or overload, it sends a protection signal to the output control unit through the protection output terminal, causing the output control unit to shut down the corresponding output channel.

7. An EtherCAT remote I / O distributed frame loss compensation method, characterized in that it is executed by an EtherCAT remote I / O system including an EtherCAT coupler, a backplane communication bus, and multiple I / O sub-modules, the method comprising: The EtherCAT coupler identifies the topology order and channel configuration of each IO submodule, assigns logical identifiers and backplane communication time slots to each IO submodule, and establishes a mapping relationship between output process data items, logical identifiers, backplane communication time slots and output channels. The EtherCAT coupler receives output process data from the EtherCAT master station according to the communication cycle, and caches historical valid output process data according to the output channel; When no valid output process data is received in the current communication cycle, the EtherCAT coupler generates compensation data based on the historical valid output process data corresponding to each output channel, writes the compensation data into the corresponding backplane communication time slot, and sends it through the backplane communication bus. Each IO submodule extracts the compensation data from the corresponding backplane communication time slot and updates the corresponding output channel based on the compensation data; When the EtherCAT coupler recovers and receives valid output process data, it writes the valid output process data into the corresponding backplane communication time slot and sends it through the backplane communication bus. Each IO submodule updates the corresponding output channel according to the valid output process data. The backplane communication bus is a differential ring backplane bus. The backplane communication frame transmitted along the differential ring backplane bus includes a time slot data area corresponding to each logical identifier. The time slot data area includes an output data field and an input data field. Each IO submodule receives and forwards the backplane communication frames in topological order, extracts output process data or compensation data from the output data field corresponding to its own logical identifier, writes the input data collected from its own input channel into the input data field corresponding to its own logical identifier, and transmits the data in other time slot data areas transparently. The EtherCAT coupler receives the backplane communication frames returned after being processed sequentially by each IO submodule.

8. The EtherCAT remote I / O distributed frame loss compensation method according to claim 7, characterized in that, The identification of the topology order and channel configuration of each IO submodule includes: The EtherCAT coupler sends an enumeration frame including the current address field and the module information area; Each IO submodule receives the enumeration frame in topological order, stores the current address field value when receiving the enumeration frame as its own logical identifier, writes a module information record including the logical identifier, module type and channel number in the module information area, and forwards the enumeration frame after incrementing the current address field value. The EtherCAT coupler receives the enumeration frames returned after being processed sequentially by each IO submodule. Based on the module information record, the topology order and channel configuration of each IO submodule are determined, and the backplane communication time slots are allocated according to the topology order and the number of channels.

9. The EtherCAT remote I / O distributed frame loss compensation method according to claim 7, characterized in that, Also includes: Count the number of communication cycles in which no valid output process data is received consecutively; When the number of communication cycles is less than the preset frame loss threshold, compensation data continues to be generated based on historical valid output process data, and the compensation data is limited according to the output range and maximum allowable change of the corresponding output channel. When the number of communication cycles reaches the preset frame loss threshold, the generation of compensation data is stopped, and the preset security output data is written into the corresponding backplane communication time slot. The corresponding IO submodule updates the output channel according to the preset security output data. After recovering and receiving valid output process data, the valid output process data is compared with the current output data of the corresponding output channel. When the difference between the two exceeds a preset switching threshold, the output data of the output channel is adjusted within a continuous communication cycle according to the maximum allowable change amount until the output channel is updated according to the recovered valid output process data.

Citation Information

Patent Citations

  • Servo instruction RBF prediction method for Glink industrial Ethernet synchronization mode data loss

    CN114488946A

  • MECHATROLINK-III-based coupler system and communication method

    CN119299265A