Crane Anti-Sway Control: Input Shaping, Fuzzy PID & LSTM

An overhead crane anti-sway control system is an intelligent control solution that uses control algorithms to suppress load swing during operation. The main technical approaches include open-loop input shaping, closed-loop fuzzy PID adaptive control, and LSTM-based predictive feedforward control. Input shaping can reduce residual sway by more than 90%, closed-loop fuzzy PID keeps steady-state sway within ±5 mm, and LSTM predictive control enables fully automatic anti-sway on complex trajectories. These three approaches are arranged by control accuracy and cost gradient to suit different operating condition requirements.


Overhead crane intelligent anti-sway control system principle: input shaping and fuzzy PID control block diagram

Comparing Three Anti-Sway Control Approaches for Overhead Cranes

technical approach Control Mode SensorRequirement residual sway Cost Commissioning Complexity Application Scenarios
input shaping(ZV/UM-ZV) Open-Loop Feedforward NoneSensor ≤50mm Low(Software Implementation) Low General-Purposeoverhead craneVariable Frequency Drive (VFD)Retrofit
fuzzy PIDAdaptive Closed-Loop Feedback Encoder+IMU ≤10mm Medium Medium PrecisionHoisting/Automation
LSTM+MPCPredictive Feedforward+Feedback Encoder+IMU+Camera ≤5mm High High Fully automaticunmanned overhead crane

For existing overhead cranes with VFDs, we recommend starting with input shaping—a zero-hardware-investment approach—before upgrading to closed-loop solutions as accuracy requirements grow. The crane's digital remote monitoring system (see intelligent upgrade solutions) can simultaneously collect sway data for model training. For newly built automated overhead cranes, deploying an LSTM+MPC solution directly is recommended for optimal anti-sway performance.


Input Shaping Parameter Design for Anti-Sway Control

The core of input shaping is designing a pulse sequence that drives residual vibration in the system output to zero. For an overhead crane's lifting spreader sway system, the natural frequency is ωn=(g/L)^0.5, where L is the wire rope length in meters. The ZV (Zero Vibration) shaper consists of two pulses with amplitudes A1=1/(1+K) and A2=K/(1+K), and a time delay of ΔT=π/ωd. Taking L=8m as an example: ωn=√(9.8/8)≈1.1rad/s, damping ratio ζ≈0.005–0.01, K=e^(−ζπ/√(1−ζ²))≈0.984, yielding A₁≈0.504, A₂≈0.496, and ΔT≈2.86s. After shaping, the sway angle at trolley travel completion is <0.5°, compared to 8–15° without shaping—a reduction of over 90%.

Real-world applications face disturbances such as real-time changes in wire rope length and load weight. The EI (Extra-Insensitive) shaper adds a third pulse to expand frequency-offset tolerance from ±5% (ZV) to ±20%, making it suitable for general-purpose cranes with frequent rope-length variations. The UM-ZV (Unity Magnitude ZV) shaper normalizes all pulse amplitudes to ±1, preventing motor overload and making it ideal for retrofitting older cranes with VFDs. The calculation parameters for all three shapers are summarized in the table below.

wire rope length(m) natural frequency(rad/s) ZVShaping Delay(s) ZVShaping Residualsway angle(°) EIShaping Residualsway angle(°) UM-ZVShaping Residualsway angle(°)
4 1.57 2.00 <0.5 <1.0 <0.3
6 1.28 2.46 <0.5 <1.0 <0.3
8 1.11 2.86 <0.5 <1.0 <0.3
10 0.99 3.17 <0.5 <1.0 <0.3
12 0.90 3.47 <0.5 <1.0 <0.3

Fuzzy PID Adaptive Control: Engineering Implementation

