Magnetic suspension rotor speed control system based on neural network

By using a neural network-based magnetic levitation mover speed control system, the BP neural network is used to adjust the PID parameters online. Combined with the EtherCat protocol and 5S algorithm, the problem of fixed parameters in traditional PID control systems is solved, and high-precision and stable mover speed control is achieved.

CN121173134APending Publication Date: 2025-12-19苏州元磁智控科技有限公司
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202511459007.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-10-13
Publication Date
2025-12-19

AI Technical Summary

Technical Problem

The existing magnetic levitation mover speed control system uses traditional PID control, and the parameter adjustment depends on manual adjustment and is fixed. It is difficult to adapt to the complex nonlinear time-varying system characteristics, making it difficult to achieve precise control of the mover.

Method used

A neural network-based control system is adopted, including an embedded controller, instruction unit, speed unit, execution unit, judgment unit, and control unit. The BP neural network module is used to adjust the PID parameters online, and combined with the EtherCat protocol and 5S algorithm, high-precision speed control of the mover is achieved.

Benefits of technology

It achieves high-precision and stable motion control of the mover, adapts to nonlinear time-varying characteristics, reduces operation and maintenance costs, improves the system's anti-interference ability and position accuracy, and extends the service life of the equipment.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121173134A_ABST
    Figure CN121173134A_ABST
Patent Text Reader

Abstract

The invention relates to the technical field of magnetic suspension systems, and particularly discloses a magnetic suspension rotor speed control system based on a neural network, which comprises an embedded controller, an instruction unit, a speed unit, an execution unit, a judgment unit and a control unit, the control unit adaptively adjusts PID parameters through a BP neural network, performs speed adjustment and updating in real time, then enters the execution unit for actual execution verification, judges whether to enter the speed unit again through the judgment unit, and performs a new round of execution verification and recursive execution until the judgment unit meets the requirements. The method is applied to the field of magnetic suspension rotor speed control, overcomes the defects that parameters in a conventional PID controller adopted in a control system of a magnetic suspension rotor are difficult to adjust, and the parameters are fixed and are difficult to face a complex time-varying system, automatically sets the parameters of the PID controller by adopting the self-learning capability of a BP neural network, adaptively adjusts the PID parameters, and improves the speed of the magnetic suspension rotor. And the robustness and reliability of the control system are improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of magnetic levitation system technology, specifically to a magnetic levitation mover speed control system based on neural networks. Background Technology

[0002] With the rapid development of society, magnetic levitation movers, as core driving components in industrial automation, have been widely used in important fields such as semiconductor manufacturing, precision machining, intelligent logistics, and high-end medical equipment due to their superior characteristics of non-contact operation, high precision, high speed, and low wear. Existing magnetic levitation mover speed control systems employ traditional PID control, with parameter adjustments primarily relying on manual methods, depending on past experience, which is time-consuming and labor-intensive. Furthermore, once the conventional PID parameters are tuned and calculated, they remain fixed throughout the control process. However, in practice, magnetic levitation mover speed control systems are quite complex, exhibiting more intricate nonlinear time-varying system characteristics, making precise mover control difficult. Summary of the Invention

[0003] To address the shortcomings of existing technologies, this invention provides a magnetic levitation mover speed control system based on neural networks, which solves the problems mentioned in the background technology.

[0004] To achieve the above objectives, the present invention provides the following technical solution: a speed control system for a magnetically levitated mover based on a neural network, comprising an embedded controller, an instruction unit, a speed unit, an execution unit, a judgment unit, and a control unit. These units work together to achieve high-precision speed control of the magnetically levitated mover. The specific structure and functions are as follows:

[0005] Embedded controller: It has a built-in real-time operating system and bus master protocol stack, which serve as the computing core and real-time communication core of the system, providing hardware support for the entire system;

[0006] Command unit: includes command receiving module and command setting module. The command receiving module is used to receive motion parameters such as the movement distance, maximum running speed and maximum acceleration of the magnetic levitation mover. The command setting module is used to accurately set the motion parameters and output them to the speed unit.

[0007] Speed ​​Unit: Includes speed planning module and trajectory planning module. The speed planning module is based on 5S algorithm and generates speed planning curve adapted to the motion characteristics of magnetic levitation mover according to the motion parameters set by the instruction unit. The trajectory planning module is used to realize linear interpolation, circular interpolation or Bézier curve interpolation to complete the planning of the mover's motion trajectory.

[0008] The execution unit includes a driver, a motor, and a mover. A permanent magnet plate is fixed on the mover (the mover includes a mover carriage, and the permanent magnet plate is fixed on the mover carriage). The driver and the motor are connected via serial communication (such as RS485 serial communication). The driver controls the motor to generate a specific magnetic field. This magnetic field interacts with the magnetic field generated by the permanent magnet fixed on the back plate of the mover carriage, pushing the mover to move in the set direction.

[0009] Judgment Unit: Includes an encoder module and a position judgment unit. The encoder module is used to acquire the actual position of the mover in real time. The position judgment unit calculates the position difference based on the target position set by the instruction unit and the actual position of the mover fed back by the encoder module, and judges whether the difference meets the preset process requirements. The process requirements are divided into three levels: low level accuracy requirement is position difference ≤ 0.02mm, medium level accuracy requirement is position difference ≤ 0.015mm, and high level accuracy requirement is position difference ≤ 0.01mm. The corresponding level is selected according to the actual needs.

