EtherCAT / CANFD hybrid cascade system power supply addressing and data uploading method and device

By adopting a power supply addressing and data upload method for a hybrid EtherCAT/CANFD cascaded system, unified addressing and secure power supply for the EtherCAT network and CANFD subnet are achieved. This solves the problems of address system fragmentation and low data transmission efficiency, improves system stability and adaptability, and simplifies system deployment and maintenance.

CN122001697APending Publication Date: 2026-05-08SHENZHEN TOPRIE ELECTRONICS CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
SHENZHEN TOPRIE ELECTRONICS CO LTD
Filing Date
2026-02-09
Publication Date
2026-05-08

AI Technical Summary

Technical Problem

The EtherCAT network and CANFD subnet use their own independent address allocation mechanisms, resulting in a fragmented system address hierarchy. This makes it difficult to achieve unified addressing and configuration of all network devices, increasing the complexity of system integration and maintenance. The lack of effective aggregation, deduplication, and forwarding mechanisms in periodic data transmission leads to repeated data uploads or low bandwidth utilization. In scenarios where single-line power supply and communication are integrated, the lack of effective safety identification mechanisms means that the accidental insertion of incompatible devices may lead to electrical damage risks.

Method used

The system adopts an EtherCAT/CANFD hybrid cascaded system for power supply addressing and data uploading. It achieves device identification and safe power supply through a single-line power supply and communication fusion link. The gateway node is automatically addressed and uniformly addressed. Data frames are aggregated and deduplicated. The core control node performs deduplication forwarding and monitors power supply status and topology changes in real time, supporting rapid adaptation to topology adjustments.

Benefits of technology

It enables unified addressing and secure power supply for all network devices, improves data transmission efficiency and system stability, reduces maintenance complexity and electrical damage risk, supports rapid topology change adaptation, and simplifies system cabling structure and deployment process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122001697A_ABST
    Figure CN122001697A_ABST
Patent Text Reader

Abstract

The invention provides a power supply addressing and data uploading method and device for an EtherCAT / CANFD hybrid cascade system, and belongs to the technical field of industrial communication and distributed data acquisition. The system is powered on to complete equipment identification and protocol matching in a low-voltage mode, high-voltage power supply is switched after verification is passed, and safe power supply is realized by means of single-line power supply and a communication fusion link; the gateway node automatically addresses the lower CANFD subnet equipment and reports the number of the equipment, the core control node calculates address offset and issues the address offset, and a uniform address space of the whole network is established; the gateway node periodically collects and packs data and transmits the data to the core control node through the EtherCAT channel, and the core control node performs duplicate removal based on a packet sequence number and then forwards the data to the upper computer. The system supports topology self-adaptive adjustment, automatic configuration, unified addressing and efficient and reliable transmission of the hybrid network are achieved, deployment and maintenance cost is reduced, and safety and adaptability are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of industrial communication and distributed data acquisition technology, specifically to a power supply addressing and data uploading method and apparatus for an EtherCAT / CANFD hybrid cascade system. Background Technology

[0002] In the field of industrial automation, industrial control systems often adopt a hierarchical network architecture. The upper layer uses industrial Ethernet such as EtherCAT networks to achieve high-speed real-time control communication, while the lower layer uses fieldbuses such as CANFD subnets to connect distributed acquisition modules, such as attached acquisition modules or actuators. Although this architecture can leverage the advantages of different network technologies, it faces many problems in practical applications.

[0003] The EtherCAT network and CANFD subnet use their own independent address allocation mechanisms, resulting in a fragmented system address hierarchy. This makes it difficult to achieve unified addressing and configuration of all network devices, increasing the complexity of system integration and maintenance. In a cascaded topology, when the number of devices changes, traditional solutions require manual DIP switch settings or software parameter reconfiguration, leading to high maintenance costs and a high risk of errors.

[0004] In periodic data transmission, the lack of effective aggregation, deduplication, and forwarding mechanisms can easily lead to duplicate data uploads or low bandwidth utilization, affecting the system's real-time performance. In scenarios where single-line power supply and communication are integrated, the lack of effective safety identification mechanisms means that the accidental insertion of incompatible devices may pose a risk of electrical damage, and the safety protection requirements of the integrated single-line power supply and communication link are not adequately met.

[0005] In existing technologies, some solutions only focus on solving a single problem and fail to form a comprehensive solution that takes into account unified addressing, automatic configuration, efficient data transmission and safe power supply, thus failing to meet the actual needs of scenarios such as industrial automation and intelligent manufacturing.

[0006] To address this, a power supply addressing and data uploading method and device for an EtherCAT / CANFD hybrid cascade system is proposed. Summary of the Invention

[0007] The present invention aims to solve the problems mentioned in the background art by providing a power supply addressing and data uploading method and apparatus for an EtherCAT / CANFD hybrid cascade system.

[0008] The specific technical solution is as follows: A power supply addressing and data upload method for an EtherCAT / CANFD hybrid cascaded system, applied to a hybrid cascaded system including a core control node, at least one gateway node, and several CANFD subnet devices connected to each gateway node, the method comprising the following steps: Step 1: Safe Power Supply Establishment Phase. Upon initial power-up, the system initiates device identification and protocol matching in low-voltage mode. After successful matching verification, it switches to high-voltage power supply mode, relying on a single-line power supply and communication fusion link to provide safe power supply to devices at all levels. This single-line power supply and communication fusion link simultaneously realizes power transmission and data interaction. The core control node establishes power control and data communication connections with each gateway node through this link, and the gateway node establishes power supply and communication connections with its downstream CANFD subnet devices through this link. Step 2: Subnet automatic addressing stage. Each gateway node initiates addressing interaction with its CANFD subnet devices through the CANFD communication link, performs automatic addressing operation, and obtains the number of devices in the corresponding subnet. Step 3: Unified addressing phase across the network. The core control node collects the number of subnet devices reported by each gateway node through the EtherCAT periodic communication link. Based on this number, it calculates the address offset corresponding to each gateway node and sends it to the gateway node through the EtherCAT data channel. After receiving the address offset, each gateway node associates it with the local address of its own connected devices to establish a unified address space covering all CANFD subnet devices. Step 4: Data acquisition and packaging stage. The gateway node reads the acquired data from the connected CANFD subnet devices in real time through the CANFD communication interface, aggregates the acquired data according to the preset cycle, and packages it into data frames. The field configuration of the data frames is adapted to the subsequent EtherCAT transmission and core control node deduplication requirements. Step 5: Data transmission deduplication stage. The gateway node transmits the packaged data frames to the core control node through the EtherCAT periodic process data channel. The core control node performs deduplication processing on the received data frames based on the preset deduplication rules to ensure that each batch of data is transmitted to the host computer only once. The core control node establishes bidirectional communication with the host computer through the USB interface or Ethernet interface and completes data forwarding.

[0009] The above method, wherein the automatic subnet addressing stage specifically includes the following sub-steps: The gateway node broadcasts addressing instructions to all its connected CANFD subnet devices via the CANFD communication link. The addressing instructions are transmitted through the data stream channel of the single-wire power supply and communication converged link. After receiving the addressing command, the CANFD subnet device sends its unique identification information back to the gateway node through the CANFD communication link; The gateway node collects the unique identification information of all CANFD subnet devices through the CANFD communication interface and sorts the unique identification information according to a preset sorting rule; Based on the sorting results, each CANFD subnet device is assigned a consecutive local address. The local address is bound to a unique identifier and stored. At the same time, the number of devices in the subnet is counted. The gateway node reports the number of subnet devices to the core control node through the EtherCAT communication link.

[0010] In the above method, the address offset is calculated as follows: the address offset of the first gateway node is 0, and the address offset of any other gateway node is equal to the sum of the number of subnet devices corresponding to all gateway nodes before that gateway node; after the core control node calculates the address offset, it sends it to the corresponding gateway node through the EtherCAT periodic process data channel. After receiving it, the gateway node combines the address offset with its local address to form the global address of the subnet device. The global address enables the core control node to directly address any CANFD subnet device through the unified address space of the entire network.

[0011] In the above method, the preset period is a configurable period. The data frame includes a data identifier field, a device identifier field, a packet sequence number field, a data length field, and a data payload field. The data identifier field is used to distinguish the data frame type, the device identifier field is used to identify the gateway node that sent the data frame, the packet sequence number field is used for data deduplication verification, the data length field is used to indicate the actual number of bytes in the data payload field, and the data payload field includes a timestamp, the number of channels, the channel data, and a checksum. After the data frame is encapsulated by the EtherCAT interface module of the gateway node, it is transmitted to the core control node through the EtherCAT periodic process data channel. The field arrangement is adapted to the protocol requirements of the transmission link to ensure transmission stability.