The fuzzy PID controller takes the lifting spreader sway angle θ and angular velocity θ’ as inputs, using a fuzzy rule base to tune the Kp, Ki, and Kd parameters online. The fuzzy universe is set to θ∈[-15°,15°] and θ’∈[-30°/s,30°/s], with narrow triangular membership functions near zero for high sensitivity and wide trapezoidal functions away from zero for broad coverage. The rule base contains 7×7=49 rules; a typical rule: when θ is large and θ’ is large (overswing), Kp is set high (for rapid return) and Kd is set to medium (to avoid overshoot). The defuzzified PID outputs (center-of-gravity method) are superimposed on the speed loop reference.

When deployed alongside the crane's AI vision inspection system (see AI Vision Inspection Technical Solution), the vision system provides redundant hook sway angle measurement. When the deviation between the vision-based angle and the encoder-derived sway angle exceeds 2°, an automatic sensor calibration is triggered. Field test data from the closed-loop anti-sway system on a 32t overhead crane: residual sway of ±4mm when unloaded and ±8mm at full load (32t), with sway angle convergence time ≤3s — meeting the ±10mm positioning accuracy required for precision hoisting operations.

LSTM Predictive Control for Crane Anti-Sway

The LSTM-MPC approach adds a feedforward prediction layer on top of the fuzzy PID baseline: an edge inference node runs the LSTM model, taking the past 32 time steps (100ms each) of sway angle and speed command sequences as input, and outputs sway angle predictions for the next 10 steps (1s). The MPC controller uses these LSTM predictions as a reference, rolling optimization of the speed command to minimize future sway. This approach relies on GPU edge inference — a Jetson Orin NX achieves single-step prediction in under 2ms, meeting real-time requirements. In fully automatic unmanned overhead crane operations (integrated with the AI unmanned crane dispatching system), the LSTM-MPC solution delivers lifting spreader positioning accuracy of ±3mm.


Kelude Anti-Sway System: Solution Advantages

Kelude offers a three-tier anti-sway solution: input shaping (standard, included free with any VFD retrofit), fuzzy PID (optional, adds IMU + encoder, compatible with Siemens/Schneider/ABB drives), and LSTM-based fully automatic anti-sway (full-stack deployment, including AI training platform). All options support OEE data upload and remote commissioning. Kelude provides a free on-site assessment and sway angle measurement report for crane anti-sway retrofit projects.

FAQ

Q: What are the key differences between input shaping and LSTM predictive control for crane anti-sway?

A: Input shaping is an open-loop control method — simple, reliable, and computationally light, well-suited for fixed rope length scenarios, reducing sway by 80%–90%. LSTM predictive control learns the system dynamics from historical data, offering better adaptability under varying rope lengths and load conditions, further reducing residual sway.

Q: How does fuzzy PID contribute to anti-sway performance?

A: Fuzzy PID adjusts PID parameters in real time based on the load sway angle, offering better adaptability than conventional fixed-parameter PID. The sway angle and sway angular velocity serve as fuzzy inference inputs, and the outputs are PD parameter corrections. It works best when combined with speed feedforward in crane anti-sway applications.

Q: What anti-sway solutions does Kelude offer?

A: Kelude provides three tiers of anti-sway solutions — input shaping, fuzzy PID, and LSTM — flexibly configurable based on accuracy requirements and budget. All options support integration with existing PLC systems and are suitable for both new installations and retrofit projects.


Overhead Crane Anti-Sway Control: Input Shaping, Fuzzy PID, and LSTM Prediction in Practice

Anti-sway control is one of the core technologies that sets intelligent overhead cranes apart from conventional lifting equipment. It directly addresses a persistent challenge in crane operation: load oscillation. When a trolley moves or stops, the suspended load naturally swings, which slows down cycle times, increases operator fatigue, and creates safety risks in crowded workshops. This article breaks down three proven technical approaches for suppressing load sway—input shaping, fuzzy PID adaptive control, and LSTM-based swing prediction—and explains how they work together in a real engineering environment.

Why Load Sway Control Matters in Overhead Crane Operation

