A communication method, system and medium based on physical interface and self-organizing network
By building networking nodes and dynamically switching networking strategies in the PCB board production test system, the problems of interface heterogeneity and dynamic adaptability are solved, an efficient and reliable communication network is implemented, and the overall efficiency and flexibility of the test system are improved.
Patent Information
- Application Number
- CN202510899083.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-07-01
- Publication Date
- 2025-09-16
- Estimated Expiration
- 2045-07-01
AI Technical Summary
The communication architecture of existing PCB board production and testing systems has core defects such as high interface heterogeneity, low indirect communication efficiency, and poor dynamic adaptability, which lead to increased complexity of the testing process, rigid resource allocation, and difficulty in improving overall efficiency.
A communication method based on physical interfaces and self-organizing networks is provided. By constructing networking nodes and matching networking strategies, nodes with different buses and communication interfaces can form a communication network. Dynamic switching of networking modes is supported to ensure the real-time and reliability of communication.
It greatly simplifies the communication method of interface heterogeneous systems, takes into account both control accuracy and dynamic adaptability, ensures the real-time and reliability of communication within the PCB board production test system, and improves the overall test efficiency.
Smart Images

Figure CN120416046B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of communication technology, and in particular to a communication method, system and medium based on a physical interface and an ad hoc network. Background Art
[0002] During the industrial production testing of PCB (Printed Circuit Board) boards, the test system typically consists of multiple heterogeneous devices, including in-circuit testers (ICTs), automated optical inspection (AOIs), functional test benches (FCTs), programming equipment, burn-in test chambers, and automated guided vehicles (AGVs). These devices must exchange data in real time during the testing process, such as transmitting test instructions, synchronizing timing, sharing status information, and returning test results. However, existing technologies have a particularly prominent problem with inconsistent communication interface standards between devices within production test systems, which manifests itself in the following technical pain points:
[0003] 1. Interface heterogeneity leads to communication barriers: This interface heterogeneity makes it impossible to establish direct communication links between devices. Data transfer requires manually configured intermediate gateways or protocol converters, which significantly increases the complexity of system deployment and maintenance costs.
[0004] 2. Indirect communication between devices without direct connection interfaces is inefficient:
[0005] For devices without direct physical connections or in wireless coverage blind spots, existing technologies typically implement indirect communication using the following methods: Cascade forwarding, which transmits data hop-by-hop through intermediate devices, leads to cumulative communication delays (e.g., AGV location data must pass through Wi-Fi → gateway → CAN → console → Ethernet → AOI equipment); centralized proxy methods, which rely on a central server to handle all communication requests, create performance bottlenecks and carry a high risk of single points of failure; and manual intervention methods, which transmit non-real-time data via USB flash drives or manual input, significantly slowing down testing. These indirect communication methods not only reduce data transmission efficiency but also introduce issues such as packet loss and timing errors due to multiple protocol conversions, impacting the accuracy and consistency of test results.
[0006] 3. Insufficient adaptability in dynamic testing scenarios:
[0007] Modern PCB test systems are becoming more flexible and intelligent, and need to support dynamic task scheduling (such as multi-station parallel testing and real-time AGV path adjustment). However, the existing communication architecture has obvious limitations:
[0008] Static binding flaw: Device communication relationships are usually fixed in advance and cannot be dynamically reconstructed according to test tasks (for example, the burning device needs to temporarily cooperate with a specific FCT station).
[0009] Limited scalability: When adding new devices, the entire network's protocol conversion rules need to be reconfigured, which takes a long time to deploy and is prone to configuration errors.
[0010] Real-time bottleneck: Complex protocol conversion chains are difficult to meet the requirements of high-real-time scenarios (such as emergency temperature control instructions in aging tests).
[0011] To address the above issues, the industry has tried various improvement solutions, but all have significant shortcomings: although multi-protocol conversion gateways can achieve interface interoperability, they have high hardware costs, extended conversion time (usually >50ms), and cannot adapt to dynamic topology changes.
[0012] Unified communications middleware shields underlying protocol differences through a software abstraction layer, but it lacks compatibility with resource-constrained embedded devices (such as sensor nodes) and requires customized development. While deploying a factory-wide Wi-Fi or 5G network for wireless coverage simplifies connectivity, electromagnetic interference and multipath effects in industrial environments can reduce communication reliability.
[0013] In summary, the communication architecture of existing PCB board production and test systems suffers from core flaws such as high interface heterogeneity, low indirect communication efficiency, and poor dynamic adaptability. These flaws lead to increased test process complexity, rigid resource allocation, and difficulty improving overall efficiency. Therefore, a new communication method is urgently needed that can adaptively accommodate multiple interfaces, support dynamic direct communication, and guarantee real-time and reliability. This approach can overcome existing technical bottlenecks and meet the needs of intelligent manufacturing. Summary of the Invention
[0014] The technical problem to be solved by the present invention is that the communication architecture of the existing PCB board production and test system has core defects such as high interface heterogeneity, low indirect communication efficiency, and poor dynamic adaptability, which lead to increased complexity of the test process, rigid resource allocation, and difficulty in improving overall efficiency. The purpose of the present invention is to provide a communication method, system and medium based on physical interfaces and self-organizing networks, constructing networking nodes according to the physical interfaces in the board production and test system, and matching networking strategies according to the board production and test tasks, so as to realize the formation of a communication network by networking nodes using different buses and different communication interfaces, and data transmission can be carried out between any two networking nodes in the network, which greatly simplifies the communication method of the interface heterogeneous system; at the same time, the networking mode dynamically changes with the execution stage of the board production and test tasks, thereby ensuring the real-time and reliability of communication within the board production and test system.
[0015] The present invention is achieved through the following technical solutions:
[0016] This solution provides a communication method based on a physical interface and an ad hoc network. The communication method is used in a board production and testing process. The communication method includes:
[0017] Construct networking nodes based on the physical interfaces in the board production test system;
[0018] Obtain a board production test task, and match a networking strategy according to the board production test task; the networking strategy includes a networking mode and a networking method; the networking method includes a designated dominant node networking method and a node active broadcast networking method; the networking mode includes a single mode and a mixed mode; in the single mode, network communication is performed in the designated dominant node networking method during the execution of the board production test task; in the mixed mode, network communication is performed in the designated dominant node networking method and the node active broadcast networking method during the execution of the board production test task, and the networking mode changes dynamically with the execution stage of the board production test task;
[0019] Each networking node forms a network and communicates according to the networking strategy.
[0020] A further optimization scheme is to construct a networking node based on the physical interface in the board production test system; including the following method:
[0021] Obtain the functional units of each test device in the board production test system;
[0022] Traversing all functional units to select a target functional unit: when functional unit i is connected to at least two arbitrary functional units via a communication channel, functional unit i is used as the target functional unit; the communication channel includes a communication interface or a communication bus;
[0023] All target functional units are used as networking nodes.
[0024] During the board production test process, the board production test system consists of a test control PC, test equipment, and the device under test. Usually, each device contains multiple different types of functional units such as main control units / processor units, and each functional unit is connected through different communication interfaces or communication buses. There is also a need for data communication between two functional units with different communication interfaces or no direct communication interface. Based on the above problem scenario, this solution constructs networking nodes according to the physical interfaces in the board production test system to realize a multi-node networking communication network based on different buses or communication interfaces. As long as there are communication links between the networking nodes, a multi-node networking communication network can be formed. In traditional designs, only nodes on the same communication bus can form a communication network. In this solution, even if different communication buses or communication interfaces are used, networking nodes can be added to the network, and any two nodes in the network can communicate with each other.
[0025] A further optimization plan is that the board production test tasks include: ICT test tasks, burning and calibration tasks, AOI inspection tasks, FCT functional test tasks, aging test tasks and AGV collaborative test tasks.
[0026] A further optimization solution is to match the networking strategy according to the board production test task; including the following method:
[0027] For ICT test tasks and programming and calibration tasks, single mode is used as the networking strategy;
[0028] For AOI inspection tasks, FCT functional test tasks, aging test tasks and AGV collaborative test tasks, the hybrid mode is used as the networking strategy.
[0029] A further optimization scheme is to use a hybrid mode as the networking strategy for the AOI inspection task, FCT functional test task, aging test task, and AGV collaborative test task; including the following methods:
[0030] Obtain the real-time execution data of each board production test task and check whether the real-time execution data meets the switching trigger conditions; if so, switch to the corresponding networking mode according to the switching trigger conditions;
[0031] The switching triggering conditions include:
[0032] a. When it is detected that all test equipment in the board production test system has been powered on, or an initialization configuration instruction has been received, the designated leading node networking mode is entered;
[0033] b. When it is detected that at least N functional units need to perform parallel tasks, or when a test start instruction is received, the node switches to the active broadcast networking mode;
[0034] c. When the test completion rate is detected to meet the preset completion rate threshold, or when a data collection instruction is received, the network is switched to the designated leading node;
[0035] d. When a failure of key test equipment is detected or an emergency interrupt signal is received, the network is forced to switch to the dominant node networking mode.
[0036] A further optimization scheme is that each networking node performs networking and communication according to the networking strategy; including the method:
[0037] Configuring a communication protocol for each networking node; the message information data packet of the communication protocol includes a functional data packet and a common data packet; the message information data packet includes: a sender node ID, a source node ID, and a target node ID;
[0038] Configuring message information data packets based on the communication protocol; the common data packets include collection data packets; the functional data packets include: one or more of networking data packets, remote call data packets, reply data packets and request retransmission data packets;
[0039] Initialize the message information of each network node, and each network node forms a network and communicates according to the networking strategy.
[0040] A further optimization scheme is that the communication protocol is configured for each networking node; including the method:
[0041] Configure each networking node as both sender and receiver;
[0042] The sender performs the following process:
[0043] S1, sending a message information data packet to the receiver. If the message information data packet contains a common data packet, proceed to step S2, otherwise, end the communication;
[0044] S2, wait for the reply from the receiver. If no reply is received within the T1 time period, return to S1. If a reply is received within the T1 time period, determine whether the reply content is a request for retransmission; if so, return to step S1; otherwise, end the communication;
[0045] The receiving party performs the following process:
[0046] K1, waiting for the header of the message information data packet;
[0047] K2, if the packet header i is received within the time period T2, then after the message information data packet corresponding to the packet header i is transmitted, it enters step K3 and returns to step K1; if the packet header is not received within the time period T2, then it returns to step K1;
[0048] K3, if the message information data is a common data packet, proceed to step K4; if the message information data contains a functional data packet, execute the corresponding function and return to step K1;
[0049] K4, perform data verification on the common data packet; if the data verification passes, reply completion to the sender and proceed to step K5; otherwise, reply retransmission request to the sender and return to step K1;
[0050] K5, determines whether the target node ID of the common data packet matches the receiving node ID. If so, runs the common data packet callback and returns to step K1. Otherwise, calls the forwarding callback and returns to step K1.
[0051] A further optimization solution is that when the message information data contains a networking data packet, the receiver performs the following process:
[0052] H1, determine whether the source node ID in the current message information data packet matches the receiver node ID. If so, end; otherwise, go to step H2;
[0053] H2, if the current networking data packet is a networking packet, determine whether the source node ID in the current message information data packet already exists in the routing table of the receiving node; if so, return to step H1; otherwise, add the source node ID in the current message information data packet to the routing table of the receiving node, call the forwarding callback, and end;
[0054] If the current networking data packet is a networking start packet, the forwarding callback is called and the process ends, and the networking packet is sent to all communication channels of the receiving node;
[0055] If the current networking data packet is a reassembled network packet, the routing table of the receiving node is deleted, and the networking packet is sent to all communication channels of the receiving node.
[0056] This solution also provides a communication system based on a physical interface and an ad hoc network, for implementing the above-mentioned communication method based on a physical interface and an ad hoc network; the system includes:
[0057] A construction module is used to construct a networking node based on the physical interface in the board production test system;
[0058] A strategy generation module is used to obtain a board production test task and match a networking strategy according to the board production test task; the networking strategy includes a networking mode and a networking method; the networking method includes a designated dominant node networking method and a node active broadcast networking method; the networking mode includes a single mode and a mixed mode; in the single mode, networking communication is performed in the designated dominant node networking method during the execution of the board production test task; in the mixed mode, networking communication is performed in the designated dominant node networking method and the node active broadcast networking method during the execution of the board production test task, and the networking mode changes dynamically with the execution stage of the board production test task;
[0059] The networking and communication module is used for networking and communication between networking nodes according to the networking strategy.
[0060] The present solution also provides a computer-readable medium having a computer program stored thereon. The computer program is executed by a processor to implement the above-mentioned communication method based on a physical interface and an ad hoc network.
[0061] Compared with the prior art, the present invention has the following advantages and beneficial effects:
[0062] 1. The present invention provides a communication method, system, and medium based on physical interfaces and ad hoc networking. Networking nodes are constructed based on the physical interfaces in a board production and test system, and a networking strategy is matched to the board production and test tasks. This allows networking nodes using different buses and communication interfaces to form a single communication network. Data can be transmitted between any two networking nodes in the network, greatly simplifying the communication method for systems with heterogeneous interfaces. Furthermore, the networking method dynamically changes with the execution stage of the board production and test tasks, ensuring the real-time and reliability of communication within the PCB board production and test system.
[0063] 2. The present invention provides a communication method, system, and medium based on a physical interface and self-organizing network. To balance control accuracy and dynamic adaptability during PCB board production testing, this solution uses a hybrid network for AOI inspection, FCT functional testing, aging testing, and AGV collaborative testing. This hybrid network allows for both control accuracy and dynamic adaptability through phased or functional mode switching. ICT testing tasks and programming and calibration tasks maintain a single-mode network communication using a designated dominant node to ensure safety and timing rigor. BRIEF DESCRIPTION OF THE DRAWINGS
[0064] In order to more clearly illustrate the technical solutions of the exemplary embodiments of the present invention, the following briefly introduces the drawings required for use in the examples. It should be understood that the following drawings only illustrate certain embodiments of the present invention and should not be considered as limiting the scope. A person of ordinary skill in the art can also derive other relevant drawings based on these drawings without inventive effort. In the drawings:
[0065] Figure 1 A flow chart of a communication method based on a physical interface and multi-node networking;
[0066] Figure 2 Schematic diagram of the communication protocol flow of each networking node;
[0067] Figure 3 This is a schematic diagram of the processing flow after the receiving node receives a common data packet;
[0068] Figure 4 This is a schematic diagram of the forwarding process after the receiving node receives a normal data packet;
[0069] Figure 5 is a schematic diagram of an example of a multi-node communication network;
[0070] Figure 6 A schematic diagram of a routing table for an example multi-node communication network;
[0071] Figure 7 This is a schematic diagram of the self-organizing network process;
[0072] Figure 8 A schematic diagram of the workflow for specifying the dominant node networking method;
[0073] Figure 9 This is a schematic diagram of a networking architecture based on physical interfaces and multiple nodes;
[0074] Figure 10 Schematic diagram of a communication network based on physical interfaces and multi-node networking architecture. DETAILED DESCRIPTION
[0075] In order to make the objectives, technical solutions and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with examples and drawings. The exemplary embodiments of the present invention and their descriptions are only used to explain the present invention and are not intended to limit the present invention.
[0076] The communication architecture of existing PCB board production and testing systems has core defects such as high interface heterogeneity, low indirect communication efficiency, and poor dynamic adaptability. These defects lead to increased test process complexity, rigid resource allocation, and difficulty in improving overall efficiency. In view of this, this solution provides the following embodiments to address the above technical issues.
[0077] Example 1: This example provides a communication method based on a physical interface and multi-node networking, such as Figure 1 As shown, the communication method is used in the board production test process, and the communication method includes:
[0078] Step 1: Construct a networking node based on the physical interface in the board production test system; this step specifically includes the following methods:
[0079] S11, obtaining the functional units of each test device in the board production test system;
[0080] S12, traversing all functional units to select a target functional unit: when functional unit i is connected to at least two arbitrary functional units via a communication channel, functional unit i is used as the target functional unit; the communication channel includes a communication interface or a communication bus;
[0081] S13, using all target functional units as networking nodes.
[0082] During the board production test process, the board production test system consists of a test control PC, test equipment, and the device under test; each device usually contains multiple different types of functional units such as main control units / processor units, and each functional unit is connected through different communication interfaces or communication buses. There is also a need for data communication between two functional units with different communication interfaces or no direct communication interface; based on the above problem scenario, this solution constructs networking nodes according to the physical interfaces in the board production test system to realize a multi-node networking communication network based on different buses or communication interfaces. As long as there are communication links between the networking nodes, a multi-node networking communication network can be formed. In traditional designs, only nodes on the same communication bus can form a communication network. In this solution, even if different communication buses or communication interfaces are used, networking nodes can be added to the network, and any two nodes in the network can communicate with each other.
[0083] Step 2: Obtain the board production test task, and match the networking strategy according to the board production test task; the networking strategy includes a networking mode and a networking method; the networking method includes a designated dominant node networking method and a node active broadcast networking method; the networking mode includes a single mode and a mixed mode; in the single mode, the board production test task is executed in the process of network communication in the designated dominant node networking method; in the mixed mode, the board production test task is executed in the process of network communication in the designated dominant node networking method and the node active broadcast networking method, and the networking mode changes dynamically with the execution stage of the board production test task;
[0084] The board production test tasks in this solution include: ICT test tasks, burning and calibration tasks, AOI inspection tasks, FCT functional test tasks, aging test tasks and AGV collaborative test tasks.
[0085] The method of matching the networking strategy according to the board production test task includes:
[0086] For ICT test tasks and programming and calibration tasks, single mode is used as the networking strategy;
[0087] For AOI inspection tasks, FCT functional test tasks, aging test tasks, and AGV collaborative test tasks, a hybrid mode is used as the networking strategy; the specific methods include:
[0088] Obtain the real-time execution data of each board production test task and check whether the real-time execution data meets the switching trigger conditions; if so, switch to the corresponding networking mode according to the switching trigger conditions;
[0089] The switching triggering conditions include:
[0090] a. When it is detected that all test equipment in the board production test system has been powered on, or an initialization configuration instruction has been received, the designated leading node networking mode is entered;
[0091] b. When it is detected that at least N functional units need to perform parallel tasks, or when a start test instruction is received, the node is switched to the active broadcast networking mode;
[0092] c. When it is detected that the test completion rate meets the preset completion rate threshold, which is set to 95% in this embodiment, or when a data collection instruction is received, the network is switched to the designated leading node networking mode;
[0093] d. When a failure of key test equipment is detected or an emergency interrupt signal is received, the network is forced to switch to the dominant node networking mode.
[0094] The PCB production testing process includes functional testing, ICT testing, FCT testing, programming, burn-in testing, and AOI inspection. Each testing phase may require different equipment configurations and network requirements. For example, ICT testing may require simultaneous execution of multiple test points, with fixed equipment locations and high-precision timing control. In this case, a designated master node networking approach may be more appropriate, as the master node can be centrally scheduled to ensure synchronization. Aging tests may involve multiple devices running for a long time, and the devices may need dynamic adjustment. If a device fails, the node active broadcast networking method may have better self-healing capabilities. In addition, AOI inspection equipment may require high-speed data transmission, but the device location is fixed, so dynamic networking may not be required. At this time, the designated dominant node networking method is more appropriate. If there are moving robotic arms or AGV carts in the test environment, they need to dynamically join the network, and the node active broadcast networking method is more suitable. In order to take into account both control accuracy and dynamic adaptability, AOI inspection, FCT functional testing, aging testing and AGV collaborative testing in this solution are networked in a mixed mode, and control accuracy and dynamic adaptability are taken into account through phased or functional mode switching. ICT test tasks and burning and calibration tasks maintain a single mode of networking communication using the designated dominant node networking method to ensure safety and timing rigor.
[0095] Step 3: Each networking node forms a network and communicates according to the networking strategy. This step specifically includes the following methods:
[0096] Configuring a communication protocol for each networking node; the message information data packet of the communication protocol includes a functional data packet and a common data packet; the message information data packet includes: a sender node ID, a source node ID, and a target node ID;
[0097] Configuring message information data packets based on the communication protocol; the common data packets include collection data packets; the functional data packets include: one or more of networking data packets, remote call data packets, reply data packets and request retransmission data packets;
[0098] Initialize the message information of each network node, and each network node forms a network and communicates according to the networking strategy.
[0099] Said configuration of communication protocol for each networking node; Figure 2 As shown, including methods:
[0100] Configure each networking node as both sender and receiver;
[0101] The sender performs the following process:
[0102] S1, sending a message information data packet to the receiver. If the message information data packet contains a common data packet, proceed to step S2, otherwise, end the communication;
[0103] S2, wait for the reply from the receiver. If no reply is received within the T1 time period, return to S1. If a reply is received within the T1 time period, determine whether the reply content is a request for retransmission; if so, return to step S1; otherwise, end the communication;
[0104] The receiving party performs the following process:
[0105] K1, waiting for the header of the message information data packet;
[0106] K2, if the packet header i is received within the time period T2, then after the message information data packet corresponding to the packet header i is transmitted, it enters step K3 and returns to step K1; if the packet header is not received within the time period T2, then it returns to step K1;
[0107] K3, if the message information data is a common data packet, proceed to step K4; if the message information data contains a functional data packet, execute the corresponding function and return to step K1;
[0108] K4, perform data verification on the common data packet; if the data verification passes, reply completion to the sender and proceed to step K5; otherwise, reply retransmission request to the sender and return to step K1;
[0109] K5, determines whether the target node ID of the normal data packet matches the receiving node ID. If so, it runs the normal data packet callback and returns to step K1. Otherwise, it calls the forwarding callback and returns to step K1. The specific processing and forwarding process after the receiving node receives the normal data packet is as follows: Figure 3 and Figure 4In the forwarding process, if the route to the target node does not exist in the routing table, no action is taken. If the communication interface recorded in the routing information is the same as the interface that received the packet, it means that the target node and the local node may be on the same communication bus, and no forwarding is performed. If a route is found in the routing table and the routing interface is not the interface that received the packet, the packet data is forwarded to the routing interface.
[0110] In this embodiment, the communication protocol uses hexadecimal and network byte order (big endian) for transmission. The field information of the message information data packet is shown in Table 1:
[0111] Table 1 Message information data packet fields
[0112]
[0113] Example 2: When the message information data contains a networking data packet, it indicates the start of self-networking. The process of self-networking is to let all nodes in the network build a routing table to access other nodes. The self-networking process can be done by the application layer specifying a node as the dominant node, and the remaining nodes wait for networking, that is, specifying the dominant node networking method; it can also be dynamically connected to the network. After each node is initialized, it sends its own networking packet to the network. After receiving the networking packet, the remaining nodes will automatically add the node information to their own routing table and send their own networking packet to it. The node actively broadcasts the networking method. Each node has a routing table that records which node it wants to access and through which of its own communication interfaces. For example, Figure 5 A multi-node communication network is shown in FIG, where the routing table finally formed by each node is as follows Figure 6 shown.
[0114] like Figure 7 As shown, the receiver performs the following process:
[0115] H1, determine whether the source node ID in the current message information data packet matches the receiver node ID. If so, end; otherwise, go to step H2;
[0116] H2, if the current networking data packet is a networking packet, determine whether the source node ID in the current message information data packet already exists in the routing table of the receiving node; if so, return to step H1; otherwise, add the source node ID in the current message information data packet to the routing table of the receiving node, call the forwarding callback, and end;
[0117] If the current networking data packet is a networking start packet, the forwarding callback is called and the process ends, and the networking packet is sent to all communication channels of the receiving node;
[0118] If the current networking data packet is a reassembled network packet, the routing table of the receiving node is deleted and the networking packet is sent to all communication channels of the receiving node. Specifically, if one of the nodes is selected as the leading node, the workflow is as follows: Figure 8 shown.
[0119] In this embodiment, the networking start packet and reassembly packet are packets sent by the dominant node in a designated dominant node networking mode. These packets do not exist in a node-initiated broadcast networking mode. A node's networking data packet is received by all nodes in the network, making it known to all nodes and enabling routing. If the source node ID (SrcID) and the receiving node ID (SelfID) of a received networking packet are equal, it indicates that the self-sent networking packet has been transmitted back, and no further operations are performed. Upon receiving the networking packet, the node forwards the networking packet to the other communication interfaces of the receiving node. Upon receiving the networking initiation packet, the node sends the networking packet to all interfaces of the receiving node. Upon receiving the reassembly packet, the node deletes the existing routing table and then sends the networking packet to all interfaces of the receiving node. Upon receiving a networking packet from another node, the node first checks the routing table for the node ID. If the node ID does not exist, the node adds the routing information to the routing table. Routing information consists of the node ID and the communication interface. The routing interface is the interface that received the packet data. If you subsequently want to send data to this node, you can send it directly through this interface. If the source node ID exists in the routing table, it means that the network packet has already come from this node, and no subsequent operations will be performed.
[0120] Example 3: During the actual production test process, when the processor unit A on the first test device needs to perform calculations on the test data, the relevant calculation functions can only be executed by the processor unit B on the second test device. In the traditional method, the first test device cannot communicate with the second test device and can only wait for the second test device to complete the calculation before manually transmitting the data to the first test device, resulting in low test efficiency. This embodiment enables processor unit A to remotely call the calculation function on the processor unit B node by writing a remote call data packet in the message information data, and implements remote calls based on a multi-node communication protocol. The field information of the remote call data packet is shown in Table 2 below. After the processor unit B node performs the relevant calculations as the executor, it returns the field information to the processor unit A node as shown in Table 3.
[0121] Table 2 Remote call fields
[0122]
[0123] Table 3 Executor return fields
[0124]
[0125] The establishment of a conventional communication network often requires that all nodes use the same communication bus, such as Ethernet, CAN, etc.; even if applications spanning different networks appear, it is necessary to develop business logic for cross-network communication, and the implementation and debugging processes are relatively complex; this solution provides a communication method based on physical interfaces and multi-node networking, which enables networking nodes using different buses and different communication interfaces to form a communication network. Data can be transmitted between any two networking nodes in the network, greatly simplifying the development process of cross-bus networking communication.
[0126] Embodiment 4: This embodiment provides a communication system based on a physical interface and multi-node networking, which is used to implement the communication method based on a physical interface and multi-node networking described in Embodiments 1 to 3; the system includes:
[0127] A construction module is used to construct a networking node based on the physical interface in the board production test system;
[0128] A strategy generation module is used to obtain a board production test task and match a networking strategy according to the board production test task; the networking strategy includes a networking mode and a networking method; the networking method includes a designated dominant node networking method and a node active broadcast networking method; the networking mode includes a single mode and a mixed mode; in the single mode, networking communication is performed in the designated dominant node networking method during the execution of the board production test task; in the mixed mode, networking communication is performed in the designated dominant node networking method and the node active broadcast networking method during the execution of the board production test task, and the networking mode changes dynamically with the execution stage of the board production test task;
[0129] The networking and communication module is used for networking and communication between networking nodes according to the networking strategy.
[0130] Example 5: This example provides Figure 9 The communication architecture shown is a communication method based on a physical interface and multi-node networking; the communication implementation is based on the communication interface and multi-node communication protocol in the board production test system, wherein the communication interface is the physical data interface of each node in the system, and the multi-node communication protocol is the data communication format of each node in the system; it is composed of a driver layer of the communication interface and an interface layer, a protocol layer and a networking layer of the multi-node communication protocol.
[0131] The driver layer is used to implement read and write drivers for different communication interfaces, which are independently implemented by various processors of production and testing equipment; the interface layer connects to the driver layer and unifies the read and write interface; the protocol layer is used for packet-based communication, realizes ID-based communication, and implements functions such as data verification and response; the networking layer is used to realize automatic networking, packet forwarding, and communication route construction.
[0132] In the actual production test process, the production test system consists of a test control PC, test equipment and the device under test. Usually, each device in the test system contains multiple different functional units, such as the main control unit and the processor unit. These functional units are used as networking nodes, and each node is connected through different communication interfaces. There is also a need for data communication between two nodes with different communication interfaces or without direct communication interfaces. Figure 10 As shown in the figure, based on the above communication architecture, a communication network is composed of multiple nodes (Node1~Node8) using different buses or communication interfaces (IIC, SPI bus, RS485 bus, RS232 bus, CAN bus). As long as there are communication links between the nodes, a communication network can be formed. In the traditional design, only nodes on the same bus can form a communication network. After using the technology of this solution, even if different communication buses or communication interfaces are used, nodes can be added to the network, and any two nodes in the network can communicate with each other.
[0133] Embodiment 6: This embodiment provides a computer-readable medium having a computer program stored thereon. The computer program is executed by a processor to implement a communication method based on a physical interface and multi-node networking as described in Embodiment 1. Specifically, the following steps are performed:
[0134] Step 1: Build networking nodes based on the physical interfaces in the board production test system;
[0135] Step 2: Obtain the board production test task, and match the networking strategy according to the board production test task; the networking strategy includes a networking mode and a networking method; the networking method includes a designated dominant node networking method and a node active broadcast networking method; the networking mode includes a single mode and a mixed mode; in the single mode, the board production test task is executed in the process of network communication in the designated dominant node networking method; in the mixed mode, the board production test task is executed in the process of network communication in the designated dominant node networking method and the node active broadcast networking method, and the networking mode changes dynamically with the execution stage of the board production test task;
[0136] Step 3: Each networking node forms a network and communicates according to the networking strategy.
[0137] The specific implementation methods described above further illustrate the objectives, technical solutions and beneficial effects of the present invention in detail. It should be understood that the above description is only a specific implementation method of the present invention and is not intended to limit the scope of protection of the present invention. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention should be included in the scope of protection of the present invention.
Claims
1. A communication method based on a physical interface and an ad hoc network, characterized in that: The communication method is used in a board production test process, and the communication method includes: A networking node is constructed based on a physical interface in a board production test system; specifically, the method includes: obtaining functional units of each test device in the board production test system; traversing all functional units to select a target functional unit; when functional unit i is connected to at least two arbitrary functional units via a communication channel, functional unit i is used as the target functional unit; the communication channel includes a communication interface or a communication bus; and all target functional units are used as networking nodes; Obtain a board production test task, and match a networking strategy according to the board production test task; the networking strategy includes a networking mode and a networking method; the networking method includes a designated dominant node networking method and a node active broadcast networking method; the networking mode includes a single mode and a mixed mode; in the single mode, networking communication is performed in the designated dominant node networking method during the execution of the board production test task; in the mixed mode, networking communication is performed in the designated dominant node networking method and the node active broadcast networking method during the execution of the board production test task, and the networking method changes dynamically with the execution stage of the board production test task; the board production test task includes: ICT test task, burning and calibration task, AOI detection task, FCT functional test task, aging test task and AGV collaborative test task; the networking strategy is matched according to the board production test task; including a method: for ICT test task and burning and calibration task, a single mode is used as the networking strategy; for AOI detection task, FCT functional test task, aging test task and AGV collaborative test task, a mixed mode is used as the networking strategy; Each networking node conducts networking and communication according to the networking strategy; The board production test system consists of multiple heterogeneous devices, including online testers, automated optical detectors, functional test benches, burning equipment, aging test chambers and automatic guided vehicles; each heterogeneous device needs to exchange data in real time during the test process; the exchanged data includes: transmitting test instructions, synchronizing timing, sharing status information and returning test results.
2. A communication method based on a physical interface and an ad hoc network according to claim 1, characterized in that: For the AOI inspection task, FCT functional test task, aging test task and AGV collaborative test task, a hybrid mode is used as a networking strategy; including the following methods: Obtain the real-time execution data of each board production test task and detect whether the real-time execution data meets the switching trigger conditions; If yes, switch to the corresponding networking mode according to the switching trigger condition; The switching triggering conditions include: a. When it is detected that all test equipment in the board production test system has been powered on, or an initialization configuration instruction has been received, the designated leading node networking mode is entered; b. When it is detected that at least N functional units need to perform parallel tasks, or when a test start instruction is received, the node switches to the active broadcast networking mode; c. When the test completion rate is detected to meet the preset completion rate threshold, or when a data collection instruction is received, the network is switched to the designated leading node; d. When a failure of key test equipment is detected or an emergency interrupt signal is received, the network is forced to switch to the dominant node networking mode.
3. The communication method based on a physical interface and an ad hoc network according to claim 1, characterized in that: Each networking node performs networking and communication according to the networking strategy; Includes methods: Configuring a communication protocol for each networking node; the message information data packets of the communication protocol include functional data packets and common data packets; The message information data packet includes: sender node ID, source node ID and target node ID; Configuring message information data packets based on the communication protocol; the common data packets include collection data packets; the functional data packets include: one or more of networking data packets, remote call data packets, reply data packets and request retransmission data packets; Initialize the message information of each network node, and each network node forms a network and communicates according to the networking strategy.
4. The communication method based on a physical interface and an ad hoc network according to claim 3, characterized in that: Said configuring communication protocols for each networking node includes: method: Configure each networking node as both sender and receiver; The sender performs the following process: S1, sending a message information data packet to the receiver. If the message information data packet contains a common data packet, proceed to step S2, otherwise, end the communication; S2, wait for the reply from the receiver. If no reply is received within the T1 time period, return to S1. If a reply is received within the T1 time period, determine whether the reply content is a request for retransmission; if so, return to step S1; otherwise, end the communication; The receiving party performs the following process: K1, waiting for the header of the message information data packet; K2, if the packet header i is received within the time period T2, then after the message information data packet corresponding to the packet header i is transmitted, it enters step K3 and returns to step K1; if the packet header is not received within the time period T2, then it returns to step K1; K3, if the message information data is a common data packet, proceed to step K4; if the message information data contains a functional data packet, execute the corresponding function and return to step K1; K4, perform data verification on the common data packet; if the data verification passes, reply completion to the sender and proceed to step K5; Otherwise, reply to the sender to request retransmission and return to step K1; K5, determines whether the target node ID of the common data packet matches the receiving node ID. If so, runs the common data packet callback and returns to step K1. Otherwise, calls the forwarding callback and returns to step K1.
5. The communication method based on physical interface and ad hoc network according to claim 4, characterized in that: When the message contains a networking data packet, the receiver performs the following process: H1, determine whether the source node ID in the current message information data packet matches the receiver node ID. If so, end; otherwise, go to step H2; H2, if the current networking data packet is a networking packet, determine whether the source node ID in the current message information data packet already exists in the routing table of the receiving node; if so, return to step H1; otherwise, add the source node ID in the current message information data packet to the routing table of the receiving node, call the forwarding callback, and end; If the current networking data packet is a networking start packet, the forwarding callback is called and the process ends, and the networking packet is sent to all communication channels of the receiving node; If the current networking data packet is a reassembled network packet, the routing table of the receiving node is deleted, and the networking packet is sent to all communication channels of the receiving node.
6. A communication system based on a physical interface and an ad hoc network, characterized in that: A communication method based on a physical interface and an ad hoc network according to any one of claims 1 to 5; the system comprises: A construction module is used to construct a networking node based on the physical interface in the board production test system; A strategy generation module is used to obtain a board production test task and match a networking strategy according to the board production test task; the networking strategy includes a networking mode and a networking method; the networking method includes a designated dominant node networking method and a node active broadcast networking method; the networking mode includes a single mode and a mixed mode; in the single mode, networking communication is performed in the designated dominant node networking method during the execution of the board production test task; in the mixed mode, networking communication is performed in the designated dominant node networking method and the node active broadcast networking method during the execution of the board production test task, and the networking mode changes dynamically with the execution stage of the board production test task; The networking and communication module is used for networking and communication between networking nodes according to the networking strategy.
7. A computer-readable medium having a computer program stored thereon, characterized in that: The computer program is executed by a processor to implement a communication method based on a physical interface and an ad hoc network as described in any one of claims 1 to 5.
Citation Information
Patent Citations
Apparatus and method for testing PCBA function
CN108076660A
BSP board card bus interface test method and device and storage medium
CN113848850A