A multi-processor layered message communication system and control method

By introducing a hierarchical message communication mechanism into a multiprocessor system, the business logic and physical link are decoupled, solving the problems of poor maintainability and portability in existing technologies and improving the system's flexibility and stability.

CN123137967APending Publication Date: 2026-11-20SHANGHAI QINGPU TECHNOLOGY CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202611586763.8
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-10-14
Publication Date
2026-11-20

AI Technical Summary

Technical Problem

Existing multiprocessor control systems require extensive code modifications when replacing the master or slave processor platform or adjusting link parameters, resulting in poor maintainability and portability.

Method used

A multi-processor hierarchical message communication system is adopted, including a master control processor, slave function processing nodes and cross-node communication framework. The application layer is responsible for message encoding and decoding, the transport layer uses task identifiers for end-to-end addressing, the link layer performs frame delimitation and verification, the physical link delivers messages through task identifiers, and the frame de-distribution unit completes in a non-interrupt context.

Benefits of technology

This decouples business logic from physical links, reduces the amount of code modification required when changing processor platforms or adjusting link parameters, and improves the maintainability and portability of the system.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN123137967A_ABST
    Figure CN123137967A_ABST
Patent Text Reader

Abstract

The application relates to the technical field of industrial control, in particular to a multi-processor layered message communication system and a control method, the communication system comprising a master control processor, at least two slave functional processing nodes and a cross-node communication framework; wherein the master control processor is connected with the at least two slave functional processing nodes through a physical link; the cross-node communication framework comprises an application layer, a transmission layer and a link layer. Through the layered setting of the application layer, the transmission layer and the link layer, the service logic only faces the message and command semantics, the addressing, the delimiting and the checking are uniformly processed by the lower layer, so that the service module does not need to perceive the physical link type and the peripheral details, and when the processor platform is replaced or the link parameter is adjusted, only the lower layer implementation needs to be modified, the service code remains stable, and the problems of poor maintainability and poor portability of the multi-processor control system are solved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of industrial control technology, and in particular to a multiprocessor hierarchical message communication system and control method. Background Technology

[0002] Molecular pumps (such as turbomolecular pumps), magnetic levitation vacuum systems, and cavity vacuum acquisition and maintenance equipment used in processes such as semiconductor thin film deposition and etching place high demands on the real-time performance, reliability, and long-term continuous operation capability of the control system. The controllers of such equipment typically employ a multi-processor hardware architecture: the main control processor is responsible for system state machine management, human-machine interaction, and issuing commands and aggregating status data from lower-level nodes; high-speed closed-loop control for rotor support / levitation multi-axis systems and high-speed closed-loop control for rotary drives (such as field-oriented control) are distributed among different subordinate functional processors. Furthermore, there are generally no direct communication links between subordinate processors; cross-node operations must be forwarded and aggregated through the main control processor. Under this architecture, the message communication mechanism between the main control processor and each subordinate processor directly determines the availability and diagnosability of the entire control system.

[0003] In existing technologies, such multiprocessor control systems have business logic and physical links bound together in practical applications. When changing the master or slave processor platform or adjusting the link parameters, extensive code modifications are required, resulting in poor maintainability and portability. Summary of the Invention

[0004] To address the poor maintainability and portability of existing multiprocessor control systems, this invention provides a multiprocessor hierarchical message communication system. This system enables hierarchical decoupling, which facilitates the migration of master and slave node platforms and the adjustment of link parameters, thus solving the problem of poor maintainability and portability of existing multiprocessor control systems.

[0005] The technical solution adopted by this invention to solve its technical problem is: A multiprocessor hierarchical message communication system includes a master processor, at least two subordinate functional processing nodes, and a cross-node communication framework; wherein, The main control processor is connected to at least two subordinate function processing nodes via physical links; The cross-node communication framework includes an application layer, a transport layer, and a link layer; The application layer is used to perform message encoding and decoding related to business operations; The transport layer uses task identifiers for end-to-end addressing, and the bit field of the task identifier is divided into a processing node field and a local task sequence number. The link layer delivers the message to the message queue of the target within the processor according to the target identifier of the message, or sends it to the cross-node target via the physical link after adding frame delimitation and verification fields; On the receiving path, the interrupt service routine of the communication interface only writes the received raw bytes into the circular receive buffer, while frame delimiting, verification, and routing are completed by the deframe distribution unit in a non-interrupt context.

[0006] Optionally, the frame structure defined by the transport layer includes length, receiver identifier, sender identifier, command word, variable-length data payload, and cyclic redundancy check.

[0007] Optionally, the physical link includes a synchronous serial full-duplex link and an asynchronous serial link; the master control processor is connected to a first slave function processing node via the synchronous serial full-duplex link, and the first slave function processing node performs rotor support / suspended multi-axis high-speed closed-loop control; the master control processor is connected to a second slave function processing node via the asynchronous serial link, and the second slave function processing node performs rotary drive high-speed closed-loop control.

