Data communication and distribution method and system for laser flight cleaning

By integrating the S7 industrial protocol with a TCP server, efficient and real-time data distribution in the laser flying cleaning system is achieved, solving the problems of inconsistent communication protocols and low data processing efficiency in existing technologies, and improving the system's scalability and reliability.

CN122001906APending Publication Date: 2026-05-08ANHUI JEE AUTOMATION EQUIP CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
ANHUI JEE AUTOMATION EQUIP CO LTD
Filing Date
2025-10-31
Publication Date
2026-05-08

AI Technical Summary

Technical Problem

In existing technologies, the communication protocols between PLC and host computer, and between host computer and galvanometer controller are not unified, resulting in low data processing efficiency, insufficient real-time performance, and difficulty in system expansion, making it difficult to meet the high real-time requirements of laser flying cleaning.

Method used

A direct communication connection is established with the industrial controller via the S7 industrial protocol to parse and verify offset data. Combined with load balancing strategies and a TCP server, data is efficiently distributed to the target galvanometer controller.

Benefits of technology

It significantly improves data transmission efficiency and system real-time performance, enhances system scalability and maintainability, and ensures long-term operational reliability in industrial environments.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122001906A_ABST
    Figure CN122001906A_ABST
Patent Text Reader

Abstract

The invention discloses a data communication and distribution method and system for laser flight cleaning, and belongs to the technical field of industrial automation control. The method comprises the following steps: directly reading battery pole offset original data in an industrial controller through an S7 industrial protocol; after the data are analyzed and verified, intelligent routing is carried out according to preset mapping and a load balancing strategy, and a target galvanometer identifier is determined; and the asynchronous TCP server distributes the data to the corresponding galvanometer controllers according to self-defined protocol frames. According to the method and the system provided by the invention, an integrated S7 protocol data acquisition and special TCP distribution architecture is constructed, so that intermediate protocol conversion is avoided, and the data transmission efficiency and the system real-time performance are remarkably improved. Based on a data processing mechanism of intelligent routing and load balancing, dynamic optimal distribution of cleaning tasks among a plurality of galvanometers is realized, the throughput of the system is improved, and the capability of coping with production fluctuation is also enhanced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of industrial automation control technology, and in particular to a data communication and distribution method and system for laser flying cleaning. Background Technology

[0002] In the manufacturing process of new energy batteries, laser-assisted cleaning technology for battery terminals requires high precision and high efficiency. In existing technologies, the galvanometer control system needs to acquire the positional offset data of each battery terminal in real time in order to adjust the laser scanning path.

[0003] Currently, common solutions have the following drawbacks: Inconsistent communication protocols: Different communication protocols are used between the PLC and the host computer, and between the host computer and the galvanometer controller, making system integration complex; Low data processing efficiency: Offset data needs to undergo multiple protocol conversions, which increases system latency; Insufficient real-time performance: Traditional solutions cannot meet the high real-time requirements of flight cleaning (typically requiring a response time of <10ms). System scalability is difficult: the existing architecture struggles to adapt quickly when battery specifications change or the number of galvanometers increases; While existing technologies may have separate S7 or TCP communication schemes, there is a lack of a complete solution that organically combines the two and is optimized for the specific scenario of battery terminal air cleaning.

[0004] Therefore, there is an urgent need for a solution that can centrally, efficiently, and reliably collect PLC data and intelligently distribute it to multiple clients to solve the above problems. Summary of the Invention

[0005] To address the technical problems existing in the background art, this invention proposes a data communication and distribution method and system for laser flying cleaning.

[0006] This invention proposes a data communication and distribution method for laser-assisted aerial cleaning, comprising the following steps: S1. Establish a direct communication connection with the industrial controller via the S7 industrial protocol, and read the original data of the battery terminal offset from the designated data block of the industrial controller. S2. The original offset data is parsed and verified to extract structured offset data containing pole markers, X-axis offset, Y-axis offset and quality status flags. S3. Based on the preset mapping relationship between pole markers and galvanometer markers, and in conjunction with a load balancing strategy, the structured offset data is allocated to the target galvanometer marker. S4. The structured offset data and the target galvanometer identifier are encapsulated into a custom protocol data frame by a TCP server and distributed to the galvanometer controller corresponding to the target galvanometer identifier.