[0012] The above method, wherein the specific implementation process of the data transmission deduplication stage is as follows: the core control node maintains a packet sequence number record of the most recently forwarded data frame for each gateway node, and the packet sequence number record is stored in the cache module of the core control node; After receiving a new data frame through the EtherCAT periodic process data channel, the core control node extracts the device identification field and packet sequence number field from the data frame through the data parsing module. Match the corresponding gateway node based on the device identifier field, find the packet sequence number record corresponding to the gateway node, and compare the packet sequence number of the new data frame with the packet sequence number of the record; If the two are different, it is determined to be new data. The core control node forwards the data frame to the host computer through the USB interface or Ethernet interface and updates the corresponding packet sequence number record in the cache module. If the two are the same, it is determined to be duplicate data, and the core control node directly discards the data frame without performing a forwarding operation.

[0013] The above method, wherein the safe power supply establishment phase further includes a power supply status monitoring mechanism: during system operation, the core control node continuously monitors the working status of the power supply link through the power supply monitoring channel of the single-line power supply and communication converged link, and the gateway node synchronously monitors the power supply parameters of itself and the connected CANFD subnet devices; when overcurrent, short circuit or device connection abnormality is detected, the core control node immediately cuts off the high-voltage power supply and triggers an alarm signal through the power supply control channel, and the alarm signal is synchronized to the host computer through the USB interface or Ethernet interface, while the system maintains the low-voltage identification mode or shuts down the power supply channel.

[0014] The above method further includes a topology adaptive adjustment mechanism: the gateway node detects the connection status of the downstream devices in real time through the CANFD communication link, and the core control node monitors the communication status of the gateway node through the EtherCAT communication link; when the insertion or removal of CANFD subnet devices or communication link abnormality is detected, the core control node automatically triggers the re-execution of the subnet automatic addressing stage and the network-wide unified addressing stage, the gateway node recounts and reports the number of subnet devices, the core control node recalculates the address offset based on the updated number of devices and issues it, and each gateway node updates the mapping relationship between local address and global address, reconstructing the network-wide unified address space.

[0015] In the above method, the fields of the data frame are arranged byte-aligned to adapt to hardware parsing requirements. The data payload field contains a CRC checksum, which is used to verify the integrity of the acquired data during transmission in the CANFD communication link and the EtherCAT periodic process data channel. After receiving the data frame through the EtherCAT interface, the core control node first verifies the validity of the data based on the CRC checksum using the built-in verification module. If the verification is successful, the packet sequence number field is extracted and the above deduplication process is performed. If the verification fails, the data frame is discarded and the fault information is recorded.

[0016] The aforementioned method further includes a communication timeout handling mechanism, in which preset timeout times are set for each stage of secure power supply establishment, automatic subnet addressing, unified network addressing, and data transmission. The core control node and gateway node monitor the execution time of each stage. When an operation in a certain stage is not completed within the corresponding preset timeout time, the system automatically triggers a retry process, and the retry instruction is transmitted through the corresponding communication link. If the number of retries reaches a preset threshold and still fails, the core control node cuts off the high-voltage power supply to the corresponding link and issues an alarm. The alarm information is uploaded to the host computer through a USB interface or Ethernet interface, and the link identifier and stage information of the timeout fault are recorded.

[0017] In the above method, after the core control node issues the address offset, each gateway node calculates its locally managed global address range based on its own address offset and the number of subnet devices using its built-in address verification module. Simultaneously, it receives address range information from other gateway nodes via the EtherCAT communication link to perform address range overlap verification. If the verification passes, the gateway node stores the mapping relationship between the global address and the local address in its local memory, completing the final establishment of a unified address space across the entire network. If the verification fails, the gateway node sends address conflict information back to the core control node via the EtherCAT periodic process data channel. Upon receiving this information, the core control node triggers an address offset recalculation process, reissuing the address offset until the verification passes.

[0018] The above method, wherein the power supply status monitoring mechanism further includes a periodic re-inspection process. After the system is powered on normally, the safety power supply control module collects power supply parameters through the monitoring channel of the single-line power supply and communication converged link at preset time intervals. The power supply parameters include voltage value, current value and link connectivity status. The collected data is transmitted to the processor for analysis. If an abnormal trend of parameters is detected but does not reach the fault threshold, the processor adjusts the power supply parameters through the power management module and reports early warning information to the core control node. The core control node forwards the early warning information to the host computer.

[0019] In the above method, after the topology adaptive adjustment mechanism is triggered, the gateway node first sends a status query command to all downstream devices through the CANFD communication link. After confirming the device connection status, it re-executes automatic addressing. The number of new subnet devices is reported to the core control node through the EtherCAT communication link. After the core control node updates the statistics of the total number of devices in the network, it recalculates the address offset of all gateway nodes and sends it out in sequence. Each gateway node updates its local address mapping table after receiving the data. The entire adjustment process is completed within 5 seconds, ensuring that the system can quickly adapt to topology changes.

[0020] The present invention also provides a power supply addressing and data uploading device for an EtherCAT / CANFD hybrid cascade system, comprising: The EtherCAT interface module is used to establish an EtherCAT master-slave communication connection with the core control node, realize the reception and transmission of data frames and the reception of address offsets, and transmit periodic data with the core control node through the EtherCAT periodic process data channel. The CANFD interface module is used to establish a CANFD communication connection with the connected CANFD subnet devices, enabling the issuance of addressing commands, the reception of unique identification information, and the reading of collected data. It also enables bidirectional data interaction with the subnet devices through the CANFD communication link. The processor is used to execute safe power supply control logic, subnet automatic addressing logic, and data aggregation and packaging logic. The processor establishes bidirectional signal connections with the EtherCAT interface module and the CANFD interface module respectively, receives data transmitted by the interface modules, and outputs control commands. The memory is used to store unique identification information, the number of subnet devices, address offset, preset period parameters, data frame format rules, and program instructions required for processor execution. The memory establishes a bidirectional data interaction connection with the processor, and the processor reads instructions and data from the memory and writes the processing results into the memory.

[0021] The aforementioned apparatus further includes: The power management module is used to switch between low-voltage and high-voltage modes, providing a stable power supply for the device itself and the connected CANFD subnet devices. The power management module establishes a control connection with the processor and receives power supply mode switching commands and fault cut-off commands output by the processor. The safe power supply control module is used to perform device identification, protocol matching verification, and power supply status monitoring. The safe power supply control module establishes bidirectional signal connections with the power management module and the processor respectively, transmits the identification results, verification results, and monitoring data to the processor, and receives control commands from the processor. The safe power supply control module is integrated into the signal processing path of the single-line power supply and communication converged link, and interacts with the core control node and the downstream CANFD subnet devices through this link to exchange power supply control signals.

[0022] In the aforementioned device, the power management module supports a wide voltage input from 9V to 28V. It receives input power through a power supply channel of a single-wire power supply and communication converged link and converts it into the operating voltage required by the device and subnet devices. The power consumption of the device during normal operation is less than 1.2W. The safe power supply handshake process of the safe power supply control module is completed within 100ms. It achieves rapid safe power supply link establishment through low-voltage identification signal interaction with the core control node and protocol matching data transmission. The signal connection between the safe power supply control module and the power management module is used to transmit power supply status monitoring data in real time to ensure the synchronization of power supply mode switching.

[0023] In the aforementioned device, the EtherCAT interface module supports a communication rate of 100Mbps and forms a periodic process data transmission channel with the EtherCAT master station of the core control node. The transmission delay of the data frame is adapted to the preset acquisition period. The CANFD interface module supports a maximum communication rate of 8Mbps and receives the acquisition data from the connected CANFD subnet devices through a polling reading mechanism. The polling command is generated by the processor and issued through the CANFD interface module. The acquisition data is transmitted to the processor for aggregation processing via the CANFD interface module.

[0024] In the aforementioned device, the processor is an ARM Cortex-M series high-performance processor, which is connected to the memory via a high-speed data bus to ensure that the data read and write rate meets the data aggregation and packaging requirements within a preset period. The signal connection between the processor and the EtherCAT interface module and the CANFD interface module adopts an interrupt triggering mechanism. When the interface module receives data or instructions, it notifies the processor to process them through an interrupt signal, thereby improving the real-time performance of data processing.

[0025] The present invention also provides an EtherCAT / CANFD hybrid cascade system, including a core control node, at least one of the above-mentioned EtherCAT / CANFD hybrid cascade system power supply addressing and data uploading devices, and a set of CANFD subnet devices connected to each device; The core control node, as the core of the system, establishes a master-slave communication relationship with the EtherCAT interface modules of each device through the EtherCAT communication link. It is used to receive the number of subnet devices reported by each device, calculate the address offset and send it down, and receive the data frames transmitted by the device and perform deduplication and forwarding. Each device establishes an integrated power supply and communication connection with the CANFD subnet devices below it through a single-line power supply and communication converged link, and performs data acquisition and addressing interaction with the subnet devices through the CANFD interface module; The system is configured to execute the power supply addressing and data upload method of the EtherCAT / CANFD hybrid cascaded system described above, and each component achieves coordinated operation of data transmission, power supply control and command interaction through corresponding communication links and power supply links.