[0010] Control unit: Includes a neural network module (based on BP neural network) and a PID control module. When the position difference calculated by the judgment unit exceeds the system's preset threshold, the neural network module adjusts the PID parameters online based on the forward calculation and backpropagation training of the BP neural network algorithm, and outputs the adjusted PID parameters to the PID control module. The PID control module corrects the speed planning curve generated by the speed unit according to the updated PID parameters, and outputs the corrected curve to the execution unit until the position difference detected by the judgment unit meets the preset process requirements.

[0011] Preferably, the real-time operating system in the embedded controller is selected from at least one of VxWorks and Sylixos, and the bus master protocol stack is used to realize real-time data interaction between the embedded controller and each unit.

[0012] Preferably, the actual position of the mover is acquired in real time by the encoder module and fed back to the driver of the execution unit. The driver feeds back the actual position data of the mover to the position judgment unit of the judgment unit in real time via the EtherCat protocol. The position judgment unit detects in real time whether the difference between the target position and the current feedback position meets the preset process requirements. If the difference exceeds the preset threshold of the system, the neural network module and PID control module of the control unit are triggered to adjust the parameters. The process of parameter adjustment, curve correction, motion control and position detection is executed cyclically until the position difference is lower than the preset threshold.

[0013] Preferably, the control logic of the neural network module includes forward computation and backward propagation computation, and the specific steps are as follows:

[0014] (1) Determine the structure of the BP neural network, including the number of nodes in the input layer, the number of nodes in the hidden layer, and the number of nodes in the output layer (the number of nodes in the output layer is 3, corresponding to the proportional, integral, and derivative coefficients of the PID, respectively). At this time, the number of iterations is... ;

[0015] (2) Obtain the target position of the mover and actual location Calculate the position error at that moment. ;

[0016] (3) Calculate the output of each neuron in the neural network. The forward calculation method is as follows:

[0017] Input layer input is (Change in error) (Integral quantity of error, (for integration iteration variables);

[0018] The input to the hidden layer is The output is In the formula These are the weight coefficients from the input layer to the hidden layer. For the hidden layer bias, The activation function for the hidden layer (the activation function is the tanh function, and the expression is...) ;

[0019] The input of the output layer is The output is In the formula These are the weight coefficients from the hidden layer to the output layer. For output layer bias, The activation function for the output layer (the activation function is the sigmoid function, and the expression is...) ), output The proportional coefficients corresponding to the PID controllers are respectively Integral coefficient Differential coefficients ;

[0020] (4) Train the neural network through backpropagation and update the network weight coefficients according to the gradient descent method:

[0021] The loss function is defined as Constructed based on positional error;

[0022] The weight adjustment amount between the hidden layer and the output layer is In the formula The learning rate (ranging from 0.001 to 0.01). The inertia coefficient (with a value range of 0.01-0.1). , For PID control output, This represents the weight adjustment amount at the previous iteration.

[0023] The weight adjustment amount between the input layer and the hidden layer is In the formula , This represents the weight adjustment amount at the previous iteration.

[0024] (5) Set the number of iterations Return to step (2) until the position error is found. Meets the preset process requirements.

[0025] Preferably, the ID control module uses a discretized PID algorithm, the algorithm expression of which is: In the formula This is the PID control output at the current moment. It is used to correct the speed planning curve. For proportionality coefficient, For integral coefficients, These are the differential coefficients, all output online by the neural network module. This represents the position error at the current moment. This represents the position error at the previous moment. It is the integral sum of the position errors at the current time and all previous times.

[0026] Preferably, the driver in the execution unit is equipped with a main control board, a USB encoding interface and a communication bus interface. The main control board is used to receive and parse control commands issued by the embedded controller. The USB encoding interface is used to connect to an external encoding device to achieve driver parameter debugging and calibration. The communication bus interface is used to ensure the stability of data interaction between the driver and the embedded controller and the motor.

[0027] Preferably, when the 5S algorithm generates the speed planning curve in the speed unit, the motion process of the mover is divided into five stages: starting acceleration, constant speed, deceleration, buffer, and stopping. The speed transition in each stage is smooth, and the initial and final speeds are both set to 0 m / s, which is suitable for the non-contact motion characteristics of the magnetically levitated mover and avoids impacts when the motion starts and stops.

[0028] Preferably, the moving carriage is also equipped with collision buffer blocks, which are fixed at both ends of the moving carriage and made of elastic wear-resistant material. They are used to buffer the impact force when abnormal deviation or collision risk occurs during the movement of the moving carriage, so as to avoid damage to the moving carriage and the permanent magnet plate and ensure the safety of system operation.

[0029] Preferably, the Hall sensor in the judgment unit is integrated into the encoder module. The encoder module also includes an encoder interface, a circuit board, and a control board. The encoder interface is used to realize data transmission between the Hall sensor and the driver. The circuit board provides a stable power supply to the Hall sensor. The control board is used to perform preliminary filtering on the position data collected by the Hall sensor to reduce the impact of environmental interference on the position detection accuracy.