[0007] Preferably, in step S1, establishing a direct communication connection specifically includes: Configure the industrial controller's IP address, rack number, and slot number; After the underlying TCP connection is successfully established, the S7 protocol handshake and communication resource allocation process is executed, and an independent heartbeat monitoring thread is started to maintain connection activity.

[0008] Preferably, step S2 specifically includes: S21. Obtain the original offset data, receive the original offset data as a byte stream and store it in a temporary buffer, and perform data length verification and preliminary format screening on the byte stream to complete the data integrity verification. S22. Process the validated byte stream, perform field mapping according to the predefined data structure specifications, and obtain the mapped data; S23. From the completed mapping data, extract the polar identifier field, X-axis offset value, Y-axis offset value and data quality flag bit in sequence to obtain the structured offset data.

[0009] Preferably, step S22 specifically includes: Calculate the field offset based on the defined position and size of each data field; Convert byte data to the corresponding programming language data type and adjust the byte order according to system byte order differences.

[0010] Preferably, step S3 specifically includes: S31. Obtain the pole identifier contained in the structured offset data; S32. Based on the pole identification, query the preset mapping relationship to obtain a set of candidate galvanometer identifications containing one or more candidate galvanometer controllers; S33. Process the candidate galvanometer identifier set, and dynamically select one from the candidate galvanometer identifier set as the final target galvanometer identifier according to the load balancing strategy; S34. Associate the final target galvanometer identifier with the corresponding structured offset data to obtain the data routing result ready for distribution.

[0011] Preferably, the load balancing strategy is as follows: Obtain the real-time operating status parameters of each candidate galvanometer controller, wherein the operating status parameters include at least the length of the data queue to be processed and the average processing delay; The operating status parameters are processed, and the real-time load score of each candidate galvanometer controller is calculated according to a predefined load scoring algorithm. By comparing the real-time load scores of all candidate galvanometer controllers, the candidate galvanometer with the lowest load score is determined as the final target galvanometer.

[0012] Preferably, the preset mapping relationship between the pole marker and the galvanometer marker is specifically defined by a configurable mapping table, and the mapping relationship defined by the mapping table includes at least one of the following: Static region mapping relationship based on the physical location of battery terminals; Based on the dynamic balancing mapping relationship of the real-time load status of each galvanometer controller; Mapping relationship of process parameters associated with battery specifications and models.

[0013] Preferably, in step S4, the TCP server uses an asynchronous event-driven model to manage the connections of all galvanometer controllers, and performs identity authentication and timeout management based on heartbeat messages for the connections; in step S4, before data distribution, a sending priority is set for different types of structured offset data, and a priority queue mechanism is used to schedule the sending order of the custom protocol data frames.

[0014] Preferably, in step S4, the encapsulation format of the custom protocol data frame includes a frame header, a data length field, a command word field, a timestamp field, a galvanometer identifier field, a data payload field, and a check field; wherein the check field adopts a CRC16 cyclic redundancy check code.

[0015] This invention proposes a data communication and distribution system for laser-assisted aerial cleaning, comprising: The data acquisition module is used to establish a direct communication connection with the industrial controller via the S7 industrial protocol and read the raw data of the battery terminal offset from a specified data block of the industrial controller. The first processing module is used to parse and verify the original offset data and extract structured offset data containing polar column identifier, X-axis offset, Y-axis offset and quality status flag. The second processing module is used to allocate the structured offset data to the target galvanometer identifier according to the preset mapping relationship between pole markers and galvanometer identifiers, and in combination with a load balancing strategy. The data distribution module is used to encapsulate the structured offset data and the target galvanometer identifier into a custom protocol data frame via a TCP server, and distribute it to the galvanometer controller corresponding to the target galvanometer identifier.

