A vision-guided rotary mold handler positioning control system

The vision-guided positioning control system for rotary mold carriers utilizes LSTM networks to predict mechanical hysteresis loop characteristics and perform dynamic position compensation, solving the signal delay and nonlinear error problems in high-frequency mold changing and high-precision machining of rotary mold carriers, and achieving a high-efficiency and high-quality production process.

CN121608169BActive Publication Date: 2026-05-08ZHEJIANG MAQI SEWING MACHINE
View PDF 2 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
ZHEJIANG MAQI SEWING MACHINE
Filing Date
2026-02-03
Publication Date
2026-05-08

AI Technical Summary

Technical Problem

Existing rotary mold-carrying machines suffer from signal transmission delays, nonlinear mechanical motion errors, and insufficient adaptability to the process environment in scenarios involving high-frequency mold changes, high-precision dynamic processing, and flexible production of multiple varieties, resulting in poor positioning accuracy and production quality.

Method used

The positioning control system of the vision-guided rotary model machine decouples the generalized disturbance torque through the joint drive unit, uses the LSTM network to predict the mechanical hysteresis loop characteristics, and combines the real-time running speed for smooth weight fusion to achieve dynamic position compensation.

Benefits of technology

It effectively overcomes the cumulative errors caused by signal transmission delay and nonlinear mechanical motion, achieving high dynamic precision positioning and ensuring high efficiency and high quality in the production process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121608169B_ABST
    Figure CN121608169B_ABST
Patent Text Reader

Abstract

The present application relates to the technical field of manipulator control, in particular to a visual-guided rotary mold transfer machine positioning control system.The system comprises a joint driving unit, a flexible transmission assembly and a vision module.A master controller first decouples the generalized disturbance torque representing the nonlinear resistance of the flexible assembly from the cross-axis current feedback of the driving unit based on the joint dynamics model;then, the LSTM network is used to learn the mechanical hysteresis loop characteristics of the torque under different rotary motion states, predict the end dynamic position compensation amount covering the system transmission delay time;finally, based on the smooth weight generated by the real-time running speed, the dynamic position compensation amount is fused with the visual positioning coordinates without disturbance.The present application combines physical priori and data driving, effectively overcomes the cumulative error caused by the nonlinear interference of the cable and the signal transmission lag in the non-slip ring rotary operation, and realizes high dynamic precision positioning.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of robotic arm control technology, specifically a vision-guided positioning control system for a rotary manipulator. Background Technology

[0002] In labor-intensive industries such as garment manufacturing and automotive interior processing, automated mold changing machines are widely used in the automatic changing, handling, and positioning of molds. Traditional automated mold changing systems typically consist of multi-axis robotic arms or gantry robots working in conjunction with conveyor lines. They utilize photoelectric sensors or limit switches for position detection and complete the grasping and placement of the molds according to preset teaching trajectories. To accommodate the processing requirements of complex curves, the end effector of the mold often needs to have 360° rotation capability to maintain compliance with the processing direction.

[0003] However, existing rotary motion and positioning control technologies still face significant technical bottlenecks when dealing with high-frequency mold changes, high-precision dynamic machining, and flexible production scenarios involving multiple product types. These bottlenecks are mainly reflected in the following three aspects: First, existing motion machines or robotic arms with 360° infinite rotation capabilities generally use conductive slip ring structures to achieve power and signal transmission between the rotating components and the fixed base. Because the slip ring uses contact-type brush transmission, long-term high-speed rotation leads to wear on the contact surface and carbon powder accumulation, resulting in unstable signal transmission. Especially in precision control requiring millisecond-level response, slip ring transmission often has a signal delay greater than 10ms. Second, existing vision guidance systems mostly adopt an open-loop control mode of "static photography – coordinate calculation – action execution." That is, a one-time photo positioning is performed before the robotic arm moves, and then the robotic arm blindly moves to the target point. This method can only solve static grasping errors but cannot cope with dynamic trajectory deviations caused by changes in the mechanical center of gravity, vibration, or assembly tolerances during the 360° rotation of the motion machine. Third, in traditional control logic, the manipulator robot functions merely as a material handling unit, with its motion control independent of subsequent processing parameters. In automated sewing, different templates and fabric thicknesses require the robot to apply varying pressure when placing the template, along with specific needle-starting actions to prevent "needle not starting" malfunctions. However, existing manipulator robots lack the ability to proactively perceive and adapt to the process environment, failing to automatically adjust the end effector's motion parameters based on visually recognized template characteristics during template changes or movements. This separation of material handling and processing often necessitates manual intervention after template changes and is prone to quality issues such as significant differences in stitch direction, broken threads, or gaps due to improper needle-starting coordination.

[0004] In summary, overcoming the cumulative errors caused by signal transmission delay and nonlinear mechanical motion during the dynamic process of a robotic arm performing 360° continuous rotation is a technical problem that urgently needs to be solved in this field.

[0005] To address this, a vision-guided positioning control system for a rotary model machine is proposed. Summary of the Invention

[0006] The purpose of this invention is to provide a vision-guided positioning control system for a rotary motion machine. The system includes a joint drive unit, a flexible transmission component, and a vision module. The main controller first decouples the generalized disturbance torque, representing the nonlinear resistance of the flexible component, from the quadrature-axis current fed back from the drive unit based on a joint dynamics model. Then, it uses an LSTM network to learn the mechanical hysteresis loop characteristics of this torque under different rotational motion states, predicting the end-effector dynamic position compensation amount covering the system's transmission delay time. Finally, based on smoothing weights generated from the real-time operating speed, the dynamic position compensation amount is seamlessly fused with the visual positioning coordinates. This invention, through a combination of physical priors and data-driven approaches, effectively overcomes the cumulative errors caused by cable nonlinear interference and signal transmission lag in slip-ring-less rotary operations, achieving highly dynamic and precise positioning.

[0007] To achieve the above objectives, the present invention provides the following technical solution:

[0008] A vision-guided positioning control system for a rotary model carrier includes:

[0009] Resistance observation module: acquires the quadrature-axis current fed back by the joint drive unit, as well as the joint angular velocity and angular acceleration fed back by the encoder and performs preprocessing; based on the preset rigid body dynamic parameters of the robotic arm, calculates the rigid body theoretical torque required for the joint to overcome rotational inertia and viscous friction, and decouples the electromagnetic torque converted from the quadrature-axis current by subtracting the rigid body theoretical torque to obtain the generalized disturbance torque.

[0010] Error prediction module: The generalized disturbance torque and the current joint motion state sequence are used as joint features input to the long short-term memory network to learn the mechanical hysteresis loop characteristics of the generalized disturbance torque under different rotation angles, and output the end dynamic position compensation amount for future moments that cover the system transmission delay time.

[0011] Fusion control module: acquires the real-time operating speed of the end effector, calculates the feedforward weights based on the real-time operating speed using a smoothing weighting function, and uses the feedforward weights to perform weighted fusion of the end effector dynamic position compensation amount and visual positioning coordinates to generate the final position control command.

[0012] Preferably, the system further includes a flexible transmission component for connecting the joint drive unit and the end effector; the resistance observation module is configured to perform segmented processing steps: real-time reading of the absolute position data of the encoder, calculating the unidirectional cumulative rotation angle of the joint drive unit relative to the zero point; dividing the unidirectional cumulative rotation angle into a linear resistance region and a nonlinear stretching region; the linear resistance region corresponds to the angle range of the flexible transmission component in a free bending state, and the nonlinear stretching region corresponds to the angle range of the flexible transmission component in a tensioned deformation state; when the unidirectional cumulative rotation angle is in the linear resistance region, the generalized disturbance torque is marked as the first type of feature data; when the unidirectional cumulative rotation angle is in the nonlinear stretching region, the generalized disturbance torque is marked as the second type of feature data; the error prediction module activates the corresponding pre-trained long short-term memory network sub-model according to the input feature type.