[0026] In the aforementioned system, the core control node has a built-in EtherCAT communication quality monitoring module. This module performs work count verification on the periodic EtherCAT communication between the core control node and each gateway node. The core control node periodically receives work count feedback values ​​from each gateway node through the EtherCAT communication link. When the work count value is detected to be lower than a preset standard value multiple times in a row, the current periodic communication is automatically stopped and the EtherCAT network is reinitialized. The core control node then sends a reconnection command to each gateway node through the EtherCAT interface, and resumes periodic data transmission after re-establishing the master-slave communication connection.

[0027] In the aforementioned system, a single gateway node can connect up to 10 CANFD subnet devices, and the system supports cascading up to 80 gateway nodes, with a total device capacity of up to 800. The EtherCAT interface modules of each gateway node are cascaded through the EtherCAT bus, and the core control node achieves unified management and control of all gateway nodes through this bus. The single-line power supply and communication converged link is implemented using standard network cables, which simultaneously carry power transmission and data interaction between nodes, simplifying the system cabling structure.

[0028] The present invention has the following beneficial effects: (i) Enhanced power supply safety: By using the hierarchical power supply mechanism and continuous monitoring function of the safety power supply control module, combined with the secure transmission characteristics of the single-line power supply and communication convergence link, the risk of electrical damage caused by the access of incompatible equipment is effectively reduced, the safety and reliability of the system power supply are improved, and the stable operation of each component is guaranteed.

[0029] (II) Addressing Configuration Optimization: By leveraging the automatic addressing function of the gateway node and the address offset calculation mechanism of the first node, the address barriers between the EtherCAT network and the CANFD subnet are broken down, enabling unified addressing for all devices in the network. No manual address configuration is required, reducing configuration errors, lowering the complexity of system deployment and maintenance, and improving configuration efficiency.

[0030] (III) High-efficiency data transmission: The periodic aggregation and packaging mechanism of the gateway node and the deduplication and marking mechanism of the first node avoid repeated data uploads and improve bandwidth utilization. The standardized format of the uploaded data frames adapts to the transmission requirements of the PDO periodic process data channel, ensuring the real-time performance and integrity of data transmission and improving the overall data processing efficiency.

[0031] (iv) Flexible Topology Adaptation: Supports hot-swapping and automatic readdressing of downstream acquisition modules, allowing the system to quickly adapt to changes in the number of devices or connection status without interrupting overall operation. The collaborative adjustment mechanism between the first node and the gateway node enhances the system's scalability and environmental adaptability, meeting the topology change requirements of different scenarios.

[0032] (v) Stable and reliable operation: Through multiple safeguards such as fault protection of the safe power supply control module, communication quality monitoring of the first node, and integrity verification of data transmission, abnormalities in power supply, communication, and data transmission are detected and dealt with in a timely manner, reducing the impact of faults on system operation and ensuring long-term stable operation of the system.

[0033] (vi) Wide Deployment and Adaptability: The single-line power supply and communication converged link uses standard network cables, simplifying the system cabling structure and reducing costs. The system supports cascading expansion of multiple gateway nodes and multiple downstream acquisition modules, adapting to various application scenarios such as industrial automation, distributed data acquisition, and laboratory testing. It can be put into use without major modifications, demonstrating strong practicality and adaptability. Attached Figure Description

[0034] Figure 1 A schematic block diagram illustrating the power supply addressing and data upload of an EtherCAT / CANFD hybrid cascaded system provided in this embodiment of the invention; Figure 2 This is a graph showing the relationship between the number of devices and the address allocation time in the power supply addressing and data upload method for the EtherCAT / CANFD hybrid cascaded system provided in this embodiment of the invention. Figure 3 This is a graph showing the relationship between power supply switching time and startup efficiency in the power supply addressing and data upload method for the EtherCAT / CANFD hybrid cascaded system provided in this embodiment of the invention. Figure 4 This is a graph showing the relationship between data aggregation cycle and transmission efficiency in the power supply addressing and data upload method of the EtherCAT / CANFD hybrid cascaded system provided in this embodiment of the invention. Figure 5 The graph shows the relationship between topology response time and system stability in the power supply addressing and data upload method of the EtherCAT / CANFD hybrid cascaded system provided in the embodiments of the present invention. Detailed Implementation

[0035] The technical solution of the present invention will be further described below with reference to the accompanying drawings and specific embodiments.

[0036] The accompanying drawings are for illustrative purposes only and are schematic diagrams, not actual images. They should not be construed as limiting the scope of this application. To better illustrate the embodiments of the present invention, some parts in the drawings may be omitted, enlarged, or reduced, and do not represent the actual dimensions of the product. It is understandable to those skilled in the art that some well-known structures and their descriptions may be omitted in the drawings.

[0037] In the accompanying drawings of the embodiments of the present invention, the same or similar reference numerals correspond to the same or similar components. In the description of the present invention, it should be understood that if terms such as "upper," "lower," "left," "right," "inner," and "outer" indicate the orientation or positional relationship based on the orientation or positional relationship shown in the drawings, they are only for the convenience of describing the present invention and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation. Therefore, the terms used to describe positional relationships in the drawings are only for illustrative purposes and should not be construed as limiting the present application. For those skilled in the art, the specific meaning of the above terms can be understood according to the specific circumstances.

[0038] In the description of this invention, unless otherwise explicitly specified and limited, the term "connection" or similar designation indicating a connection between components should be interpreted broadly. For example, it can refer to a fixed connection, a detachable connection, or an integral part; it can be a mechanical connection or an electrical connection; it can be a direct connection or an indirect connection through an intermediate medium; it can refer to the internal communication between two components or the interaction between two components. Those skilled in the art can understand the specific meaning of the above terms in this invention based on the specific circumstances.

[0039] Reference Figure 1-5 This specific implementation provides the following three embodiments, wherein... Figure 1 This demonstrates the connection relationships between core components during the power supply addressing and data upload process of the EtherCAT / CANFD hybrid cascade system; Figure 2 The demonstration showed that as the number of devices increased, the address allocation time increased linearly, reflecting the relationship between the load and time consumption during the initialization phase. Figure 3 The results show that for every 1ms increase in switching time, startup efficiency decreases by 0.2%. Figure 4 It shows that the transmission efficiency reaches its peak (nearly 100%) when the period is about 20ms, and the efficiency drops sharply (to -60%) when the period is too long (>30ms). Figure 5 The results show that for every 1 second increase in response time, the stability score decreases by approximately 1.2 points (100 → 88).

[0040] This embodiment provides a power supply addressing and data upload method for an EtherCAT / CANFD hybrid cascaded system, applicable to a hybrid cascaded system comprising a core control node, at least one gateway node, and several CANFD subnet devices connected to each gateway node. The method includes the following steps: Step 1: Safe Power Supply Establishment Phase. Upon initial power-up, the system initiates device identification and protocol matching in low-voltage mode. After successful matching verification, it switches to high-voltage power supply mode, relying on a single-line power supply and communication converged link to provide safe power supply to devices at all levels. This link simultaneously enables power transmission and data interaction. The core control node establishes power control and data communication connections with each gateway node through this link, and the gateway node establishes power supply and communication connections with its downstream CANFD subnet devices through this link. Step 2: Subnet automatic addressing stage. Each gateway node initiates addressing interaction with its CANFD subnet devices through the CANFD communication link, performs automatic addressing operation, and obtains the number of devices in the corresponding subnet. Step 3: Unified addressing phase across the network. The core control node collects the number of subnet devices reported by each gateway node through the EtherCAT periodic communication link. Based on this number, it calculates the address offset corresponding to each gateway node and sends it to the gateway node through the EtherCAT data channel. After receiving the address offset, each gateway node associates it with the local address of its own connected devices to establish a unified address space covering all CANFD subnet devices. Step 4: Data acquisition and packaging stage. The gateway node reads the acquired data from the connected CANFD subnet devices in real time through the CANFD communication interface, aggregates the acquired data according to the preset cycle, and packages it into data frames. The field configuration of the data frames is adapted to the subsequent EtherCAT transmission and core control node deduplication requirements. Step 5: Data transmission deduplication stage. The gateway node transmits the packaged data frames to the core control node through the EtherCAT periodic process data channel. The core control node performs deduplication processing on the received data frames based on the preset deduplication rules to ensure that each batch of data is transmitted to the host computer only once. The core control node establishes bidirectional communication with the host computer through the USB interface or Ethernet interface and completes data forwarding.