[0008] Optionally, the master control processor exchanges fixed-length full-duplex data with the first slave function processing node via the synchronous serial full-duplex link at a predetermined cycle, and the commands to be sent are queued and sent in the next exchange cycle; the synchronous serial full-duplex link is a shared bus, and the bus target selection is completed through chip select or general input / output interface before communication.

[0009] Optionally, it may also include a hardware abstraction layer, which encapsulates asynchronous communication interface peripherals and / or synchronous communication interface peripherals, and provides a unified interface for initialization, sending, receiving and bus target selection.

[0010] Optionally, the service scheduling module within the subordinate function processing node interacts with the control algorithm running in the timer interrupt context via a shared data area. The shared data area adopts a single-write, multi-read partition and ensures data consistency through a write completion flag and instruction sequence number.

[0011] Another objective of this invention is to provide a multiprocessor hierarchical message communication control method, applied to the multiprocessor hierarchical message communication system described above; the multiprocessor hierarchical message communication control method includes: a message sending step: the application layer encodes and decodes the service message and then hands it over to the transport layer; the transport layer performs end-to-end addressing using a task identifier, the bit field of the task identifier is divided into a processing node field and a local task sequence number, the transport layer determines the target node based on the processing node field; if the target node is the current processor, the link layer delivers the message to the message queue of the target within the current processor; if the target node is a cross-node target, the link layer adds frame delimiter and check fields to the message and then sends it to the cross-node target via the physical link; Message reception steps: In the interrupt service routine of the communication interface, only the received raw bytes are written to the circular receive buffer and the write pointer is updated; in the non-interrupt context, the frame de-framing and distribution unit retrieves the byte stream from the circular receive buffer, performs frame delimiting and verification in a state machine manner, and routes the verified messages to the target message queue according to the receiver identifier. Non-blocking request initiation steps: After the master control side business module initiates a request to the subordinate function processing node through the cross-node communication framework, it immediately returns and registers the pending transaction description, which includes a suspension flag, command type, sending time, and timing information used for timeout determination; Periodic processing steps: In an independent periodic processing process, inbound messages are processed. Based on the predetermined correspondence between response command words and request command words, the inbound messages are matched with the pending transaction descriptions. When the expected response command word is matched, the result code and error code are parsed, and the pending flag is cleared. Timeout handling steps: If the expected response command word is not matched after the predetermined timeout period, the timeout result is set and logged; Status confirmation step: When the response only indicates that the command has been accepted, the actual running status of the subordinate function processing node is refreshed and confirmed through periodic status queries, so as to separate the command acceptance status from the actual running status.

[0012] Optionally, in the message sending step, the frame delimiter, the verification field, and the message content constitute a frame structure, which includes a length, a receiver identifier, a sender identifier, a command word, a variable-length data payload, and a cyclic redundancy check; in the periodic processing step, matching the inbound message with the pending transaction description includes: matching the response command word in the inbound message with the command type of the pending transaction description based on a predetermined correspondence between the response command word and the request command word.

[0013] Optionally, in the message sending step, the master control processor exchanges fixed-length full-duplex data with the first slave function processing node via a synchronous serial full-duplex link at a predetermined cycle. The command to be sent is queued and sent in the next exchange cycle. When the synchronous serial full-duplex link is a shared bus, the bus target selection is completed through chip select or general input / output interface before communication. The message sent via the asynchronous serial link is carried in a variable-length frame.

[0014] Optionally, it also includes a collaboration step within the subordinate node: within the subordinate function processing node, the service scheduling module interacts with the control algorithm running in the timer interrupt context via a shared data area. The shared data area adopts a single-write, multi-read partition and ensures data consistency through a write completion flag and instruction sequence number. The service scheduling module then interacts with the main control processor via the cross-node communication framework.

[0015] The beneficial effects of this invention are: The multiprocessor layered message communication system provided by this invention, through the layered setup of application layer, transport layer and link layer, enables business logic to only deal with message and command semantics, while addressing, delimitation and verification are handled uniformly by the lower layer. As a result, business modules do not need to be aware of physical link type and peripheral details. When changing processor platform or adjusting link parameters, only the lower layer implementation needs to be modified, and the business code remains stable, solving the problem of poor maintainability and portability of multiprocessor control systems. Attached Figure Description

[0016] The present invention will be further described below with reference to the accompanying drawings and embodiments.

[0017] Figure 1 This is a schematic diagram of the synchronous / asynchronous dual-link topology of the master and slave nodes in this invention; Figure 2 This is a schematic diagram of the software structure for human-machine interface and system control and downward delegation on the main control side in this invention; Figure 3 This is a schematic diagram of the inter-module communication layered model in this invention; Figure 4 This is a schematic diagram of the cross-node receiving path in this invention. Detailed Implementation

[0018] The present invention will now be described in further detail. The embodiments described below are exemplary and intended to explain the present invention, and should not be construed as limiting the present invention. All other embodiments obtained by those skilled in the art based on the embodiments of the present invention without inventive effort are within the scope of protection of the present invention.