[0016] The proposed data communication and distribution method and system for laser-assisted aerial cleaning in this invention significantly improves data transmission efficiency and system real-time performance by constructing an integrated S7 protocol data acquisition and dedicated TCP distribution architecture, avoiding intermediate protocol conversions. Based on an intelligent routing and load-balancing data processing mechanism, the system achieves dynamic optimization of cleaning tasks among multiple galvanometers, increasing system throughput and enhancing its ability to handle production fluctuations. Furthermore, the modular design of the system, coupled with comprehensive connection monitoring and error recovery mechanisms, ensures long-term operational reliability in industrial environments. When production line configurations change, only parameter adjustments are needed for rapid adaptation, greatly improving the system's scalability and maintainability. Attached Figure Description

[0017] Figure 1 This is a flowchart illustrating the data communication and distribution method for laser-based aerial cleaning proposed in this invention. Figure 2 This is a schematic diagram of the system architecture of a data communication and distribution system for laser aerial cleaning proposed in this invention; Figure 3 This is a schematic diagram of the hardware connection structure of one embodiment of a data communication and distribution system for laser aerial cleaning proposed in this invention; Figure 4 This is a schematic diagram illustrating the implementation process of one embodiment of the data communication and distribution system for laser-based aerial cleaning proposed in this invention. Detailed Implementation

[0018] Reference Figures 1-4 The present invention proposes a data communication and distribution method for laser-assisted aerial cleaning, comprising the following steps: S1. Establish a direct communication connection with the industrial controller via the S7 industrial protocol, and read the raw data of the battery terminal offset from the designated data block of the industrial controller.

[0019] In this embodiment, step S1, establishing a direct communication connection specifically includes: Configure the industrial controller's IP address, rack number, and slot number; After the underlying TCP connection is successfully established, the S7 protocol handshake and communication resource allocation process is executed, and an independent heartbeat monitoring thread is started to maintain connection activity.

[0020] S2. Parse and verify the original offset data to extract structured offset data containing pole markers, X-axis offset, Y-axis offset, and quality status flags.

[0021] In this embodiment, step S2 specifically includes: S21. Obtain the original offset data, receive the original offset data as a byte stream and store it in a temporary buffer, perform data length verification and preliminary format screening on the byte stream to complete the data integrity verification. S22. Process the validated byte stream, perform field mapping according to the predefined data structure specifications, and obtain the mapped data; S23. From the completed mapping data, extract the polar identifier field, X-axis offset value, Y-axis offset value, and data quality flag in sequence to obtain structured offset data.

[0022] Specifically, step S22 includes: Calculate the field offset based on the defined position and size of each data field; Convert byte data to the corresponding programming language data type and adjust the byte order according to system byte order differences.

[0023] Specifically, the data parsing and verification process includes: 1) Byte stream reception and buffering: The raw data successfully read from the industrial controller is parsed in the form of a byte stream. The system first stores the received byte stream into a temporary buffer and performs basic integrity checks on the data in the temporary buffer, including data length verification and preliminary format screening.

[0024] 2) Data Structure Mapping: Based on predefined data structure specifications, the system parses the byte stream according to a specific format. This process involves: Field offset calculation: Determine the starting position of each field in the byte stream based on the definition position and size of each data field in the structure; Data type conversion: Convert byte data to the corresponding C# data type, such as converting 4 bytes to a single-precision floating-point number, or 2 bytes to an integer; Byte order processing: Make necessary byte order adjustments based on the byte order differences between the industrial controller and the host system to ensure the correctness of data parsing.

[0025] 3) Data extraction and reconstruction: First, extract the pole identification field for subsequent data routing; then extract the X-axis and Y-axis offset values, which are the core parameters of galvanometer control; finally, extract the data quality flag to determine the reliability of the data.

[0026] S3. Based on the preset mapping relationship between pole markers and galvanometer markers, and combined with the load balancing strategy, the structured offset data is allocated to the target galvanometer marker.