[0013] Preferably, the preprocessing includes: performing a moving average filter on the collected quadrature-axis current and calculating the derivative of the filtered quadrature-axis current with respect to time to obtain the current change rate; simultaneously monitoring the change rate of the joint angular velocity; when the current change rate is greater than a preset impact gradient threshold and the joint angular velocity is found to be unable to increase with the increase of current, the system is determined to be mechanically stuck, and an abnormal blocking flag is generated; the fusion control module responds to the abnormal blocking flag by resetting the feedforward weight to zero and locking the generated final position control command as the current position hold command.

[0014] Preferably, the preset rigid body dynamic parameters of the robotic arm are acquired and stored through a parameter identification process: under no-load conditions where the joint drive unit is not connected to the flexible transmission component, the joint drive unit is controlled to perform multi-band sinusoidal scanning motion; the cross-axis current sequence, joint angular velocity sequence and angular acceleration sequence during the motion process are collected simultaneously; a dynamic regression equation with rotational inertia and viscous friction coefficient as undetermined coefficients is constructed, and the collected sequence data is iteratively solved using the least squares method until the residual converges, and the calibration values ​​of rotational inertia and viscous friction coefficient are obtained.

[0015] Preferably, the Long Short-Term Memory (LSTM) network includes an input attention layer; calculates the first-order difference of the input generalized perturbation torque sequence and identifies the zero-crossing moment when the difference sign flips; calculates the cross-correlation coefficient between the input generalized perturbation torque sequence and the current joint angular velocity sequence; assigns dynamic weights to the generalized perturbation torque features of the current time step based on the zero-crossing moment and the cross-correlation coefficient; when a zero-crossing moment is detected, assigns dynamic weights with a weight coefficient greater than a preset weight threshold (e.g., 0.5) to enhance the network's ability to capture features of motor commutation gap and cable hysteresis loop start point.

[0016] Preferably, the smooth weighting function is an S-shaped membership function based on the speed range. The specific steps for calculating the feedforward weight include: presetting a first speed threshold and a second speed threshold, wherein the first speed threshold is defined as the lower limit for dynamic compensation effectiveness, the second speed threshold is defined as the upper limit for visual closure effectiveness, and the first speed threshold is greater than the second speed threshold; if the real-time running speed is greater than the first speed threshold, the calculated feedforward weight is one, and the final position control command is completely dominated by the end-effector dynamic position compensation amount; if the real-time running speed is less than the second speed threshold, the calculated feedforward weight is zero, and the final position control command is completely dominated by the visual positioning coordinates; if the real-time running speed is between the first speed threshold and the second speed threshold, the feedforward weight smoothly decays from one to zero according to the S-shaped curve as the speed decreases.

[0017] Preferably, the visual positioning coordinates are generated by a visual feedback module, which includes an industrial camera, an exposure control unit, and an image processing unit mounted on the end effector; the visual positioning coordinate generation step includes:

[0018] The exposure control unit acquires the real-time operating speed of the end effector; according to the preset photosensitivity curve, when the real-time operating speed exceeds the preset motion blur threshold, the shutter time of the industrial camera is shortened inversely, and the analog gain is simultaneously nonlinearly increased to compensate for the image brightness, so as to acquire clear original image frames.

[0019] The image processing unit receives the end-effector dynamic position compensation amount output by the error prediction module, superimposes it onto the current theoretical joint position fed back by the encoder, and calculates the estimated projection coordinates of the feature points; using the estimated projection coordinates as anchor points, it crops out a region of interest smaller than the field of view of the original image frame, and the region of interest covers the estimated mechanical hysteresis drift range.

[0020] Within the region of interest, a subpixel edge extraction algorithm is used to identify template feature points, and the subpixel-level coordinates of the template feature points in the image coordinate system are calculated. The pre-calibrated camera intrinsic parameter matrix and hand-eye calibration extrinsic parameter matrix are called to map and convert the subpixel-level coordinates into three-dimensional spatial coordinates in the robot base coordinate system. The distortion correction is performed on the converted three-dimensional spatial coordinates, and the final visual positioning coordinates are output to the fusion control module.

[0021] Compared with the prior art, the beneficial effects of the present invention are as follows:

[0022] 1. This invention utilizes a rigid body dynamics model to extract inertial force and viscous friction components from the quadrature-axis current of a servo motor, accurately extracting pure mechanical characteristics that characterize the nonlinear resistance of the flexible transmission component. This allows the control system to "sense" the hidden mechanical hysteresis and elastic deformation at the end effector through electrical signals. This combination of physical prior and data-driven processing effectively solves the trajectory tracking deviation problem caused by complex cable tension changes during high-speed reciprocating rotation of the flexible connection structure, ensuring that the dynamic trajectory error of the end effector within the 360° omnidirectional motion range always converges to an extremely low range allowed by precision manufacturing processes.

[0023] 2. This invention uses the generalized disturbance torque extracted from physical components and the temporal motion state as joint features input into a neural network. This allows the system to establish a precise nonlinear mapping relationship, accurately predict position drift caused by the resistance of flexible components in the future, and generate feedforward compensation commands before the error actually occurs. This predictive control mechanism breaks the strict dependence of conventional feedback control on the real-time performance of sensors, ensuring that the system maintains a millisecond-level control response speed even with inherent physical delays in visual feedback processing and signal transmission, achieving precise synchronization between "vision" and "mechanics" in the time dimension.

[0024] 3. By constructing a continuously differentiable smooth weighting function, this invention enables the system to automatically adjust the allocation of control weights according to the real-time operating speed, achieving a smooth transition between the two modes of "high-speed dynamic predictive control" and "low-speed visual closed-loop control," completely eliminating torque mutations and mechanical jitter that may be caused by the instantaneous switching of control logic. This design not only ensures the smoothness and safety of the mold conveyor during high-speed operation, preventing template displacement due to vibration, but also ensures that visual feedback can be fully utilized to achieve zero static error locking during the low-speed alignment stage, perfectly balancing the dual requirements of high production efficiency and high processing quality for automated production lines. Attached Figure Description

[0025] Figure 1 This is a schematic diagram of a vision-guided positioning control system for a rotary model carrier provided in an embodiment of the present invention;

[0026] Figure 2 A control logic block diagram of a vision-guided rotary model positioning control system provided in an embodiment of the present invention;

[0027] Figure 3 A flowchart of a visually guided positioning control method provided in an embodiment of the present invention. Detailed Implementation

[0028] 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.

[0029] Please see Figures 1 to 3 This invention provides a vision-guided positioning control system for a rotary model moving machine, the technical solution of which is as follows:

[0030] A vision-guided positioning control system for a rotary model carrier includes:

[0031] Resistance observation module: acquires the quadrature-axis current fed back by the joint drive unit, as well as the joint angular velocity and angular acceleration fed back by the encoder and performs preprocessing; based on the preset rigid body dynamic parameters of the robotic arm, calculates the rigid body theoretical torque required for the joint to overcome rotational inertia and viscous friction, and decouples the electromagnetic torque converted from the quadrature-axis current by subtracting the rigid body theoretical torque to obtain the generalized disturbance torque.

[0032] Error prediction module: The generalized disturbance torque and the current joint motion state sequence are used as joint features input to the long short-term memory network to learn the mechanical hysteresis loop characteristics of the generalized disturbance torque under different rotation angles, and output the end dynamic position compensation amount for future moments that cover the system transmission delay time.

[0033] Fusion control module: acquires the real-time operating speed of the end effector, calculates the feedforward weights based on the real-time operating speed using a smoothing weighting function, and uses the feedforward weights to perform weighted fusion of the end effector dynamic position compensation amount and visual positioning coordinates to generate the final position control command.