[0019] To address the poor maintainability and portability of existing multiprocessor control systems, this invention provides a multiprocessor hierarchical message communication system. This system includes a master processor, at least two subordinate functional processing nodes, and a cross-node communication framework. The master processor is connected to the at least two subordinate functional processing nodes via physical links; there is no direct physical interconnection between the at least two subordinate functional processing nodes. The cross-node communication framework includes an application layer, a transport layer, and a link layer. The application layer performs business-related message encoding and decoding. The transport layer uses task identifiers for end-to-end addressing. The task identifier's bit field is divided into a processing node field and a local task sequence number, allowing the same identifier to simultaneously represent the target node and the target task within that node. The sending side only needs to compare the processing node field with its own node number to determine whether the message belongs to intra-node delivery or cross-node transmission. Local communication and cross-node communication share the same set of addressing semantics, avoiding the complexity and maintenance burden caused by the coexistence of two addressing mechanisms. The link layer, based on the message's target identifier, delivers the message to the target's message queue within the processor, or... After adding frame delimiting and verification fields, the data is sent to the cross-node target via the physical link. That is, the link layer performs unified traffic splitting based on the target identifier of the message, either local enqueuing or cross-node framing. This centralizes frame boundary identification, buffer management, and routing decisions at the link layer. Regardless of whether the underlying layer is an asynchronous byte stream or a synchronous full-duplex link, framing and routing are performed according to a unified model. This eliminates the causes of frame boundary identification errors and buffer overflows from a mechanism perspective. Intermittent faults can be located and diagnosed due to the verification and logging mechanisms. This solves the problem of lacking a unified framing and routing model when asynchronous byte streams and synchronous full-duplex links are used together, which easily leads to frame boundary identification errors, buffer overflows, and difficult-to-locate intermittent faults with poor diagnosability. On the receiving path, the interrupt service routine of the communication interface only writes the received raw bytes into the circular receive buffer. Frame delimiting, verification, and routing are completed by the deframe distribution unit in a non-interrupt context. This ensures that the interrupt execution time does not change with message length, bit error rate, or protocol complexity. The execution timing of the high-speed closed-loop control algorithm running in the timer interrupt is not affected by communication behavior, and the determinism of the control cycle is guaranteed.

[0020] The multiprocessor layered message communication system provided by this invention, through the layered setup of application layer, transport layer and link layer, enables business logic to only deal with message and command semantics, while addressing, delimitation and verification are handled uniformly by the lower layer. As a result, business modules do not need to be aware of physical link type and peripheral details. When changing processor platform or adjusting link parameters, only the lower layer implementation needs to be modified, and the business code remains stable, solving the problem of poor maintainability and portability of multiprocessor control systems.

[0021] Specifically, the preferred frame structure defined by the transport layer of this invention includes length, receiver identifier, sender identifier, command word, variable-length data payload, and cyclic redundancy check. Through the unified frame structure of length field, sender and receiver identifiers, command word, variable-length payload, and CRC, the delimitation is clear, the routing and response are traceable, erroneous frames can be detected and located by combining logs, thus improving diagnostics.

[0022] The preferred physical links of this invention include a synchronous serial full-duplex link and an asynchronous serial link. The master control processor is connected to a first slave function processing node via the synchronous serial full-duplex link. The first slave function processing node performs high-speed closed-loop control of rotor support / suspended multi-axis systems. The master control processor is connected to a second slave function processing node via the asynchronous serial link. The second slave function processing node performs high-speed closed-loop control of rotary drive systems. By using the synchronous serial full-duplex link to carry the support / suspended multi-axis closed-loop control and the asynchronous serial link to carry the rotary drive closed-loop control, the advantages of both types of services are utilized: the support side achieves strict synchronization and high refresh rate, while the drive side achieves flexible carrying of variable-length commands. This avoids the conflicting requirements of synchronous high refresh rate for support control and variable-length command requirements for rotary drive services regarding link timing characteristics.

[0023] In this invention, the main control processor preferably performs fixed-length full-duplex data exchange with the first subordinate functional processing node via a synchronous serial full-duplex link at predetermined cycles. Commands to be sent are queued and sent in the next exchange cycle. The synchronous serial full-duplex link is a shared bus, and the bus target is selected before communication via chip select or general-purpose input / output interface. Through fixed-length full-duplex cycle exchange, command queuing to the next cycle, and chip select / IO target selection, the exchange timing is predictable, bandwidth can be reserved, multiple devices share the bus without conflict, and contention among multiple devices on the shared bus and unpredictable synchronous service timing are avoided.

[0024] Furthermore, the preferred multiprocessor hierarchical message communication system of the present invention also includes a hardware abstraction layer. This hardware abstraction layer encapsulates asynchronous communication interface peripherals and / or synchronous communication interface peripherals, providing unified initialization, sending, receiving, and bus target selection interfaces. By uniformly encapsulating the initialization, sending, receiving, and bus selection interfaces through the hardware abstraction layer, the services and peripherals are decoupled. Changing the processor platform only requires reimplementing the hardware abstraction layer, solving the problem of high platform migration costs caused by service modules directly accessing peripheral registers.