[0027] In this embodiment, step S3 specifically includes: S31. Obtain the pole identifier contained in the structured offset data; S32. Based on the pole identification, query the preset mapping relationship to obtain a set of candidate galvanometer identifications containing one or more candidate galvanometer controllers; S33. Process the candidate galvanometer identifier set, and dynamically select one from the candidate galvanometer identifier set as the final target galvanometer identifier according to the load balancing strategy; S34. Associate the final target galvanometer identifier with the corresponding structured offset data to obtain the data routing result ready for distribution.

[0028] Specifically, the load balancing strategy is as follows: Obtain the real-time operating status parameters of each candidate galvanometer controller. The operating status parameters include at least the length of the data queue to be processed and the average processing delay. Process operating status parameters and calculate the real-time load score of each candidate galvanometer controller according to a predefined load scoring algorithm; By comparing the real-time load scores of all candidate galvanometer controllers, the candidate galvanometer with the lowest load score is determined as the final target galvanometer.

[0029] Specifically, the load scoring algorithm uses a simple weighted scoring algorithm: load score = queue length × weight coefficient. The module will select the candidate galvanometer with the lowest load score as the final target galvanometer.

[0030] In this embodiment, the preset mapping relationship between pole markers and galvanometer markers is specifically defined through a configurable mapping table. The mapping relationship defined in this table includes at least one of the following: Static region mapping relationship based on the physical location of battery terminals; Based on the dynamic balancing mapping relationship of the real-time load status of each galvanometer controller; Mapping relationship of process parameters associated with battery specifications and models.

[0031] Specifically, the airborne cleaning station has two lasers and two galvanometers. The outer markings of the poles are odd numbers (e.g., 1, 3, 5, 7, ..., 63), while the inner markings are even numbers (e.g., 2, 4, 6, 8, ..., 64). One galvanometer is responsible for cleaning the outer side, and the other for cleaning the inner side. During pole addressing, the offset data is bound to the current tray. The airborne cleaning station captures a reference point with a camera and simultaneously scans the tray to confirm the tray number, then reads the corresponding offset.

[0032] S4. The structured offset data and the target galvanometer identifier are encapsulated into a custom protocol data frame via a TCP server and distributed to the galvanometer controller corresponding to the target galvanometer identifier.

[0033] Specifically, the data is encapsulated and distributed to the target galvanometer controller in real time and with precision through a TCP server, thereby enabling laser-driven cleaning of moving battery terminals through dynamic tracking.

[0034] In this embodiment, the TCP server in step S4 uses an asynchronous event-driven model to manage the connections of all galvanometer controllers, and performs identity authentication and timeout management based on heartbeat messages for the connections.

[0035] Specifically, the core server architecture is built using an event-driven asynchronous programming model: Main listening thread: responsible for accepting new client connection requests without blocking other network operations; Worker thread pool: Allocate an independent worker thread for each client connection to handle data sending and receiving tasks; Event notification mechanism: Respond to network events, such as data arrival or connection loss, through callback functions or event handlers.

[0036] In this embodiment, in step S4, before data distribution, a sending priority is set for different types of structured offset data, and a priority queue mechanism is used to schedule the sending order of custom protocol data frames.

[0037] In this embodiment, in step S4, the encapsulation format of the custom protocol data frame includes a frame header, a data length field, a command word field, a timestamp field, a galvanometer identifier field, a data payload field, and a check field; wherein, the check field adopts a CRC16 cyclic redundancy check code.

[0038] Specifically, the frame format of the custom binary protocol data frame is as follows: Frame header: 2 bytes, fixed as 0xAA55.

[0039] Data length: 2 bytes, indicating the length of the subsequent data payload.

[0040] Command word: 1 byte, 0x01 represents real-time offset data.

[0041] Timestamp: 4 bytes, the number of milliseconds since the system started.

[0042] Galvanometer ID: 1 byte, which is the identifier of the target galvanometer.

[0043] Data payload: includes X-axis offset (4-byte floating-point number) and Y-axis offset (4-byte floating-point number).

[0044] Check field: 2 bytes, calculated using the CRC16-CCITT algorithm on all data after the frame header and before the check field.