[0034] Example 1:

[0035] This embodiment applies to intelligent sewing in automated garment production lines, specifically involving a 360° rotating template machine that eliminates the need for conductive slip rings and utilizes highly flexible drag chain cables. In this application scenario, the template machine needs to clamp an acrylic garment template approximately 1.5 meters in length and width, performing high-speed, complex curved trajectory movements below the sewing machine head to automatically sew collars, cuffs, and other parts. Due to the extremely high production cycle requirements, the rotating joints of the template machine often need to complete a rapid 180-degree turn within 300 milliseconds, and the end-positioning accuracy must be controlled within ±0.05 millimeters.

[0036] As one embodiment of the present invention, refer to Figure 1 A schematic diagram of a vision-guided positioning control system for a rotary model moving machine, referring to... Figure 2A control logic block diagram of a vision-guided rotary model positioning control system, referring to... Figure 3 Flowchart of the visually guided positioning control method.

[0037] Furthermore, the system also includes a flexible transmission component for connecting the joint drive unit and the end effector; the resistance observation module is configured to perform segmented processing steps: real-time reading of the absolute position data of the encoder, calculating the unidirectional cumulative rotation angle of the joint drive unit relative to the zero point; dividing the unidirectional cumulative rotation angle into a linear resistance region and a nonlinear stretching region; when the unidirectional cumulative rotation angle is in the linear resistance region, marking the generalized disturbance torque as first-type feature data; when the unidirectional cumulative rotation angle is in the nonlinear stretching region, marking the generalized disturbance torque as second-type feature data; the error prediction module activates one of the two pre-trained long short-term memory network sub-models for computation based on whether the input feature is first-type feature data or second-type feature data.

[0038] Specifically, in the actual operation of this embodiment, the flexible transmission component consists of a corrugated pipe with an inner diameter of 25 mm and six highly flexible shielded cables wrapped inside. Offline testing of the cable's mechanical properties revealed that when the moving machine joint rotates from zero to within a 220-degree range in the positive direction, the cable assembly primarily undergoes bending deformation. The resulting reverse resistance torque increases approximately linearly with the angle, with an average resistance torque of about 0.3 N·m. This range is defined as the linear resistance zone. However, when the rotation angle exceeds 220 degrees and approaches the 360-degree limit, the cable assembly becomes tightly twisted internally, beginning to undergo axial tensile deformation. The resistance torque increases exponentially to over 1.8 N·m, exhibiting extremely strong nonlinear stiffness characteristics. This range is defined as the nonlinear tensile zone. Based on this physical fact, during system operation, the main controller reads encoder values ​​at a frequency of 1 kHz. When the current cumulative angle is detected to be 150 degrees, the system determines that it is in the linear region and automatically calls the first type LSTM sub-model, which has a simpler structure and a computation time of only 0.2 milliseconds. This model focuses on handling low-frequency friction interference. When the cumulative angle is detected to reach 340 degrees, the system immediately and seamlessly switches to the second type LSTM sub-model, which has a larger number of parameters and stronger nonlinear fitting capabilities. Through this segmented modeling strategy, in a complex sewing task involving the entire stroke, the error prediction module successfully predicted the 0.12 mm end rebound displacement of the cable under extreme tension and generated the reverse compensation torque in advance, so that the actual trajectory error is always kept within 0.03 mm, effectively avoiding control divergence caused by model mismatch.

[0039] The beneficial technical effects achieved by this invention through its physical partitioning-based model divide-and-conquer strategy are as follows: It provides a profound insight into the distinctly different mechanical behaviors of flexible cables at different deformation stages. By decomposing the complex global nonlinear problem into two relatively simple sub-problems, it significantly reduces the training difficulty and overfitting risk of a single neural network model. Compared to using a single model to forcibly fit the full range of data, this segmented processing method not only improves the prediction accuracy of high-order nonlinear disturbances under the ultimate tensile state of the cable but also optimizes the allocation of computational resources, ensuring that the system achieves optimal dynamic response performance under different operating conditions.

[0040] Furthermore, the resistance observation module also includes an abnormal interference monitoring unit; the abnormal interference monitoring unit is configured to perform the following steps: perform a moving average filter on the collected quadrature-axis current, and calculate the differential value of the filtered quadrature-axis current with respect to time to obtain the current change rate; simultaneously monitor the change rate of the joint angular velocity fed back by the encoder; when the current change rate is greater than a preset impact gradient threshold, and it is detected that the joint angular velocity cannot increase with the increase of current, it is determined that the system is in a mechanical jam or cable entanglement state, and an abnormal blocking flag is generated; in response to receiving the abnormal blocking flag, the fusion control module forcibly resets the feedforward weight to zero, and locks the generated final position control command as the current position hold command or emergency stop command to cut off the feedforward compensation loop.

[0041] Before performing weighted fusion, the fusion control module performs a delay compensation step on the visual positioning coordinates: obtaining the total system delay time from the start of camera exposure to data transmission to the main controller; obtaining the end-effector dynamic position compensation amount output by the error prediction module at the current moment and the joint angular velocity fed back by the encoder; calculating the macroscopic motion displacement based on the product of the joint angular velocity and the total system delay time, and superimposing the end-effector dynamic position compensation amount into the macroscopic motion displacement to obtain the total delay correction vector; superimposing the total delay correction vector onto the original visual positioning coordinates fed back by the visual feedback module to obtain the time-synchronized corrected visual coordinates, which then participate in the subsequent weighted fusion.

[0042] Specifically, during a certain automated production process, the air pipe under the rotating joint of the conveyor machine accidentally got caught on a protruding screw on the frame. At this moment, the joint drive unit was attempting to execute a rotation command at a speed of 60 rpm. Due to the air pipe being stuck, the resistance experienced by the motor increased dramatically. The abnormal interference monitoring unit detected a surge in the quadrature-axis current from 1.5 amps to 8.2 amps within two control cycles (approximately 2 milliseconds), with a current change rate as high as 3.35 amps / millisecond, far exceeding the preset normal acceleration threshold of 0.8 amps / millisecond. Simultaneously, the angular velocity fed back by the encoder did not increase with the increase in current; instead, it plummeted from 60 rpm to 5 rpm, with a significantly negative rate of change. This physical discrepancy of "high force and slow speed" triggered the jamming judgment logic of the monitoring unit, and the system immediately generated an abnormal blocking flag. Within microseconds of receiving the flag, the fusion control module first instantly reset the feedforward weights for strong torque compensation, originally calculated based on LSTM, to zero. This prevented the AI ​​model from misinterpreting the force as "high resistance" and outputting excessive driving force, which could lead to the trachea rupture. Immediately afterward, the controller issued an emergency stop command and locked the motor brake. Subsequent inspection revealed that due to the timely protection, the trachea only suffered minor marks and did not break, and the motor drive module did not burn out due to overcurrent, thus averting a serious production stoppage.

[0043] Furthermore, the system performed coordinate extrapolation based on dynamic prediction. The total system delay was measured to be 35ms. At a certain moment, the visual feedback coordinate display showed a deviation of +2.0mm, while the motor angular velocity was 10 degrees / second (in the deceleration phase), and the LSTM predicted a micro-displacement of -0.1mm due to cable rebound. The algorithm calculated the macro-displacement correction: 10 × 0.035 × arm length coefficient = 0.8mm. At this point, the system no longer considered the current deviation to be 2.0mm, but corrected it to 2.0 - 0.8 (macro-motion) - (-0.1) (micro-rebound) = 1.3mm. The fusion controller performed closed-loop control based on this "current extrapolated coordinates." Experimental results showed that this compensation mechanism reduced the dynamic tracking error at high speeds by 60%; through this spatiotemporal alignment mechanism that integrates macro-kinematics and micro-dynamics, the phase lag caused by the physical delay of the sensor was mathematically eliminated. By utilizing high-frequency motion data from the motor and microscopic nonlinear data predicted by AI, the "past image" is extrapolated into the "present coordinates," ensuring that the visual feedback data still has extremely high real-time reference value in high-speed dynamic scenarios and guaranteeing the accuracy of fusion control across the entire speed domain.