[0025] In this invention, the service scheduling module within the subordinate function processing node and the control algorithm running in the timer interrupt context interact through a shared data area. The shared data area adopts a single-write, multi-read partitioning, and data consistency is ensured by writing completion flags and instruction sequence numbers, so as to ensure data consistency under lock-free conditions and avoid timing jitter caused by mutual exclusion between interrupts and the main loop.

[0026] In summary, this invention provides an implementable, scalable communication system with predictable timing behavior in multiprocessor embedded control scenarios with limited resources and strong real-time control cycles, while taking into account both long-term continuous operation availability and diagnosability of abnormal scenarios.

[0027] Another objective of this invention is to provide a multiprocessor hierarchical message communication control method, which is applied to the multiprocessor hierarchical message communication system described above. Specifically, the multiprocessor hierarchical message communication control method includes: a message sending step: the application layer encodes and decodes the service message and then hands it over to the transport layer; the transport layer performs end-to-end addressing using a task identifier, and the bit field of the task identifier is divided into a processing node field and a local task sequence number; the transport layer determines the target node based on the processing node field; if the target node is the current processor, the link layer delivers the message to the message queue of the target within the current processor; if the target node is a cross-node target, the link layer adds frame delimiter and check fields to the message and then sends it to the cross-node target via the physical link; Message reception steps: In the interrupt service routine of the communication interface, only the received raw bytes are written to the circular receive buffer and the write pointer is updated; in the non-interrupt context, the frame de-framing and distribution unit retrieves the byte stream from the circular receive buffer, performs frame delimiting and verification in a state machine manner, and routes the verified messages to the target message queue according to the receiver identifier. The message sending and receiving steps make the cross-node communication processing path clear and traceable. The local / cross-node splitting on the sending side and the interruption, buffering, and deframe distribution on the receiving side are asynchronous, which together ensures the determinism of the control cycle and the real-time performance of the communication.

[0028] Non-blocking request initiation steps: After the master control side business module initiates a request to the subordinate function processing node through the cross-node communication framework, it immediately returns and registers the pending transaction description, which includes the suspension flag, command type, sending time and timing information used for timeout determination; This non-blocking request initiation step allows the main control side business module to return immediately after initiating a request, only registering the description of the pending transaction, thus avoiding blocking on the call stack and waiting for a response, thereby not slowing down the human-machine interface refresh and the system state machine progression.

[0029] Periodic processing steps: Inbound messages are processed in an independent periodic processing process. Based on the predetermined correspondence between response command words and request command words, inbound messages are matched with pending transaction descriptions. When the expected response command word is matched, the result code and error code are parsed and the pending flag is cleared. This cycle processing step completes inbound message processing and response matching within an independent cycle, enabling the decoupled processing of requests and responses to have a predictable timing.

[0030] Timeout handling steps: If the expected response command word is not matched after the predetermined timeout period, the timeout result is set and logged; This timeout handling step sets the timeout result and logs it when no expected response is found after the predetermined timeout period, avoiding permanent suspension due to lost response and improving the diagnosability of abnormal scenarios.

[0031] Status confirmation steps: When the response only indicates that the command has been accepted, the actual running status of the subordinate function processing node is refreshed and confirmed through periodic status queries, so as to separate the command acceptance status from the actual running status. This status confirmation step confirms the actual operating status through periodic status queries, separating the command acceptance status from the actual operating status. This avoids misjudging a command as having entered the target operating state when it has already been accepted, thus improving system robustness.

[0032] Furthermore, in the preferred embodiment of the present invention, in the message sending step, frame delimitation, verification fields, and message content constitute a frame structure. The frame structure includes length, receiver identifier, sender identifier, command word, variable-length data payload, and cyclic redundancy check, so that the sender and receiver have a consistent agreement on frame boundaries and content, improving the accuracy and fault tolerance of parsing. In the periodic processing step, matching the inbound message with the pending transaction description includes: matching the response command word in the inbound message with the command type of the pending transaction description according to the predetermined correspondence between the response command word and the request command word, so that the response matching process is predictable and determinable, and the result code and error code can be accurately parsed after successful matching, further improving the reliability and diagnosability of non-blocking transaction processing.

[0033] Furthermore, in the preferred embodiment of this invention, during the message sending step, the main control processor performs fixed-length full-duplex data exchange with the first subordinate functional processing node via a synchronous serial full-duplex link at a predetermined cycle. Commands to be sent are queued and sent in the next exchange cycle. When the synchronous serial full-duplex link is a shared bus, bus target selection is performed before communication via chip select or a general-purpose input / output interface. Messages sent via the asynchronous serial link are carried in variable-length frames. This part further clarifies the differentiated processing between synchronous and asynchronous channels at the method level. Specifically, the fixed-length full-duplex data exchange and command queuing via the synchronous serial full-duplex link ensures timing determinism and prevents command loss. In a shared bus scenario, target selection via chip select or a general-purpose input / output interface ensures reliable addressing for multiple connected devices. Messages sent via the asynchronous serial link are carried in variable-length frames, adapting to byte streams and variable-length services. Thus, within the same control method framework, both high synchronization requirements and flexible data organization requirements are considered, achieving a good trade-off between real-time performance and versatility.