[0030] Preferably, when the PID control module corrects the speed planning curve, it uses a fixed sampling time for data acquisition and output control. The sampling time is set to 0.004s to adapt to the real-time control requirements of the high-speed motion scenario of the magnetic levitation mover, ensuring the timeliness and accuracy of the speed correction response.

[0031] This invention provides a magnetic levitation mover speed control system based on a neural network, which has the following advantages:

[0032] 1. Compared to the limitations of traditional magnetic levitation mover speed control systems, which rely on "manual adjustment of PID parameters and fixed parameters," this invention utilizes a BP neural network module in the control unit. By leveraging its forward computation and backpropagation training capabilities, it can adjust the proportional coefficient (Kp), integral coefficient (Ki), and derivative coefficient (Kd) of the PID online based on the difference between the actual position and the target position of the mover (provided in real-time feedback from Hall sensors). This eliminates the need for repeated manual adjustments based on experience, significantly reducing the time and labor costs associated with parameter tuning. Furthermore, it allows for real-time adaptation to the nonlinear time-varying characteristics of the magnetic levitation system (such as changes in the magnetic field and load fluctuations during motion), avoiding the problem of fixed parameters being unable to cope with complex operating conditions and ensuring that the control parameters are always in an optimal state.

[0033] 2. This invention ensures high-precision control through multiple technological designs: First, the speed unit generates a smooth speed planning curve based on the 5S algorithm, dividing the motion of the mover into an acceleration segment, a constant speed segment, a deceleration segment, a buffer segment, and a stopping segment. It also adapts to the trajectory characteristics of both circular and linear guide rails, avoiding precision deviations caused by motion start-stop impacts. Second, the judgment unit performs preliminary filtering on the mover position data through the encoder module to reduce environmental electromagnetic interference. It also provides three levels of process precision selection: low (≤0.02mm), medium (≤0.015mm), and high (≤0.01mm), which can meet the stringent position accuracy requirements of different scenarios such as semiconductor manufacturing and precision machining. Third, the "BP neural network adaptive PID" control logic can correct the speed planning curve in real time. Compared with traditional PID control, it can significantly reduce speed errors in the acceleration and deceleration stages, achieving precise control of the mover's speed and position.

[0034] 3. This invention improves system stability from both hardware and software aspects: On the hardware side, the driver module of the execution unit realizes real-time feedback of the mover position data through the EtherCat protocol, with low communication latency and strong anti-interference capability. At the same time, when the mover trolley moves along the arc section and the straight section of the guide rail, the speed planning curve can be adapted to the curvature of the guide rail. On the software side, the backpropagation training of the BP neural network can dynamically adjust the weight coefficients according to the error, reduce the impact of external interference on the control effect, and enable the system to remain stable in high-speed and high-acceleration motion scenarios, reducing the occurrence rate of abnormal situations such as mover deviation and jamming.

[0035] 4. The hardware structure design of this invention balances safety and practicality: First, collision buffer blocks made of elastic wear-resistant material are fixed at both ends of the mover carriage, which can buffer the impact force when the mover deviates abnormally or collides, avoiding damage to the mover carriage, permanent magnet, and coil; Second, the driver module integrates a main control board, a USB encoding interface, and a communication bus interface. The USB encoding interface facilitates the connection of external devices to debug and calibrate driver parameters, while the communication bus interface ensures stable data interaction and reduces the difficulty of disassembly and debugging during operation and maintenance; Third, the control board of the encoder module uses sliding average filtering or Kalman filtering to process position data, and the circuit board provides stable power supply, further reducing the risk of hardware failure and extending the service life of the system.

[0036] 5. With its characteristics of "non-contact motion, high-precision control, and adaptive adjustment," this invention can be widely applied in fields such as semiconductor manufacturing, precision machining, intelligent logistics, and high-end medical equipment. Compared to traditional mechanical transmission systems, the wear-free and low-noise advantages of magnetic levitation movers can extend equipment maintenance cycles. Furthermore, the high-precision control and adaptive adjustment capabilities of this invention can meet the diverse needs of different fields for mover speed and position, improving the overall performance and product yield of downstream equipment. Attached Figure Description

[0037] Figure 1 This is a schematic diagram of the magnetic levitation mover speed control system based on neural networks according to the present invention;

[0038] Figure 2 This is a 3D structural schematic diagram of the present invention;

[0039] Figure 3 A schematic diagram of the moving trolley structure;

[0040] Figure 4 This is a 3D top view of the structure of the present invention;

[0041] Figure 5 This is a 3D structural side view of the present invention;

[0042] Figure 6 This is a schematic diagram of the driver structure of the present invention;

[0043] Figure 7 This is a schematic diagram of the encoder structure of the present invention;

[0044] Figure 8 This is a diagram of the BP neural network structure.

[0045] Figure 9 To compare the speed curve based on PID control with the preset 5S curve;

[0046] Figure 10 Comparison of the speed curve of PID control based on BP neural network adaptive adjustment with the preset 5S curve;

[0047] Figure 11 A comparison of speed errors between PID control and adaptive PID control based on BP neural network;

[0048] Figure 12 The curves represent the adaptive PID parameters based on BP neural network adjustment. Detailed Implementation

[0049] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0050] Example 1: The present invention provides a technical solution as follows: Figures 1-7 As shown: A magnetic levitation propeller speed control system based on neural networks, comprising:

[0051] Embedded Controller: The embedded controller is the core control hardware of the entire system, including memory and processor, as well as computer instructions stored in memory and running on the processor. The processor can be a Central Processing Unit (CPU), but it can also be other general-purpose processors, controllers, PLCs, Digital Signal Processors (DSPs), Application-Specific Integrated Circuits (ASICs), Programmable Gate Arrays (FPGAs), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor can be a microprocessor or any conventional processor.

[0052] Command Unit: Includes a command receiving module and a command setting module. The command receiving module configures and provides the motion position of the magnetically levitated mover. 500mm, maximum speed of the mover The maximum acceleration of the moving part is 500 mm / s. 5000mm / s2 The settings are configured via the instruction setting module and then transmitted to the speed unit.

[0053] The velocity unit includes a velocity planning module and a trajectory planning module. Velocity planning uses the 5S algorithm, calculating in multiple segments with initial and final velocities of 0 m / s. The trajectory planning module performs linear interpolation, circular interpolation, and Bézier curve calculations.

[0054] The execution unit includes an execution driver, a motor, a moving trolley, and a speed unit that outputs the planned speed. The output is sent to the actuator driver via a bus protocol, such as EtherCat bus. The actuator driver controls the motor to generate a specific magnetic field via a serial port protocol. The specific magnetic field interacts with the magnetic field generated by the permanent magnet fixed on the moving carriage, driving the moving carriage to move in a specific direction.

[0055] The judgment unit includes an encoder module 6 and a position judgment module. The position judgment module calculates the difference between the set position and the actual position of the moving trolley fed back by the Hall sensor after it stops. To determine whether the process requirements are met, the process requirements are divided into three levels: low level is 0.02mm, medium level is 0.015mm, and high level is 0.01mm. The low level is selected for judgment.

[0056] The control unit includes a BP neural network module and a PID control module. The BP neural network module detects the current position based on the Hall sensor. With setting location The difference The PID parameters are calculated forward and the weight coefficients are updated through backpropagation to adaptively adjust the PID parameters.

[0057] In this embodiment, the system achieves high-precision speed control of the magnetic levitation subcar through a closed-loop process of "command input, speed and trajectory planning, motion execution, position detection and accuracy evaluation, PID parameter adaptive adjustment and re-execution".

[0058] The command unit issues motion parameters of 500mm, 500mm / s, and 5000mm / s².

[0059] The velocity unit generates the 5S algorithm velocity curve and linear interpolation trajectory;

[0060] The execution unit drives the movement of the trolley;

[0061] Determine the difference in detection unit position ,like >0.02mm, triggering the control unit to adjust PID parameters;

[0062] The control unit updates the PID parameters and corrects the speed curve using a BP neural network.

[0063] The execution unit adjusts its motion according to the corrected curve until the judgment unit detects it. If the error is ≤0.02mm, the system stops adjusting and the moving trolley stops precisely at the target position of 500mm.

[0064] The configuration and control logic of this embodiment can effectively solve the problem that traditional PID controllers have fixed parameters and are difficult to adapt to the nonlinear time-varying characteristics of magnetic levitation systems, thus achieving high-precision and stable motion control of the moving trolley.

[0065] More specifically, the speed planning module is based on the 5S algorithm and generates a speed planning curve that adapts to the motion characteristics of the magnetically levitated mover according to the motion parameters set by the instruction unit (the mover moves along the circular arc section of the guide rail 4 or the straight section of the guide rail 5, and the curve adapts to the guide rail trajectory). The trajectory planning module is used to realize linear interpolation (adapting to the straight section of the guide rail 5), circular interpolation (adapting to the circular arc section of the guide rail 4), or Bezier curve interpolation to complete the planning of the mover's motion trajectory.

[0066] Furthermore, the execution unit includes a driver module 3, a motor, and a mover (the mover includes a mover carriage 1, on which a permanent magnet 12 and a coil 13 are fixed; the driver module 3 includes a driver housing 31, a driver base plate 32, a driver power supply line 33, a motor power supply line 34, a main control board 35, a USB encoding interface 36, and a communication bus interface 37; the driver housing 31 is fixed on the driver base plate 32; the main control board 35 has the driver core circuit built in; the driver power supply line 33 supplies power to the driver module 3; the motor power supply line 34 connects the driver module 3 and the motor; the driver module 3 and the motor are connected via series...). The system uses a serial communication interface (such as RS485 serial communication). The driver module 3 controls the motor to generate a specific magnetic field. This magnetic field interacts with the magnetic field generated by the permanent magnet 12 on the moving carriage 1, propelling the moving carriage 1 along the arc section guide rail 4 or the straight section guide rail 5 in a set direction. Collision buffer blocks 11 are also fixed at both ends of the moving carriage 1. The judgment unit includes an encoder module 6 and a position judgment unit. The encoder module 6 includes an encoder interface 61, a circuit board 62, a Hall sensor 63, and a control board 64. The circuit board 62 provides a stable power supply to the Hall sensor 63, and the control board 64 is used to control the position acquired by the Hall sensor 63. The data undergoes preliminary filtering. The encoder interface 61 enables data transmission between the Hall sensor 63 and the driver module 3. The Hall sensor 63 is used to acquire the actual position of the moving trolley 1 in real time. The position judgment unit calculates the position difference based on the target position set by the instruction unit and the actual position of the moving trolley 1 fed back by the Hall sensor 63, and determines whether the difference meets the preset process requirements. The process requirements are divided into three levels: low-level accuracy requirement is a position difference ≤ 0.02mm, medium-level accuracy requirement is a position difference ≤ 0.015mm, and high-level accuracy requirement is a position difference ≤ 0.01mm. The corresponding level can be selected according to actual needs. The control unit includes a neural network module (based on a BP neural network) and a PID control module. When the position difference calculated by the judgment unit exceeds the system's preset threshold, the neural network module adjusts the PID parameters online based on the forward calculation and backpropagation training of the BP neural network algorithm, and outputs the adjusted PID parameters to the PID control module. The PID control module corrects the speed planning curve generated by the speed unit based on the updated PID parameters, and outputs the corrected curve to the execution unit through the communication bus interface 37 of the driver module 3, until the position difference detected by the judgment unit meets the preset process requirements.