Load sway is not just an inconvenience; it is a measurable drag on productivity. Every time the operator has to wait for the load to settle before lowering it, valuable seconds are lost. In high-throughput facilities, these seconds add up to significant downtime across a shift. More importantly, uncontrolled sway increases the risk of collisions with nearby equipment, structures, or personnel. The consequences range from damaged goods to serious workplace injuries.

Traditional mechanical anti-sway devices—such as guide rollers or tensioned ropes—offer limited relief. They add weight, require regular maintenance, and still leave residual oscillation. Electronic anti-sway systems, by contrast, actively control the crane's motion to cancel out swing before it grows. This shift from passive damping to active control is what enables modern cranes to move faster and stop more precisely without compromising safety.

Input Shaping: Open-Loop Control for Swing Suppression

Input shaping is a feedforward technique that modifies the acceleration commands sent to the crane drive before they reach the motor. Instead of commanding a sudden start or stop, the controller breaks the motion into a series of smaller, precisely timed steps. The resulting velocity profile is designed so that the swing induced by one step is cancelled out by the swing induced by the next.

The key to effective input shaping lies in the design of the shaper parameters. For a crane with a known hoist rope length, the natural frequency of the pendulum can be calculated. The shaper then uses this frequency to determine the timing and amplitude of each step. A well-tuned shaper can reduce residual sway by 90% or more without requiring any feedback sensors. This makes it an attractive option for retrofitting existing cranes where adding sensors is impractical.

However, input shaping has its limitations. It assumes a constant rope length and a linear system, which is rarely the case in real-world operation. If the hoist is moving up or down while the trolley is traversing, the pendulum frequency changes, and the shaper's performance degrades. This is where closed-loop control methods come into play.

Fuzzy PID Control: Adaptive Closed-Loop Sway Damping

Fuzzy PID control extends the classic PID algorithm by adding a rule-based logic layer that adjusts the controller gains in real time. Standard PID controllers work well when the system parameters are fixed, but a crane's dynamics change constantly with load weight, rope length, and trolley speed. A fixed-gain PID tuned for one condition may oscillate or respond sluggishly under another.

The fuzzy logic component continuously monitors the sway angle and its rate of change, then adjusts the proportional, integral, and derivative gains to suit the current operating state. For example, when the sway angle is large and growing, the controller increases the derivative gain to apply stronger damping. When the load is nearly settled, it reduces the gains to avoid introducing new oscillations.

In practice, fuzzy PID control is implemented with a sway sensor—typically an encoder on the hoist drum or an inertial measurement unit (IMU) mounted near the load. The sensor feeds real-time sway data to the controller, which calculates corrective trolley movements. This closed-loop approach handles varying rope lengths and external disturbances far better than open-loop input shaping alone.

LSTM Swing Prediction: Anticipating Motion Before It Happens

Long Short-Term Memory (LSTM) networks bring a predictive dimension to anti-sway control. Rather than reacting to sway as it occurs, an LSTM model learns the crane's swing patterns from historical operating data and predicts the next few seconds of motion. This foresight allows the controller to begin corrective action earlier, reducing the magnitude of sway before it fully develops.

Training an LSTM model requires collecting data from the crane's sensors over a range of operating conditions—different load weights, rope lengths, and motion profiles. The model learns the relationship between the crane's command inputs and the resulting sway response. Once trained, it can run in real time on the crane's PLC or a dedicated edge computer, generating predictions that feed into the control loop alongside the fuzzy PID logic.

The combination of LSTM prediction and fuzzy PID control is particularly effective for complex maneuvers, such as simultaneous trolley and hoist motion, where the system dynamics are too nonlinear for traditional model-based control. The LSTM handles the nonlinearity by learning it from data, while the fuzzy PID provides robust feedback correction when the prediction drifts.

Sensor Configuration and System Architecture for Anti-Sway Control

A practical anti-sway system requires careful sensor selection and integration. The most common configuration uses a combination of:

  • Hoist drum encoder — measures rope payout to calculate pendulum length
  • Trolley position encoder — tracks trolley location along the bridge
  • Sway angle sensor — typically an IMU or laser-based system mounted near the load beam