[0045] It should be noted that the TCP server performs the following initialization tasks upon startup: Network parameter configuration: Set the IP address and port number that the server listens on. Usually, any local IP address and a predefined dedicated port are used. Connection pool initialization: Creates a client connection management data structure to store and maintain information about all active client connections; Resource pre-allocation: Pre-allocate network buffers, thread resources, etc., to ensure stable performance even under high concurrency conditions; Full policy settings: Configure security parameters such as connection authentication mechanisms and access control lists.

[0046] Reference Figures 1-4 The present invention proposes a data communication and distribution system for laser-assisted aerial cleaning, comprising: The data acquisition module is used to establish a direct communication connection with the industrial controller via the S7 industrial protocol and read the raw data of the battery terminal offset from the designated data block of the industrial controller. The first processing module is used to parse and verify the original offset data and extract structured offset data containing polar column identifiers, X-axis offsets, Y-axis offsets and quality status flags. The second processing module is used to allocate structured offset data to the target galvanometer markers according to the preset mapping relationship between pole markers and galvanometer markers, and in combination with the load balancing strategy. The data distribution module is used to encapsulate the structured offset data and the target galvanometer identifier into a custom protocol data frame via a TCP server, and distribute it to the galvanometer controller corresponding to the target galvanometer identifier.

[0047] This embodiment is implemented on a typical new energy battery electrode laser flying cleaning production line, and its hardware connection is as follows: Figure 3 As shown, it specifically includes: Industrial controller: A Siemens S7-1500 series programmable logic controller (PLC) is used to receive the results from the vision inspection system and store the position offset data of each battery terminal in its DB154 data block.

[0048] Host industrial computer: An industrial computer equipped with an Intel i5 processor and 8GB of memory, running the Windows 10 operating system. The data communication and distribution system of this invention is deployed on this industrial computer as a service program written in C#.

[0049] Galvanometer control system: includes two scanning galvanometers and their matching motion control cards. Each galvanometer is responsible for cleaning the battery terminals in a specific area on the production line.

[0050] Network equipment: Gigabit industrial Ethernet switch, used to connect all the above devices.

[0051] Lasers: Two low-power pulsed lasers, whose output is controlled by a galvanometer control system.

[0052] The system software in this embodiment runs on a host industrial control computer. The core workflow, implemented on a typical new energy battery electrode laser flying cleaning production line, is as follows: Figure 4 As shown, first open and start both galvanometer software programs. Then open the distribution system, start the system, and automatically connect to the PLC and start the TCP server. Start the thread and wait for the PLC to send a data read signal; read the offset data from the PLC and save it to the queue, while verifying that the data length is 128 (128 data points correspond to 64 poles, each pole has X-axis coordinate data and Y-axis coordinate data); according to the galvanometer's ID (whether it is responsible for the inner or outer side), classify and sort the offset data and store them in the corresponding queues; wait for the flight start signal, and when the start signal is received, send the data to the galvanometer to start the flight cleaning.

[0053] The above description is only a preferred embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any equivalent substitutions or modifications made by those skilled in the art within the scope of the technology disclosed in the present invention, based on the technical solution and inventive concept of the present invention, should be covered within the scope of protection of the present invention.

Claims

1. A data communication and distribution method for laser-assisted aerial cleaning, characterized in that, Includes the following steps: S1. Establish a direct communication connection with the industrial controller via the S7 industrial protocol, and read the original data of the battery terminal offset from the designated data block of the industrial controller. S2. The original offset data is parsed and verified to extract structured offset data containing pole markers, X-axis offset, Y-axis offset and quality status flags. S3. Based on the preset mapping relationship between pole markers and galvanometer markers, and in conjunction with a load balancing strategy, the structured offset data is allocated to the target galvanometer marker. S4. The structured offset data and the target galvanometer identifier are encapsulated into a custom protocol data frame by a TCP server and distributed to the galvanometer controller corresponding to the target galvanometer identifier.

2. The data communication and distribution method for laser-assisted aerial cleaning according to claim 1, characterized in that, In step S1, establishing a direct communication connection specifically includes: Configure the industrial controller's IP address, rack number, and slot number; After the underlying TCP connection is successfully established, the S7 protocol handshake and communication resource allocation process is executed, and an independent heartbeat monitoring thread is started to maintain connection activity.