[0067] This embodiment revolves around a closed-loop logic of "speed planning, motion drive, position detection, parameter adjustment, and speed correction" to achieve high-precision movement of the magnetically levitated trolley along the guide rail.

[0068] The core design of the 5S speed curve: The speed unit is based on the 5S algorithm to divide the motion into "start-up acceleration segment, constant speed segment, deceleration segment, buffer segment, and stop segment", and forces the initial / final velocity to be 0m / s to adapt to the non-contact characteristics of magnetic levitation and avoid start-stop impact; at the same time, the parameters are dynamically adjusted according to the guide rail type; when moving along the straight section of the guide rail, the slope of the acceleration / deceleration segment is constant (linear change); when moving along the circular arc section of the guide rail, the speed in the buffer segment is reduced to 200mm / s (to adapt to the centrifugal force requirements and avoid trajectory deviation), ensuring that the curve is completely matched with the motion characteristics of the guide rail.

[0069] Seamless connection of interpolation trajectories: The straight segment adopts the "straight interpolation algorithm" (interpolation step size 0.001mm, matching low-level accuracy), and the arc segment adopts the "circular arc interpolation algorithm" (calculates coordinate points based on the center, radius and angle), ensuring that there are no breaks in the trajectory of the straight segment and the arc segment, and avoiding accuracy deviation at the connection.

[0070] The driver module 3 receives the curve signal via the EtherCat protocol (parsing delay ≤0.1ms to ensure real-time performance). After being parsed by the main control board 35, it sends a PWM control signal (frequency 20kHz to avoid motor vibration) to the motor via the RS485 serial port.

[0071] The magnetic field generated by the motor coil 13 interacts with the magnetic field of the permanent magnet 12 (neodymium iron boron N52 material) of the moving trolley 1, forming an electromagnetic thrust along the guide rail, which propels the trolley to move along the planned trajectory. At the same time, the collision buffer blocks 11 (polyurethane material) at both ends of the trolley can buffer abnormal collisions and ensure hardware safety.

[0072] The encoder module 6 has a built-in Hall sensor 63 (linear accuracy 0.0005mm) that collects position data at a frequency of 1kHz. The data is then stably powered by the circuit board 62 (5V±0.01V), and the signal is amplified (10 times) and filtered by the control board 64 using a moving average filter (window size 5) to filter out electromagnetic interference and ensure that the actual position data error is ≤0.001mm.

[0073] Position determination unit calculation Using "Δx≤0.02mm" as the low-level accuracy standard, it determines in real time whether to trigger subsequent adjustments.

[0074] Real-time parameter calculation of BP neural network: The input layer receives "position error" Error change Error integral and The PID parameters are calculated forward through the hidden layer (tanh activation function) and the output layer (sigmoid activation function). ); through backpropagation (based on the loss function) The gradient descent method is used to update the weights. The parameters are optimized with a learning rate η = 0.005 and an inertia coefficient α = 0.05, balancing the convergence speed and stability.

[0075] PID dynamic correction curve: Speed ​​correction is calculated based on new parameters using a discretization algorithm. ,like If positive (positional lag), then superimpose. Increase the speed; if it is negative (position ahead), subtract it. The speed is reduced, and the corrected curve is fed back to the execution unit via the communication bus to achieve dynamic adjustment.

[0076] After the execution unit adjusts the motion according to the correction curve, the judgment unit immediately re-detects. If the error still exceeds the limit, repeat the "position detection, parameter adjustment, and speed correction" process (each loop takes ≤0.004s, i.e., PID sampling time). Usually, 3-5 iterations are sufficient. ≤0.02mm, ensuring the trolley stops precisely at the target position.

[0077] This configuration can be flexibly adapted to different guide rails and accuracy requirements:

[0078] Guide rail type adaptation: In addition to straight / circular arc guide rails, when facing complex curved guide rails (such as S-shaped ones), you can switch to the "Bezier curve interpolation algorithm", which generates a curve that fits the trajectory by adjusting the coordinates of the control points, and at the same time extends the 5S algorithm buffer segment (such as from 0.5s to 1s) to improve motion stability.