[0034] The preferred embodiment of this invention's multiprocessor hierarchical message communication control method further includes a slave node internal collaboration step: within the slave functional processing node, the service scheduling module and the control algorithm running in a timer interrupt context interact via a shared data area. This shared data area employs a single-write, multi-read partitioning, and data consistency is ensured through a write completion flag and instruction sequence number. The service scheduling module then interacts with the master processor via a cross-node communication framework. In this step, the slave node internal collaboration step enables the control algorithm and service scheduling within the slave functional processing node to interact securely using a single-write, multi-read approach with a write completion flag and instruction sequence number. The service scheduling module then interacts with the master processor via the cross-node communication framework. Thus, the collaboration within the slave node and the cross-node communication form a clear hierarchical boundary: the control algorithm focuses on high real-time closed-loop control, while the service scheduling focuses on message processing and state aggregation. This ensures data consistency within the slave node while avoiding interference from internal collaboration logic to cross-node communication, improving the overall system's real-time performance, consistency, and reliability.

[0035] In summary, this invention addresses the current practice where support / suspension control and rotary drive control are typically placed on different slave nodes, with no direct communication between nodes. The master controller needs to aggregate, arbitrate, and issue commands and safety-related states, while the human-machine interface refresh and fault handling paths should not be suspended for extended periods due to single cross-node command blocking. If the communication mechanism lacks predictable timing behavior and unified addressing and framing abstraction for both local and cross-node operations, it will be difficult to simultaneously meet the requirements of long-term continuous operation availability and diagnosticability for abnormal scenarios in industrial settings. A typical hardware configuration involves multiple circuit boards and processors working together: the master node is responsible for the system state machine, human-machine interaction, and command and state aggregation for lower-level nodes; multiple slave nodes respectively handle high-speed closed-loop control for rotor support / suspension multi-axis systems and high-speed closed-loop control for rotary drives (such as field-oriented or similar vector control strategies). If the above functions are mixed with underlying details such as synchronous and asynchronous serial links in the same bare-metal loop or tightly coupled calls, the following problems will occur: 1. Business logic is tied to physical links. Changing the main controller or slave processor platform or adjusting link parameters requires extensive code modifications, resulting in poor maintainability and portability. 2. When asynchronous byte streams and synchronous full-duplex links are used together, if there is a lack of a unified framing and routing model, boundary identification errors, buffer overflows, and intermittent faults that are difficult to diagnose are likely to occur. 3. High real-time control algorithms often run in timer interrupt context. If complex protocol parsing is performed or data structures without agreement are contested with the main program within the interrupt, the determinism of the control cycle will be compromised. 4. For rotation-driven "request-response" type services, if the call stack is blocked while waiting for a response, it will slow down the refresh of the human-machine interface and the advancement of the system state machine. Furthermore, the lack of timeout and state separation can easily lead to misjudgments.

[0036] Existing general-purpose middleware or heavy-duty protocol stacks often fall short of the requirements of such embedded products in terms of CPU time, storage resources, and real-time performance; while simple "point-to-point raw read and write" lacks cross-module addressing, integrity verification, and unified local / cross-node abstraction.

[0037] Therefore, this invention provides a communication system and corresponding control method that combines layered decoupling, differentiated dual physical channel carrying, interrupt simplification and asynchronous distribution, and supports non-blocking asynchronous transactions.

[0038] It should be noted that the communication system and control method provided by this invention do not limit the specific models, peripheral numbers, and software symbols of the master and slave processors; implementers can select equivalent devices and names based on the product hardware and internal design documents.

[0039] Specifically, this invention provides a multi-processing node hierarchical message communication system (typically implemented as a controller for multi-node vacuum rotary equipment such as a molecular pump), and a communication and service collaborative control method implemented on this system. The system's software structure relies on a cross-node communication framework (communication framework), and its hardware topology consists of a master control processor connected to subordinate functional processing nodes via cross-node physical links. There is no direct physical interconnection between subordinate nodes. Cross-node services are forwarded and aggregated by the master control processor. The specific structure and concept are summarized below: 1. Hardware abstraction and multi-channel physical support: The main control side encapsulates various asynchronous or synchronous communication interface peripherals through the hardware abstraction layer, providing unified initialization, sending, receiving and bus target selection capabilities.

[0040] 2. A message-driven task model and global addressing are implemented. The communication framework provides a message delivery mechanism based on task identifiers. The task identifier's bit field is divided into a processing node field and a local task sequence number: the sending side determines whether the message is delivered within the local node or transmitted across nodes based on the field. In small embedded environments, static tables or similar methods can be used to achieve constant-time lookup from module identifiers to message queue references. Each task maintains its own message queue. The queue's underlying layer can use a circular buffer to store message descriptions or pointers, supporting low-copy delivery. The system maintains a global module registry, registering the correspondence between modules and message queues. Registration or deregistration can be performed when tasks start or stop.