[0041] This solution enables the coordinated operation of power supply safety and data transmission in a hybrid cascaded system, breaks down address barriers between different network types, achieves unified access for all network devices, reduces redundant content in data transmission, improves data transmission efficiency, and simplifies system cabling and overall deployment processes.

[0042] Specifically, in this embodiment, the automatic subnet addressing stage includes the following sub-steps: The gateway node broadcasts addressing instructions to all its connected CANFD subnet devices via the CANFD communication link. The addressing instructions are transmitted through the data stream channel of the single-wire power supply and communication converged link. After receiving the addressing command, the CANFD subnet device sends its unique identification information back to the gateway node through the CANFD communication link; The gateway node collects the unique identification information of all CANFD subnet devices through the CANFD communication interface and sorts the unique identification information according to a preset sorting rule; Based on the sorting results, each CANFD subnet device is assigned a consecutive local address. The local address is bound to a unique identifier and stored. At the same time, the number of devices in the subnet is counted. The gateway node reports the number of subnet devices to the core control node through the EtherCAT communication link.

[0043] This solution enables subnet devices connected to the gateway node to obtain ordered and unique local addresses, ensuring accurate addressing of devices within the subnet, laying the foundation for unified addressing across the entire network, and reducing the operational complexity of manually configuring addresses.

[0044] Specifically, in this embodiment, the address offset is calculated as follows: the address offset of the first gateway node is 0, and the address offset of any other gateway node is equal to the sum of the number of subnet devices corresponding to all gateway nodes before that gateway node; after the core control node calculates the address offset, it sends it to the corresponding gateway node through the EtherCAT periodic process data channel. After receiving it, the gateway node combines the address offset with its local address to form the global address of the subnet device. The global address enables the core control node to directly address any CANFD subnet device through the unified address space of the entire network.

[0045] This scheme achieves a smooth mapping from the local address of each gateway node to the global address through explicit offset calculation logic, ensuring that there is no overlap in the address space of the entire network, achieving accurate addressing of devices across subnets, and improving the orderliness of system address management.

[0046] Specifically, in this embodiment, the preset period is a configurable period. The data frame includes a data identifier field, a device identifier field, a packet sequence number field, a data length field, and a data payload field. The data identifier field is used to distinguish the data frame type, the device identifier field is used to identify the gateway node that sent the data frame, the packet sequence number field is used for data deduplication verification, the data length field is used to indicate the actual number of bytes in the data payload field, and the data payload field includes a timestamp, the number of channels, the channel data, and a checksum. After the data frame is encapsulated by the EtherCAT interface module of the gateway node, it is transmitted to the core control node through the EtherCAT periodic process data channel. The field arrangement is adapted to the protocol requirements of the transmission link to ensure transmission stability.

[0047] The standardized data frame structure of this solution adapts to the needs of different transmission links, ensures the consistency of data parsing, and the configurable period meets the real-time requirements of different application scenarios. The clear division of labor among the fields ensures the integrity and distinguishability of data transmission.

[0048] Specifically, in this embodiment, the data transmission deduplication stage is implemented as follows: the core control node maintains a record of the sequence number of the most recently forwarded data frame for each gateway node, and the sequence number record is stored in the cache module of the core control node. After receiving a new data frame through the EtherCAT periodic process data channel, the core control node extracts the device identification field and packet sequence number field from the data frame through the data parsing module. Match the corresponding gateway node based on the device identifier field, find the packet sequence number record corresponding to the gateway node, and compare the packet sequence number of the new data frame with the packet sequence number of the record; If the two are different, it is determined to be new data. The core control node forwards the data frame to the host computer through the USB interface or Ethernet interface and updates the corresponding packet sequence number record in the cache module. If the two are the same, it is determined to be duplicate data, and the core control node directly discards the data frame without performing a forwarding operation.

[0049] This scheme avoids transmitting duplicate data to the host computer through serial number verification, reduces the data processing pressure on the host computer, saves transmission bandwidth, and ensures the uniqueness and efficiency of data transmission.

[0050] Specifically, in this embodiment, the safe power supply establishment phase also includes a power supply status monitoring mechanism: during system operation, the core control node continuously monitors the working status of the power supply link through the power supply monitoring channel of the single-line power supply and communication converged link, and the gateway node synchronously monitors the power supply parameters of itself and the connected CANFD subnet devices; when an overcurrent, short circuit or device connection abnormality is detected, the core control node immediately cuts off the high-voltage power supply and triggers an alarm signal through the power supply control channel. The alarm signal is synchronized to the host computer through the USB interface or Ethernet interface, while the system maintains the low-voltage identification mode or shuts down the power supply channel.

[0051] This solution monitors the power supply link status in real time, responds promptly to power supply anomalies, avoids damage to equipment caused by abnormal power supply, improves the safety and stability of the system power supply, and reduces equipment operation risks.

[0052] Specifically, in this embodiment, the method further includes a topology adaptive adjustment mechanism: the gateway node detects the connection status of the downstream devices in real time through the CANFD communication link, and the core control node monitors the communication status of the gateway node through the EtherCAT communication link; when the insertion or removal of CANFD subnet devices or communication link abnormality is detected, the core control node automatically triggers the re-execution of the subnet automatic addressing stage and the network-wide unified addressing stage, the gateway node recounts and reports the number of subnet devices, the core control node recalculates the address offset based on the updated number of devices and sends it down, and each gateway node updates the mapping relationship between the local address and the global address, reconstructing the network-wide unified address space.

[0053] This solution enables the system to automatically adapt to changes in device connection status, complete address reconstruction without manual intervention, improve the system's adaptability to topology changes, and reduce system maintenance costs.

[0054] Specifically, in this embodiment, the fields of the data frame are arranged byte-aligned to adapt to hardware parsing requirements. The data payload field contains a CRC checksum, which is used to verify the integrity of the collected data during transmission in the CANFD communication link and the EtherCAT periodic process data channel. After the core control node receives the data frame through the EtherCAT interface, it first verifies the validity of the data based on the CRC checksum using the built-in verification module. If the verification is successful, the packet sequence number field is extracted and the above deduplication process is performed. If the verification fails, the data frame is discarded and the fault information is recorded.

[0055] This solution adds an integrity check before data deduplication to prevent invalid or corrupted data from entering subsequent processing, ensuring the reliability of transmitted data and reducing the waste of processing resources caused by data corruption.

[0056] Specifically, in this embodiment, the method also includes a communication timeout handling mechanism. Preset timeout times are set for each stage of secure power supply establishment, automatic subnet addressing, unified network addressing, and data transmission. The core control node and gateway node monitor the operation execution time of each stage. When an operation in a certain stage is not completed within the corresponding preset timeout time, the system automatically triggers a retry process, and the retry instruction is transmitted through the corresponding communication link. If the number of retries reaches a preset threshold and still fails, the core control node cuts off the high-voltage power supply to the corresponding link and issues an alarm. The alarm information is uploaded to the host computer through a USB interface or Ethernet interface, and the link identifier and stage information of the timeout fault are recorded at the same time.

[0057] This solution implements time control for each communication stage, promptly addresses communication delays or failures, and enhances the system's fault response capabilities through retry and alarm mechanisms, ensuring the continuity of system operation.

[0058] Specifically, in this embodiment, after the core control node issues the address offset, each gateway node calculates its local global address range based on its own address offset and the number of devices in the subnet using its built-in address verification module. Simultaneously, it receives address range information from other gateway nodes via the EtherCAT communication link to perform address range overlap verification. If the verification passes, the gateway node stores the mapping relationship between the global address and the local address in its local memory, completing the final establishment of a unified address space across the entire network. If the verification fails, the gateway node sends address conflict information back to the core control node via the EtherCAT periodic process data channel. Upon receiving this information, the core control node triggers the address offset recalculation process and reissues the address offset until the verification passes.

[0059] This scheme avoids address overlap between different gateway nodes through address range verification, ensuring the uniqueness of the entire network address space. The recalculation mechanism after a conflict improves the accuracy of address allocation and enhances the reliability of system address management.

[0060] Specifically, in this embodiment, the power supply status monitoring mechanism also includes a periodic re-inspection process. After the system is powered on normally, the safety power supply control module collects power supply parameters through the monitoring channel of the single-line power supply and communication converged link at preset time intervals. The power supply parameters include voltage value, current value and link connectivity status. The collected data is transmitted to the processor for analysis. If an abnormal trend of parameters is detected but the fault threshold is not reached, the processor adjusts the power supply parameters through the power management module and reports early warning information to the core control node. The core control node forwards the early warning information to the host computer.