[0079] Accuracy level matching: Medium level ( ≤0.015mm) can optimize the filter window (from 5 to 8) and reduce the interpolation step size (from 0.001mm to 0.0008mm); high-level ( For ≤0.01mm, a high-precision Hall sensor (such as A1325 with an accuracy of 0.0003mm) can be replaced, shortening the PID sampling time (from 0.004s to 0.002s) without modifying the closed-loop core logic.

[0080] To address the pain point of insufficient accuracy caused by fixed parameters in traditional PID control, this solution utilizes the following core mechanism:

[0081] Load variation adaptation: When the trolley enters the arc section of the guide rail, the increased centrifugal force causes position lag. (Increase), BP neural network automatically increases (Enhanced Proportion Adjustment) and (Enhanced integral regulation) to accelerate error convergence;

[0082] Interference suppression: caused by electromagnetic noise During instantaneous fluctuations, the neural network increases. (Enhanced differential adjustment) suppresses the influence of instantaneous errors on speed;

[0083] Hardware attenuation adaptation: The attenuation of magnetic flux in permanent magnets leads to a decrease in thrust. (Continuously positive), the neural network continuously increases the weights through iterative optimization. and This compensates for insufficient thrust.

[0084] In actual testing, the error fluctuation range of traditional PID is 0.01-0.03mm (some exceed the standard), while the error fluctuation of this solution is 0.008-0.018mm (meets the standard throughout), improving accuracy and stability by more than 40%, ensuring the stability and reliability of industrial automation scenarios.

[0085] The process of adaptively adjusting PID parameters based on a BP neural network in Example 1; as follows: Figure 8 As shown:

[0086] (1) Determine the structure of the BP neural network, including the number of nodes in the input layer. The number of hidden layer nodes is The number of output layer nodes is 3. =1;

[0087] (2) Obtain and Calculate the error at that time. ;

[0088] (3) Calculate the output of each layer of neurons in the BP neural network. The forward calculation method is as follows:

[0089] Input layer input is ;

[0090] The input to the hidden layer is The output is ;

[0091] In the formula These are the weight coefficients of the hidden layer. The activation function for the hidden layer is the tanh function, expressed as follows: .

[0092] The input to the output layer is: ;

[0093] The output is ;

[0094] ;

[0095] In the formula These are the output layer weight coefficients. The activation function for the output layer is the sigmoid function, expressed as follows: .

[0096] (4) Backpropagation calculation method:

[0097] The loss function is defined as: ;

[0098] The weight adjustment between the hidden layer and the output layer is:

[0099] ;

[0100] In the formula With a learning rate of 0.001, The inertia coefficient is 0.01;

[0101] ;

[0102] ;

[0103] because Unknown, adopted Instead, the learning rate is adjusted to compensate for the resulting error.

[0104] After simplification and approximation, we can obtain: ;

[0105] ;

[0106] Similarly, the weight adjustment amount between the input layer and the hidden layer is:

[0107] ;

[0108] ;

[0109] The weight parameters are updated based on the weight adjustment amount.

[0110] (5) Settings And return to step one;

[0111] (6) The PID algorithm is calculated as follows:

[0112] ;

[0113] In the formula , , These are the proportional, integral, and differential coefficients.

[0114] The adjusted planning speed is:

[0115] ;

[0116] The sampling time is 0.004s.

[0117] In Example 1, the design of BP neural network adaptively adjusting PID parameters addresses the pain points of traditional magnetic levitation mover speed control. It achieves a technological breakthrough through "parameter self-tuning and dynamic error correction." The core technical effects and functions are as follows:

[0118] Traditional PID controllers rely on manual tuning and have fixed parameters, making them unable to handle nonlinear time-varying characteristics such as magnetic field fluctuations and load changes, easily leading to excessive errors. This solution uses a BP neural network for "forward parameter calculation + backward weighting" to dynamically adjust... When the error increases, automatically improve Rapid response, increased Eliminate accumulated deviation; when error fluctuates, add... Interference suppression. Combined with a discretized PID algorithm using 0.004s high-frequency sampling, the position difference can be quickly calculated. Converging to ≤0.02mm (low-level precision) to meet the high-precision requirements of semiconductor manufacturing, precision machining, and other industries.

[0119] Magnetic levitation systems exhibit significant nonlinearity due to factors such as rail type, electromagnetic interference, and permanent magnet attenuation. In this design, the tanh function in the hidden layer of the BP neural network handles the nonlinear mapping, while the sigmoid function in the output layer ensures reasonable parameters. For unknown problems, the "1 approximation and 0.001 learning rate compensation" are used to simplify the calculation and adapt the nonlinear changes of the system through weight iteration. For example, when the circular arc guide rail moves, the parameters are quickly adjusted to cope with the fluctuation of centrifugal force load and avoid trajectory deviation.

[0120] Magnetic levitation systems are susceptible to electromagnetic noise and power supply fluctuations, leading to data fluctuations and unstable speeds. The proposed solution ensures stability through two key aspects: First, a 0.01 inertia coefficient is introduced during backpropagation, and weight updates retain the trend from the previous iteration, preventing sudden parameter changes due to instantaneous errors and mitigating rapid acceleration / deceleration of the mover. Second, the input layer incorporates "error change and error integral sum" to filter out instantaneous interference pulses, ensuring parameter adjustments are based on error trends and enhancing anti-interference capabilities.

[0121] Industrial scenarios have high requirements for operation and maintenance and compatibility. This solution eliminates the need for manual adjustment of PID parameters, and the neural network automatically adjusts online, significantly reducing operation and maintenance costs. The 0.004s sampling time is compatible with the 1kHz acquisition frequency of the Hall sensor, and the correction curve directly drives the motor through the driver communication bus interface without the need for additional hardware modifications. It has strong compatibility and is suitable for industrial automation needs.

[0122] In summary, this design addresses the pain points of traditional PID control systems, which rely on fixed parameters and manual intervention. With its high precision, nonlinear adaptation, stable anti-interference capabilities, and industrial applicability, it provides crucial support for the speed control system of magnetic levitation movers, ensuring their reliable operation under complex working conditions.

[0123] Example 2:

[0124] Trajectory planning is performed based on input parameters, and a preset 5-second velocity curve is generated. The parameters are 0.5, 0.1, and 0.01 respectively; for example... Figure 9 The image shows a comparison between the speed curve regulated by PID control and the preset curve. Figure 10 The image shows a comparison between the speed curve adjusted by PID control based on a BP neural network and the preset curve. Figure 11 The image shows a comparison of the errors of the two control methods, such as... Figure 12 China The parameter curves are shown above. As can be seen, the PID control using a BP neural network has smaller errors, especially in the acceleration and deceleration regions, indicating that the optimized mover speed has higher stability and anti-interference capability.

[0125] Smaller overall error: Compared to traditional PID control, the speed feedback curve of BP neural network PID control has a higher degree of fit with the preset 5S curve. Figure 9 and Figure 10 As shown in the figure, it can more accurately track the preset trajectory;

[0126] Key area error optimization is outstanding: During the start-up acceleration and deceleration stopping phases (the region with the strongest system nonlinearity and highest parameter sensitivity), the error of BP neural network PID control is significantly smaller than that of traditional PID (e.g., Figure 11 (As shown); this is because the neural network can adjust the PID parameters in real time. It adapts to load changes and magnetic field fluctuations during acceleration / deceleration, avoiding the "overshoot" or "hysteresis" errors caused by fixed parameters in traditional PID controllers.

[0127] Smoother speed output: The speed curve of BP neural network PID control has smaller fluctuations (e.g., Figure 10 As shown in the figure, there is no sudden increase / decrease in speed that may occur in traditional PID, ensuring the smoothness of the mover during motion;

[0128] Stronger anti-interference capability: Error comparison chart (e.g.) Figure 11 As shown in the figure, the error fluctuation range of BP neural network PID control is narrower, indicating that it can effectively suppress the influence of external factors such as electromagnetic interference and power supply fluctuations on speed control. The core reason is that the neural network continuously optimizes the weights through backpropagation, dynamically corrects the PID parameters, and offsets the deviation caused by interference.

[0129] Parameter curves (e.g.) Figure 12 The diagram shows the real-time output trend of PID parameters from the BP neural network. Combined with error data, it can be verified that the neural network can adaptively adjust parameters according to the motion state of the mover (such as enhancing proportional regulation during acceleration and enhancing derivative suppression during deceleration), rather than relying on fixed values ​​like traditional PID. This characteristic further proves that the collaborative design of BP neural network and PID can adapt to the time-varying characteristics of magnetic levitation system, providing technical support for high-precision speed control in subsequent industrial scenarios (such as semiconductor manufacturing and precision machining).

[0130] Although embodiments of the invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the appended claims and their equivalents.

Claims

1. A speed control system for a magnetically levitated propeller based on a neural network, characterized in that, It includes an embedded controller, instruction unit, speed unit, execution unit, judgment unit, and control unit. These units work together to achieve high-precision speed control of the magnetically levitated mover. The specific structure and functions are as follows: Embedded controller: It has a built-in real-time operating system and bus master protocol stack, which serve as the computing core and real-time communication core of the system, providing hardware support for the entire system; Command unit: includes command receiving module and command setting module. The command receiving module is used to receive motion parameters such as the movement distance, maximum running speed and maximum acceleration of the magnetic levitation mover. The command setting module is used to accurately set the motion parameters and output them to the speed unit. Speed ​​Unit: Includes speed planning module and trajectory planning module. The speed planning module is based on 5S algorithm and generates speed planning curve adapted to the motion characteristics of magnetic levitation mover according to the motion parameters set by the instruction unit. The trajectory planning module is used to realize linear interpolation, circular interpolation or Bézier curve interpolation to complete the planning of the mover's motion trajectory. The execution unit includes a driver, a motor, and a mover. A permanent magnet plate is fixed on the mover. The driver and the motor are connected via serial communication. The driver controls the motor to generate a specific magnetic field. This magnetic field interacts with the magnetic field generated by the permanent magnet fixed on the back plate of the mover carriage, thus pushing the mover to move in the set direction. Judgment Unit: Includes an encoder module and a position judgment unit. The encoder module is used to acquire the actual position of the mover in real time. The position judgment unit calculates the position difference based on the target position set by the instruction unit and the actual position of the mover fed back by the encoder module, and judges whether the difference meets the preset process requirements. The process requirements are divided into three levels: low level accuracy requirement is position difference ≤ 0.02mm, medium level accuracy requirement is position difference ≤ 0.015mm, and high level accuracy requirement is position difference ≤ 0.01mm. The corresponding level is selected according to the actual needs. Control unit: includes a neural network module and a PID control module. When the position difference calculated by the judgment unit exceeds the system's preset threshold, the neural network module adjusts the PID parameters online based on the forward calculation and backpropagation training of the BP neural network algorithm, and outputs the adjusted PID parameters to the PID control module. The PID control module corrects the speed planning curve generated by the speed unit based on the updated PID parameters, and outputs the corrected curve to the execution unit until the position difference detected by the judgment unit meets the preset process requirements.

2. A magnetic levitation propeller speed control system based on a neural network according to claim 1, characterized in that, The real-time operating system in the embedded controller is selected from at least one of VxWorks and Sylixos, and the bus master protocol stack is used to realize real-time data interaction between the embedded controller and each unit.

3. A magnetic levitation propeller speed control system based on a neural network according to claim 2, characterized in that, The actual position of the mover is acquired in real time by the encoder module and fed back to the driver of the execution unit. The driver feeds back the actual position data of the mover to the position judgment unit of the judgment unit in real time through the EtherCat protocol. The position judgment unit detects in real time whether the difference between the target position and the current feedback position meets the preset process requirements. If the difference exceeds the preset threshold of the system, the neural network module and PID control module of the control unit are triggered to adjust the parameters. The process of parameter adjustment, curve correction, motion control and position detection is executed in a loop until the position difference is lower than the preset threshold.

4. A magnetic levitation propeller speed control system based on a neural network according to claim 3, characterized in that, The control logic of the neural network module includes forward computation and backward propagation computation, and the specific steps are as follows: (1) Determine the structure of the BP neural network, including the number of nodes in the input layer, the number of nodes in the hidden layer, and the number of nodes in the output layer. At this time, the number of iterations is... ; (2) Obtain the target position of the mover and actual location Calculate the position error at that moment. ; (3) Calculate the output of each neuron in the neural network. The forward calculation method is as follows: Input layer input is , ; The input to the hidden layer is The output is In the formula These are the weight coefficients from the input layer to the hidden layer. For hidden layer bias, The activation function for the hidden layer; The input of the output layer is The output is In the formula These are the weight coefficients from the hidden layer to the output layer. For output layer bias, The activation function of the output layer, output The proportional coefficients corresponding to the PID controllers are respectively Integral coefficient Differential coefficients ; (4) Train the neural network through backpropagation and update the network weight coefficients according to the gradient descent method: The loss function is defined as Constructed based on positional error; The weight adjustment amount between the hidden layer and the output layer is In the formula For learning rate, The inertia coefficient, , For PID control output, This represents the weight adjustment amount at the previous iteration. The weight adjustment amount between the input layer and the hidden layer is In the formula , This represents the weight adjustment amount at the previous iteration. (5) Set the number of iterations Return to step (2) until the position error is found. Meets the preset process requirements.

5. A magnetic levitation propeller speed control system based on a neural network according to claim 4, characterized in that, The PID control module uses a discretized PID algorithm, the algorithm expression of which is: In the formula This is the PID control output at the current moment. It is used to correct the speed planning curve. For proportionality coefficient, For integral coefficients, These are the differential coefficients, all output online by the neural network module. This represents the position error at the current moment. This represents the position error at the previous moment. It is the integral sum of the position errors at the current time and all previous times.

6. A magnetic levitation propeller speed control system based on a neural network according to claim 5, characterized in that, The driver in the execution unit is equipped with a main control board, a USB encoding interface, and a communication bus interface. The main control board is used to receive and parse control commands issued by the embedded controller. The USB encoding interface is used to connect external encoding devices to achieve driver parameter debugging and calibration. The communication bus interface is used to ensure the stability of data interaction between the driver, the embedded controller, and the motor.

7. A magnetic levitation propeller speed control system based on a neural network according to claim 6, characterized in that, When the 5S algorithm generates the velocity planning curve in the velocity unit, the motion process of the mover is divided into five stages: starting acceleration, constant speed, deceleration, buffering, and stopping. The velocity transition in each stage is smooth, and the initial and final velocities are both set to 0 m / s to adapt to the non-contact motion characteristics of the magnetically levitated mover and avoid impacts when the motion starts and stops.

8. A magnetic levitation propeller speed control system based on a neural network according to claim 7, characterized in that, The moving trolley is also equipped with collision buffer blocks, which are fixed at both ends of the moving trolley and made of elastic wear-resistant material. They are used to buffer the impact force when there is abnormal deviation or collision risk during the movement of the moving trolley, so as to avoid damage to the moving trolley and permanent magnet plates and ensure the safety of system operation.

9. A magnetic levitation mover speed control system based on a neural network according to claim 8, characterized in that, The Hall sensor in the judgment unit is integrated into the encoder module. The encoder module also includes an encoder interface, a circuit board, and a control board. The encoder interface is used to realize data transmission between the Hall sensor and the driver. The circuit board provides a stable power supply to the Hall sensor. The control board is used to perform preliminary filtering on the position data collected by the Hall sensor to reduce the impact of environmental interference on the position detection accuracy.

10. A magnetic levitation propeller speed control system based on a neural network according to claim 9, characterized in that, When the PID control module corrects the speed planning curve, it uses a fixed sampling time for data acquisition and output control. The sampling time is set to 0.004s to adapt to the real-time control requirements of the high-speed motion scenario of the magnetic levitation mover, ensuring the timeliness and accuracy of the speed correction response.