[0044] This invention constructs a low-level safety barrier independent of the AI ​​control loop. When faced with sudden failures such as cable entanglement or mechanical jamming, the system can quickly identify logical paradoxes at the physical level and decisively cut off feedforward compensation loops that may lead to the expansion of the failure. This prevents the intelligent control system from causing equipment damage due to "overexertion" in overcoming abnormal resistance, greatly improving the system's industrial-grade robustness and safety.

[0045] Furthermore, the preset rigid body dynamic parameters of the robotic arm are acquired and stored through the following parameter identification process: under no-load conditions where the joint drive unit is not connected to the flexible transmission component, the joint drive unit is controlled to perform multi-band sinusoidal scanning motion; the cross-axis current sequence, joint angular velocity sequence, and angular acceleration sequence during the motion process are collected synchronously; a dynamic regression equation with rotational inertia and viscous friction coefficient as undetermined coefficients is constructed, and the collected sequence data is iteratively solved using the least squares method until the residual converges, thereby obtaining the calibration values ​​of the rotational inertia and viscous friction coefficient.

[0046] The parameter identification process specifically includes: under no-load conditions where the joint drive unit is not connected to the flexible transmission component, firstly, zero-point calibration is performed on each sensor to ensure that the deviation between the encoder feedback value and the actual position is less than 0.1 degrees and the deviation between the quadrature axis current feedback value and the actual value is less than 0.05 amperes; then, the joint drive unit is controlled to perform multi-band sinusoidal scanning motion with a frequency from 0.5 Hz to 20 Hz and an amplitude of ±10 degrees, with a sampling frequency of not less than 5 kHz; simultaneously, no less than 150,000 sets of quadrature axis current sequences, joint angular velocity sequences, and angular acceleration sequences are collected. Based on this, a dynamic regression equation was constructed with rotational inertia and viscous friction coefficient as undetermined coefficients. This equation stipulates that the electromagnetic torque is equal to the sum of the product of rotational inertia and angular acceleration, the product of viscous friction coefficient and angular velocity, and the Coulomb friction compensation term. The collected data was iteratively solved using the recursive least squares method, and the convergence criterion was set as the parameter change rate between two adjacent iterations being less than 0.1% or the number of iterations reaching 1000. The obtained calibration values ​​of rotational inertia and viscous friction coefficient were stored in the non-volatile memory of the controller as the reference parameters of the system.

[0047] Preferably, the fusion control module further includes an end effector weight adaptive module; the adaptive module is configured to: when the system adds or unloads the end effector each time, compare the current generalized disturbance torque statistical characteristics (e.g., the average torque at static equilibrium) with the reference value during calibration, and estimate the current equivalent moment of inertia increment of the system online; add the incremental compensation term to the original parameters to obtain the corrected dynamic parameters, which are used for subsequent resistance decoupling calculations, thereby ensuring that the system can accurately extract cable resistance characteristics even under load.

[0048] Specifically, during the factory commissioning phase of the manipulator, engineers first connected the bare joints of the machine, without cables and templates installed, to the commissioning system. The control program drove the joint motors to perform a sinusoidal sweep motion with a frequency linearly increasing from 0.5 Hz to 20 Hz and an amplitude of 10 degrees, lasting for 30 seconds. During this period, the data acquisition card simultaneously recorded over 150,000 sets of quadrature-axis current, angular velocity, and angular acceleration data at a sampling rate of 5 kHz. Subsequently, the built-in parameter identification algorithm constructed a regression matrix based on the rigid body dynamics equations and used the recursive least squares method to iteratively calculate this massive amount of data. After approximately 45 iterations, the calculation residuals converged to the order of 10 to the power of -5, ultimately identifying the total moment of inertia of the rotor and load disk of the joint motor as 0.0025 kg·m² and the viscous friction coefficient as 0.01 N·m·s / radian. These two calibration values ​​were permanently written into the controller's non-volatile memory as reference parameters for subsequent calculations of the generalized disturbance torque. In subsequent actual operation, no matter how the motor accelerates or decelerates, the system can use these parameters to accurately calculate the theoretical torque used to overcome its own inertia, thereby ensuring that the decoupled "disturbance torque" purely reflects the external resistance of the cable.

[0049] This invention provides a precise "self-awareness" benchmark for the entire control system through this standardized offline parameter identification process. By accurately calibrating the rigid body dynamics model of the motor under no-load conditions, the system can completely separate the motor's own inertial forces and inherent frictional forces from the total driving force, eliminating the influence of individual hardware differences on control accuracy. This ensures that the cable resistance features extracted during subsequent online operation are no longer mixed with dynamic noise from the motor's acceleration and deceleration process, significantly improving the purity and physical interpretability of the AI ​​model's input data.

[0050] Furthermore, the long short-term memory network in the error prediction module includes an input attention layer; the input attention layer is configured to: calculate the first-order difference of the input generalized disturbance torque sequence and identify the zero-crossing moment when the difference sign flips; calculate the cross-correlation coefficient between the input generalized disturbance torque sequence and the current joint angular velocity sequence; assign dynamic weights to the generalized disturbance torque features of the current time step based on the zero-crossing moment and the cross-correlation coefficient; when a zero-crossing moment is detected, assign dynamic weights with a weight coefficient greater than a preset weight threshold (e.g., 0.5) to enhance the network's ability to capture features of motor commutation gap and cable hysteresis loop start point.

[0051] The time-series input window length for the error prediction module is set to T=50 control cycles. The input feature vector includes the generalized perturbation torque, joint angular velocity, and angular acceleration at the current time step. The Long Short-Term Memory (LSTM) network is designed as a two-layer structure, with 128 and 64 hidden layer nodes respectively. The input attention layer calculates a weighted score between the input features and the hidden state at the previous time step using a fully connected layer and a Softmax activation function, generating attention coefficients for different time steps. The weighted feature vector is then input into the LSTM unit. At the time step where the torque zero-crossing is detected, the initial attention coefficient bias for that step is forcibly increased to above 0.8.

[0052] The training process of the Long Short-Term Memory (LSTM) network includes: collecting system data from the carrier machine under three working conditions—no load, half load, and full load—for various operating conditions such as constant speed rotation, step acceleration / deceleration, and sinusoidal frequency sweep, with each set of data containing no less than 1000 sample points; using an 80% training set and a 20% validation set split; using MSE (mean squared error) as the loss function; and setting the training stopping condition as the validation set MSE not decreasing for 5 consecutive epochs; this method ensures that the network has sufficient generalization ability for the nonlinear characteristics of cable resistance.

[0053] In the attention mechanism of Long Short-Term Memory (LSTM) networks, the attention coefficients typically follow a probability distribution with a sum of 1. During the normal time steps of a motor's smooth operation (i.e., the non-zero-crossing region), the weights assigned to each time step by the attention mechanism are usually in a low-level, uniform distribution state due to the gradual change in input characteristics (generalized perturbation torque) (e.g., in the 50 time step window of this embodiment, the average weight baseline value is approximately 0.02 to 0.2).

[0054] The "preset weight threshold" is defined as the critical value that distinguishes between "background features" and "key features." The threshold value is set to [0.5, 0.9]. The lower limit of 0.5 is set because when the weight of a single time step exceeds 0.5, it means that the contribution of the features at that specific moment to the network output exceeds the sum of all other historical moments, thus ensuring that the network can "focus" on the nonlinear change in mechanical backlash during motor commutation. In this embodiment, the threshold is set to 0.6 to complement the operation mentioned above of increasing the weight to 0.9, ensuring that key features are fully captured.

