Share this

How can a stepper motor directly control a PLC? What are the methods?

2026-04-06 03:14:29 · · #1

A stepper system consists of a stepper driver and a stepper motor. The stepper motor is driven by the stepper driver, which acts as a power supply. It is controlled by external pulse signals and direction signals (in this example, pulses output by a Siemens PLC), which in turn control the rotation angle and speed of the stepper motor.

Stepper driver + stepper motor + Siemens PLC (CPU 222 CN)

Related definitions

1. Driver: The medium used by PLC to control stepper motors. It is responsible for amplifying the pulse signals given by PLC and sending them to the stepper motor so that the motor runs according to the parameters given by PLC and driver.

Control process

2. Step angle: The angle by which the stepper motor rotates with each pulse. The most common step angle is 1.8°, and this usually cannot be changed.

Example: Without microstepping set, how many pulses does the PLC need to send to control a stepper motor with a step angle of 1.8° to rotate one revolution (360°)?

A: 360°/X = 1.8°/1, so X = 200 pulses.

3. Microstepping: In practical applications, it has been found that a large step angle results in a large rotation angle with each turn, which can cause vibration and increase control error. Therefore, microstepping was introduced. This means that the step angle is divided into smaller increments using the DIP switches on the driver, resulting in smoother motor rotation.

Example: If the step angle is 1.8° and the microstepping is set to 10 microsteps, then for every pulse sent by the PLC, the motor only rotates 0.18°. How many pulses does the PLC need to send to complete one full rotation (360°) of the stepper motor?

A: 360°/X = 0.18°/1, so X = 2000 pulses.

Summary: The larger the step angle, the fewer the number of pulses; the smaller the step angle, the more pulses.

Introduction to Stepper System Hardware (Taking ProFit Stepper Motor as an Example)

1. Stepper driver

Pfide Drive Instructions

There are generally two types of direction control for stepper motors:

A) Pulse + Direction: When a pulse is generated by PUL, the motor will rotate, and the direction is determined by DIR.

B) Forward pulse + reverse pulse: When a pulse is generated by PUL, the rotation is forward; when a pulse is generated by DIR, the rotation is reverse. However, PUL and DIR cannot generate pulses simultaneously.

2. Stepper motor

When the A and B phase windings are swapped, the motor can be reversed.

In automated production lines for modular machine tools, three types of slides are generally set up according to different machining accuracy requirements: (1) hydraulic slides, used in roughing operations with large cutting volume and low machining accuracy requirements; (2) mechanical slides, used in semi-finishing operations with medium cutting volume and certain machining accuracy requirements; and (3) CNC slides, used in finishing operations with small cutting volume and high machining accuracy requirements. Programmable logic controllers (PLCs) are widely used in industrial automatic control due to their advantages such as strong versatility, high reliability, simple instruction system, easy programming and learning, easy mastery, small size, less maintenance work, and convenient on-site interface installation. In particular, they have shown excellent performance in the control of automated production lines for modular machine tools and the S, T, M function control of CNC machine tools. The open-loop servo mechanism of stepper motor controlled by PLC is applied to the control of CNC slides on automated production lines for modular machine tools, which can eliminate the CNC system of this unit and reduce the cost of the control system of this unit by 70-90%, or even only occupy 3-5 I/O interfaces and <1KB of memory of the PLC control unit of the automatic line. In particular, it can significantly reduce the cost of control systems in large automated production lines.

2. PLC-controlled CNC slide structure

In general, the CNC slides in automated production lines of combination machine tools adopt open-loop servo mechanisms driven by stepper motors. CNC slides controlled by PLCs consist of a programmable controller, a loop pulse distributor, a stepper motor driver, a stepper motor, and a servo transmission mechanism, as shown in Figure 1.

Gears Z1 and Z2 in the servo transmission mechanism should be designed with backlash elimination measures to avoid creating a reverse dead zone or reducing machining accuracy; while the choice of ball screw pair should be determined based on the machining accuracy requirements of the unit. Using ball screw pairs offers advantages such as high transmission efficiency, good system rigidity, high transmission accuracy, and long service life, but it is more expensive and lacks self-locking capability.

3. PLC Control Method for CNC Slide Tables

There are three main control factors for CNC slide tables:

3.1 Travel Control

The stroke control of conventional hydraulic and mechanical slides is achieved using position or pressure sensors (limit switches/dead stops); while the stroke of CNC slides is achieved through digital control. From the structure of a CNC slide, we know that the slide's stroke is proportional to the total rotation angle of the stepper motor; therefore, controlling only the total rotation angle of the stepper motor is sufficient. From the working principle and characteristics of stepper motors, we know that the total rotation angle of the stepper motor is proportional to the number of input control pulses; therefore, the number of pulses output by the PLC can be determined based on the displacement of the servo mechanism.

n = DL/d (1)

In the formula, DL represents the displacement of the servo mechanism (mm), and d represents the pulse equivalent of the servo mechanism (mm/pulse).

3.2 Feed rate control

The feed speed of the servo mechanism depends on the speed of the stepper motor, which in turn depends on the input pulse frequency. Therefore, the pulse frequency output by the PLC can be determined based on the required feed speed for the process.

f = Vf/60d (Hz) (2)

In the formula, Vf represents the feed speed of the servo mechanism (mm/min).

3.3 Feed Direction Control

Feed direction control is the same as stepper motor rotation control. The direction of rotation of a stepper motor can be changed by altering the energizing sequence of its windings; for example, a three-phase stepper motor rotates forward when energized in the sequence A-AB-B-BC-C-CA-A…; and it rotates in reverse when energized in the sequence A-AC-C-CB-B-BA-A… Therefore, this can be achieved by changing the output sequence of the hardware ring distributor using the direction control signal output from the PLC, or by programming to change the order of the output pulses to alter the energizing sequence of the stepper motor windings.

4. PLC Software Control Logic

As can be seen from the PLC control method of the slide table, the total number of input pulses and the pulse frequency of the stepper motor should be controlled accordingly. Therefore, a pulse signal generator with controllable total number of pulses and pulse frequency is set in the control software; for controllable control pulses with lower frequency, a timer in the PLC can be used, as shown in Figure 2. The pulse frequency can be controlled by the timing constant of the timer, and the total number of pulses can be controlled by setting a pulse counter C10. When the number of pulses reaches the set value, the counter C10 activates and cuts off the pulse generator circuit, stopping its operation. When there is no pulse input, the stepper motor of the servo mechanism stops running, and the servo actuator is positioned. When the displacement speed requirement of the servo actuator is high, a high-speed pulse generator in the PLC can be used. Different PLCs can provide high-speed pulse frequencies of 4000~6000Hz. For general servo mechanisms on automatic lines, the speed requirement can be fully met.

Read next

CATDOLL 108CM Dodo – Natural Tone

Height: 108cm Weight: 14.5kg Shoulder Width: 26cm Bust/Waist/Hip: 51/47/59cm Oral Depth: 3-5cm Vaginal Depth: 3-13cm An...

Articles 2026-02-22
CATDOLL 133CM Kiki Shota Doll

CATDOLL 133CM Kiki Shota Doll

Articles
2026-02-22
CATDOLL Jo Hard Silicone Head

CATDOLL Jo Hard Silicone Head

Articles
2026-02-22
CATDOLL 139CM Tami Silicone Doll

CATDOLL 139CM Tami Silicone Doll

Articles
2026-02-22