[0061] This solution involves periodic re-inspection to continuously monitor the power supply status, detect potential power supply anomalies in advance, and prevent the escalation of faults through parameter adjustment and early warning mechanisms, thereby ensuring the continuous stability of the system's power supply.

[0062] Specifically, in this embodiment, after the topology adaptive adjustment mechanism is triggered, the gateway node first sends a status query command to all downstream devices through the CANFD communication link. After confirming the device connection status, it re-executes automatic addressing. The number of new subnet devices is reported to the core control node through the EtherCAT communication link. After the core control node updates the statistics of the number of devices in the entire network, it recalculates the address offset of all gateway nodes and sends it out in sequence. After receiving it, each gateway node updates its local address mapping table. The entire adjustment process is completed within 5 seconds, ensuring that the system can quickly adapt to topology changes.

[0063] The standardized topology adjustment process of this solution ensures that the system can quickly adapt to changes in the addition or removal of devices, complete address mapping updates in a short time, ensure the continuity of system operation, and improve the ease of system operation and maintenance.

[0064] This embodiment discloses a power supply addressing and data uploading device for an EtherCAT / CANFD hybrid cascade system, comprising: an EtherCAT interface module, a CANFD interface module, a processor, and a memory, wherein: The EtherCAT interface module is used to establish an EtherCAT master-slave communication connection with the core control node, realize the reception and transmission of data frames and the reception of address offsets, and transmit periodic data with the core control node through the EtherCAT periodic process data channel. The CANFD interface module is used to establish a CANFD communication connection with the connected CANFD subnet devices, enabling the issuance of addressing commands, the reception of unique identification information, and the reading of collected data. It also enables bidirectional data interaction with the subnet devices through the CANFD communication link. The processor is used to execute safe power supply control logic, subnet automatic addressing logic, and data aggregation and packaging logic. The processor establishes bidirectional signal connections with the EtherCAT interface module and the CANFD interface module respectively, receives data transmitted by the interface modules and outputs control commands. The memory is used to store unique identification information, the number of subnet devices, address offset, preset period parameters, data frame format rules, and program instructions required by the processor. The memory establishes a bidirectional data interaction connection with the processor, and the processor reads instructions and data from the memory and writes the processing results into the memory.

[0065] This solution provides hardware support for address management, data processing, and transmission in hybrid cascaded systems through the collaborative work of various modules, ensuring the effective implementation of related methods and improving the adaptability and data processing capabilities of the device.

[0066] Specifically, in this embodiment, it also includes: a power management module and a safe power supply control module, wherein: The power management module is used to switch between low-voltage and high-voltage modes, providing a stable power supply for the device itself and the connected CANFD subnet devices. The power management module establishes a control connection with the processor and receives power supply mode switching commands and fault cut-off commands output by the processor. The safe power supply control module is used to perform device identification, protocol matching verification, and power supply status monitoring. The safe power supply control module establishes bidirectional signal connections with the power management module and the processor respectively, transmits identification results, verification results, and monitoring data to the processor, and receives control commands from the processor. The safe power supply control module is integrated into the signal processing path of the single-line power supply and communication converged link, and interacts with the core control node and the downstream CANFD subnet devices through this link to exchange power supply control signals.

[0067] This solution enables flexible switching and safety verification of power supply modes, strengthens the power supply safety management capabilities of the device, ensures stable power supply for the device itself and its downstream equipment, and improves the reliability of device operation.

[0068] Specifically, in this embodiment, the power management module supports a wide voltage input from 9V to 28V. It receives the input power through the power supply channel of the single-wire power supply and communication converged link and converts it into the operating voltage required by the device and subnet devices. The power consumption of the device during normal operation is less than 1.2W. The safe power supply handshake process of the safe power supply control module is completed within 100ms. The fast safe power supply link is established through low-voltage identification signal interaction with the core control node and protocol matching data transmission. The signal connection between the safe power supply control module and the power management module is used to transmit power supply status monitoring data in real time to ensure the synchronization of power supply mode switching.

[0069] This solution features a wide voltage input to adapt to different power supply environments, which can improve the adaptability of the device to different usage scenarios. The fast and safe power supply handshake process ensures the efficiency and safety of power supply establishment and can reduce the power consumption of the device during operation.

[0070] Specifically, in this embodiment, the EtherCAT interface module supports a communication rate of 100Mbps, forming a periodic process data transmission channel with the EtherCAT master station of the core control node, and the transmission delay of the data frame is adapted to the preset acquisition period; the CANFD interface module supports a maximum communication rate of 8Mbps, and receives the acquisition data of the connected CANFD subnet devices through a polling reading mechanism. The polling command is generated by the processor and issued through the CANFD interface module. The acquisition data is transmitted to the processor through the CANFD interface module for aggregation processing.

[0071] This solution supports interfaces with adaptable rates to meet the speed requirements of data transmission at different levels. The polling reading mechanism ensures the timeliness and orderliness of data collection from subnet devices, thereby improving the overall performance of device data collection and transmission.

[0072] Specifically, in this embodiment, the processor adopts a high-performance ARM Cortex-M series processor and is connected to the memory through a high-speed data bus to ensure that the data read and write rate meets the data aggregation and packaging requirements within a preset period; the signal connection between the processor and the EtherCAT interface module and the CANFD interface module adopts an interrupt triggering mechanism. When the interface module receives data or instructions, it notifies the processor to process them through an interrupt signal, thereby improving the real-time performance of data processing.

[0073] In this solution, a high-performance processor and a high-speed data bus improve data processing and read / write speeds, while an interrupt triggering mechanism ensures the real-time performance of interface data processing, guaranteeing that the device completes data processing tasks within a preset period.

[0074] This embodiment provides an EtherCAT / CANFD hybrid cascade system, including a core control node, at least one EtherCAT / CANFD hybrid cascade system power supply addressing and data upload device as in Embodiment 2, and a set of CANFD subnet devices connected to each device; The core control node, as the core of the system, establishes a master-slave communication relationship with the EtherCAT interface modules of each device through the EtherCAT communication link. It is used to receive the number of subnet devices reported by each device, calculate the address offset and send it down, and receive the data frames transmitted by the device and perform deduplication and forwarding. Each device establishes an integrated power supply and communication connection with the CANFD subnet devices below it through a single-line power supply and communication converged link, and performs data acquisition and addressing interaction with the subnet devices through the CANFD interface module; The system is configured to execute the power supply addressing and data uploading method of the EtherCAT / CANFD hybrid cascaded system according to any one of claims 1 to 7, wherein each component realizes the coordinated operation of data transmission, power supply control and command interaction through the corresponding communication link and power supply link.

[0075] This solution integrates core control nodes, related devices, and subnet equipment to form a complete hybrid cascaded operation system, ensuring the coordinated realization of functions such as safe power supply, automatic addressing, and data transmission, thereby improving the overall operating efficiency and compatibility of the system.

[0076] Specifically, in this embodiment, the core control node has a built-in EtherCAT communication quality monitoring module. This module performs work count verification on the EtherCAT periodic communication between the core control node and each gateway node. The core control node periodically receives the work count feedback value from each gateway node through the EtherCAT communication link. When the work count value is detected to be lower than the preset standard value for multiple consecutive times, the current periodic communication is automatically stopped and the EtherCAT network is reinitialized. The core control node sends a reconnection command to each gateway node through the EtherCAT interface, and resumes periodic data transmission after re-establishing the master-slave communication connection.

[0077] This solution monitors the communication quality of the EtherCAT link in real time, promptly detects and repairs communication anomalies, ensures the stability of periodic data transmission, and reduces the impact of communication failures on system operation.

[0078] Specifically, in this embodiment, a single gateway node can connect up to 10 CANFD subnet devices, and the system supports a maximum of 80 cascaded gateway nodes, with a total device capacity of up to 800. The EtherCAT interface modules of each gateway node are cascaded through the EtherCAT bus, and the core control node achieves unified management and control of all gateway nodes through this bus. The single-line power supply and communication converged link is implemented using standard network cables, which simultaneously carry power transmission and data interaction between nodes, simplifying the system cabling structure.

[0079] This solution supports multi-node and multi-device cascading expansion, improving the application coverage of the system. The use of standard network cables simplifies system cabling costs and difficulties, and enhances the deployment flexibility of the system.