[0055] Specifically, when the motion machine executes a complex "paperclip" sewing trajectory, the joint motor needs to frequently switch between forward and reverse rotation. At the instant the motor decelerates from forward to zero and begins to reverse, due to the backlash in the reducer and the change in the direction of the cable's elastic force, the generalized disturbance torque experiences a brief "dead zone" followed by a jump. This is the most difficult nonlinear characteristic to predict in a hysteresis loop. In this embodiment, the input attention layer calculates the first-order difference of the torque sequence in real time. At the moment the motor speed crosses zero and the sign of the torque difference flips (i.e., the commutation moment), the attention mechanism immediately increases the feature weight of that time step from the default 0.2 to 0.9. This means that the LSTM network will be "fully focused" on learning the mechanical changes at this instant. Data shows that after introducing this attention mechanism, for the 0.08 mm mechanical backlash sudden change generated at the commutation moment, the system's prediction response time is shortened from 12 milliseconds to 3 milliseconds, almost achieving synchronization with the physical change. Meanwhile, the calculation of cross-correlation coefficients helps the network identify which torque fluctuations are caused by speed changes (inertial correlation) and which are independent cable interferences, thereby further suppressing prediction noise and ensuring that the peak value of the end-positioning error is always controlled below 0.04 mm during continuous commutation.

[0056] This invention introduces an attention mechanism triggered by physical features, endowing neural networks with the ability to "focus on" specific mechanical control characteristics. By automatically identifying critical moments of drastic dynamic behavior such as motor commutation and clearance crossing, and dynamically increasing the data weights at these moments, the system overcomes the shortcomings of traditional recurrent neural networks in averaging weights when processing stationary and abrupt data. This significantly improves the model's sensitivity to capturing nonlinear inflection points of mechanical hysteresis loops, thereby achieving precise compensation for dynamic backlash.

[0057] The joint features of the error prediction module also include the cable historical deformation power index; the calculation steps of the index are as follows: in each control cycle, calculate the absolute value of the product of the current generalized disturbance torque and the joint angular velocity to obtain the instantaneous deformation power; integrate the instantaneous deformation power within the past set time window to obtain the cable historical deformation power index reflecting the recent fatigue relaxation state of the flexible transmission component; use this index as an additional state input to the long short-term memory network to correct the network's prediction of stiffness softening of the flexible transmission component after repeated stretching.

[0058] After 50 consecutive large-amplitude reciprocating twists, the polymer sheath of the flexible cable softens due to the "stress relaxation" effect. At the same twist angle, the resistance torque decreases by approximately 10% compared to the cold state. Furthermore, the system introduces a historical work index for the cable's deformation. Specifically, the controller calculates the cable's deformation power (torque multiplied by speed) over the past 60 seconds in real time. During continuous operation, this integral value gradually accumulates to 500 joules. Upon receiving this high-value input, the LSTM network automatically adjusts its internal weights, reducing the output compensation by 8% to match the softened cable characteristics. After a 10-minute shutdown, the integral value decays to zero, and the model automatically reverts to the cold-state compensation parameters. This invention, by introducing a historical work index reflecting the material's rheological properties, achieves the beneficial technical effect of giving the control system the ability to perceive the fatigue state of flexible materials. As a polymer material, the mechanical properties of cables have a strong historical dependence. This technical solution enables the AI ​​model to dynamically adjust its prediction strategy based on the cable's recent usage intensity, perfectly solving the overcompensation or undercompensation problems caused by cable softening or hardening.

[0059] Furthermore, the weighted fusion mechanism of the fusion control module is specifically as follows: Feedforward weights are calculated based on the real-time operating speed and two preset speed thresholds—namely, a first speed threshold defined as the lower limit of dynamic compensation effectiveness and a second speed threshold defined as the upper limit of visual loop closure effectiveness (and the second speed threshold is less than the first speed threshold). The weight calculation logic is as follows: when the real-time operating speed is greater than or equal to the first speed threshold, the feedforward weight is one; when the real-time operating speed is less than or equal to the second speed threshold, the feedforward weight is zero; when the real-time operating speed is between the two, a cosine smooth interpolation algorithm is used to calculate the weights. The specific steps are: calculate the difference between the real-time operating speed and the second speed threshold, divide it by the difference between the first and second speed thresholds to obtain a normalized ratio; calculate the cosine value of the product of this normalized ratio and pi; subtract this cosine value from one and divide by two to obtain the final feedforward weight. This algorithm ensures that the first derivative of the weights at the two threshold boundaries is zero, thereby achieving a smooth transition without acceleration jumps. The final generated position control command is equal to the product of the feedforward weight and the end-effector dynamic position compensation, plus the product of the complement of the feedforward weight (i.e., one minus the feedforward weight) and the corrected visual coordinates after delay compensation. The end-effector dynamic position compensation is output by the error prediction module, and the corrected visual coordinates are the coordinates output by the visual feedback module after delay correction.

[0060] The selection of the first and second speed thresholds follows these principles: the first speed threshold should be set to a speed limit not lower than the total system transmission delay, specifically quantified as the ratio of the maximum allowable static error of the end effector to the total system delay time, to ensure that the delay in visual feedback during high-speed motion does not lead to overshoot; the second speed threshold should be set to the minimum speed sufficient for the visual feedback algorithm to converge stably, typically about one-tenth of the first speed threshold. In this embodiment, based on parameters such as a system transmission delay of 35 milliseconds, an allowable static error of 0.02 mm at the end effector, and a maximum cable stiffness of 0.5 N·m / radian, the first speed threshold is set to 60 degrees / second (corresponding to an end effector linear velocity of approximately 0.5 m / second), and the second speed threshold is set to 5 degrees / second.

[0061] Before performing weighted fusion, the fusion control module also includes a consistency check step: calculating the numerical difference between the prediction compensation command of the previous control cycle and the visual feedback command of the current cycle. If the difference exceeds a set threshold (for example, more than 0.5 mm or its corresponding torque equivalent), it indicates that there is a conflict between the two signals. The system does not directly execute the above weighted fusion formula, but instead uses low-pass filtering to smooth the two signals to prevent system oscillation caused by sudden commands.

[0062] To ensure the continuity and smoothness of the weights during the switching process, the smoothing weighting function is constructed using a cosine-based smoothing interpolation algorithm. The specific calculation logic of this weight executes the following steps: First, normalization processing: The system first calculates the normalization ratio of the real-time running speed relative to the speed range. This ratio is the quotient of the difference between "real-time running speed minus the second speed threshold" and "first speed threshold minus the second speed threshold". When the real-time running speed is between the two thresholds, the value range of this normalization ratio is zero to one. Second, mapping calculation: The above normalization ratio is mapped to feedforward weights using the half-cycle characteristic of the cosine function. The calculation logic is as follows: Take the cosine value of the product of the normalization ratio and pi, subtract this cosine value from one, and divide by two to obtain the final feedforward weights.

[0063] Through the above calculations, when the real-time operating speed approaches the first speed threshold, the slope of the tangent line of the weighted curve approaches zero and smoothly transitions to one; when the real-time operating speed approaches the second speed threshold, the slope of the tangent line of the weighted curve also approaches zero and smoothly transitions to zero. This mathematical characteristic that the derivative at both extreme points is zero ensures in principle that no sudden acceleration occurs at the control mode switching point, thereby achieving a smooth and uninterrupted transition of torque output.

