High-frequency real-time control method and device based on integrated bus architecture
By designing an integrated bus architecture for the computation and control modules, and combining concurrent queues and load prediction models, adaptive task scheduling and initialization of the motor control system are achieved. This solves the problems of insufficient real-time performance and reliability in traditional motor control systems and improves the performance of multi-motor collaborative control.
Patent Information
- Application Number
- CN202510281594.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-11
- Publication Date
- 2026-02-24
- Estimated Expiration
- 2045-03-11
AI Technical Summary
Traditional motor control systems have shortcomings in terms of real-time performance and reliability. In particular, in multi-motor collaborative control scenarios, it is difficult to balance task resource occupation and response time, lack effective use of historical data, fail to establish a dynamic correlation mechanism between task priority and load status, and have low efficiency in collaborative data interaction between the calculation module and the control module.
The system adopts an integrated bus architecture, dividing it into a calculation module and a control module. Data interaction is achieved through concurrent queues, using industrial Ethernet and fieldbus. A task history database and load prediction model are established to realize dynamic adjustment of task weight coefficients and adaptive task scheduling. A motor abstraction layer is constructed for adaptive initialization, and control parameters are dynamically generated based on load prediction results.
It significantly improves the real-time performance and reliability of multi-motor collaborative control, can dynamically respond to load changes, improve system stability and control accuracy, and has good scalability and maintainability.
Smart Images