[0080] Specifically, in this embodiment, the preset period is a dynamically adjustable period, calculated using the following adaptive adjustment equation: ; in: T: Dynamic acquisition period (unit: ms); Minimum allowed data acquisition period (ms), range: 5-20ms; acquisition method: system configuration parameters; adjustment suggestion: set according to the data processing capability of the gateway processor. A smaller value can be set for stronger processing capabilities to improve real-time performance. : Maximum allowed acquisition period (ms); Value range: 50~200ms; Acquisition method: System configuration parameters; Adjustment suggestion: Set according to the overall real-time requirements of the system. For systems with high real-time requirements, a smaller maximum value should be set. : The number of CANFD subnet devices connected to the current gateway node, with a value range of 1 to 1. Acquisition method: Automatically obtained from the gateway's local addressing table; Adjustment suggestion: The system should be automatically updated to reflect the real-time device scale; Maximum number of devices supported by a single gateway; value range: constant (e.g., 10); acquisition method: hardware design parameters; adjustment suggestion: set according to the gateway's physical interface capabilities and processing power; Packet loss rate of the most recent data transmission (range 0-1), obtained by statistical analysis of the results of the most recent N transmissions; adjustment suggestion: periodic update, a key indicator for evaluating network communication quality; Current EtherCAT link load rate (range 0-1), obtained through periodic sampling by the EtherCAT interface monitoring module; adjustment suggestion: periodic update to detect main network communication pressure; Topology stability coefficient, ranging from 0.5 to 1.0, reflects the current stability of subnet device connections; acquisition method: dynamic calculation; adjustment suggestion: initial value is 1. When devices are added or removed, the system automatically reduces this value to temporarily extend the cycle and reduce the load, and then gradually restores it to 1 over time. α, β, γ: Weighting coefficients, satisfying α+β+γ=1, used to adjust the degree of influence of each factor on the cycle; α: Device Quantity Weighting System; Meaning: The weight of the number of devices in the current subnet in load calculation; Value range: 0.4~0.6; Acquisition method: System configuration parameters; Adjustment suggestion: When the number of connected devices has a significant impact on system load, this value can be appropriately increased. β: Packet loss rate weighting coefficient, meaning: the weight of the impact of network transmission packet loss rate in load calculation; value range: 0.2~0.4; acquisition method: system configuration parameter; adjustment suggestion: when the network condition is unstable and packet loss has a significant impact on the system, this value should be increased; γ: EtherCAT load weighting coefficient, meaning: the weight of the EtherCAT main network communication load rate in load calculation; value range: 0.2~0.4; acquisition method: system configuration parameter; adjustment suggestion: when the system is more sensitive to the load fluctuation of the EtherCAT main network, this value can be increased.

[0081] The derivation of the equation is as follows: The equation is constructed based on the following system observation and control principles: 1. Normalization processing: Number of devices Divide by Normalize to the range of 0 to 1 to avoid excessive influence of a single parameter on the adjustment results.

[0082] 2. Load-sensitive adjustment: Molecular part The overall load index is calculated, and a higher value indicates a higher system load. When the load index increases, the acquisition cycle T should be extended to reduce the processing and transmission pressure.