[0064] Specifically, the first speed threshold for the moving machine is set to 60 degrees per second, and the second speed threshold is set to 5 degrees per second. When the moving machine is in a high-speed shifting phase of 120 degrees per second, since the speed far exceeds the first speed threshold, the system determines that there is significant dynamic blur and delay in the visual feedback. Therefore, the feedforward weight is reset to 1, and the system relies entirely on the compensation amount predicted by LSTM for high-frequency open-loop control to ensure a smooth trajectory without jitter. When the moving machine approaches the target point and begins to decelerate, the speed drops to 30 degrees per second. The weight calculated by the S-curve function is 0.5. At this point, the control command consists of 50% prediction compensation and 50% visual positioning, and visual correction is introduced. When the speed further decreases to the fine-tuning alignment phase of 2 degrees per second, the weight smoothly decays to 0, and the system fully switches to a visual closed-loop mode, utilizing the static high-precision characteristics of the high-definition camera to eliminate the final 0.01 mm positioning residual. Throughout the deceleration process, since the weight change follows a continuously differentiable S-curve, the torque output curve of the servo motor never shows a step change. Actual test data shows that this fusion strategy eliminates the impact torque of about 0.2 N·m generated at the speed critical point of traditional hard switching, which reduces the vibration amplitude of the robotic arm end effector by 95% and achieves a silky smooth "dynamic-to-static transition".

[0065] This invention solves the control conflict problem in multi-source sensor data fusion from a mathematical perspective by employing a velocity field-based, non-disruptive, smooth fusion control strategy. By constructing a continuously differentiable weighted transition interval, the system cleverly avoids potential "control jumps" and mechanical shocks that may occur when switching between high-speed feedforward control and low-speed feedback control. This not only ensures dynamic tracking performance at high speeds and static positioning accuracy at low speeds but also significantly extends the service life of precision transmission mechanisms and improves the operational quality of the equipment.

[0066] Furthermore, the visual feedback module includes an industrial camera, an exposure control unit, and an image processing unit mounted on the end effector; the step of generating visual positioning coordinates specifically includes: Sub-step one: motion adaptive acquisition, the exposure control unit acquires the real-time running speed of the end effector; according to a preset photosensitivity curve, when the real-time running speed exceeds a preset motion blur threshold, the shutter time of the industrial camera is shortened inversely proportionally, and the analog gain is simultaneously nonlinearly increased to compensate for image brightness, acquiring a clear original image frame; Sub-step two: prediction-guided region locking, the image processing unit receives the end effector dynamic position compensation amount output by the error prediction module and superimposes it onto the current joint feedback from the encoder. Theoretical position: Calculate the estimated projected coordinates of feature points; using the estimated projected coordinates as anchor points, crop a region of interest smaller than the original image field of view from the original image frame, the region of interest covering the estimated mechanical hysteresis drift range; Sub-step three: High-precision coordinate calculation: within the region of interest, use a sub-pixel edge extraction algorithm to identify template feature points, calculate the sub-pixel level coordinates of the feature points in the image coordinate system, call the pre-calibrated camera intrinsic parameter matrix and hand-eye calibration extrinsic parameter matrix, map the sub-pixel level coordinates into three-dimensional spatial coordinates in the robot base coordinate system, perform distortion correction on the converted three-dimensional spatial coordinates, and output the final visual positioning coordinates to the fusion control module.

[0067] The camera intrinsic parameter matrix and hand-eye calibration extrinsic parameter matrix are obtained through the following calibration process: The industrial camera's intrinsic parameters are calibrated using the Zhang Zhengyou planar calibration method. The calibration board has a checkerboard pattern with a side length of 25 mm. Images of the calibration board are taken from at least 20 different angles during calibration. The camera's focal length, principal point coordinates, radial and tangential distortion coefficients are calculated. Hand-eye relationship calibration is performed using the Tsai hand-eye calibration method or a similar absolute orientation method. During calibration, the calibration tool board on the robotic arm's end effector and the reference board fixed within the camera's field of view need to perform feature point matching under at least 15 different robotic arm postures. The rotation matrix and translation vector from the camera coordinate system to the robotic arm's base coordinate system are calculated. The calibration accuracy is verified as follows: After the calibration process is completed, 10 feature point positions that were not calibrated are randomly selected. The calibration matrix is ​​used to perform coordinate transformation, and the results are compared with the actual positions. The transformation error is required to be less than 0.1 mm. When the error exceeds 0.1 mm, calibration data should be re-acquired or calibration parameters adjusted.

[0068] When the subpixel edge extraction algorithm performs feature recognition within the region of interest, the input image quality requirements are as follows: the image contrast (difference between the feature pixel value and the background pixel value) around the feature point is not less than 30 gray levels, and the image sharpness index (defined as the energy proportion of high-frequency components in the image) is not less than 0.6; when the speed of the moving machine exceeds 200 mm / s, the camera exposure time should be automatically compressed according to the real-time speed to ensure that the motion blur of the acquired original image frame within the region of interest does not exceed 0.5 pixels; if the feature point contrast is detected to be less than 30 or the sharpness index is less than 0.6, the system should automatically trigger exposure parameter adjustment or switch to pure prediction compensation mode, and temporarily disable visual feedback.

[0069] Preferably, the system further includes a hand-eye calibration verification module; the module is configured to: every 1000 control cycles (e.g., at a control frequency of 1 kHz, approximately 1000 seconds or the end of a production shift), transform a set of pre-stored calibration feature points using the current extrinsic parameter matrix and compare them with historical calibration data; if the coordinate transformation error increases by more than 0.05 mm compared to the initial calibration, a calibration matrix drift warning is automatically generated, prompting the operator to recalibrate; the recalibration adopts an incremental method, requiring only the collection of 3-5 new feature point pairs, and fine-tuning of the original parameter matrix through least squares optimization, without the need for a complete recalibration process.

[0070] Specifically, when the template carrier sweeps across the template markers at a high linear speed of 500 mm / s, severe motion blur will occur in the image if conventional settings are used. In this embodiment, after detecting this speed, the exposure control unit immediately shortens the camera exposure time from the standard 5000 microseconds to 50 microseconds, while simultaneously increasing the analog gain by 12 dB to ensure that the image grayscale value remains clear at around 120 even under extremely short exposure. Next, the image processing unit does not search the full-frame 5-megapixel image but instead receives compensation information predicted by the LSTM module: "currently drifted 0.5 mm in the negative X-axis direction due to cable drag." Based on the encoder's theoretical position and this predicted drift, the system directly locks onto a tiny region of interest of only 200x200 pixels. Within this region of interest, the algorithm performs sub-pixel edge extraction, calculating the feature center coordinates as (105.34, 98.67), achieving an accuracy of 0.02 pixels. By using intrinsic parameters and hand-eye matrix transformation, the coordinates in the base coordinate system (X=500.12mm, Y=300.05mm) were finally calculated. The entire process, from the end of exposure to the output of coordinates, took only 4 milliseconds, which is nearly 90% shorter than the 35 milliseconds of full-image search, effectively solving the visual latency problem.

[0071] This invention breaks through the performance bottleneck of traditional machine vision systems, which are characterized by slow observation and slow computation, through a visual processing mechanism that integrates hardware adaptation and predictive guidance algorithms. Motion-adaptive exposure eliminates dynamic blur, and LSTM predictive guidance enables precise local processing of regions of interest, significantly reducing the amount of image data processed. This improves the real-time performance of visual feedback by an order of magnitude, enabling it to meet the stringent timing requirements of high-speed rotating models and achieving sub-pixel-level precision positioning in highly dynamic environments.