[0041] 3. Following the OSI layered communication model, the application layer is responsible for message encoding / decoding related to business logic and processing received data, without directly relying on specific peripheral registers. The transport layer defines an end-to-end addressable frame structure, including length, receiver identifier, sender identifier, command word, variable-length data payload, and cyclic redundancy check (e.g., 16-bit CRC). The link layer determines the target based on the target identifier: if it is a target within the same processor, the parsed message is delivered to the corresponding message queue; if it is a cross-node target, frame delimiters and check fields are added before transmission via asynchronous or synchronous links to enhance fault tolerance and diagnostics.

[0042] 4. Receive Path: Communication interface interrupt service routine - FIFO - frame de-distribution unit. In interrupt context, the driver only writes the received raw bytes to the circular receive buffer and updates the write pointer, keeping the execution time extremely short. In non-interrupt context, the frame de-distribution unit draws data from the FIFO in a polling or periodic manner, performs frame delimiting, verification, and routing to the target message queue according to the receiver's identifier; the parsing process can be implemented using a state machine to avoid performing complex logic within the interrupt.

[0043] 5. Non-blocking control method for request-response type services: When the main control side service module initiates a request, it returns immediately (non-blocking), only registering the description of the pending transaction: including the suspension flag, command type, sending time, and timeout period. During independent periodic processing: inbound messages are processed, the expected response command word is matched (e.g., there is a predetermined correspondence with the request command word), the result code and error code are parsed, and the suspension is cleared; if no response is received after the predetermined timeout period, the timeout result is set and logged. For rotation-driven commands, a successful response does not directly equate to entering the target running state: the actual running state is refreshed through periodic status queries to separate command acceptance from the running state, reducing the risk of misjudgment.

[0044] The beneficial effects achieved by this invention in multi-processing node embedded control scenarios requiring support-rotation dual-channel coordination, such as vacuum and process equipment, mainly include (molecular pumps are a typical use case): 1. Decoupling of business and transmission: The application layer only deals with message and command semantics, the transmission layer and link layer uniformly handle addressing, delimitation and verification, and the hardware abstraction layer isolates hardware differences, which is conducive to the migration of master and slave node platforms and the adjustment of link parameters.

[0045] 2. Unified abstraction across nodes and local nodes: The same set of task identifiers and registry models covers local queue delivery and cross-link sending. When expanding new modules, the main additions are registration items and command definitions to reduce coupling.

[0046] 3. A trade-off between real-time performance and reliability that is controllable: Asynchronous link paths adapt to byte streams and variable-length services; synchronous link paths use fixed-period, fixed-length full-duplex switching to meet the synchronization and high refresh requirements of the support control side; interrupt services are simplified to reduce jitter, and asynchronous frame distribution avoids blocking the control loop.

[0047] 4. Asynchronous transactions and fault tolerance: Request-response timeouts and logging are used to avoid blocking human-computer interaction and system state machine; critical business operations confirm the true state through periodic status queries to improve robustness. In summary, this invention provides an implementable, scalable communication system and control method with predictable timing behavior for the aforementioned multi-processor node industrial controllers (including molecular pump controllers) in resource-constrained embedded environments.

[0048] To make the above-mentioned objects, features and advantages of the present invention more apparent and understandable, specific embodiments of the present invention will be described in detail below with reference to the accompanying drawings.

[0049] Example 1

[0050] See Figure 1 , Figure 2 As shown, this embodiment provides an overall topology and master-side deployment method for a multi-processor hierarchical message communication system. The master processor connects to slave function processing node 1 via a synchronous serial full-duplex link. This synchronous serial full-duplex link is a shared bus and can be shared with other devices such as non-volatile memory. Before communication, the bus target is selected via chip select or a general-purpose input / output interface. The master processor connects to slave function processing node 2 via an asynchronous serial link. The electrical specifications of the asynchronous serial link are selected based on the actual hardware, such as RS232, RS485, or similar asynchronous serial interfaces, but are not limited to these. Slave function processing node 1 performs rotor support / suspended multi-axis high-speed closed-loop control, while slave function processing node 2 performs rotary drive high-speed closed-loop control. There is no direct physical interconnection between the two slave function processing nodes; cross-node services are uniformly forwarded and aggregated by the master processor.

[0051] This embodiment sets up a hardware abstraction layer to encapsulate asynchronous communication interface peripherals and / or synchronous communication interface peripherals, providing a unified interface for initialization, sending, receiving, and bus target selection. Service modules do not directly access peripheral registers. The human-machine interface and system control logic on the master control side issues instructions to the two subordinate functional processing nodes and aggregates status through a proxy or equivalent interface. Its hierarchical relationship is as follows: Figure 2 Consistent with the above. The runtime environment (i.e., the communication framework) provides basic capabilities such as task scheduling, message queues, and module registration; the system maintains a global module registry, registering the correspondence between modules and message queues. Modules can be registered or unregistered when a task starts or stops, thus enabling constant-time lookup from module identifiers to message queue references in a small embedded environment using static tables or similar methods.

[0052] It should be noted that the specific models, peripheral numbers, physical link types (including but not limited to Ethernet, SPI, RS232, etc.) and software symbols of the master processor and slave function processing nodes can be selected and named according to the product hardware and internal design documents, and this invention does not limit them; the number of slave function processing nodes is not limited to two. Any architecture in which the master connects at least two slave function processing nodes through physical links and there is no direct communication between the slave nodes falls within the protection scope of this invention.