Figure CN119788455B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the field of data processing, in particular to a high-frequency real-time control method and device based on an integrated bus architecture. BACKGROUND
[0002] Traditional motor control systems usually adopt a single bus architecture, which has the problem of insufficient real-time performance and reliability. Existing control methods often use fixed task scheduling strategies, which are difficult to dynamically optimize according to load changes. In particular, in the context of multi-motor collaborative control, the system is difficult to balance the resource occupation and response time of different tasks.
[0003] At the same time, the existing system has obvious deficiencies in load prediction and parameter adaptation. The traditional method lacks effective use of historical data, cannot accurately predict the trend of load changes, and has not established a dynamic correlation mechanism between task priority and load state. The system is also relatively mechanical in terms of motor abstract modeling and initialization configuration, making it difficult to adapt to the control needs of different types of motors.
[0004] In addition, the existing technology also has problems in the coordination of the calculation module and the control module. There is a lack of efficient data interaction mechanism, and the concurrent processing capability is not fully utilized, which affects the overall performance of the system. The solution to these problems is of great significance to improving the real-time performance and reliability of the motor control system. SUMMARY
[0005] In view of the problems in the prior art, the present application provides a high-frequency real-time control method and device based on an integrated bus architecture, which can significantly improve the real-time performance and reliability of multi-motor collaborative control through adaptive task scheduling and load prediction compensation.
[0006] In order to solve at least one of the above problems, the present application provides the following technical solutions:
[0007] In a first aspect, the present application provides a high-frequency real-time control method based on an integrated bus architecture, comprising:
[0008] The control system is divided into a calculation module and a control module, wherein the calculation module and the control module adopt a concurrent queue mode for data interaction, the control module includes multiple motor control units, each motor control unit is connected to a corresponding motor through an integrated bus, the integrated bus includes an industrial Ethernet bus and a field bus, the calculation module includes multiple calculation tasks, each calculation task is provided with a corresponding task weight coefficient, a task history database is established, the task history database records the response time and resource occupation of each calculation task performed by the motor under different load states;
[0009] The real-time load data of the motor is collected through the integrated bus, wherein the real-time load data includes motor torque, motor speed and motor current, the real-time load data is input into a load prediction model, the load prediction model is trained based on the task history database, the load prediction model outputs a load prediction result, the load prediction result includes a predicted load interval and a load change trend, the task weight coefficient is dynamically adjusted based on the load prediction result to generate a pre-adjustment weight coefficient, the pre-adjustment weight coefficient changes nonlinearly with the change of the load prediction result, the calculation tasks are prioritized based on the pre-adjustment weight coefficient, an adaptive task scheduling strategy is established according to the priority, the adaptive task scheduling strategy is optimized and configured based on the response time and resource occupation in the task history database, the calculation module generates a calculation result according to the adaptive task scheduling strategy, and the calculation result is transmitted to the control module through the concurrent queue;
[0010] The control module receives the calculation result, reads a motor configuration file, wherein the motor configuration file includes motor model parameters, motor initialization parameters and motor control parameters, abstractly models the motor according to the motor model parameters to generate a motor abstraction layer, adaptively initializes the motor based on the motor abstraction layer and the motor initialization parameters, matches the load prediction result with the motor control parameters to generate load adaptive control parameters, compensates and adjusts the calculation result according to the load adaptive control parameters, and sends control instructions to the motor through the integrated bus, the control module receives the encoding feedback information of the motor through the integrated bus, and stores the encoding feedback information and corresponding load data in the task history database for online optimization and update of the load prediction model.
[0011] Further, the control system is divided into a calculation module and a control module, wherein the calculation module and the control module interact with each other in a concurrent queue mode, the control module includes multiple motor control units, each motor control unit is connected with a corresponding motor through an integrated bus, the integrated bus includes an industrial Ethernet bus and a field bus, and includes:
[0012] A concurrent data queue structure is established based on a cache, a read-write controller and a data synchronizer are configured in the concurrent data queue structure, the read-write controller includes a mutual exclusion mechanism and a condition variable, the data synchronizer is responsible for read-write synchronization and state monitoring of queue data, data transmission from a calculation module to a control module is realized through the concurrent data queue structure, a data priority identification bit and a data check bit are set in the data queue, the data priority identification bit is used to mark a priority order of data processing, and the data check bit is used to ensure correctness of data transmission.
[0013] A multi-path motor control unit array is constructed in the control module, an independent communication resource pool is allocated for each motor control unit, the communication resource pool includes an Ethernet communication interface and a field bus interface, a TCP / IP protocol stack and a real-time Ethernet protocol stack are configured in the Ethernet communication interface, a CAN bus protocol is configured in the field bus interface, a control link is established according to a motor communication characteristic and a corresponding communication protocol, the control link includes an uplink data channel and a downlink data channel, and sending of a motor control instruction and receiving of a state feedback are realized through the control link.
[0014] Further, the calculation module includes a plurality of calculation tasks, a corresponding task weight coefficient is set for each calculation task, a task history database is established, the task history database records response times and resource occupancies of the motor in executing each calculation task under different load states, and the task history database includes:
[0015] A task manager is established in the calculation module, the task manager is designed in a hierarchical structure and includes a task scheduling layer, a task execution layer and a resource management layer, a task priority queue is established in the task scheduling layer, a unique task identifier and an initial weight coefficient are allocated for each calculation task, the task identifier includes a task type code and a time stamp information, the initial weight coefficient is determined based on real-time requirements and calculation complexity of the task, and creation, destruction and state management of the calculation task are realized through the task manager.
[0016] A task history database of a distributed data storage architecture is constructed, the task history database includes a real-time data table and a historical data table, execution information of each calculation task under a current load state is recorded in the real-time data table, the execution information includes a task start time, a completion time, a CPU occupancy rate and a memory usage, a load state index is established in the historical data table, and task execution information under different load states is stored in a time sequence, and historical data is periodically archived and cleaned through a data compression algorithm.
[0017] Further, the real-time load data is input into a load prediction model, the load prediction model is trained based on the task history database, the load prediction model outputs a load prediction result, the load prediction result includes a predicted load interval and a load change trend, the task weight coefficient is dynamically adjusted based on the load prediction result to generate a pre-adjustment weight coefficient, the pre-adjustment weight coefficient changes nonlinearly with the change of the load prediction result, and the calculation task is prioritized based on the pre-adjustment weight coefficient, including:
[0018] A load prediction model is constructed based on a long short-term memory neural network, the load prediction model includes an input layer, a hidden layer and an output layer, a data normalization unit is arranged at the input layer to standardize real-time load data, a forgetting gate and a memory gate are arranged at the hidden layer to filter invalid features through the forgetting gate and retain important features through the memory gate, and an activation function is arranged at the output layer to map the output of the neural network to a load prediction interval and a change trend, and sample data in the task history database is used to train and optimize parameters of the load prediction model;
[0019] A weight adjuster based on a fuzzy neural network is constructed, the weight adjuster receives an output result of the load prediction model, converts the load prediction result into a weight adjustment amount through a fuzzy rule base, the fuzzy rule base includes a load interval rule set and a trend rule set, a pre-adjustment weight coefficient is calculated according to the weight adjustment amount, the pre-adjustment weight coefficient is input into a task priority sorting module, and the task priority sorting module uses an improved quicksort algorithm to rearrange priorities of calculation tasks to generate a task execution sequence.
[0020] Further, the adaptive task scheduling strategy is established according to the priority sorting, the adaptive task scheduling strategy is optimized and configured based on response time and resource occupation in the task history database, the calculation module generates a calculation result according to the adaptive task scheduling strategy, and the calculation result is transmitted to the control module through the concurrent queue, including:
[0021] A multi-level feedback task scheduler is constructed, the multi-level feedback task scheduler includes a task allocation unit and a resource monitoring unit, a plurality of priority queues are arranged in the task allocation unit, each priority queue is configured with an independent time slice length and a scheduling period, a dynamic time slice is set based on response time in the task history database, a task switching threshold is set based on resource occupation, system resource utilization is collected in real time through the resource monitoring unit, and task degradation processing is triggered when resource utilization exceeds the switching threshold;
[0022] A parallel computing framework is established in the solving module, and the parallel computing framework comprises a task decomposer and a result synthesizer, the task decomposer splits the solving task into a plurality of subtasks according to an adaptive task scheduling strategy, allocates computing resources to process each subtask in parallel, the result synthesizer aggregates and verifies the calculation results of the subtasks, generates a final solving result, encapsulates the solving result into a data packet, and transmits the data packet to the control module through a concurrent queue mechanism.
[0023] Further, the motor is abstractly modeled according to the motor model parameters to generate a motor abstraction layer, the motor is adaptively initialized based on the motor initialization parameters called from the motor abstraction layer, the load adaptive control parameters are generated by matching the load prediction results with the motor control parameters, the solving result is compensated and adjusted according to the load adaptive control parameters, and the control instructions are sent to the motor through the integrated bus, including:
[0024] A motor object abstraction layer is constructed, the motor object abstraction layer comprises a parameter description module and a function interface module, a motor characteristic model is established in the parameter description module, the motor characteristic model comprises an electrical parameter model and a mechanical parameter model, a basic parameter matrix is configured according to motor model parameters, a standardized control instruction set is encapsulated in the function interface module, the control instruction set comprises motion control instructions and state query instructions, and the unified management of different types of motors is realized through the motor object abstraction layer;
[0025] An adaptive motor controller is established, the adaptive controller comprises a parameter matching unit and a compensation and adjustment unit, the parameter matching unit receives the load prediction results, selects the optimal control parameter group from the motor control parameter library, and adaptively adjusts the control parameters according to the load state, the compensation and adjustment unit corrects and compensates the solving result based on the load adaptive control parameters, adopts a feedforward compensation strategy to optimize the control performance, and sends the corrected control instructions to the motor execution unit through the integrated bus.
[0026] Further, the control module receives the encoding feedback information of the motor through the integrated bus, and stores the encoding feedback information and corresponding load data into the task history database for online optimization and update of the load prediction model, including:
[0027] A feedback signal processor is constructed, which comprises a data acquisition unit and a signal analysis unit. The data acquisition unit periodically acquires position information, speed information and current information output by a motor encoder through an integrated bus. A signal filter and a data verifier are arranged in the signal analysis unit. The signal filter is used to filter high-frequency noise of the collected data, and the data verifier is used to verify data integrity. The processed feedback information is encoded and packaged in a preset format.
[0028] A data update manager is established, which comprises a data classification module and a model optimization module. The data classification module performs time synchronization and feature extraction on the encoded feedback information and load data, and stores the processed data into corresponding data tables of a task history database. The model optimization module periodically reads new data samples and performs online fine-tuning on network parameters of the load prediction model using an incremental learning algorithm to realize continuous optimization of the prediction model.
[0029] In a second aspect, the application provides a high-frequency real-time control device based on an integrated bus architecture, comprising:
[0030] A solving module is used to divide the control system into a solving module and a control module. The solving module and the control module interact with each other in a concurrent queue mode. The control module comprises multiple motor control units. Each motor control unit is connected to a corresponding motor through an integrated bus. The integrated bus comprises an industrial Ethernet bus and a field bus. The solving module comprises multiple solving tasks. Each solving task is provided with a corresponding task weight coefficient. A task history database is established. The task history database records response times and resource occupancy of the motor in different load states when performing each solving task.
[0031] The prediction module is used to collect real-time load data of the motor through the integrated bus, wherein the real-time load data includes motor torque, motor speed and motor current. The real-time load data is input into a load prediction model, which is trained based on the task history database. The load prediction model outputs a load prediction result, which includes a predicted load range and a load change trend. Based on the load prediction result, the task weight coefficients are dynamically adjusted to generate pre-adjusted weight coefficients. The pre-adjusted weight coefficients change non-linearly with the load prediction result. Based on the pre-adjusted weight coefficients, the calculation tasks are prioritized. An adaptive task scheduling strategy is established based on the priority ranking. The adaptive task scheduling strategy is optimized based on the response time and resource consumption in the task history database. The calculation module generates a calculation result according to the adaptive task scheduling strategy and transmits the calculation result to the control module through the concurrent queue.
[0032] The control module receives the calculation results, reads the motor configuration file (including motor model parameters, motor initialization parameters, and motor control parameters), performs abstract modeling of the motor based on the motor model parameters to generate a motor abstraction layer, performs adaptive initialization of the motor based on the motor abstraction layer and the motor initialization parameters, matches the load prediction results with the motor control parameters to generate load adaptive control parameters, compensates and adjusts the calculation results based on the load adaptive control parameters, and sends control commands to the motor via the integrated bus. The control module also receives coded feedback information from the motor via the integrated bus and stores the coded feedback information and corresponding load data in the task history database for online optimization and updating of the load prediction model.
[0033] Thirdly, this application provides an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the steps of the high-frequency real-time control method based on an integrated bus architecture.
[0034] Fourthly, this application provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the high-frequency real-time control method based on an integrated bus architecture.
[0035] Fifthly, this application provides a computer program product, including a computer program / instructions, which, when executed by a processor, implement the steps of the high-frequency real-time control method based on an integrated bus architecture.
[0036] As can be seen from the above technical solution, this application provides a high-frequency real-time control method and device based on an integrated bus architecture. The system is divided into a calculation module and a control module, achieving efficient data interaction through concurrent queues. It adopts an integrated architecture of industrial Ethernet bus and fieldbus, trains a load prediction model based on historical data, and dynamically adjusts the task weight coefficients. An adaptive initialization of different motor models is achieved by establishing a motor abstraction layer, and control parameters are dynamically generated based on the load prediction results. This method overcomes the limitations of traditional fixed scheduling strategies, significantly improving the real-time performance and reliability of multi-motor collaborative control through adaptive task scheduling and load prediction compensation. Attached Figure Description
[0037] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0038] Figure 1 This is one of the flowcharts illustrating the high-frequency real-time control method based on an integrated bus architecture in the embodiments of this application;
[0039] Figure 2 This is the second flowchart illustrating the high-frequency real-time control method based on an integrated bus architecture in this application embodiment;
[0040] Figure 3 This is the third flowchart illustrating the high-frequency real-time control method based on an integrated bus architecture in this application embodiment;
[0041] Figure 4 This is the fourth flowchart illustrating the high-frequency real-time control method based on an integrated bus architecture in the embodiments of this application.
[0042] Figure 5 This is the fifth flowchart illustrating the high-frequency real-time control method based on an integrated bus architecture in the embodiments of this application;
[0043] Figure 6 This is the sixth flowchart illustrating the high-frequency real-time control method based on an integrated bus architecture in the embodiments of this application;
[0044] Figure 7 This is the seventh flowchart illustrating the high-frequency real-time control method based on an integrated bus architecture in the embodiments of this application.
[0045] Figure 8 This is a structural diagram of the high-frequency real-time control device based on an integrated bus architecture in the embodiments of this application;
[0046] Figure 9 This is a schematic diagram of the structure of the electronic device in the embodiments of this application.
[0047] Figure label:
[0048] Electronic device 9600, central processing unit 9100, memory 9140, communication module 9110, input unit 9120, audio processor 9130, display 9160, power supply 9170, buffer memory 9141, application / function storage unit 9142, data storage unit 9143, driver storage unit 9144, antenna 9111, speaker 9131, microphone 9132. Detailed Implementation
[0049] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0050] The acquisition, storage, use, and processing of data in this application all comply with the relevant provisions of national laws and regulations.
[0051] To address the problems existing in current technologies, this application provides a high-frequency real-time control method and apparatus based on an integrated bus architecture. The system is divided into a solution module and a control module, achieving efficient data interaction through concurrent queues. An integrated architecture combining industrial Ethernet bus and fieldbus is adopted. A load prediction model is trained based on historical data to dynamically adjust task weight coefficients. An adaptive initialization of different motor models is achieved by establishing a motor abstraction layer, and control parameters are dynamically generated based on load prediction results. This method overcomes the limitations of traditional fixed scheduling strategies, significantly improving the real-time performance and reliability of multi-motor collaborative control through adaptive task scheduling and load prediction compensation.
[0052] To significantly improve the real-time performance and reliability of multi-motor cooperative control through adaptive task scheduling and load prediction compensation, this application provides an embodiment of a high-frequency real-time control method based on an integrated bus architecture. See [link to relevant documentation]. Figure 1 The high-frequency real-time control method based on an integrated bus architecture specifically includes the following:
[0053] Step S101: The control system is divided into a calculation module and a control module. The calculation module and the control module interact with each other using a concurrent queue method. The control module includes multiple motor control units. Each motor control unit is connected to the corresponding motor through an integrated bus. The integrated bus includes an industrial Ethernet bus and a fieldbus. The calculation module includes multiple calculation tasks. Each calculation task is set with a corresponding task weight coefficient. A task history database is established. The task history database records the response time and resource consumption of the motor when executing each calculation task under different load conditions.
[0054] Optionally, the high-frequency real-time control method based on an integrated bus architecture provided in this embodiment first divides the control system into independent calculation modules and control modules. This division is based on the demand for high-precision motion control in actual industrial scenarios. The calculation module is responsible for computationally intensive tasks such as complex trajectory planning and dynamic calculations, while the control module focuses on real-time control and status monitoring of the motor. This functional separation can improve the real-time performance and reliability of the system.
[0055] This embodiment employs a concurrent queue approach to facilitate data interaction between the computation module and the control module. Specifically, the concurrent queue utilizes a double-ended circular buffer structure, with the write end connected to the output interface of the computation module and the read end connected to the input interface of the control module. To ensure the real-time performance and reliability of data interaction, a semaphore-based mutual exclusion mechanism is implemented within the concurrent queue. After the computation module completes a computation task, it uses the semaphore mechanism to wake up the control module and read new control data.
[0056] In the specific implementation of the control module, a multi-channel motor control unit array was constructed, with each control unit independently responsible for controlling one motor. To accommodate the communication requirements of different types of motors, this embodiment designed an integrated bus architecture that combines industrial Ethernet and fieldbus. The industrial Ethernet bus uses the EtherCAT protocol, supporting high-speed data transmission and precise synchronous control; the fieldbus includes CAN bus and EtherCAT bus for connecting traditional industrial equipment. This hybrid bus architecture ensures both real-time system performance and good compatibility.
[0057] This embodiment sets up multiple solution tasks in the solution module, including trajectory planning, kinematics calculation, and dynamics calculation. Each solution task is assigned a weight coefficient, which reflects the importance and real-time requirements of the task. For example, in the event of emergency braking of the robot, the weight coefficient of the trajectory planning task will be dynamically increased to ensure that the system can respond quickly to braking commands.
[0058] To achieve dynamic task scheduling and optimization, this embodiment establishes a task history database. This database employs a distributed storage architecture, comprising a real-time data area and a historical data area. The real-time data area records the current load status of the motor (e.g., speed, torque, current) and the execution status of each calculation task (e.g., start time, end time, CPU utilization, memory usage). The historical data area stores long-term accumulated task execution data, which is categorized and indexed according to load status for subsequent task scheduling optimization and load prediction.
[0059] In practical applications, when the motor load changes significantly, such as when a robot grips a heavy object causing a sudden increase in load, this embodiment can quickly adjust the task weight coefficients and execution order based on empirical data in the task history database. This adaptive scheduling mechanism based on historical data effectively improves the system's response speed and control accuracy under different load conditions.
[0060] By modularizing the control system, employing concurrent queues for inter-module communication, integrating multiple bus technologies to construct an integrated control network, and introducing dynamic task weight adjustment and historical data analysis mechanisms, this embodiment significantly improves the system's real-time control performance and adaptability. In real-world industrial scenarios, this solution can effectively handle complex operating conditions such as drastic load changes and emergency braking, ensuring the stability and reliability of the control system.
[0061] Furthermore, the task history database in this embodiment not only serves the current task scheduling but also provides a data foundation for continuous system optimization. By analyzing task execution patterns and resource usage characteristics in historical data, task scheduling strategies can be continuously improved, enhancing the overall system performance. For example, in periodic production tasks, the system can predictively adjust task weights and resource allocation, thereby achieving a more efficient control process.
[0062] Step S102: Collect real-time load data of the motor through the integrated bus, wherein the real-time load data includes motor torque, motor speed and motor current. Input the real-time load data into the load prediction model. The load prediction model is trained based on the task history database. The load prediction model outputs load prediction results, which include predicted load range and load change trend. Dynamically adjust the task weight coefficients based on the load prediction results to generate pre-adjusted weight coefficients. The pre-adjusted weight coefficients change non-linearly with the load prediction results. Prioritize the calculation tasks based on the pre-adjusted weight coefficients. Establish an adaptive task scheduling strategy based on the priority ranking. The adaptive task scheduling strategy is optimized based on the response time and resource consumption in the task history database. The calculation module generates calculation results according to the adaptive task scheduling strategy and transmits the calculation results to the control module through the concurrent queue.
[0063] Optionally, this embodiment uses an integrated bus to collect motor operating status data in real time, constructing a complete load prediction and task scheduling optimization mechanism. Specifically, it employs a combination of industrial Ethernet bus and fieldbus to synchronously collect motor torque, speed, and current data with a sampling period of 1 millisecond. These data collectively reflect the actual load status of the motor.
[0064] Based on data acquisition, this embodiment designs a deep learning-based load prediction model. This model employs a Long Short-Term Memory (LSTM) network structure, which can effectively capture the temporal characteristics of motor load. The model's input layer includes three feature dimensions: motor torque, speed, and current. The hidden layer uses an attention mechanism to weightedly fuse features from different time scales. The output layer provides the predicted load range and load change trend. The predicted load range represents the possible range of motor load values over a future period, while the load change trend reflects whether the load is rising, falling, or stable.
[0065] The load prediction model in this embodiment is trained based on accumulated operational data in the task history database. The training data includes motor load sequences under different operating conditions and corresponding task execution records. By analyzing historical data, the model can establish a mapping relationship between motor load characteristics and task performance. For example, under sudden load increases, the response time of some computationally intensive tasks will significantly increase; this correlation is accurately captured by the model and used for subsequent predictions.
[0066] Based on load prediction results, this embodiment implements a dynamic adjustment mechanism for task weight coefficients. Specifically, a nonlinear mapping function is used to convert the predicted load range and trend into weight adjustment amounts. When a drastic load change is predicted, the weight coefficients of tasks highly correlated with the load are significantly increased to ensure these critical tasks can respond promptly to load changes. This nonlinear adjustment strategy enables rapid adaptation of task weights while maintaining system stability.
[0067] At the task scheduling level, this embodiment prioritizes the computation tasks based on pre-adjusted weight coefficients. The ranking algorithm comprehensively considers the task weight coefficients, expected execution time, and resource requirements to generate an optimal task execution sequence. For example, when a robot performs a precision assembly task, trajectory planning and kinematics calculation tasks are given higher priority to ensure the accuracy of motion control.
[0068] The adaptive task scheduling strategy in this embodiment is based on in-depth analysis of historical execution data. By analyzing the response time and resource usage recorded in the historical task database, a correlation model between task execution characteristics and system performance is established. This optimization mechanism based on historical data can dynamically adjust task execution parameters, such as time slice allocation and resource constraints, thereby achieving continuous optimization of task scheduling.
[0069] The calculation module executes various calculation tasks according to an adaptive task scheduling strategy, generating calculation results containing motor control parameters. These results are transmitted to the control module via a concurrent queue, and the queue's buffering mechanism ensures the reliability and real-time performance of data transmission. During data transmission, a timestamp-based synchronization mechanism is employed to ensure that the calculation results are delivered to the control module in a timely manner and that corresponding control actions are executed.
[0070] This embodiment significantly improves the control system's adaptability to load changes by constructing a complete load prediction and task scheduling framework. In practical applications, this solution can effectively predict and respond to various load changes, such as sudden changes in robot load and complex scenarios like multi-motor cooperative control, ensuring the system's control accuracy and response speed.
[0071] Furthermore, the adaptive scheduling mechanism in this embodiment also exhibits excellent scalability. By continuously accumulating and analyzing operational data, the system can continuously optimize the prediction model and scheduling strategy to adapt to more diverse application scenarios. Simultaneously, the non-linear weight adjustment mechanism ensures that the system maintains stable operation even under extreme conditions, improving overall reliability.
[0072] Step S103: The control module receives the calculation result, reads the motor configuration file, wherein the motor configuration file includes motor model parameters, motor initialization parameters, and motor control parameters. Based on the motor model parameters, it performs abstract modeling of the motor to generate a motor abstraction layer. Based on the motor abstraction layer, it calls the motor initialization parameters to perform adaptive initialization of the motor. It matches the load prediction result with the motor control parameters to generate load adaptive control parameters. Based on the load adaptive control parameters, it compensates and adjusts the calculation result and sends control commands to the motor through the integrated bus. The control module receives the coded feedback information of the motor through the integrated bus and stores the coded feedback information and corresponding load data in the task history database for online optimization and updating of the load prediction model.
[0073] Optionally, this embodiment implements an adaptive control mechanism based on a motor abstract model in the control module. The control module first receives the solution results from the solution module from the concurrent queue, and simultaneously reads the motor configuration file stored locally. This configuration file contains complete parameter information of the motor, providing basic data support for subsequent control strategy optimization.
[0074] In the motor model construction phase, this embodiment uses abstract modeling based on motor model parameters. Specifically, different types of motors (such as servo motors and stepper motors) are abstracted into a unified mathematical model, including core characteristics such as electrical equations and mechanical equations. This abstract modeling method gives the control strategy good versatility and portability. The motor abstraction layer, as an intermediate interface, shields the hardware differences between different motor models, providing a unified calling interface for upper-level control algorithms.
[0075] Based on the motor abstraction layer, this embodiment implements an adaptive initialization process for motor parameters. The initialization process first reads the motor initialization parameters, including basic parameters such as rated voltage, rated current, and rated speed, and then dynamically adjusts these parameters according to the current load state. For example, when a heavy motor load is detected, the system will correspondingly increase the current limit value to ensure that the motor can provide sufficient output torque.
[0076] This embodiment innovatively matches and maps load prediction results with motor control parameters to generate load adaptive control parameters. This process involves the coordinated optimization of multiple control parameters, such as PID parameters and feedforward compensation coefficients. Specifically, when the load prediction result indicates that the load is about to increase, the system will pre-increase the proportional coefficient and integral time constant to improve the anti-interference capability of the control system; when a sharp change in load is predicted, the derivative coefficient will be adjusted accordingly to enhance the dynamic response characteristics of the system.
[0077] The compensation and adjustment of the solution results is another innovation of this embodiment. Based on the load adaptive control parameters, the system performs real-time compensation on the control commands generated by the solution module. For example, when the robot is performing a position control task, if it is predicted that an increase in load will lead to an increase in position error, the system will automatically calculate the compensation amount and add it to the original control command, thereby ensuring control accuracy.
[0078] During the execution of control commands, this embodiment acquires encoder feedback information from the motor in real time via an integrated bus. This feedback information includes state variables such as actual position, speed, and acceleration, which are recorded in the task history database along with the current load data. This closed-loop feedback mechanism is not only used for real-time control but also provides continuously updated training data for optimizing the load prediction model.
[0079] The online optimization and update mechanism in this embodiment is crucial for ensuring the long-term stable operation of the system. By analyzing newly added historical data, the system can promptly identify prediction deviations in the load prediction model and fine-tune the model using incremental learning. This adaptive learning mechanism enables the prediction model to continuously adapt to the aging characteristics of the equipment and changes in operating conditions, maintaining high prediction accuracy.
[0080] In practical applications, this embodiment significantly improves the adaptability and reliability of the motor control system. For example, in flexible manufacturing scenarios for industrial robots, when the robot needs to frequently switch between workpieces of different weights, this solution can accurately predict load changes and adjust the control strategy in advance, effectively avoiding overshoot and oscillation problems in traditional control schemes.
[0081] Furthermore, the motor abstraction layer design in this embodiment facilitates subsequent functional expansion. By adding new interface definitions to the abstraction layer, the system can easily support the integration of new types of motors while maintaining the stability of the original control strategy. This modular design approach greatly improves the maintainability and scalability of the system.
[0082] By establishing a complete feedback loop, this embodiment not only achieves high precision and high reliability in motor control, but also constructs a continuously optimized learning system that can continuously improve control performance and prediction accuracy, providing an effective solution for the intelligent upgrading of industrial automation.
[0083] As described above, the high-frequency real-time control method based on an integrated bus architecture provided in this application can divide the system into a solution module and a control module, achieve efficient data interaction through concurrent queues, adopt an integrated architecture of industrial Ethernet bus and fieldbus, train a load prediction model based on historical data, and realize dynamic adjustment of task weight coefficients. By establishing a motor abstraction layer, adaptive initialization of different motor models is achieved, and control parameters are dynamically generated based on load prediction results. This method breaks through the limitations of traditional fixed scheduling strategies, and significantly improves the real-time performance and reliability of multi-motor cooperative control through adaptive task scheduling and load prediction compensation.
[0084] In one embodiment of the high-frequency real-time control method based on an integrated bus architecture of this application, see [link to relevant documentation]. Figure 2 It can also specifically include the following:
[0085] Step S201: Establish a concurrent data queue structure based on the cache, configure a read / write controller and a data synchronizer in the concurrent data queue structure. The read / write controller includes a mutex lock mechanism and a condition variable. The data synchronizer is responsible for the read / write synchronization and status monitoring of the queue data. Data transmission from the solution module to the control module is realized through the concurrent data queue structure. Set a data priority flag bit and a data check bit in the data queue. The data priority flag bit is used to mark the priority order of data processing, and the data check bit is used to ensure the correctness of data transmission.
[0086] Step S202: Construct a multi-channel motor control unit array in the control module, and allocate an independent communication resource pool to each motor control unit. The communication resource pool includes an Ethernet communication interface and a fieldbus interface. Configure a TCP / IP protocol stack and a real-time Ethernet protocol stack in the Ethernet communication interface, and configure a CAN bus protocol in the fieldbus interface. The fieldbus interface can be a CAN physical interface. Select the corresponding communication protocol according to the motor communication characteristics to establish a control link. The control link includes an uplink data channel and a downlink data channel. The motor control commands are sent and the status feedback is received through the control link.
[0087] Optionally, this embodiment implements an adaptive control mechanism based on a motor abstract model in the control module. The control module first receives the solution results from the solution module from the concurrent queue, and simultaneously reads the motor configuration file stored locally. This configuration file contains complete parameter information of the motor, providing basic data support for subsequent control strategy optimization.
[0088] In the motor model construction phase, this embodiment uses abstract modeling based on motor model parameters. Specifically, different types of motors (such as servo motors and stepper motors) are abstracted into a unified mathematical model, including core characteristics such as electrical equations and mechanical equations. This abstract modeling method gives the control strategy good versatility and portability. The motor abstraction layer, as an intermediate interface, shields the hardware differences between different motor models, providing a unified calling interface for upper-level control algorithms.
[0089] Based on the motor abstraction layer, this embodiment implements an adaptive initialization process for motor parameters. The initialization process first reads the motor initialization parameters, including basic parameters such as rated voltage, rated current, and rated speed, and then dynamically adjusts these parameters according to the current load state. For example, when a heavy motor load is detected, the system will correspondingly increase the current limit value to ensure that the motor can provide sufficient output torque.
[0090] This embodiment innovatively matches and maps load prediction results with motor control parameters to generate load adaptive control parameters. This process involves the coordinated optimization of multiple control parameters, such as PID parameters and feedforward compensation coefficients. Specifically, when the load prediction result indicates that the load is about to increase, the system will pre-increase the proportional coefficient and integral time constant to improve the anti-interference capability of the control system; when a sharp change in load is predicted, the derivative coefficient will be adjusted accordingly to enhance the dynamic response characteristics of the system.
[0091] The compensation and adjustment of the solution results is another innovation of this embodiment. Based on the load adaptive control parameters, the system performs real-time compensation on the control commands generated by the solution module. For example, when the robot is performing a position control task, if it is predicted that an increase in load will lead to an increase in position error, the system will automatically calculate the compensation amount and add it to the original control command, thereby ensuring control accuracy.
[0092] During the execution of control commands, this embodiment acquires encoder feedback information from the motor in real time via an integrated bus. This feedback information includes state variables such as actual position, speed, and acceleration, which are recorded in the task history database along with the current load data. This closed-loop feedback mechanism is not only used for real-time control but also provides continuously updated training data for optimizing the load prediction model.
[0093] The online optimization and update mechanism in this embodiment is crucial for ensuring the long-term stable operation of the system. By analyzing newly added historical data, the system can promptly identify prediction deviations in the load prediction model and fine-tune the model using incremental learning. This adaptive learning mechanism enables the prediction model to continuously adapt to the aging characteristics of the equipment and changes in operating conditions, maintaining high prediction accuracy.
[0094] In practical applications, this embodiment significantly improves the adaptability and reliability of the motor control system. For example, in flexible manufacturing scenarios for industrial robots, when the robot needs to frequently switch between workpieces of different weights, this solution can accurately predict load changes and adjust the control strategy in advance, effectively avoiding overshoot and oscillation problems in traditional control schemes.
[0095] Furthermore, the motor abstraction layer design in this embodiment facilitates subsequent functional expansion. By adding new interface definitions to the abstraction layer, the system can easily support the integration of new types of motors while maintaining the stability of the original control strategy. This modular design approach greatly improves the maintainability and scalability of the system.
[0096] By establishing a complete feedback loop, this embodiment not only achieves high precision and high reliability in motor control, but also constructs a continuously optimized learning system that can continuously improve control performance and prediction accuracy, providing an effective solution for the intelligent upgrading of industrial automation.
[0097] In one embodiment of the high-frequency real-time control method based on an integrated bus architecture of this application, see [link to relevant documentation]. Figure 3 It can also specifically include the following:
[0098] Step S301: Establish a task manager in the solution module. The task manager adopts a hierarchical structure design, including a task scheduling layer, a task execution layer, and a resource management layer. In the task scheduling layer, a task priority queue is established, and a unique task identifier and initial weight coefficient are assigned to each solution task. The task identifier includes a task type code and timestamp information. The initial weight coefficient is determined based on the real-time requirements and computational complexity of the task. The creation, destruction, and status management of solution tasks are realized through the task manager.
[0099] Step S302: Construct a task history database with a distributed data storage architecture. The task history database includes a real-time data table and a historical data table. The real-time data table records the execution information of each computation task under the current load state. The execution information includes task start time, completion time, CPU utilization, and memory usage. A load state index is established in the historical data table. The task execution information under different load states is stored in time sequence. The historical data is periodically archived and cleaned using a data compression algorithm.
[0100] Optionally, this embodiment first implements an efficient layered task management architecture in the field of task management. Specifically, the task manager adopts a three-layer structure design, including a task scheduling layer, a task execution layer, and a resource management layer. The layers communicate with each other through standardized interfaces, realizing the modularization and decoupling of task management.
[0101] At the task scheduling layer, this embodiment innovatively introduces a priority-based task queue management mechanism. Each computation task is assigned a unique task identifier, which consists of a task type code and a timestamp. The task type code distinguishes different types of computation tasks, such as trajectory planning and dynamics calculation, while the timestamp tracks the task's lifecycle. Simultaneously, based on the task's real-time requirements and computational complexity, an initial weight coefficient is assigned to each task. For example, trajectory planning tasks requiring real-time response are given a higher initial weight, while non-real-time tasks such as background data analysis are given a lower weight.
[0102] This embodiment implements complete task lifecycle management within the Task Manager. From task creation, the Task Manager allocates necessary computing resources, monitors the task's execution status, and reclaims resources upon task completion. This granular task management mechanism ensures efficient utilization of system resources and avoids resource waste and task backlog.
[0103] In terms of data storage, this embodiment constructs a distributed task history database, employing a storage structure that combines real-time data tables and historical data tables. The real-time data tables primarily record task execution information under the current load condition, including key indicators such as task start time, completion time, CPU utilization, and memory usage. This real-time data provides an important basis for the system's dynamic load balancing and resource scheduling.
[0104] This embodiment innovatively establishes a load status index in the historical data table, storing task execution information under different load conditions in a time-series manner. This indexing mechanism greatly improves the retrieval efficiency of historical data, providing reliable data support for subsequent load prediction and performance optimization. Simultaneously, the historical data is periodically archived and cleaned using a data compression algorithm, effectively solving the storage space problem during long-term operation.
[0105] To ensure the system's real-time performance and reliability, this embodiment establishes a concurrent data queue structure based on a high-speed cache. The read / write controller configured in this structure implements secure access control to shared resources through mutex locks and condition variables. The data synchronizer is responsible for synchronizing read / write operations and monitoring the status of queue data, ensuring reliable data transmission between the computation module and the control module.
[0106] In this embodiment, a data priority flag and a data check flag are set in the data queue. The priority flag is used to mark the priority order of data processing, so that the system can prioritize the processing of important control data, while the check flag ensures the correctness of data transmission through algorithms such as cyclic redundancy check.
[0107] In the implementation of the control module, this embodiment constructs a multi-channel motor control unit array and allocates an independent communication resource pool for each control unit. The communication resource pool includes an Ethernet communication interface and a fieldbus interface, configured with TCP / IP protocol stack, real-time Ethernet protocol stack, and CAN bus protocol respectively, to adapt to the communication needs of different types of motors.
[0108] This embodiment dynamically selects the most suitable communication protocol to establish the control link based on the motor's communication characteristics. The control link includes an uplink data channel for sending control commands and a downlink data channel for receiving status feedback, forming a complete bidirectional communication mechanism. This flexible communication architecture enables the system to simultaneously support multiple types of motor control, significantly improving the system's compatibility and scalability.
[0109] In practical applications, the task management and data storage architecture of this embodiment significantly improves the system's operating efficiency and reliability. For example, in the collaborative control scenario of multi-joint robots, the system can rationally allocate computing resources and communication bandwidth according to the control requirements of different joints, ensuring the real-time performance of critical control tasks, while providing rich historical data to support the adjustment of optimized control strategies.
[0110] In one embodiment of the high-frequency real-time control method based on an integrated bus architecture of this application, see [link to relevant documentation]. Figure 4 It can also specifically include the following:
[0111] Step S401: Construct a load prediction model based on a long short-term memory neural network. The load prediction model includes an input layer, a hidden layer, and an output layer. A data normalization unit is set in the input layer to standardize the real-time load data. Forget gate and memory gate are set in the hidden layer. Invalid features are filtered out by the forget gate, and important features are retained by the memory gate. An activation function is set in the output layer to map the output of the neural network to the load prediction range and the trend of change. The load prediction model is trained and the parameters are optimized using sample data from the task history database.
[0112] Step S402: Construct a weight adjuster based on a fuzzy neural network. The weight adjuster receives the output of the load prediction model and converts the load prediction result into a weight adjustment amount through a fuzzy rule base. The fuzzy rule base includes a load interval rule set and a trend rule set. Calculate the pre-adjusted weight coefficient based on the weight adjustment amount and input the pre-adjusted weight coefficient into the task priority sorting module. The task priority sorting module uses an improved quicksort algorithm to rearrange the priorities of the task calculation and generate a task execution sequence.
[0113] Optionally, this embodiment constructs an intelligent load prediction model based on a Long Short-Term Memory (LSTM) neural network to accurately predict the system's load status and changing trends. In the input layer, this embodiment designs a data normalization unit to standardize the real-time collected load data, mapping raw data such as CPU utilization and memory usage to the [-1,1] interval, thus eliminating the influence of different units on prediction accuracy.
[0114] In the design of the hidden layer, this embodiment innovatively optimizes the gating mechanism of LSTM. The forget gate filters input features through the sigmoid function, automatically filtering out features with low contribution to load prediction, such as transient load fluctuations. The memory gate, on the other hand, retains feature information with predictive value, such as the periodic change pattern and long-term trend of the load. This dual-gate structure significantly improves the model's ability to perceive load changes.
[0115] This embodiment employs a combined activation function design at the output layer, simultaneously mapping the neural network output to two dimensions: a load prediction range and a trend. The load prediction range reflects the possible range of system load over a future period, while the trend indicates the direction of load development. This multi-dimensional prediction provides a more comprehensive basis for subsequent task scheduling decisions.
[0116] During model training, this embodiment fully utilizes sample data from the task history database. By extracting task execution information under different load conditions, a training set containing various load scenarios is constructed. The training process employs the backpropagation algorithm to optimize network parameters by minimizing prediction error, thereby improving the model's generalization ability.
[0117] To achieve dynamic adjustment of task priorities, this embodiment constructs a weight adjuster based on a fuzzy neural network. This adjuster receives the output of the load prediction model and converts the prediction results into specific weight adjustment amounts using a predefined fuzzy rule base. The fuzzy rule base includes a load interval rule set and a trend rule set, corresponding to the two input dimensions of load level and changing trend, respectively.
[0118] This embodiment fully considers the needs of real-world application scenarios in the design of fuzzy rules. For example, when an upward trend in load is predicted, the rule base will appropriately reduce the weight of computationally intensive tasks and increase the priority of lightweight tasks to prevent system overload. Conversely, when the load is at a low level and the predicted trend is stable, the rule base will tend to increase the weight of heavy tasks to improve resource utilization efficiency.
[0119] The weight adjuster calculates pre-adjusted weight coefficients based on the fuzzy inference results. These coefficients comprehensively consider the original weights of the current task and load prediction information. The pre-adjusted weight coefficients are then input into the task priority sorting module, which uses an improved quicksort algorithm to prioritize the tasks. The improved sorting algorithm enhances the processing efficiency for nearly ordered sequences by optimizing the partitioning strategy.
[0120] The innovation of this embodiment lies in the deep integration of load prediction and task scheduling. By capturing the temporal characteristics of load changes through an LSTM network and dynamically adjusting weights using a fuzzy neural network, a closed-loop task optimization mechanism is formed. This mechanism can predictively adjust task priorities, avoiding the latency problems caused by traditional passive response methods.
[0121] In practical applications, this embodiment significantly improves the system's load balancing capability and task processing efficiency. For example, in multi-robot collaborative operation scenarios, the system can adaptively adjust the execution priority of each robot's control tasks based on the predicted load status, ensuring timely response to critical control commands while smoothly handling non-critical tasks and maintaining stable system operation.
[0122] This embodiment not only solves the problems of blindness and lag in traditional task scheduling, but also achieves optimal allocation of system resources through intelligent prediction and fuzzy control. This data-driven intelligent scheduling scheme provides a new approach to task management in complex control systems.
[0123] In one embodiment of the high-frequency real-time control method based on an integrated bus architecture of this application, see [link to relevant documentation]. Figure 5 It can also specifically include the following:
[0124] Step S501: Construct a multi-level feedback task scheduler. The multi-level feedback task scheduler includes a task allocation unit and a resource monitoring unit. In the task allocation unit, multiple priority queues are set. Each priority queue is configured with an independent time slice length and scheduling cycle. Dynamic time slices are set based on the response time in the task history database. Task switching thresholds are set based on resource utilization. The resource monitoring unit collects system resource utilization in real time. When the resource utilization exceeds the switching threshold, task degradation processing is triggered.
[0125] Step S502: Establish a parallel computing framework in the solution module. The parallel computing framework includes a task decomposer and a result synthesizer. The task decomposer splits the solution task into multiple subtasks according to an adaptive task scheduling strategy, allocates computing resources to process each subtask in parallel, and the result synthesizer summarizes and verifies the calculation results of the subtasks to generate the final solution result. The solution result is then encapsulated into a data packet and transmitted to the control module through a concurrent queue mechanism.
[0126] Optionally, this embodiment constructs a high-efficiency multi-level feedback task scheduler, employing dynamic time-slice allocation and resource adaptive adjustment mechanisms to achieve intelligent scheduling and optimized resource allocation of computation tasks. The task allocation unit sets up multiple priority queues, each with independently configured time-slice length and scheduling period, forming a hierarchical task processing structure.
[0127] This embodiment innovatively introduces a dynamic time slice allocation mechanism based on historical data. By analyzing the task response times recorded in the task history database, the average execution time and fluctuation range of different types of tasks are calculated, and the time slice length of each priority queue is dynamically adjusted. For example, for computationally intensive trajectory planning tasks, a longer time slice is allocated to reduce task switching overhead; while for lightweight status monitoring tasks, a shorter time slice is configured to improve response speed.
[0128] In terms of resource monitoring, this embodiment designs a sophisticated resource monitoring unit. This unit collects system resource metrics such as CPU utilization, memory usage, and I / O load in real time, and dynamically calculates resource utilization based on these metrics. When the utilization of a certain type of resource exceeds a preset switching threshold, a task degradation mechanism is triggered to release system resources by reducing task priority or suspending non-critical tasks.
[0129] This embodiment employs an innovative task decomposition strategy in the design of the parallel computing framework. The task decomposer adaptively selects the optimal task splitting scheme based on the computational characteristics of the task and the current system resource status. For parallelizable computational tasks, such as the kinematic calculations of a multi-degree-of-freedom robot, they are decomposed into multiple independent sub-tasks for parallel processing, significantly improving computational efficiency.
[0130] In the task decomposition process, this embodiment considers data dependencies and computational load balancing. By analyzing the task's data flow graph, computational units that can be executed in parallel are identified, and computational resources are allocated reasonably according to the complexity of each computational unit. For example, in robot joint trajectory planning, the kinematic calculations of different joints are assigned to different processing cores, while ensuring that the cooperative constraints between joints are satisfied.
[0131] The result synthesizer employs a design combining double buffering and verification mechanisms. After a subtask is completed, the result is first stored in a temporary buffer for data integrity and correctness verification. Once verification is successful, the result is transferred to the main buffer, and the status flag is updated via atomic operations to ensure data consistency. Finally, the verified calculation result is encapsulated into a standard data packet and transmitted to the control module via a concurrent queue mechanism.
[0132] This embodiment employs a lock-free design in its concurrent queue implementation, ensuring secure data transmission through atomic operations and memory barriers. The queue includes read / write pointers and status flags, supporting a multi-producer, multi-consumer model and avoiding the performance overhead of traditional locking mechanisms.
[0133] In practical applications, this embodiment significantly improves the system's computational efficiency and resource utilization. For example, in multi-robot collaborative operation scenarios, the system can dynamically adjust the allocation of computing resources according to the control requirements of each robot, ensuring the real-time performance of critical control commands, while fully utilizing the computing power of multi-core processors through parallel computing.
[0134] When the system load changes abruptly, the multi-level feedback mechanism in this embodiment can respond quickly, maintaining stable system operation through task degradation and resource reallocation. This adaptive scheduling strategy is particularly suitable for the real-time processing needs of complex control systems, effectively solving the adaptability problem of traditional fixed scheduling schemes under dynamic loads.
[0135] This embodiment achieves intelligent scheduling and efficient utilization of computing resources through the organic combination of multi-level feedback scheduling and a parallel computing framework. This adaptive scheduling scheme based on historical data provides a reliable technical solution for real-time computing of complex control systems.
[0136] In one embodiment of the high-frequency real-time control method based on an integrated bus architecture of this application, see [link to relevant documentation]. Figure 6 It can also specifically include the following:
[0137] Step S601: Construct a motor object abstraction layer, which includes a parameter description module and a functional interface module. In the parameter description module, a motor characteristic model is established, which includes an electrical parameter model and a mechanical parameter model. A basic parameter matrix is configured according to the motor model parameters. In the functional interface module, a standardized control instruction set is encapsulated, which includes motion control instructions and status query instructions. The unified management of different motor models is achieved through the motor object abstraction layer.
[0138] Step S602: Establish a motor adaptive controller. The adaptive controller includes a parameter matching unit and a compensation adjustment unit. The parameter matching unit receives the load prediction result, selects the optimal control parameter group from the motor control parameter library, and adaptively adjusts the control parameters according to the load state. The compensation adjustment unit corrects and compensates the solution result based on the load adaptive control parameters, optimizes the control performance using a feedforward compensation strategy, and sends the corrected control command to the motor execution unit through the integrated bus.
[0139] Optionally, this embodiment constructs a motor object abstraction layer, which achieves unified management and control of different motor models through parametric modeling and standardized interface design. The motor characteristic model established in the parameter description module includes electrical parameter models and mechanical parameter models, comprehensively describing the dynamic characteristics of the motor.
[0140] In the electrical parameter model, this embodiment considers key parameters of the motor such as rated voltage, rated current, winding resistance, and inductance, and establishes the correlation between these parameters. The mechanical parameter model includes mechanical characteristic parameters such as rotor inertia, friction coefficient, maximum speed, and rated torque. These parameters are uniformly described through a basic parameter matrix, allowing the characteristics of different motor models to be expressed and processed within the same framework.
[0141] This embodiment features a hierarchical control instruction set designed in the functional interface module. Motion control instructions include basic instructions such as position control, speed control, and torque control, as well as composite motion control instructions. Status query instructions cover functions such as motor operating status, fault diagnosis, and parameter reading. Through a unified instruction interface, standardized control of different motor models is achieved.
[0142] In the design of the motor adaptive controller, this embodiment innovatively introduces load prediction results as the basis for control parameter optimization. The parameter matching unit selects the most suitable parameter set for the current operating condition from the motor control parameter library based on the predicted load state. These parameters include PID controller parameters, feedforward compensation coefficients, filter parameters, etc.
[0143] This embodiment employs a parameter adaptive adjustment strategy based on load characteristics. When the load changes, the controller can dynamically adjust the control parameters according to the output of the load prediction model. For example, in the control of robot joint motors, when an increase in load is predicted, the proportional gain of the torque control is automatically increased to improve the system's anti-interference capability; when the load decreases, the control gain is appropriately reduced to avoid system oscillation.
[0144] The compensation adjustment unit employs an innovative feedforward compensation strategy, which predictively compensates for the impact of load changes by establishing a load disturbance model. This compensation mechanism is particularly suitable for applications requiring high precision, such as robot motion control. For example, when a robot's end effector performs precision operations, feedforward compensation can effectively suppress positional deviations caused by load changes.
[0145] This embodiment employs an integrated bus design for control command transmission, supporting multiple industrial bus protocols such as EtherCAT and PROFINET. A unified communication interface enables real-time and reliable transmission of control commands. The bus system utilizes a distributed clock synchronization mechanism to ensure command synchronization during multi-motor collaborative control.
[0146] In practical applications, this embodiment significantly improves the accuracy and reliability of motor control. For example, in the cooperative control of multi-joint robots, the system can adjust the control strategy in real time according to the load status of each joint motor, ensuring the smoothness and accuracy of the motion trajectory. When a joint experiences a sudden load change, the adaptive controller can respond quickly, maintaining control performance through parameter adjustment and feedforward compensation.
[0147] The motor object abstraction layer in this embodiment simplifies the development and maintenance of motor control systems. Through unified parameter descriptions and standardized interfaces, it significantly reduces repetitive development work for different motor models. Simultaneously, the modular design makes the system easily expandable; integrating new motor models only requires configuring the corresponding parameter models.
[0148] Under complex operating conditions, the adaptive control strategy in this embodiment exhibits excellent adaptability. Through load prediction and parameter adaptation, the system can maintain stable control performance under varying load conditions. This prediction-based adaptive control scheme provides an intelligent solution for motor control systems.
[0149] This embodiment achieves intelligent and standardized motor control through the organic combination of a motor object abstraction layer and an adaptive controller. This design not only improves the reliability and adaptability of the control system, but also provides a scalable technical framework for motor control in the field of industrial automation.
[0150] In one embodiment of the high-frequency real-time control method based on an integrated bus architecture of this application, see [link to relevant documentation]. Figure 7 It can also specifically include the following:
[0151] Step S701: Construct a feedback signal processor, which includes a data acquisition unit and a signal analysis unit. The data acquisition unit periodically acquires the position information, speed information and current information output by the motor encoder through an integrated bus. The signal analysis unit sets a signal filter and a data verifier. The signal filter filters the acquired data for high-frequency noise, and the data verifier verifies the integrity of the data. The processed feedback information is encoded and packaged according to a preset format.
[0152] Step S702: Establish a data update manager, which includes a data classification module and a model optimization module. The data classification module performs time synchronization and feature extraction on the encoded feedback information and load data, and stores the processed data in the corresponding data table of the task history database. The model optimization module periodically reads the newly added data samples and uses an incremental learning algorithm to fine-tune the network parameters of the load prediction model online, so as to realize the continuous optimization of the prediction model.
[0153] Optionally, this embodiment constructs a high-precision feedback signal processor, which realizes real-time monitoring and data optimization of the motor's operating status through a multi-level data processing and verification mechanism. The data acquisition unit adopts a periodic sampling strategy to acquire key status information output by the motor encoder through an integrated bus.
[0154] During signal acquisition, this embodiment employs synchronous sampling technology to ensure the timing consistency of position, velocity, and current information. By configuring a reasonable sampling period, real-time data transmission is guaranteed while avoiding increased system load caused by excessively high sampling frequencies. For example, in robot joint control, an adaptive sampling strategy is adopted based on the dynamic characteristics of different joints, using a higher sampling frequency for critical joints and a lower sampling frequency for secondary joints.
[0155] This embodiment incorporates an innovative filtering algorithm in its signal analysis unit. The signal filter employs a multi-stage filtering structure, combining low-pass filtering and median filtering to effectively remove high-frequency noise and abrupt interference. The filtering parameters are dynamically adjusted based on signal characteristics. For example, for speed signals, a narrower filtering bandwidth is used in the low-speed range to improve signal smoothness; while the bandwidth is appropriately expanded in the high-speed range to ensure the signal's fast response characteristics.
[0156] The data validator employs multiple verification mechanisms, including data format verification, range verification, and consistency verification. By setting reasonable verification rules, it promptly detects and filters abnormal data. For example, when the relationship between position and velocity signals is detected to deviate from physical laws, an anomaly handling mechanism is triggered to ensure data reliability.
[0157] This embodiment innovatively designs a data encoding and packaging scheme, employing compression encoding technology to reduce data transmission volume. Appropriate encoding methods are selected based on the characteristics of different signal types; for example, incremental encoding is used for position signals, and fixed-point representation is used for velocity signals, achieving efficient data transmission.
[0158] In the data update manager, this embodiment implements intelligent data classification and model optimization. The data classification module first aligns the encoded feedback information and load data in time, establishing temporal correlations between different data sources. Through feature extraction algorithms, key features reflecting the dynamic characteristics of the system are extracted, such as load change trends and motion pattern characteristics.
[0159] This embodiment employs a hierarchical architecture for data storage. The task history database contains multiple dedicated tables, each storing different types of data. Efficient data querying and management are achieved through indexing and relationship building. For example, a timestamp-based index allows for quick retrieval of runtime data for specific time periods.
[0160] The model optimization module employs an online optimization strategy based on incremental learning. By periodically analyzing newly added data samples, the performance of the prediction model is evaluated, and the model parameters are fine-tuned based on the evaluation results. This incremental learning approach avoids the overhead of retraining the entire model required by traditional batch learning, while maintaining the model's predictive accuracy.
[0161] In practical applications, this embodiment significantly improves the system's adaptability and reliability. For example, during the long-term operation of an industrial robot, through continuous data accumulation and model optimization, the system can continuously improve its ability to predict load changes under different working conditions, providing a more accurate decision-making basis for adaptive control.
[0162] The data processing flow in this embodiment fully considers the actual needs of industrial sites. Through multi-level data processing and verification, practical problems such as sensor noise and data loss are effectively solved. Meanwhile, the incremental learning mechanism enables the system to continuously adapt to dynamic changes in equipment performance, maintaining good control performance.
[0163] This embodiment constructs a complete data processing and optimization closed loop through the collaborative work of the feedback signal processor and the data update manager. This design not only improves the system's operational stability but also provides strong support for predictive maintenance and performance optimization of the equipment.
[0164] To significantly improve the real-time performance and reliability of multi-motor cooperative control through adaptive task scheduling and load prediction compensation, this application provides an embodiment of a high-frequency real-time control device based on an integrated bus architecture for implementing all or part of the aforementioned high-frequency real-time control method based on an integrated bus architecture. See [link to embodiment].Figure 8 The high-frequency real-time control device based on an integrated bus architecture specifically includes the following components:
[0165] The calculation module 10 is used to divide the control system into a calculation module and a control module. The calculation module and the control module interact with each other through a concurrent queue. The control module includes multiple motor control units. Each motor control unit is connected to the corresponding motor through an integrated bus. The integrated bus includes an industrial Ethernet bus and a fieldbus. The calculation module includes multiple calculation tasks. Each calculation task is set with a corresponding task weight coefficient and a task history database is established. The task history database records the response time and resource consumption of the motor when executing each calculation task under different load conditions.
[0166] The prediction module 20 is used to collect real-time load data of the motor through the integrated bus, wherein the real-time load data includes motor torque, motor speed and motor current. The real-time load data is input into a load prediction model, which is trained based on the task history database. The load prediction model outputs a load prediction result, which includes a predicted load range and a load change trend. Based on the load prediction result, the task weight coefficients are dynamically adjusted to generate pre-adjusted weight coefficients. The pre-adjusted weight coefficients change non-linearly with the load prediction result. Based on the pre-adjusted weight coefficients, the calculation tasks are prioritized. An adaptive task scheduling strategy is established based on the priority ranking. The adaptive task scheduling strategy is optimized based on the response time and resource consumption in the task history database. The calculation module generates a calculation result according to the adaptive task scheduling strategy and transmits the calculation result to the control module through the concurrent queue.
[0167] The control module 30 is used to receive the calculation result, read the motor configuration file (which includes motor model parameters, motor initialization parameters, and motor control parameters), perform abstract modeling of the motor based on the motor model parameters to generate a motor abstraction layer, perform adaptive initialization of the motor based on the motor abstraction layer and the motor initialization parameters, match the load prediction result with the motor control parameters to generate load adaptive control parameters, compensate and adjust the calculation result based on the load adaptive control parameters, and send control commands to the motor through the integrated bus. The control module also receives the coded feedback information of the motor through the integrated bus and stores the coded feedback information and corresponding load data in the task history database for online optimization and updating of the load prediction model.
[0168] As described above, the high-frequency real-time control device based on an integrated bus architecture provided in this application can divide the system into a calculation module and a control module, achieve efficient data interaction through concurrent queues, adopt an integrated architecture of industrial Ethernet bus and fieldbus, train a load prediction model based on historical data, and realize dynamic adjustment of task weight coefficients. By establishing a motor abstraction layer, adaptive initialization of different motor models is achieved, and control parameters are dynamically generated based on load prediction results. This method breaks through the limitations of traditional fixed scheduling strategies, and significantly improves the real-time performance and reliability of multi-motor cooperative control through adaptive task scheduling and load prediction compensation.
[0169] From a hardware perspective, in order to significantly improve the real-time performance and reliability of multi-motor cooperative control through adaptive task scheduling and load prediction compensation, this application provides an embodiment of an electronic device for implementing all or part of the high-frequency real-time control method based on an integrated bus architecture. The electronic device specifically includes the following components:
[0170] The system comprises a processor, memory, a communications interface, and a bus; wherein the processor, memory, and communications interface communicate with each other via the bus; the communications interface is used to realize information transmission between the high-frequency real-time control device based on the integrated bus architecture and core business systems, user terminals, and related databases and other related devices; the logic controller can be a desktop computer, tablet computer, or mobile terminal, etc., and this embodiment is not limited to these. In this embodiment, the logic controller can be implemented with reference to the embodiments of the high-frequency real-time control method based on the integrated bus architecture and the embodiments of the high-frequency real-time control device based on the integrated bus architecture, the contents of which are incorporated herein, and repeated details will not be described again.
[0171] It is understood that the user terminal may include smartphones, tablet computers, network set-top boxes, portable computers, desktop computers, personal digital assistants (PDAs), in-vehicle devices, smart wearable devices, etc. Among these, the smart wearable devices may include smart glasses, smartwatches, smart bracelets, etc.
[0172] In practical applications, parts of the high-frequency real-time control method based on an integrated bus architecture can be executed on the electronic device side as described above, or all operations can be completed in the client device. The choice can be made based on the processing power of the client device and the limitations of the user's usage scenario. This application does not impose any limitations on this. If all operations are completed in the client device, the client device may further include a processor.
[0173] The aforementioned client device may have a communication module (i.e., a communication unit) that can communicate with a remote server to achieve data transmission with the server. The server may include a server on the task scheduling center side; in other implementation scenarios, it may also include a server on an intermediate platform, such as a server on a third-party server platform that has a communication link with the task scheduling center server. The server may include a single computer device, a server cluster consisting of multiple servers, or a distributed server structure.
[0174] Figure 9 This is a schematic block diagram illustrating the system configuration of the electronic device 9600 according to an embodiment of this application. Figure 9 As shown, the electronic device 9600 may include a central processing unit 9100 and a memory 9140; the memory 9140 is coupled to the central processing unit 9100. It is worth noting that... Figure 9 This is an example; other types of structures can also be used to supplement or replace this structure to achieve telecommunications functions or other functions.
[0175] In one embodiment, the high-frequency real-time control method based on an integrated bus architecture can be integrated into the central processing unit 9100. The central processing unit 9100 can be configured to perform the following control:
[0176] Step S101: The control system is divided into a calculation module and a control module. The calculation module and the control module interact with each other using a concurrent queue method. The control module includes multiple motor control units. Each motor control unit is connected to the corresponding motor through an integrated bus. The integrated bus includes an industrial Ethernet bus and a fieldbus. The calculation module includes multiple calculation tasks. Each calculation task is set with a corresponding task weight coefficient. A task history database is established. The task history database records the response time and resource consumption of the motor when executing each calculation task under different load conditions.
[0177] Step S102: Collect real-time load data of the motor through the integrated bus, wherein the real-time load data includes motor torque, motor speed and motor current. Input the real-time load data into the load prediction model. The load prediction model is trained based on the task history database. The load prediction model outputs load prediction results, which include predicted load range and load change trend. Dynamically adjust the task weight coefficients based on the load prediction results to generate pre-adjusted weight coefficients. The pre-adjusted weight coefficients change non-linearly with the load prediction results. Prioritize the calculation tasks based on the pre-adjusted weight coefficients. Establish an adaptive task scheduling strategy based on the priority ranking. The adaptive task scheduling strategy is optimized based on the response time and resource consumption in the task history database. The calculation module generates calculation results according to the adaptive task scheduling strategy and transmits the calculation results to the control module through the concurrent queue.
[0178] Step S103: The control module receives the calculation result, reads the motor configuration file, wherein the motor configuration file includes motor model parameters, motor initialization parameters, and motor control parameters. Based on the motor model parameters, it performs abstract modeling of the motor to generate a motor abstraction layer. Based on the motor abstraction layer, it calls the motor initialization parameters to perform adaptive initialization of the motor. It matches the load prediction result with the motor control parameters to generate load adaptive control parameters. Based on the load adaptive control parameters, it compensates and adjusts the calculation result and sends control commands to the motor through the integrated bus. The control module receives the coded feedback information of the motor through the integrated bus and stores the coded feedback information and corresponding load data in the task history database for online optimization and updating of the load prediction model.
[0179] As described above, the electronic device provided in this application divides the system into a calculation module and a control module. It achieves efficient data interaction through concurrent queues, adopts an integrated architecture of industrial Ethernet bus and fieldbus, trains a load prediction model based on historical data, and dynamically adjusts task weight coefficients. By establishing a motor abstraction layer, it achieves adaptive initialization of different motor models and dynamically generates control parameters based on load prediction results. This method overcomes the limitations of traditional fixed scheduling strategies and significantly improves the real-time performance and reliability of multi-motor collaborative control through adaptive task scheduling and load prediction compensation.
[0180] In another embodiment, the high-frequency real-time control device based on the integrated bus architecture can be configured separately from the central processing unit 9100. For example, the high-frequency real-time control device based on the integrated bus architecture can be configured as a chip connected to the central processing unit 9100, and the high-frequency real-time control method function based on the integrated bus architecture can be realized through the control of the central processing unit.
[0181] like Figure 9 As shown, the electronic device 9600 may further include: a communication module 9110, an input unit 9120, an audio processor 9130, a display 9160, and a power supply 9170. It is worth noting that the electronic device 9600 does not necessarily need to include these components. Figure 9 All components shown; in addition, the electronic device 9600 may also include Figure 9 For components not shown, please refer to existing technologies.
[0182] like Figure 9 As shown, the central processing unit 9100, sometimes also referred to as a controller or operating control, may include a microprocessor or other processor device and / or logic device, which receives inputs and controls the operation of various components of the electronic device 9600.
[0183] The memory 9140 may be, for example, one or more of a cache, flash memory, hard drive, removable media, volatile memory, non-volatile memory, or other suitable devices. It may store the aforementioned failure-related information, and also store a program for executing that information. The central processing unit 9100 may execute the program stored in the memory 9140 to perform information storage or processing, etc.
[0184] Input unit 9120 provides input to central processing unit 9100. Input unit 9120 may be, for example, a keypad or touch input device. Power supply 9170 provides power to electronic device 9600. Display 9160 displays images and text. Display may be, for example, an LCD display, but is not limited thereto.
[0185] The memory 9140 can be a solid-state memory, such as a read-only memory (ROM), random access memory (RAM), a SIM card, etc. It can also be a memory that retains information even when power is off, can be selectively erased, and contains more data; examples of this type of memory are sometimes referred to as EPROMs. The memory 9140 can also be some other type of device. The memory 9140 includes a buffer memory 9141 (sometimes referred to as a buffer). The memory 9140 may include an application / function storage unit 9142 for storing application programs and function programs or processes for executing the operation of the electronic device 9600 via the central processing unit 9100.
[0186] The memory 9140 may also include a data storage unit 9143 for storing data, such as contacts, digital data, pictures, sounds, and / or any other data used by the electronic device. The driver storage unit 9144 of the memory 9140 may include various drivers for the electronic device for communication functions and / or for performing other functions of the electronic device (such as messaging applications, address book applications, etc.).
[0187] The communication module 9110 is a transmitter / receiver that sends and receives signals via the antenna 9111. The communication module 9110 (transmitter / receiver) is coupled to the central processing unit 9100 to provide input signals and receive output signals, which is the same as in a conventional mobile communication terminal.
[0188] Based on different communication technologies, multiple communication modules 9110 can be configured in the same electronic device, such as cellular network modules, Bluetooth modules, and / or wireless LAN modules. The communication module 9110 (transmitter / receiver) is also coupled to a speaker 9131 and a microphone 9132 via an audio processor 9130 to provide audio output via the speaker 9131 and receive audio input from the microphone 9132, thereby realizing typical telecommunications functions. The audio processor 9130 may include any suitable buffer, decoder, amplifier, etc. Additionally, the audio processor 9130 is coupled to a central processing unit 9100, enabling on-device recording via the microphone 9132 and on-device playback of stored audio via the speaker 9131.
[0189] Embodiments of this application also provide a computer-readable storage medium capable of implementing all steps of the high-frequency real-time control method based on an integrated bus architecture, where the execution subject is a server or client, as described in the above embodiments. The computer-readable storage medium stores a computer program that, when executed by a processor, implements all steps of the high-frequency real-time control method based on an integrated bus architecture, where the execution subject is a server or client, as described in the above embodiments. For example, when the processor executes the computer program, it implements the following steps:
[0190] Step S101: The control system is divided into a calculation module and a control module. The calculation module and the control module interact with each other using a concurrent queue method. The control module includes multiple motor control units. Each motor control unit is connected to the corresponding motor through an integrated bus. The integrated bus includes an industrial Ethernet bus and a fieldbus. The calculation module includes multiple calculation tasks. Each calculation task is set with a corresponding task weight coefficient. A task history database is established. The task history database records the response time and resource consumption of the motor when executing each calculation task under different load conditions.
[0191] Step S102: Collect real-time load data of the motor through the integrated bus, wherein the real-time load data includes motor torque, motor speed and motor current. Input the real-time load data into the load prediction model. The load prediction model is trained based on the task history database. The load prediction model outputs load prediction results, which include predicted load range and load change trend. Dynamically adjust the task weight coefficients based on the load prediction results to generate pre-adjusted weight coefficients. The pre-adjusted weight coefficients change non-linearly with the load prediction results. Prioritize the calculation tasks based on the pre-adjusted weight coefficients. Establish an adaptive task scheduling strategy based on the priority ranking. The adaptive task scheduling strategy is optimized based on the response time and resource consumption in the task history database. The calculation module generates calculation results according to the adaptive task scheduling strategy and transmits the calculation results to the control module through the concurrent queue.
[0192] Step S103: The control module receives the calculation result, reads the motor configuration file, wherein the motor configuration file includes motor model parameters, motor initialization parameters, and motor control parameters. Based on the motor model parameters, it performs abstract modeling of the motor to generate a motor abstraction layer. Based on the motor abstraction layer, it calls the motor initialization parameters to perform adaptive initialization of the motor. It matches the load prediction result with the motor control parameters to generate load adaptive control parameters. Based on the load adaptive control parameters, it compensates and adjusts the calculation result and sends control commands to the motor through the integrated bus. The control module receives the coded feedback information of the motor through the integrated bus and stores the coded feedback information and corresponding load data in the task history database for online optimization and updating of the load prediction model.
[0193] As described above, the computer-readable storage medium provided in this application divides the system into a calculation module and a control module. It achieves efficient data interaction through concurrent queues, adopts an integrated architecture of industrial Ethernet bus and fieldbus, trains a load prediction model based on historical data, and dynamically adjusts task weight coefficients. By establishing a motor abstraction layer, it enables adaptive initialization of different motor models and dynamically generates control parameters based on load prediction results. This method overcomes the limitations of traditional fixed scheduling strategies and significantly improves the real-time performance and reliability of multi-motor collaborative control through adaptive task scheduling and load prediction compensation.
[0194] Embodiments of this application also provide a computer program product capable of implementing all steps of the high-frequency real-time control method based on an integrated bus architecture, where the execution subject is a server or client, as described in the above embodiments. When executed by a processor, this computer program / instruction implements the steps of the high-frequency real-time control method based on an integrated bus architecture. For example, the computer program / instruction implements the following steps:
[0195] Step S101: The control system is divided into a calculation module and a control module. The calculation module and the control module interact with each other using a concurrent queue method. The control module includes multiple motor control units. Each motor control unit is connected to the corresponding motor through an integrated bus. The integrated bus includes an industrial Ethernet bus and a fieldbus. The calculation module includes multiple calculation tasks. Each calculation task is set with a corresponding task weight coefficient. A task history database is established. The task history database records the response time and resource consumption of the motor when executing each calculation task under different load conditions.
[0196] Step S102: Collect real-time load data of the motor through the integrated bus, wherein the real-time load data includes motor torque, motor speed and motor current. Input the real-time load data into the load prediction model. The load prediction model is trained based on the task history database. The load prediction model outputs load prediction results, which include predicted load range and load change trend. Dynamically adjust the task weight coefficients based on the load prediction results to generate pre-adjusted weight coefficients. The pre-adjusted weight coefficients change non-linearly with the load prediction results. Prioritize the calculation tasks based on the pre-adjusted weight coefficients. Establish an adaptive task scheduling strategy based on the priority ranking. The adaptive task scheduling strategy is optimized based on the response time and resource consumption in the task history database. The calculation module generates calculation results according to the adaptive task scheduling strategy and transmits the calculation results to the control module through the concurrent queue.
[0197] Step S103: The control module receives the calculation result, reads the motor configuration file, wherein the motor configuration file includes motor model parameters, motor initialization parameters, and motor control parameters. Based on the motor model parameters, it performs abstract modeling of the motor to generate a motor abstraction layer. Based on the motor abstraction layer, it calls the motor initialization parameters to perform adaptive initialization of the motor. It matches the load prediction result with the motor control parameters to generate load adaptive control parameters. Based on the load adaptive control parameters, it compensates and adjusts the calculation result and sends control commands to the motor through the integrated bus. The control module receives the coded feedback information of the motor through the integrated bus and stores the coded feedback information and corresponding load data in the task history database for online optimization and updating of the load prediction model.
[0198] As described above, the computer program product provided in this application divides the system into a calculation module and a control module. It achieves efficient data interaction through concurrent queues, adopts an integrated architecture of industrial Ethernet bus and fieldbus, trains a load prediction model based on historical data, and dynamically adjusts task weight coefficients. By establishing a motor abstraction layer, it enables adaptive initialization of different motor models and dynamically generates control parameters based on load prediction results. This method overcomes the limitations of traditional fixed scheduling strategies and significantly improves the real-time performance and reliability of multi-motor collaborative control through adaptive task scheduling and load prediction compensation.
[0199] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, apparatus, or computer program products. Therefore, the present invention can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, the present invention can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0200] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (devices), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0201] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0202] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 Figure 1 The steps of the function specified in one or more boxes.
[0203] Specific embodiments have been used to illustrate the principles and implementation methods of this invention. The descriptions of the embodiments above are only for the purpose of helping to understand the method and core ideas of this invention. At the same time, for those skilled in the art, there will be changes in the specific implementation methods and application scope based on the ideas of this invention. Therefore, the content of this specification should not be construed as a limitation of this invention.
Claims
1. A high-frequency real-time control method based on an integrated bus architecture, characterized in that, The method includes: The control system is divided into a calculation module and a control module. The calculation module and the control module interact with each other using a concurrent queue method. The control module includes multiple motor control units, each of which is connected to the corresponding motor via an integrated bus, which includes an industrial Ethernet bus and a fieldbus. The calculation module includes multiple calculation tasks, each of which is assigned a corresponding task weight coefficient, reflecting the importance and real-time requirements of the task. A task history database is established, which records the response time and resource consumption of the motor when executing each calculation task under different load conditions. The real-time load data of the motor is collected through the integrated bus, including motor torque, motor speed and motor current. The real-time load data is input into the load prediction model, which is trained based on the task history database. The training data includes motor load sequences under different operating conditions and corresponding solution task execution records. Through the analysis of historical data, the load prediction model can establish a mapping relationship between motor load characteristics and solution task performance. The load prediction model outputs load prediction results, which include predicted load ranges and load change trends. Based on the load prediction results, the task weight coefficients are dynamically adjusted to generate pre-adjusted weight coefficients. The pre-adjusted weight coefficients change non-linearly with the load prediction results. When a drastic change in load is predicted, the weight coefficients of the calculation tasks that are highly correlated with the load will be increased to ensure that critical tasks can respond to load changes in a timely manner. The computation tasks are prioritized based on the pre-adjusted weight coefficients. The prioritization algorithm comprehensively considers the weight coefficients, expected execution time, and resource requirements of the tasks to generate an optimal task execution sequence. An adaptive task scheduling strategy is established based on the priority ranking. The adaptive task scheduling strategy is optimized based on the response time and resource consumption in the task history database. The computation module generates the computation result according to the adaptive task scheduling strategy and transmits the computation result to the control module through the concurrent queue. The control module receives the calculation result and reads the motor configuration file, which includes motor model parameters, motor initialization parameters, and motor control parameters. Based on the motor model parameters, the motor is abstractly modeled to generate a motor abstraction layer. Based on the motor abstraction layer, the motor initialization parameters are called to perform adaptive initialization of the motor. The initialization process first reads the motor initialization parameters and then dynamically adjusts these parameters according to the current load state. The load prediction results are matched with the motor control parameters to generate load adaptive control parameters. When the load prediction results indicate that the load is about to increase, the proportional coefficient and integral time constant are increased in advance to improve the anti-interference capability of the control system. When a sharp change in load is predicted, the derivative coefficient is adjusted accordingly to enhance the dynamic response characteristics of the system. The calculation results are compensated and adjusted according to the load adaptive control parameters, and control commands are sent to the motor through the integrated bus. The control module receives the coded feedback information of the motor through the integrated bus and stores the coded feedback information and the corresponding load data in the task history database for online optimization and updating of the load prediction model.
2. The high-frequency real-time control method based on an integrated bus architecture according to claim 1, characterized in that, The control system is divided into a calculation module and a control module. The calculation module and the control module interact with each other using a concurrent queue method. The control module includes multiple motor control units, each connected to its corresponding motor via an integrated bus. The integrated bus includes an industrial Ethernet bus and a fieldbus. A concurrent data queue structure is established based on a high-speed cache. A read / write controller and a data synchronizer are configured in the concurrent data queue structure. The read / write controller includes a mutex lock mechanism and a condition variable. The data synchronizer is responsible for the read / write synchronization and status monitoring of the queue data. Data transmission from the solution module to the control module is realized through the concurrent data queue structure. A data priority flag bit and a data check bit are set in the data queue. The data priority flag bit is used to mark the priority order of data processing, and the data check bit is used to ensure the correctness of data transmission. A multi-channel motor control unit array is constructed in the control module, and an independent communication resource pool is allocated to each motor control unit. The communication resource pool includes an Ethernet communication interface and a fieldbus interface. A TCP / IP protocol stack and a real-time Ethernet protocol stack are configured in the Ethernet communication interface, and a CAN bus protocol is configured in the fieldbus interface. The corresponding communication protocol is selected according to the motor communication characteristics to establish a control link. The control link includes an uplink data channel and a downlink data channel. The motor control commands are sent and the status feedback is received through the control link.
3. The high-frequency real-time control method based on an integrated bus architecture according to claim 1, characterized in that, The calculation module includes multiple calculation tasks, and each calculation task is set with a corresponding task weight coefficient, which reflects the importance of the task and the real-time requirements. A task history database is established, which records the response time and resource consumption of the motor when performing each calculation task under different load conditions, including: A task manager is established in the solution module. The task manager adopts a hierarchical structure design, including a task scheduling layer, a task execution layer, and a resource management layer. A task priority queue is established in the task scheduling layer. A unique task identifier and an initial weight coefficient are assigned to each solution task. The task identifier includes a task type code and timestamp information. The initial weight coefficient is determined based on the task's real-time requirements and computational complexity. The creation, destruction, and status management of solution tasks are realized through the task manager. A task history database with a distributed data storage architecture is constructed. The task history database includes a real-time data table and a historical data table. The real-time data table records the execution information of each computation task under the current load state. The execution information includes task start time, completion time, CPU utilization, and memory usage. A load state index is established in the historical data table. The task execution information under different load states is stored in time sequence. The historical data is periodically archived and cleaned through a data compression algorithm.
4. The high-frequency real-time control method based on an integrated bus architecture according to claim 1, characterized in that, The real-time load data is input into the load prediction model, which is trained based on the historical task database. The training data includes motor load sequences under different operating conditions and corresponding task execution records. Through analysis of historical data, the load prediction model can establish a mapping relationship between motor load characteristics and task performance. The load prediction model outputs load prediction results, including predicted load ranges and load change trends. Based on the load prediction results, the task weight coefficients are dynamically adjusted to generate pre-adjusted weight coefficients. These pre-adjusted weight coefficients change non-linearly with the load prediction results. When a drastic load change is predicted, the weight coefficients of tasks with high load correlation are increased to ensure that critical tasks can respond to load changes in a timely manner. Based on the pre-adjusted weight coefficients, the tasks are prioritized. The prioritization algorithm comprehensively considers the task weight coefficients, expected execution time, and resource requirements to generate an optimal task execution sequence, including: A load prediction model is constructed based on a long short-term memory neural network. The load prediction model includes an input layer, a hidden layer, and an output layer. A data normalization unit is set in the input layer to standardize the real-time load data. Forget gate and memory gate are set in the hidden layer. The forget gate filters out invalid features, and the memory gate retains important features. An activation function is set in the output layer to map the output of the neural network to the load prediction range and the trend of change. The load prediction model is trained and its parameters are optimized using sample data from the task history database. A weight adjuster based on a fuzzy neural network is constructed. The weight adjuster receives the output of the load prediction model and converts the load prediction result into a weight adjustment amount through a fuzzy rule base. The fuzzy rule base includes a load interval rule set and a trend rule set. A pre-adjustment weight coefficient is calculated based on the weight adjustment amount. The pre-adjustment weight coefficient is input into a task priority sorting module. The task priority sorting module uses an improved quicksort algorithm to reorder the priority of the tasks and generate a task execution sequence.
5. The high-frequency real-time control method based on an integrated bus architecture according to claim 1, characterized in that, The step of establishing an adaptive task scheduling strategy based on the priority order, wherein the adaptive task scheduling strategy is optimized based on the response time and resource consumption in the task history database, and the solution module generates a solution result according to the adaptive task scheduling strategy and transmits the solution result to the control module through the concurrent queue, includes: A multi-level feedback task scheduler is constructed, which includes a task allocation unit and a resource monitoring unit. Multiple priority queues are set in the task allocation unit, and each priority queue is configured with an independent time slice length and scheduling cycle. Dynamic time slices are set based on response times in the task history database, and task switching thresholds are set based on resource utilization. The resource monitoring unit collects system resource utilization in real time, and triggers task degradation processing when resource utilization exceeds the switching threshold. A parallel computing framework is established in the solution module. The parallel computing framework includes a task decomposer and a result synthesizer. The task decomposer splits the solution task into multiple subtasks according to an adaptive task scheduling strategy, allocates computing resources to process each subtask in parallel, and the result synthesizer summarizes and verifies the calculation results of the subtasks to generate the final solution result. The solution result is encapsulated into a data packet and transmitted to the control module through a concurrent queue mechanism.
6. The high-frequency real-time control method based on an integrated bus architecture according to claim 1, characterized in that, The process involves abstractly modeling the motor based on its model parameters to generate a motor abstraction layer. Based on this abstraction layer, the motor initialization parameters are called to perform adaptive initialization. The initialization process first reads the motor initialization parameters and then dynamically adjusts them according to the current load state. The load prediction results are matched with the motor control parameters to generate adaptive load control parameters. When the load prediction indicates an impending load increase, the proportional coefficient and integral time constant are pre-increased to improve the control system's anti-interference capability. When a sharp load change is predicted, the derivative coefficient is adjusted accordingly to enhance the system's dynamic response characteristics. The calculation results are compensated and adjusted based on the adaptive load control parameters, and control commands are sent to the motor via the integrated bus, including: A motor object abstraction layer is constructed, which includes a parameter description module and a functional interface module. A motor characteristic model is established in the parameter description module, which includes an electrical parameter model and a mechanical parameter model. A basic parameter matrix is configured according to the motor model parameters. A standardized control instruction set is encapsulated in the functional interface module, which includes motion control instructions and status query instructions. The unified management of different motor models is realized through the motor object abstraction layer. An adaptive motor controller is established, which includes a parameter matching unit and a compensation adjustment unit. The parameter matching unit receives the load prediction result, selects the optimal control parameter group from the motor control parameter library, and adaptively adjusts the control parameters according to the load state. The compensation adjustment unit corrects and compensates the solution result based on the load adaptive control parameters, optimizes the control performance by adopting a feedforward compensation strategy, and sends the corrected control command to the motor execution unit through an integrated bus.
7. The high-frequency real-time control method based on an integrated bus architecture according to claim 1, characterized in that, The control module receives the coded feedback information from the motor via the integrated bus, and stores the coded feedback information and corresponding load data into the task history database for online optimization and updating of the load prediction model, including: A feedback signal processor is constructed, which includes a data acquisition unit and a signal analysis unit. The data acquisition unit periodically acquires the position information, speed information and current information output by the motor encoder through an integrated bus. The signal analysis unit sets a signal filter and a data verifier. The signal filter filters the acquired data for high-frequency noise, and the data verifier verifies the integrity of the data. The processed feedback information is encoded and packaged according to a preset format. A data update manager is established, which includes a data classification module and a model optimization module. The data classification module performs time synchronization and feature extraction on the encoded feedback information and load data, and stores the processed data in the corresponding data table of the task history database. The model optimization module periodically reads the newly added data samples and uses an incremental learning algorithm to fine-tune the network parameters of the load prediction model online, so as to achieve continuous optimization of the prediction model.
8. A high-frequency real-time control device based on an integrated bus architecture, characterized in that, The device includes: The calculation module divides the control system into a calculation module and a control module. The calculation module and the control module interact with each other via a concurrent queue. The control module includes multiple motor control units, each connected to a corresponding motor via an integrated bus, which includes an industrial Ethernet bus and a fieldbus. The calculation module includes multiple calculation tasks, each with a corresponding task weight coefficient reflecting its importance and real-time requirements. A task history database is established, recording the response time and resource consumption of each calculation task performed by the motor under different load conditions. The prediction module is used to collect real-time load data of the motor via the integrated bus. The real-time load data includes motor torque, motor speed, and motor current. This real-time load data is input into a load prediction model, which is trained based on the historical task database. The training data includes motor load sequences under different operating conditions and corresponding task execution records. Through analysis of historical data, the load prediction model can establish a mapping relationship between motor load characteristics and task performance. The load prediction model outputs load prediction results, including predicted load ranges and load change trends. Based on the load prediction results, the task weight coefficients are dynamically adjusted to generate pre-adjusted weight coefficients. The coefficients change non-linearly with the load prediction results. When a drastic load change is predicted, the weight coefficients of the calculation tasks that are highly correlated with the load are increased to ensure that critical tasks can respond to load changes in a timely manner. Based on the pre-adjusted weight coefficients, the calculation tasks are prioritized. The prioritization algorithm comprehensively considers the weight coefficients, expected execution time, and resource requirements of the tasks to generate an optimal task execution sequence. An adaptive task scheduling strategy is established based on the priority ranking. The adaptive task scheduling strategy is optimized based on the response time and resource consumption in the task history database. The calculation module generates the calculation results according to the adaptive task scheduling strategy and transmits the calculation results to the control module through the concurrent queue. The control module receives the calculation results, reads the motor configuration file (including motor model parameters, motor initialization parameters, and motor control parameters), performs abstract modeling of the motor based on the motor model parameters to generate a motor abstraction layer, and uses the motor initialization parameters to perform adaptive initialization of the motor based on the motor abstraction layer. The initialization process first reads the motor initialization parameters and then dynamically adjusts these parameters according to the current load state. The load prediction results are matched with the motor control parameters to generate load adaptive control parameters. When the load prediction results indicate an impending load increase, the proportional coefficient and integral time constant are pre-increased to improve the anti-interference capability of the control system. When a sharp load change is predicted, the derivative coefficient is adjusted accordingly to enhance the dynamic response characteristics of the system. The calculation results are compensated and adjusted according to the load adaptive control parameters, and control commands are sent to the motor via the integrated bus. The control module receives the coded feedback information from the motor via the integrated bus and stores the coded feedback information and corresponding load data in the task history database for online optimization and updating of the load prediction model.
9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the steps of the high-frequency real-time control method based on an integrated bus architecture as described in any one of claims 1 to 7.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the steps of the high-frequency real-time control method based on an integrated bus architecture as described in any one of claims 1 to 7.
Citation Information
Patent Citations
Multi-shaft servo control system and magic ball matrix
CN102819242A
Multifunctional reconfigurable independent operation motor controller and method
CN115128998A
Stepping motor driving control method and system
CN118573058A
Tension control method and system based on feed-forward compensation
CN119240407A