3. The data communication and distribution method for laser-assisted aerial cleaning according to claim 1, characterized in that, Step S2 specifically includes: S21. Obtain the original offset data, receive the original offset data as a byte stream and store it in a temporary buffer, and perform data length verification and preliminary format screening on the byte stream to complete the data integrity verification. S22. Process the validated byte stream, perform field mapping according to the predefined data structure specifications, and obtain the mapped data; S23. From the completed mapping data, extract the polar identifier field, X-axis offset value, Y-axis offset value and data quality flag bit in sequence to obtain the structured offset data.

4. The data communication and distribution method for laser-assisted aerial cleaning according to claim 3, characterized in that, Step S22 specifically includes: Calculate the field offset based on the defined position and size of each data field; Convert byte data to the corresponding programming language data type and adjust the byte order according to system byte order differences.

5. The data communication and distribution method for laser-assisted aerial cleaning according to claim 1, characterized in that, Step S3 specifically includes: S31. Obtain the pole identifier contained in the structured offset data; S32. Based on the pole identification, query the preset mapping relationship to obtain a set of candidate galvanometer identifications containing one or more candidate galvanometer controllers; S33. Process the candidate galvanometer identifier set, and dynamically select one from the candidate galvanometer identifier set as the final target galvanometer identifier according to the load balancing strategy; S34. Associate the final target galvanometer identifier with the corresponding structured offset data to obtain the data routing result ready for distribution.

6. The data communication and distribution method for laser-assisted aerial cleaning according to claim 5, characterized in that, The load balancing strategy is as follows: Obtain the real-time operating status parameters of each candidate galvanometer controller, wherein the operating status parameters include at least the length of the data queue to be processed and the average processing delay; The operating status parameters are processed, and the real-time load score of each candidate galvanometer controller is calculated according to a predefined load scoring algorithm. By comparing the real-time load scores of all candidate galvanometer controllers, the candidate galvanometer with the lowest load score is determined as the final target galvanometer.

7. The data communication and distribution method for laser-assisted aerial cleaning according to claim 5, characterized in that, The preset mapping relationship between pole markers and galvanometer markers is specifically defined through a configurable mapping table, which defines at least one of the following mapping relationships: Static region mapping relationship based on the physical location of battery terminals; Based on the dynamic balancing mapping relationship of the real-time load status of each galvanometer controller; Mapping relationship of process parameters associated with battery specifications and models.

8. The data communication and distribution method for laser-assisted aerial cleaning according to claim 1, characterized in that, In step S4, the TCP server uses an asynchronous event-driven model to manage the connections of all galvanometer controllers, and performs identity authentication and timeout management based on heartbeat messages for the connections. In step S4, before data distribution, the sending priority is set for different types of structured offset data, and a priority queue mechanism is used to schedule the sending order of the custom protocol data frames.

9. The data communication and distribution method for laser-assisted aerial cleaning according to claim 1, characterized in that, In step S4, the encapsulation format of the custom protocol data frame includes a frame header, a data length field, a command word field, a timestamp field, a galvanometer identifier field, a data payload field, and a check field; wherein, the check field adopts a CRC16 cyclic redundancy check code.

10. A data communication and distribution system for laser-assisted aerial cleaning, characterized in that, include: The data acquisition module is used to establish a direct communication connection with the industrial controller via the S7 industrial protocol and read the raw data of the battery terminal offset from a specified data block of the industrial controller. The first processing module is used to parse and verify the original offset data and extract structured offset data containing polar column identifier, X-axis offset, Y-axis offset and quality status flag. The second processing module is used to allocate the structured offset data to the target galvanometer identifier according to the preset mapping relationship between pole markers and galvanometer identifiers, and in combination with a load balancing strategy. The data distribution module is used to encapsulate the structured offset data and the target galvanometer identifier into a custom protocol data frame via a TCP server, and distribute it to the galvanometer controller corresponding to the target galvanometer identifier.