[0053] Example 2

[0054] See Figure 3 , Figure 4 As shown, this embodiment illustrates the layered structure of the cross-node communication framework, the differentiated bearer of the dual physical channels, and the processing method of the receiving path.

[0055] In the sending direction, the application layer organizes command semantics and encodes / decodes business messages, and then hands the processed messages over to the transport layer. The application layer does not directly rely on specific peripheral registers. The transport layer uses task identifiers for end-to-end addressing. The bit field of the task identifier is divided into a processing node field and a local task sequence number (e.g., the high bit represents the processing node field and the low bit represents the local task sequence number). The sending side determines the target node based on this processing node field. The link layer determines the target node based on the target identifier: if the target is the current processor, the parsed message is delivered to the corresponding message queue within the current processor; if the target is a cross-node target, frame delimiters and check fields are added to the message before it is sent via the selected physical link.

[0056] In the receiving direction, combined Figure 4 In the interrupt context, the communication media driver only writes the received raw bytes to the circular receive buffer (FIFO) and updates the write pointer, keeping the execution time extremely short. In the non-interrupt context, the frame de-framing and distribution unit draws streams from the circular buffer in a polling or periodic manner, performs frame delimitation and verification in a state machine manner, and routes the verified messages to the target message queue according to the receiver identifier, thereby avoiding the completion of complex logic within the interrupt.

[0057] Regarding dual-channel differentiation, the asynchronous link uses variable-length frames to carry service messages, adapting to byte streams and variable-length services; on the synchronous link, the master processor performs fixed-length full-duplex data exchange with the first subordinate functional processing node according to the product-agreed cycle. Commands to be sent can be queued for the next exchange cycle, emphasizing timing determinism, and target selection is completed first when sharing the bus. In this embodiment, the frame structure defined by the transport layer includes length, receiver identifier, sender identifier, command word, variable-length data payload, and cyclic redundancy check, such as using 16-bit CRC for integrity verification.

[0058] In addition, each task maintains its own message queue, and the underlying layer of the queue can use a circular buffer to store message descriptions or pointers to support low-copy delivery; the global module registry maintained by the system registers the correspondence between the module and the message queue, so that local queue delivery and cross-link sending are uniformly abstracted under the same addressing model.

[0059] Example 3

[0060] This embodiment illustrates the non-blocking control method and state separation mechanism for request-response type services. When the main control side service module initiates a request, it returns immediately (non-blocking), only registering the description of the pending transaction. The description of the pending transaction includes a suspension flag, command type, sending time, and timing information used for timeout determination.

[0061] During independent cycle processing, the main control processor processes inbound messages: based on the predetermined correspondence between response command words and request command words, it matches the response command words in the inbound message with the command type described in the pending transaction; when the expected response command word is matched, it parses the result code and error code, and clears the pending flag. If the expected response command word is not matched within the predetermined timeout period, the timeout result is set and logged to avoid permanent suspension due to lost response.

[0062] For rotation-driven commands, a successful response does not directly equate to the subordinate function processing node having entered the target running state. This embodiment periodically queries and refreshes the status to confirm the actual running state of the subordinate function processing node, thereby separating the command acceptance state from the actual running state and reducing the risk of misjudgment. Fixed-length full-duplex data exchange, command queuing, and shared bus target selection transmitted via synchronous serial full-duplex links, as well as messages carried in variable-length frames via asynchronous serial links, all follow the aforementioned unified framing and addressing model.

[0063] Example 4

[0064] This embodiment illustrates the collaboration method within the subordinate function processing node. Within subordinate function processing node 1 or subordinate function processing node 2, the service scheduling module interacts with the control algorithm running in the timer interrupt context via a shared data area. The shared data area employs a single-write, multi-read partitioning approach, and data consistency is ensured through a write completion flag and instruction sequence number. This avoids data contention and tearing reads between the interrupt context and service scheduling without requiring complex locking mechanisms and with extremely low overhead. The service scheduling module then interacts with the main control processor via a cross-node communication framework, thereby achieving layered decoupling between internal collaboration within the subordinate node and cross-node communication.

[0065] Based on the above-described preferred embodiments of the present invention, and through the foregoing description, those skilled in the art can make various changes and modifications without departing from the inventive concept. The technical scope of this invention is not limited to the contents of the specification, but must be determined according to the scope of the claims.

Claims

1. A multiprocessor hierarchical message communication system, characterized in that, It includes a master processor, at least two slave functional processing nodes, and a cross-node communication framework; among which, The main control processor is connected to at least two subordinate function processing nodes via physical links; The cross-node communication framework includes an application layer, a transport layer, and a link layer; The application layer is used to perform message encoding and decoding related to business operations; The transport layer uses task identifiers for end-to-end addressing, and the bit field of the task identifier is divided into a processing node field and a local task sequence number. The link layer delivers the message to the message queue of the target within the processor according to the target identifier of the message, or sends it to the cross-node target via the physical link after adding frame delimitation and verification fields; On the receiving path, the interrupt service routine of the communication interface only writes the received raw bytes into the circular receive buffer, while frame delimiting, verification, and routing are completed by the deframe distribution unit in a non-interrupt context.