[0072] Furthermore, the system also includes a topology safety management module; the topology safety management module is configured to: set a software limit threshold, which is less than the physical breakage limit angle of the flexible transmission component; accumulate the unidirectional rotation angle of the joint drive unit in real time; when the unidirectional rotation angle reaches the software limit threshold, send a unidirectional prohibition command to the fusion control module to prohibit the generation of rotation control commands in the same direction; when the joint drive unit is detected to be in an idle standby state, automatically generate an unwinding trajectory command to drive the joint drive unit to rotate in the opposite direction until the unidirectional rotation angle returns to zero; logically eliminating the risk of "twisted wire breakage" that may be faced by the slip ring-less structure. Through strict software limits and intelligent idle unwinding strategies, the system ensures both the flexibility of large-angle rotation in a single task and ensures that the cable assembly always operates within a safe deformation range, thereby achieving long-term reliable operation capability equivalent to infinite rotation without using expensive and easily damaged slip rings.

[0073] This embodiment employs a model divide-and-conquer strategy based on physical partitioning to gain profound insights into the distinctly different mechanical behaviors of flexible cables at different deformation stages. By decomposing the complex global nonlinear problem into two relatively simple sub-problems, it significantly reduces the training difficulty and overfitting risk of a single neural network model. Compared to using a single model to forcibly fit the full range of data, this segmented processing approach not only improves the prediction accuracy of high-order nonlinear disturbances under the ultimate tensile state of the cable but also optimizes the allocation of computational resources, ensuring that the system achieves optimal dynamic response performance under various operating conditions.

[0074] Example 2:

[0075] This embodiment is applied to a high-end automated sewing production line. The template carrier needs to hold a heavy template containing multiple layers of leather and sponge composite material, executing complex trajectories at the sewing station, including sharp turns, small-radius arcs, and frequent starts and stops. Due to the weight and inertia of the workpiece, and the extremely high positional accuracy requirements of the sewing stitches, any slight vibration caused by the dragging of flexible cables or mechanical backlash can lead to uneven stitch spacing or even needle breakage. This embodiment focuses on demonstrating how the system specifically achieves abnormal working condition monitoring, refined prediction of hysteresis loops, and seamless multimodal switching.

[0076] As one embodiment of the present invention, refer to Figure 1 A schematic diagram of a vision-guided positioning control system for a rotary model moving machine, referring to... Figure 2 A control logic block diagram of a vision-guided rotary model positioning control system, referring to... Figure 3 Flowchart of the visually guided positioning control method.

[0077] During prolonged continuous operation, the flexible transmission components (including servo power cables, encoder signal lines, and high-pressure air pipes) connecting the joint drive unit and the end effector exhibit extremely complex nonlinear mechanical characteristics. In this embodiment, the resistance observation module no longer treats the cable as a single homogeneous body, but instead implements a strict physical partitioning strategy.

[0078] The system reads the absolute position feedback from the encoder in real time and calculates the unidirectional cumulative rotation angle. Laboratory tests show that the cable assembly of the device is in the "linear resistance zone" within a range of ±270 degrees, where its rebound torque is approximately proportional to the rotation angle, and its average stiffness coefficient is relatively small. However, when the rotation angle exceeds 270 degrees and enters the "nonlinear tension zone," the cable assembly exhibits exponentially increasing tensile resistance due to its tight twisting. When the conveyor rotates to 150 degrees, the resistance observation module identifies that it is currently in the linear zone, automatically labels the decoupled generalized disturbance torque as a first-type feature, and activates the first LSTM sub-model with fewer parameters and extremely fast response speed, focusing on handling viscous friction fluctuations caused by speed changes. When the conveyor performs a large-angle rotation reaching 320 degrees, the module immediately identifies that it has entered the nonlinear tension zone, the data stream is labeled as a second-type feature, and the system seamlessly switches to the pre-trained second LSTM sub-model with high-dimensional nonlinear fitting capabilities.

[0079] To prevent equipment damage caused by accidental cable entanglement or mechanical jamming, this embodiment deploys a millisecond-level abnormal interference monitoring unit. In a simulated production accident test, a rigid obstacle was deliberately placed on the rotating path of the conveyor. When the conveyor struck the obstacle at a speed of 90 degrees per second, the motor current surged instantaneously. The monitoring unit detected a sharp increase in the differential value (current change rate) of the quadrature-axis current within two consecutive control cycles (approximately 2 milliseconds), reaching an astonishing rate of 5 amperes per millisecond, which usually indicates that the motor is outputting huge torque; however, at the same time, the angular velocity fed back by the encoder did not increase accordingly, and its rate of change was instead negative (sharp deceleration).

[0080] This phenomenon of "torque surge followed by speed drop" constitutes a logical paradox at the physical level. The monitoring unit immediately determines that the system is in a "mechanical jam" state and generates an abnormal blocking flag. This flag directly triggers the highest priority interrupt of the fusion control module: within 1 millisecond, the system forcibly resets the LSTM feedforward weights to zero, cuts off the intelligent compensation loop that attempts to overcome resistance by increasing torque, and locks the final control command as "emergency stop brake". Thanks to this underlying physical logic protection, the motor current is cut off before reaching its peak, preventing the driver from overloading and burning out, and the robotic arm itself does not suffer structural deformation, verifying the "fuse-out" protection capability of this mechanism under extreme conditions.

[0081] To address the mechanical backlash issues caused by frequent reversals in precision sewing, the long short-term memory network in the error prediction module is given special "attention." When sewing a "W"-shaped trajectory, the joint motor needs to perform three consecutive forward and reverse switching within a very short time. At each reversal, the meshing surface of the gear set changes, and the direction of the elastic force of the cable also reverses, causing the generalized disturbance torque to cross zero.

[0082] In this embodiment, the input attention layer monitors the first-order difference of the torque sequence in real time. When a sign flip of the torque difference is detected (i.e., a zero-crossing), the attention mechanism automatically increases the feature weight of that time step from the average value of 0.2 to 0.95. This dynamic weighting operation essentially tells the neural network, "The data at this moment is crucial." Simulation and experimental comparisons show that after introducing this mechanism, the network's prediction delay for the 0.05 mm instantaneous jump caused by mechanical backlash is reduced from 15 milliseconds to less than 2 milliseconds. In terms of sewing results, the overlapping stitches or skewed stitches that were prone to occur at corners are completely eliminated, and the peak value of the trajectory tracking error is suppressed to below 0.04 mm.

[0083] To address the challenge of handing over control between high-speed dynamic tracking and low-speed static alignment, this embodiment employs a smooth fusion strategy based on speed ranges. The system presets a first speed threshold of 50 degrees per second and a second speed threshold of 2 degrees per second.

[0084] When the sewing machine moves at a high speed of 120 degrees per second between two sewing tracks, far exceeding the first threshold, the system calculates a feedforward weight of 1. At this point, control is entirely dominated by the LSTM prediction module, relying on model feedforward compensation to overcome cable resistance. The vision system runs only in the background and does not participate in the closed loop, avoiding the misleading effects of motion blur. As the sewing machine approaches the needle drop point and begins to decelerate, the speed drops to 20 degrees per second. The weight calculated by the S-curve function smoothly transitions to 0.6, and the control command is composed of 60% prediction and 40% visual feedback. Finally, when the speed drops to 1 degree per second for fine-tuning alignment, the weight decays to 0, and the system fully enters the visual closed-loop mode, using the sub-pixel accuracy of the high-definition camera to eliminate the final 0.01 mm static error. The torque output curve is continuous and smooth throughout the process, without any abrupt changes. The measured end jitter amplitude of the accelerometer is reduced by 92%, achieving a truly "seamless switching."

[0085] To complement the aforementioned control strategy, the visual feedback module implements strict exposure control. When the moving machine is in the high-speed rotation phase, the exposure control unit compresses the industrial camera's shutter speed from 8000 microseconds to 50 microseconds based on the real-time speed, and simultaneously increases the analog gain by 15 dB to compensate for the amount of light entering the camera. This operation ensures that images captured under high-speed motion have clear and sharp edges, without any ghosting.

