PLC Anti-interference Parameter Settings for Carton Forming Machines Operating in Factory Strong Electromagnetic Environments
The Ghost in the Machine at the Steel Mill Annex
A packaging operation co-located in a building adjacent to a steel rolling mill in Tangshan called us with a problem that defied logic. Their Zray ZX-650 carton former would randomly stop mid-cycle without an alarm, then restart normally 30 seconds later. The HMI showed no faults. The PLC error log was empty. The problem happened exclusively between 2 PM and 4 PM, and never on Sundays.
It took three site visits to correlate the pattern: the adjacent rolling mill ran its 6,000 kW induction furnace for a heat treatment batch every weekday afternoon. When the furnace fired, the electromagnetic field induced millivolt-level noise on the carton former’s unshielded sensor cables. The noise spikes were just above the PLC’s digital input threshold voltage, causing phantom “emergency stop” signals that lasted less than one scan cycle — too brief to log, but long enough to halt execution.
This is a textbook case of electromagnetic interference in an industrial PLC system, and it’s far more common than most factory engineers realize. Any carton forming machine operating within 50 meters of large motors, induction heaters, welding equipment, or even poorly-filtered variable frequency drives is subject to EMI. The carton former’s own servo drives are often the worst offenders.

Hardware-Level Mitigations That Must Come First
Before touching a single PLC parameter, address the physical layer. No software filter can compensate for a fundamentally bad installation.
Cable segregation is non-negotiable. Sensor signal cables (24V DC, 4-20 mA, encoder feedback) must run in a separate cable tray from power cables (380V AC motor feeds, VFD output cables, heater circuits). Minimum separation: 300 mm for parallel runs under 5 meters, 500 mm for longer parallel runs. Where cables must cross, they should cross at 90 degrees. At the Tangshan plant, we found the carton counter’s encoder cable zip-tied to the vacuum pump’s power cable for a 4-meter run. Separating them eliminated about 70% of the noise problem immediately.
Shield grounding at one end only. Shielded sensor cables should have the shield drain wire connected to the control cabinet’s ground bus at the PLC end, and left floating at the sensor end. Grounding both ends creates ground loops — a difference in earth potential between two points in the factory drives current through the shield, which inductively couples noise into the signal conductors. A common mistake: electricians who “helpfully” ground both ends “for better protection.”
Ferrite cores on VFD output cables. The variable frequency drive cables running from VFD to servo motor are broadband RF transmitters. Clamp-on ferrite cores (TDK ZCAT series or equivalent, impedance >100 ohms at 10-100 MHz) placed within 150 mm of the VFD output terminals reduce conducted emissions by 10-15 dB, which is often the difference between marginal and stable operation.
The Five PLC Parameters That Filter Out What Hardware Can’t
Once the physical layer is clean, the PLC’s input filtering and program structure provide the second line of defense.
Input filter time constant: Most PLC digital input modules have a configurable hardware filter, typically 0.5 ms to 20 ms. The default on many systems is 1 ms, which is too fast for a noisy factory environment. Set all digital inputs to 5 ms minimum, and 10 ms for safety-critical inputs like emergency stop circuits. A 10 ms filter rejects noise pulses shorter than 10 ms — which covers essentially all EMI-induced transients — while adding negligible response delay for a machine cycling at 1-2 Hz.
Hysteresis on analog inputs: Analog sensors (pressure transducers, temperature probes, vacuum sensors) should have software hysteresis applied in the PLC program. A typical implementation: the PLC only registers a change when the analog value moves by more than 0.5% of full scale and holds for at least three consecutive scan cycles. Without hysteresis, a 4-20 mA loop picking up 50 Hz noise can cause the PLC to see rapid fluctuations that trigger nuisance alarms.
Debounce logic for physical pushbuttons: EMI can be picked up on the long cable runs to operator panel pushbuttons. Implement a software debounce that requires a button state to be stable for 50 ms before the PLC acts on it. This is standard practice in automotive PLC programming but surprisingly absent from many packaging machine programs.
Watchdog timer with automatic retry: Configure the PLC’s task watchdog to be slightly longer than the worst-case scan time — typically 1.5× the maximum observed scan time over a 24-hour period. When the watchdog triggers, the program should attempt one automatic restart before latching a fault. This prevents a single noise-induced watchdog timeout from stopping a production line that requires manual intervention to restart.
Shielded communication protocols: If the PLC communicates with remote I/O, HMIs, or upstream/downstream equipment over RS-485 or Ethernet, ensure the physical layer is properly terminated. RS-485 networks must have 120-ohm termination resistors at both ends of the bus and fail-safe bias resistors. Ethernet networks in factory environments should use shielded Cat6 cable with metal RJ45 connectors bonded to the cabinet ground.
The Sunday Test
The simplest diagnostic for EMI problems: run the machine on a Sunday when nearby heavy equipment is idle and compare the PLC’s diagnostic buffer — unsolicited state changes, communication retries, analog value jitter — with a weekday log. If Sunday is quiet and Tuesday is noisy, EMI is your problem, not the PLC program.
Want To Know More About Our Upgraded Machines?
Send your carton specifications and output demand, our engineer will provide free technical scheme & quotation
Subscribe To Get Latest News & Technical Guides
Leave your business email to receive free industry articles and new product updates