2. The multiprocessor hierarchical message communication system as described in claim 1, characterized in that, The frame structure defined by the transport layer includes length, receiver identifier, sender identifier, command word, variable-length data payload, and cyclic redundancy check.

3. The multiprocessor hierarchical message communication system as described in claim 1, characterized in that, The physical link includes a synchronous serial full-duplex link and an asynchronous serial link; the master control processor is connected to the first slave function processing node via the synchronous serial full-duplex link, and the first slave function processing node performs rotor support / suspended multi-axis high-speed closed-loop control. The master control processor is connected to the second slave function processing node via the asynchronous serial link, and the second slave function processing node performs high-speed closed-loop control of rotation drive type.

4. The multiprocessor hierarchical message communication system as described in claim 3, characterized in that, The master control processor exchanges fixed-length full-duplex data with the first slave function processing node via the synchronous serial full-duplex link at a predetermined cycle, and the commands to be sent are queued and sent in the next exchange cycle; the synchronous serial full-duplex link is a shared bus, and the bus target selection is completed through chip select or general input / output interface before communication.

5. The multiprocessor hierarchical message communication system as described in claim 1, characterized in that, It also includes a hardware abstraction layer, which encapsulates asynchronous communication interface peripherals and / or synchronous communication interface peripherals, and provides a unified interface for initialization, sending, receiving and bus target selection.

6. The multiprocessor hierarchical message communication system as described in claim 1, characterized in that, The service scheduling module within the subordinate function processing node interacts with the control algorithm running in the timer interrupt context via a shared data area. The shared data area adopts a single-write, multi-read partitioning, and ensures data consistency through a write completion flag and instruction sequence number.

7. A multiprocessor hierarchical message communication control method, characterized in that, The method is applied to a multiprocessor hierarchical message communication system as described in any one of claims 1-6; the multiprocessor hierarchical message communication control method includes: a message sending step: the application layer encodes and decodes the service message and then hands it over to the transport layer; the transport layer performs end-to-end addressing using a task identifier, the bit field of the task identifier is divided into a processing node field and a local task sequence number, the transport layer determines the target node based on the processing node field; if the target node is the current processor, the link layer delivers the message to the message queue of the target within the current processor; if the target node is a cross-node target, the link layer adds frame delimiter and check fields to the message and then sends it to the cross-node target via the physical link; Message reception steps: In the interrupt service routine of the communication interface, only the received raw bytes are written to the circular receive buffer and the write pointer is updated; in the non-interrupt context, the frame de-framing and distribution unit retrieves the byte stream from the circular receive buffer, performs frame delimiting and verification in a state machine manner, and routes the verified messages to the target message queue according to the receiver identifier. Non-blocking request initiation steps: After the master control side business module initiates a request to the subordinate function processing node through the cross-node communication framework, it immediately returns and registers the pending transaction description, which includes a suspension flag, command type, sending time, and timing information used for timeout determination; Periodic processing steps: In an independent periodic processing process, inbound messages are processed. Based on the predetermined correspondence between response command words and request command words, the inbound messages are matched with the pending transaction descriptions. When the expected response command word is matched, the result code and error code are parsed, and the pending flag is cleared. Timeout handling steps: If the expected response command word is not matched after the predetermined timeout period, the timeout result is set and logged; Status confirmation step: When the response only indicates that the command has been accepted, the actual running status of the subordinate function processing node is refreshed and confirmed through periodic status queries, so as to separate the command acceptance status from the actual running status.

8. The multiprocessor hierarchical message communication control method as described in claim 7, characterized in that, In the message sending step, frame delimiting, verification fields, and message content constitute a frame structure, which includes length, receiver identifier, sender identifier, command word, variable-length data payload, and cyclic redundancy check. In the periodic processing step, matching the inbound message with the pending transaction description includes: matching the response command word in the inbound message with the command type of the pending transaction description based on a predetermined correspondence between the response command word and the request command word.

9. The multiprocessor hierarchical message communication control method as described in claim 7, characterized in that, In the message sending step, the master control processor exchanges fixed-length full-duplex data with the first slave function processing node via a synchronous serial full-duplex link at a predetermined cycle. The command to be sent is queued and sent in the next exchange cycle. When the synchronous serial full-duplex link is a shared bus, the bus target selection is completed through chip select or general input / output interface before communication. The message sent via the asynchronous serial link is carried in a variable-length frame.

10. The multiprocessor hierarchical message communication control method as described in claim 7, characterized in that, It also includes a collaborative step within the subordinate node: within the subordinate function processing node, the service scheduling module and the control algorithm running in the timer interrupt context interact through the shared data area. The shared data area adopts a single-write, multi-read partition and ensures data consistency through a write completion flag and instruction sequence number. The service scheduling module then interacts with the main control processor through the cross-node communication framework.