[0083] 3. Topological stability compensation: Introducing the denominator When topologically unstable ( When the ratio is smaller, the ratio increases, causing T to tend towards This avoids frequent addressing and data transmission conflicts.

[0084] 4. Boundary control: pass Limit the ratio to no more than 1, ensuring that T is always within [ Within the range.

[0085] When the load index is 0 and the topology is stable To achieve maximum real-time performance.

[0086] When the load index is close to or exceeds When T approaches This provides ample time for data aggregation.

[0087] Example: Assume the system parameters are set as follows: =10ms; =100ms; =10; α=0.5, β=0.3, γ=0.2; =0.8 (current topology is relatively stable); if the current state of a gateway node is: =8; =0.05; =0.4; Substitute into the equation to calculate: Load index = ; ; ; ; ms; Therefore, the gateway node will use a collection period of approximately 65.7ms to ensure real-time performance while avoiding network overload.

[0088] The technical advantages of this solution: 1. Adaptive load balancing: Dynamically adjusts the data collection cycle based on real-time network conditions to avoid data accumulation or network congestion.

[0089] 2. Improve transmission reliability: Automatically reduce frequency when packet loss rate is high to reduce duplicate transmissions and resource waste.

[0090] 3. Enhance system stability: Extend the cycle when the topology changes to avoid addressing and data transmission conflicts.

[0091] 4. Optimize the balance between real-time performance and efficiency: Maximize bandwidth utilization while ensuring timely data upload.

[0092] 5. Reduced configuration complexity: No need to manually set fixed cycles, the system automatically adapts to changes in the operating environment.

[0093] Working principle and process This adaptive adjustment mechanism is integrated into the processor of the gateway node and operates according to the following process; At the start of the data collection cycle, data is first collected and packaged, then transmitted to the target system, and the packet loss rate in the transmission statistics is updated. .

[0094] Next, system parameters are collected, and the load index is calculated based on these parameters. Based on the load index, the system calculates a new acquisition period T_new.

[0095] Then it is determined whether the difference between T_new and the current period T_cur exceeds 10%.

[0096] If the difference exceeds 10%, update the acquisition timer and adjust the period to T_new; If the difference does not exceed 10%, the current collection cycle will remain unchanged.

[0097] Finally, the system enters the next data collection cycle and repeats the above process.

[0098] Working principle: This system achieves secure and stable operation of the hybrid cascaded network through the coordinated operation of its various components. The specific logic is as follows: (a) Safe power supply logic After the system powers on, the safety power supply control module initiates low-voltage mode, performing device identification and protocol matching via a single-wire power supply and communication converged link. The safety power supply control module verifies device compatibility and communication adaptability; upon successful verification, it triggers a switch to high-voltage power supply mode, where the single-wire power supply and communication converged link simultaneously handles power transmission and data interaction. During operation, the safety power supply control module continuously monitors the power supply status, immediately cutting off high-voltage power upon detecting any anomalies to ensure the safety of the first node, gateway node, and downstream acquisition modules.

[0099] (II) Addressing and Addressing Logic The gateway node broadcasts addressing commands to its downstream acquisition modules via the CANFD subnet, collects the unique identifiers of each module, sorts them according to preset rules, assigns a contiguous local address to each module, and simultaneously counts the number of devices within the subnet and reports this count to the first node via the EtherCAT network. The first node calculates the corresponding address offset based on the number of devices reported by each gateway node and sends this offset to the corresponding gateway node via the EtherCAT network. The gateway node combines the local address with the offset to form a unified address space across the entire network, enabling the first node to accurately address any downstream acquisition module using a global address.

[0100] (III) Data Transmission Logic The gateway node periodically reads the collected data from the downstream acquisition modules through the CANFD subnet, aggregates and packages it into upload data frames according to a fixed format. The upload data frame includes fields such as data identifier, device identifier, packet sequence number, data length, and data payload, and is transmitted to the first node through the PDO periodic process data channel. The first node maintains a sequence number record of uploaded data at the gateway node level using deduplication tags. Upon receiving a new upload data frame, it extracts the packet sequence number and compares it with the record, forwarding only the new data with the updated sequence number to avoid duplicate transmission. Finally, it forwards the data to the host computer via the USB uplink interface or Ethernet uplink interface.

[0101] (iv) Topology Adaptive Logic The gateway node monitors the connection status of the connected acquisition modules in real time via the CANFD subnet, while the first node monitors the communication status of the gateway node via the EtherCAT network. When a device insertion, removal, or communication anomaly is detected, the first node automatically triggers a readdressing process. The gateway node recounts and reports the number of devices, the first node recalculates and distributes the address offset, and the gateway node updates the mapping relationship between the local address and the global address to achieve topology adaptation.

[0102] How to use: (I) System Deployment According to application requirements, a cascaded topology is constructed using standard network cables. The first node, gateway node, and downstream acquisition modules are connected through a single-wire power supply and communication integrated link to ensure smooth communication between all components. The gateway node and the corresponding downstream acquisition module form a one-to-one communication association. The host computer is connected to the first node through a USB uplink interface or an Ethernet uplink interface.

[0103] (ii) Power-on start Upon system power connection, the first node, gateway node, and downstream acquisition modules are powered on sequentially. The safety power supply control module automatically initiates the low-voltage identification process, completing device identification and protocol matching through a single-line power supply and communication converged link. After successful verification, it automatically switches to high-voltage power supply mode, establishes a stable power supply link, and the system enters standby mode.

[0104] (III) Automatic Configuration After the system is powered on, no manual intervention is required. The addressing and addressing process is executed automatically: the gateway node completes the local device addressing and reports the number of devices, the first node calculates and sends out the address offset, and each gateway node completes the address mapping, quickly establishing a unified address space for the entire network, enabling devices to be used as plug and play.

[0105] (iv) Data Acquisition and Processing After the system is running stably, the gateway node collects data from the connected acquisition modules through the CANFD subnet at a preset cycle, packages the data, and transmits it to the first node through the PDO periodic process data channel. After the first node completes data deduplication, it forwards the data to the host computer through the USB uplink interface or Ethernet uplink interface. The host computer then displays, stores, and performs subsequent analysis of the data.

[0106] (v) Topology Adjustment When adding, replacing, or removing downstream acquisition modules, simply plug and unplug the devices. Upon detecting a topology change, the system automatically triggers a re-addressing and relocation process, requiring no manual parameter configuration, quickly updating the address mapping, and restoring normal operation.

[0107] (vi) Maintenance and monitoring During system operation, the safety power supply control module monitors the power supply status in real time, while the first node monitors the EtherCAT network communication quality. In the event of an anomaly, the system automatically triggers an alarm, which is then uploaded to the host computer via the USB uplink interface or Ethernet uplink interface. Maintenance personnel can then use the alarm information to specifically troubleshoot the first node, gateway node, downstream acquisition modules, or link failures.

[0108] In summary, the power supply addressing and data upload method and apparatus for the EtherCAT / CANFD hybrid cascade system provided in this embodiment have the following advantages: (i) Enhanced power supply safety: By using the hierarchical power supply mechanism and continuous monitoring function of the safety power supply control module, combined with the secure transmission characteristics of the single-line power supply and communication convergence link, the risk of electrical damage caused by the access of incompatible equipment is effectively reduced, the safety and reliability of the system power supply are improved, and the stable operation of each component is guaranteed.

[0109] (II) Addressing Configuration Optimization: By leveraging the automatic addressing function of the gateway node and the address offset calculation mechanism of the first node, the address barriers between the EtherCAT network and the CANFD subnet are broken down, enabling unified addressing for all devices in the network. No manual address configuration is required, reducing configuration errors, lowering the complexity of system deployment and maintenance, and improving configuration efficiency.

[0110] (III) High-efficiency data transmission: The periodic aggregation and packaging mechanism of the gateway node and the deduplication and marking mechanism of the first node avoid repeated data uploads and improve bandwidth utilization. The standardized format of the uploaded data frames adapts to the transmission requirements of the PDO periodic process data channel, ensuring the real-time performance and integrity of data transmission and improving the overall data processing efficiency.

[0111] (iv) Flexible Topology Adaptation: Supports hot-swapping and automatic readdressing of downstream acquisition modules, allowing the system to quickly adapt to changes in the number of devices or connection status without interrupting overall operation. The collaborative adjustment mechanism between the first node and the gateway node enhances the system's scalability and environmental adaptability, meeting the topology change requirements of different scenarios.

[0112] (v) Stable and reliable operation: Through multiple safeguards such as fault protection of the safe power supply control module, communication quality monitoring of the first node, and integrity verification of data transmission, abnormalities in power supply, communication, and data transmission are detected and dealt with in a timely manner, reducing the impact of faults on system operation and ensuring long-term stable operation of the system.

[0113] (vi) Wide Deployment and Adaptability: The single-line power supply and communication converged link uses standard network cables, simplifying the system cabling structure and reducing costs. The system supports cascading expansion of multiple gateway nodes and multiple downstream acquisition modules, adapting to various application scenarios such as industrial automation, distributed data acquisition, and laboratory testing. It can be put into use without major modifications, demonstrating strong practicality and adaptability.

[0114] In addition, this application also provides the following example: a distributed industrial temperature acquisition system.

[0115] I. Technical Solution This example demonstrates a distributed industrial temperature acquisition system based on the power supply addressing and data uploading method and device of the EtherCAT / CANFD hybrid cascade system, which is suitable for multi-point temperature monitoring scenarios in large production workshops.

[0116] The system consists of: one core control node, 10 gateway nodes, 80 CANFD subnet devices (temperature acquisition modules), a host computer, and several standard network cables. The core control node establishes master-slave communication with each gateway node via an EtherCAT communication link. Each gateway node connects eight temperature acquisition modules via a single-wire power supply and communication integrated link, forming 10 CANFD subnets. The core control node is equipped with USB and Ethernet interfaces for bidirectional communication with the host computer. Each gateway node integrates an EtherCAT interface module, a CANFD interface module, a processor, memory, a power management module, and a safety power supply control module. The processor uses an ARM Cortex-M series, and the memory stores addressing data, address offsets, and program instructions.

[0117] The system operates according to the following process: 1. Establishment of safe power supply: After the system is powered on, the safe power supply control module starts the low-voltage mode, initiates device identification and protocol matching through the single-line power supply and communication converged link, and switches to high-voltage power supply after the verification is successful, while continuously monitoring the power supply status.

[0118] 2. Automatic Subnet Addressing: Each gateway node broadcasts addressing instructions through the CANFD communication link, collects the unique identification information of the connected temperature acquisition modules, assigns consecutive local addresses after sorting by the identification information values, counts the number of subnet devices, and reports to the core control node.

[0119] 3. Unified addressing across the network: The core control node receives the number of devices reported by each gateway node, calculates the address offset (the first gateway node has an offset of 0, the second has 8, the third has 16, and so on), and sends it to the corresponding gateway node. The gateway node combines the local address with the offset to form a global address.

[0120] 4. Data Acquisition and Transmission: The gateway node collects temperature data from the temperature acquisition module according to a preset cycle, aggregates and packages it into standard data frames (including data identifier, device identifier, packet number, data length, and data payload), and transmits it to the core control node through the EtherCAT periodic process data channel.

[0121] 5. Data deduplication and forwarding: The core control node maintains packet sequence number records at the gateway node level. After receiving a data frame, it compares the sequence number and only forwards new data to the host computer. The system supports topology adaptation. When the temperature acquisition module is plugged in or unplugged or communication is abnormal, the re-addressing and relocation process is automatically triggered.

[0122] 6. Auxiliary protection mechanism: The system sets a communication timeout period, and automatically retryes after each stage of operation times out. If the retry fails, the power supply to the corresponding link is cut off and an alarm is triggered. The core control node performs work count verification on the EtherCAT periodic communication to ensure communication quality.

[0123] II. Working Principle (a) Safe power supply logic The safety power supply control module first performs device identity and protocol compatibility verification in low-voltage mode to prevent electrical damage caused by incompatible devices. After successful verification, the power management module responds to the processor's command to switch to high-voltage power supply, with the single-line power supply and communication converged link transmitting power and data simultaneously. During operation, the safety power supply control module collects power supply voltage and current parameters in real time and transmits them to the processor for analysis. If anomalies such as overcurrent or short circuit are detected, the processor immediately instructs the power management module to cut off the high-voltage power supply, triggering an alarm and maintaining low-voltage mode.

[0124] (II) Addressing and Addressing Logic The gateway node processor broadcasts addressing commands via the CANFD interface module. Upon receiving these commands, the temperature acquisition modules return unique identifiers. The processor collects the information, sorts it in ascending order of value, assigns a local address (1-8) to each module, counts the number of devices (8), and reports this count to the core control node via the EtherCAT interface module. The core control node receives the device count from the 10 gateway nodes (each with 8 devices), calculates the offset according to an accumulation rule, and sends it out. The gateway nodes add their local addresses to the offsets to form a global address (8-80). The core control node can directly address any temperature acquisition module using this global address.

[0125] (III) Data Transmission Logic The gateway node processor polls the temperature data from the connected temperature acquisition modules via the CANFD interface module at a preset cycle. After aggregating the data from the eight modules, it encapsulates the data into data frames in a standard format, with the packet sequence number increasing with the number of transmissions. The data frames are transmitted to the core control node via the EtherCAT periodic process data channel. The core control node extracts the device identifier and packet sequence number, compares them with the cached historical sequence numbers. If the sequence numbers are different, it is determined to be new data and forwarded to the host computer via USB or Ethernet interface, while simultaneously updating the cached sequence number; otherwise, the data frame is discarded.

[0126] (iv) Topology Adaptive Logic The gateway node monitors the connection status of the temperature acquisition module in real time via the CANFD communication link. When it detects module insertion / removal or communication interruption, it immediately reports to the core control node. The core control node triggers a re-addressing process, where the gateway node re-collects identification information, assigns local addresses, counts the number of devices, and reports the results. The core control node recalculates the offset and sends it down, and the gateway node updates the global address mapping to achieve adaptive topology adjustment.

[0127] III. Experimental Data The system was deployed in a large production workshop and ran continuously for 30 days. The experimental data are as follows: 1. Safe power supply: A total of 800 device access verifications were completed with a protocol matching accuracy of 100%. In 30 simulated accesses of incompatible devices, the safe power supply control module rejected high-voltage power supply in all cases, and no equipment damage occurred. During operation, there were 5 power supply anomalies, and the system cut off the high-voltage power supply and issued an alarm in each case within a short period of time.

[0128] 2. Addressing and addressing: After the system is powered on, it quickly completes automatic addressing and unified addressing. The entire system has a short addressing time, no address overlap or conflict, and the core control node can respond promptly to any temperature acquisition module accessed through the global address.

[0129] 3. Data transmission: With a preset data acquisition cycle, more than one million frames of temperature data have been transmitted cumulatively. The data transmission accuracy is 100%, the duplicate data discard rate meets expectations, and the bandwidth utilization is significantly improved compared to traditional solutions. The data received by the host computer fully presents the temperature change trend of each acquisition point.

[0130] 4. Topology Adaptive: After simulating 20 hot-swapping of temperature acquisition modules, the system automatically triggers readdressing and relocation in each case. The adjustment process does not affect the operation of other subnets, and the new topology stabilizes in a short time.

[0131] 5. Fault Response: Simulated 10 communication link interruption failures. If the system failed to recover after a timeout retry, an alarm was triggered. The fault response was timely, and no data loss or system crash occurred.

[0132] IV. Technical Effects 1. Significantly improved power supply safety: Through low-voltage identification, protocol matching and high-voltage power supply classification mechanism, combined with continuous power supply monitoring and abnormal disconnection function, the risk of equipment damage caused by incompatible equipment access and power supply failure is completely avoided, ensuring the power supply reliability of the system in complex industrial environments.

[0133] 2. Efficient and convenient addressing configuration: Automatic addressing and address offset calculation mechanism realizes unified addressing across the entire network, eliminating the need for manual address configuration and avoiding human error; Topology adaptive function supports hot-swapping of devices, and the addition or removal of devices does not interrupt system operation, greatly reducing system deployment and maintenance costs.

[0134] 3. Efficient and complete data transmission: Periodic aggregation and packaging reduce the frequency of data transmission, and the deduplication mechanism based on packet sequence number avoids duplicate data from occupying bandwidth and improves bandwidth utilization; standardized data frame format and CRC check ensure the integrity and accuracy of data transmission, meeting the real-time and reliability requirements of industrial scenarios.

[0135] 4. Stable and reliable system operation: Multiple protection mechanisms, such as communication timeout handling, work count verification, and fault alarm, ensure that the system responds quickly in case of abnormal situations such as equipment failure and link interruption, reduce the impact of failure on overall operation, and achieve long-term stable operation.

[0136] 5. Strong scenario adaptability: It adopts standard network cables to build a single-line power supply and communication integrated link, simplifying the complexity and cost of wiring; it supports the cascading expansion of multiple gateway nodes and multiple subnet devices, and can flexibly adjust the number of devices according to the scale of the workshop to adapt to distributed data acquisition scenarios of different scales.

[0137] The above are merely preferred embodiments of the present invention and are not intended to limit the implementation methods and protection scope of the present invention. Those skilled in the art should recognize that any equivalent substitutions and obvious changes made based on the description and illustrations of the present invention should be included within the protection scope of the present invention.

Claims

1. A power supply addressing and data upload method for an EtherCAT / CANFD hybrid cascaded system, applied to a hybrid cascaded system including a core control node, at least one gateway node, and several CANFD subnet devices connected to each gateway node, characterized in that, The method includes the following steps: Step 1: Safe power supply establishment phase. When the system is powered on, it initially adopts low-voltage mode to initiate device identification and protocol matching. After the matching verification is passed, it switches to high-voltage power supply mode. It relies on the single-line power supply and communication converged link to provide safe power supply for each level of equipment. The single-line power supply and communication converged link realizes power transmission and data interaction at the same time. Step 2: Subnet auto-addressing stage, each gateway node performs auto-addressing operation on the CANFD subnet devices under its connection to obtain the number of devices in the corresponding subnet; Step 3: In the unified addressing phase across the entire network, the core control node collects the number of subnet devices reported by each gateway node, calculates the address offset corresponding to each gateway node and sends it to that gateway node, and establishes a unified address space covering all CANFD subnet devices across the entire network. Step 4: Data Acquisition and Packaging Stage. The gateway node reads the acquired data from the connected CANFD subnet devices through the CANFD communication interface, aggregates the acquired data according to a preset cycle, and packages it into data frames. Step 5: Data transmission deduplication stage. The gateway node transmits the packaged data frames to the core control node through the EtherCAT periodic process data channel. The core control node performs deduplication processing on the received data frames to ensure that each batch of data is transmitted to the host computer only once. The core control node establishes communication with the host computer through the USB interface or Ethernet interface and completes data forwarding.

2. The method according to claim 1, characterized in that, The automatic subnet addressing stage specifically includes the following sub-steps: The gateway node broadcasts addressing instructions to all CANFD subnet devices connected to it. After receiving the addressing command, the CANFD subnet device sends its unique identification information back to the gateway node; The gateway node collects the unique identification information of all CANFD subnet devices and sorts the unique identification information according to a preset sorting rule; Based on the sorting results, each CANFD subnet device is assigned a consecutive local address, and the number of devices in that subnet is counted.

3. The method according to claim 1, characterized in that, The address offset is calculated as follows: the address offset of the first gateway node is 0, and the address offset of any other gateway node is equal to the sum of the number of subnet devices corresponding to all the gateway nodes before that gateway node.

4. The method according to claim 1, characterized in that, The preset period is a configurable period. The data frame includes a data identifier field, a device identifier field, a packet sequence number field, a data length field, and a data payload field. The data identifier field is used to distinguish the data frame type, the device identifier field is used to identify the gateway node that sent the data frame, the packet sequence number field is used for data deduplication verification, the data length field is used to indicate the actual number of bytes in the data payload field, and the data payload field includes a timestamp, the number of channels, the channel data, and a checksum.

5. The method according to claim 1, characterized in that, The specific implementation process of the data transmission deduplication stage is as follows: the core control node maintains a record of the packet sequence number of the most recently forwarded data frame for each gateway node; After receiving a new data frame, the core control node extracts the device identifier field and packet sequence number field from the data frame; Find the corresponding packet sequence number record based on the device identifier field, and compare the packet sequence number of the new data frame with the packet sequence number of the record; If the two are different, it is determined to be new data. The core control node forwards the data frame to the host computer and updates the corresponding packet sequence number record. If the two are the same, it is determined to be duplicate data, and the core control node discards the data frame.

6. The method according to claim 1, characterized in that, The safe power supply establishment phase also includes a power supply status monitoring mechanism: during system operation, the working status of the power supply link is continuously monitored. When overcurrent, short circuit or abnormal equipment connection is detected, the high-voltage power supply is immediately cut off and an alarm is triggered, maintaining the low-voltage identification mode or shutting down the power supply channel.

7. The method according to claim 1, characterized in that, The method also includes a topology adaptive adjustment mechanism: when the insertion or removal of CANFD subnet devices or communication link abnormalities are detected, the automatic subnet addressing stage and the unified addressing stage of the entire network are automatically triggered to re-execute, update the number of subnet devices and address offsets, and reconstruct the unified address space of the entire network.

8. A power supply addressing and data uploading device for an EtherCAT / CANFD hybrid cascade system, characterized in that, include: The EtherCAT interface module is used to establish an EtherCAT communication connection with the core control node, enabling the reception and transmission of data frames as well as the reception of address offsets. The CANFD interface module is used to establish a CANFD communication connection with the connected CANFD subnet devices, enabling the issuance of addressing commands, the reception of unique identification information, and the reading of collected data. The processor is used to execute safe power supply control logic, subnet automatic addressing logic, and data aggregation and packaging logic. The processor establishes signal connections with the EtherCAT interface module and the CANFD interface module, respectively. The memory is used to store unique identification information, the number of subnet devices, address offset, preset period parameters, data frame format rules, and program instructions required for processor execution. The memory establishes a data interaction connection with the processor.

9. The apparatus according to claim 8, characterized in that, Also includes: The power management module is used to switch between low-voltage and high-voltage modes, providing a stable power supply for the device itself and the connected CANFD subnet devices. The power management module establishes a control connection with the processor. The safe power supply control module is used to perform device identification, protocol matching verification, and power supply status monitoring. The safe power supply control module establishes signal connections with the power management module and the processor, respectively. The safe power supply control module is integrated into the signal processing path of the single-line power supply and communication converged link.

10. An EtherCAT / CANFD hybrid cascade system, characterized in that, It includes a core control node, at least one EtherCAT / CANFD hybrid cascade system power supply addressing and data upload device as described in claim 8 or 9, and a set of CANFD subnet devices connected to each device; The core control node, as the core of the system, establishes a master-slave communication relationship with each device through the EtherCAT communication link. It is used to receive the number of subnet devices reported by each device, calculate the address offset and send it down, and receive the data frames transmitted by the device and perform deduplication and forwarding. The system is configured to perform the power supply addressing and data upload method for the EtherCAT / CANFD hybrid cascaded system as described in any one of claims 1 to 7.