[0086] Next, the image processing unit receives the 0.8 mm deviation due to inertial lag predicted by the LSTM and directly crops a region of interest (ROI) of only 5% of the full image area around the estimated coordinates. The algorithm extracts sub-pixel corner points only within this tiny region and maps the extraction results back to the robot's base coordinate system using a hand-eye matrix. The processing time of this pure image algorithm is compressed to less than 4 milliseconds. Combined with camera exposure and data transmission time, the total lag time of visual feedback is kept within a predictable range. This "prediction-guided vision" mechanism transforms visual feedback from a lagging observer into a real-time sensor capable of keeping pace with high-frequency control, providing a precise spatiotemporal reference for the final fusion control.

[0087] Through a series of innovative designs that delve into the physical essence and control logic, this invention successfully solves the precision control challenges in heavy-duty, flexible, and highly dynamic scenarios, providing a high-precision, high-safety, and highly adaptable universal solution for high-end automated sewing equipment.

[0088] 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 vision-guided positioning control system for a rotary model moving machine, characterized in that, include: Resistance observation module: acquires the quadrature-axis current fed back by the joint drive unit, as well as the joint angular velocity and angular acceleration fed back by the encoder; Based on the preset rigid body dynamics parameters of the robotic arm, the theoretical rigid body torque required for the joint to overcome rotational inertia and viscous friction is calculated, and the generalized disturbance torque is obtained by subtracting the theoretical rigid body torque from the electromagnetic torque converted from the quadrature axis current and decoupling. Error prediction module: The generalized disturbance torque and the current joint motion state sequence are used as joint features input to the long short-term memory network to learn the mechanical hysteresis loop characteristics of the generalized disturbance torque under different rotation angles, and output the end dynamic position compensation amount for future moments that cover the system transmission delay time. Fusion control module: acquires the real-time operating speed of the end effector, and calculates the feedforward weights based on the real-time operating speed using a smoothing weighting function; Using the feedforward weights, the end-effector dynamic position compensation and visual positioning coordinates are weighted and fused to generate the final position control command. The final generated position control command is equal to the product of the feedforward weights and the end-effector dynamic position compensation, plus the product of the complement of the feedforward weights and the corrected visual coordinates after delay compensation. The complement of the feedforward weights is one minus the feedforward weights, and the corrected visual coordinates are the coordinates output by the visual feedback module after delay correction.

2. The vision-guided positioning control system for a rotary model moving machine according to claim 1, characterized in that, The system also includes a flexible transmission component for connecting the joint drive unit and the end effector; the resistance observation module is configured to perform segmented processing steps: read the absolute position data of the encoder in real time and calculate the unidirectional cumulative rotation angle of the joint drive unit relative to the zero point; The unidirectional cumulative rotation angle is divided into a linear resistance zone and a nonlinear stretching zone. The linear resistance zone corresponds to the angle range of the flexible transmission component in a free bending state, and the nonlinear tension zone corresponds to the angle range of the flexible transmission component in a tensioned deformation state. When the unidirectional cumulative rotation angle is in the linear resistance zone, the generalized disturbance torque is marked as the first type of characteristic data. When the unidirectional cumulative rotation angle is in the nonlinear stretching region, the generalized perturbation torque is marked as the second type of feature data; the error prediction module activates the corresponding pre-trained long short-term memory network sub-model according to the input feature type.

3. The vision-guided positioning control system for a rotary model moving machine according to claim 1, characterized in that, Acquiring cross-axis current, joint angular velocity, and angular acceleration also includes a preprocessing step: the collected cross-axis current is subjected to a moving average filter, and the differential value of the filtered cross-axis current with respect to time is calculated to obtain the rate of change of current; at the same time, the rate of change of joint angular velocity is monitored. When the rate of change of current is greater than the preset impact gradient threshold, and the joint angular velocity is found to be unable to increase with the increase of current, the system is determined to be mechanically stuck and an abnormal blocking flag is generated. In response to the abnormal blocking flag, the fusion control module resets the feedforward weight to zero and locks the generated final position control command as the current position hold command.

4. The vision-guided positioning control system for a rotary model moving machine according to claim 1, characterized in that, The preset rigid body dynamic parameters of the robotic arm are acquired and stored through the parameter identification process: under the no-load condition where the joint drive unit is not connected to the flexible transmission component, the joint drive unit is controlled to perform multi-band sinusoidal scanning motion. The cross-axis current sequence, joint angular velocity sequence, and angular acceleration sequence during the motion process are collected synchronously. A dynamic regression equation with rotational inertia and viscous friction coefficient as undetermined coefficients is constructed. The collected sequence data is iteratively solved using the least squares method until the residuals converge, and the calibration values ​​of rotational inertia and viscous friction coefficient are obtained.

5. The vision-guided positioning control system for a rotary model moving machine according to claim 1, characterized in that, The long short-term memory network includes an input attention layer; calculates the first-order difference of the input generalized perturbation torque sequence and identifies the zero-crossing moment when the difference sign flips; and calculates the cross-correlation coefficient between the input generalized perturbation torque sequence and the current joint angular velocity sequence. Based on the zero-crossing time and cross-correlation coefficient, dynamic weights are assigned to the generalized disturbance torque characteristics of the current time step; When a zero-crossing moment is detected, a dynamic weight with a weight coefficient greater than a preset weight threshold is assigned.

6. The vision-guided positioning control system for a rotary model moving machine according to claim 1, characterized in that, The smooth weighting function is an S-shaped membership function based on the speed range. The calculation of the feedforward weight specifically includes: preset a first speed threshold and a second speed threshold, wherein the first speed threshold is defined as the lower limit of dynamic compensation effectiveness, the second speed threshold is defined as the upper limit of visual closure effectiveness, and the first speed threshold is greater than the second speed threshold; if the real-time running speed is greater than the first speed threshold, the calculated feedforward weight is one, and the final position control command is completely dominated by the end-effector dynamic position compensation amount; if the real-time running speed is less than the second speed threshold, the calculated feedforward weight is zero, and the final position control command is completely dominated by the visual positioning coordinates; if the real-time running speed is between the first speed threshold and the second speed threshold, the feedforward weight smoothly decays from one to zero as the speed decreases according to the S-shaped curve.

7. The vision-guided positioning control system for a rotary model moving machine according to claim 1, characterized in that, The visual positioning coordinates are generated by a visual feedback module, which includes an industrial camera, an exposure control unit, and an image processing unit mounted on the end effector. Generating visual positioning coordinates includes: The exposure control unit acquires the real-time operating speed of the end effector; according to the preset photosensitivity curve, when the real-time operating speed exceeds the preset motion blur threshold, the shutter time of the industrial camera is shortened in an inverse relationship, and the analog gain is simultaneously nonlinearly increased to compensate for the image brightness, and the original image frame is acquired. The image processing unit receives the end-effector dynamic position compensation amount output by the error prediction module, superimposes it onto the current theoretical joint position fed back by the encoder, and calculates the estimated projection coordinates of the feature points; using the estimated projection coordinates as anchor points, it crops out a region of interest smaller than the field of view of the original image frame, and the region of interest covers the estimated mechanical hysteresis drift range. Within the region of interest, a subpixel edge extraction algorithm is used to identify template feature points, and the subpixel-level coordinates of the template feature points in the image coordinate system are calculated. The pre-calibrated camera intrinsic parameter matrix and hand-eye calibration extrinsic parameter matrix are called to map and convert the subpixel-level coordinates into three-dimensional spatial coordinates in the robot base coordinate system. The distortion correction is performed on the converted three-dimensional spatial coordinates, and the final visual positioning coordinates are output to the fusion control module.

Citation Information

Patent Citations

  • Composite anti-interference control method and system for spindle motion system of high-speed pattern sewing machine

    CN113890437A

  • Charging pile cable plugging system based on machine vision

    CN120792570A