These sensors feed into a central controller that runs the input shaping, fuzzy PID, and LSTM algorithms. The controller outputs velocity commands to the variable frequency drives (VFDs) that power the trolley and bridge motors. Communication between the sensors, controller, and drives typically uses a fieldbus protocol such as PROFINET or EtherCAT, ensuring low-latency data exchange.

For retrofit installations, the sensor suite can be simplified. A single IMU mounted on the hoist block, combined with the existing drum encoder, provides sufficient data for fuzzy PID control. Input shaping can be added purely in software, requiring no additional hardware. This modular approach allows facilities to scale their anti-sway capability based on budget and operational needs.

Field Tuning and Commissioning of Anti-Sway Systems

Getting an anti-sway system to perform well in the field requires systematic tuning. The process typically follows these steps:

  1. Baseline measurement — operate the crane without anti-sway active and record the natural sway frequency and damping ratio for various rope lengths.
  2. Input shaper calibration — set the shaper parameters based on the measured frequencies, then verify sway reduction with a test move.
  3. Fuzzy PID gain adjustment — start with conservative gains and gradually increase them while monitoring sway angle and motor current. The goal is fast settling without overshoot or motor strain.
  4. LSTM model validation — if using a predictive model, compare its predictions against actual sway data and retrain if the error exceeds acceptable limits.
  5. End-to-end test — run a full duty cycle with load pickup, traverse, and lowering to confirm that residual sway stays within the ±5 mm target.

During commissioning, it is important to involve the crane operators. Their feedback on feel and responsiveness is valuable for fine-tuning the system. A system that performs well in theory but feels unnatural to operate will not be accepted on the shop floor.

Comparing Electronic and Mechanical Anti-Sway Approaches

Mechanical anti-sway systems rely on physical devices to constrain load movement. Common examples include telescopic guide arms, tensioned wire ropes, and damping rollers mounted on the load beam. These systems are robust and require no electronics, but they add significant weight to the hoist, reduce the effective lifting height, and cannot adapt to changing load conditions.

Electronic anti-sway systems, by contrast, use the crane's own motion to cancel swing. They add no weight to the load path, do not reduce lifting height, and can adapt in real time to changing rope lengths and load masses. The trade-off is complexity: sensors, controllers, and software all need to be maintained and calibrated. However, the performance gains—faster cycle times, lower operator fatigue, and improved safety—typically justify the added complexity in demanding applications.

Many modern cranes combine both approaches. A lightweight mechanical damper can handle low-frequency sway, while the electronic system manages higher-frequency oscillations and provides fine positioning. This hybrid strategy offers the best of both worlds, though it requires careful engineering to avoid interference between the two systems.

Key Takeaways for Implementing Anti-Sway Control

Implementing an effective anti-sway system on an overhead crane involves several interconnected decisions. The choice between open-loop input shaping, closed-loop fuzzy PID, and predictive LSTM control depends on the application's requirements for accuracy, speed, and cost. Input shaping offers a low-cost entry point with significant sway reduction, while fuzzy PID adds robustness for varying operating conditions. LSTM prediction provides the highest level of performance for complex, nonlinear maneuvers but requires data collection and model training.

For most industrial applications, a combination of input shaping and fuzzy PID control delivers the best balance of performance and practicality. Adding LSTM prediction is worthwhile when the crane operates in highly variable conditions or when positioning accuracy is critical, such as in automated warehouses or precision assembly lines.

Regardless of the chosen approach, proper sensor installation and systematic field tuning are essential to achieving the ±5 mm residual sway target. With the right engineering, an anti-sway system can transform a standard overhead crane into a precise, high-speed material handling tool that operators trust and rely on.

Related News

contact

contact us

phone:
+86 13903802779

mail:3915269@qq.com

Working hours: Monday to Friday

Wechat
Wechat
SHARE
TOP