PLC Control Method of Stepper Motor
1. Introduction
With the development of microelectronics and computer technology, programmable controllers have made rapid progress. Their functions have far exceeded the scope of logic control and sequential control. They can be effectively combined with computers to perform analog control and have remote communication functions. Some people call it one of the three pillars of modern industrial control (i.e. PLC, robot, CAD/CAM). At present, programmable controllers (PLC) have been widely used in metallurgy, mining, machinery, light industry and other fields, providing a powerful tool for industrial automation.
2. Basic structure of PLC
PLC adopts a typical computer structure, mainly including CPU, RAM, ROM and input/output interface circuits. If PLC is regarded as a system, the system consists of input variables-PLC-output variables. Various external switch signals, analog signals, and sensor detection signals are all used as PLC input variables. They are input into the internal registers through the external terminals of PLC, and sent to the output terminals after the internal logic operation or other various operations and processing of PLC. They are the output variables of PLC, and these output variables are used to control various peripheral devices.
III. Control Method and Research
1. Introduction to the Special Functions of FP1
(1) Pulse Output
FP1's output terminal Y7 can output pulses. The pulse frequency can be adjusted through software programming. Its output frequency range is 360Hz~5kHz.
(2) High-speed Counter (HSC)
FP1 has a high-speed counter inside, which can input two pulses at the same time. The maximum counting frequency is 10kHz and the counting range is -8388608~+8388607.
(3) Input Delay Filter
FP1's input terminal uses input delay filtering to prevent the unreliability caused by mechanical jitter of the switch. Its delay time can be adjusted as needed. The adjustment range is 1ms~128ms.
(4) Interrupt Function
FP1 has two types of interrupts, one is external hard interrupt and the other is internal timing interrupt.
2. Speed Control of Stepper Motor
FP1 has an SPD0 instruction. This instruction can realize speed and position control in conjunction with the pulse output function of HSC and Y7. The speed control ladder diagram is shown in Figure 1, the control mode parameters are shown in Figure 2, and the pulse output frequency setting curve is shown in Figure 3.
3. Control the program operation of the system
Figure 4 is the principle wiring diagram of the control system. In Figure 4, the pulse output by Y7 is used as the clock pulse of the stepper motor, and the pulse is generated by the driver to control the operation of the stepper motor. At the same time, Y7 is connected to the input contact X0 of the PLC, and is sent to the HSC inside the PLC through X0. The HSC counts the number of pulses of Y7, and when it reaches the predetermined value, an interrupt occurs, so that the pulse frequency of Y7 is switched to the next parameter, thereby achieving more accurate position control. The ladder diagram for realizing this control is shown in Figure 5.
The operating program of the control system: The first sentence is to clear DT9044 and DT9045, that is, to prepare for HSC counting; the second to fifth sentences are to establish a parameter table, and the parameters are stored in the data register area with DT20 as the first address; the last sentence is to start the SPD0 instruction. When this sentence is executed, the set parameters are taken out from DT20 and the corresponding control requirements are completed.
From the first sentence, it can be seen that the first parameter is K0, which is the characteristic value of the PULSE mode, thereby specifying the output mode. The second parameter is K70, corresponding to a pulse frequency of 500Hz, so Y7 sends a pulse with a frequency of 500Hz. The third parameter is K1000, that is, after sending 1000 pulses at this frequency, it switches to the next frequency. The next frequency, that is, the last parameter, is K0, so when this step is executed, the pulse stops, so the motor stops. Therefore, when this program is run, the stepper motor can drive the control object at the specified speed and the predetermined number of revolutions, so that it stops automatically after reaching the predetermined position.
The programmable controller can easily realize the control of motor speed and position, conveniently and reliably operate various stepper motors, and complete various complex tasks. It represents the advanced industrial automation revolution and accelerates the realization of mechatronics.
Previous article:What is ECD
Next article:Frequency Converter Principle
Recommended ReadingLatest update time:2024-11-17 03:03
- Popular Resources
- Popular amplifiers
- High signal-to-noise ratio MEMS microphone drives artificial intelligence interaction
- Advantages of using a differential-to-single-ended RF amplifier in a transmit signal chain design
- ON Semiconductor CEO Appears at Munich Electronica Show and Launches Treo Platform
- ON Semiconductor Launches Industry-Leading Analog and Mixed-Signal Platform
- Analog Devices ADAQ7767-1 μModule DAQ Solution for Rapid Development of Precision Data Acquisition Systems Now Available at Mouser
- Domestic high-precision, high-speed ADC chips are on the rise
- Microcontrollers that combine Hi-Fi, intelligence and USB multi-channel features – ushering in a new era of digital audio
- Using capacitive PGA, Naxin Micro launches high-precision multi-channel 24/16-bit Δ-Σ ADC
- Fully Differential Amplifier Provides High Voltage, Low Noise Signals for Precision Data Acquisition Signal Chain
- Innolux's intelligent steer-by-wire solution makes cars smarter and safer
- 8051 MCU - Parity Check
- How to efficiently balance the sensitivity of tactile sensing interfaces
- What should I do if the servo motor shakes? What causes the servo motor to shake quickly?
- 【Brushless Motor】Analysis of three-phase BLDC motor and sharing of two popular development boards
- Midea Industrial Technology's subsidiaries Clou Electronics and Hekang New Energy jointly appeared at the Munich Battery Energy Storage Exhibition and Solar Energy Exhibition
- Guoxin Sichen | Application of ferroelectric memory PB85RS2MC in power battery management, with a capacity of 2M
- Analysis of common faults of frequency converter
- In a head-on competition with Qualcomm, what kind of cockpit products has Intel come up with?
- Dalian Rongke's all-vanadium liquid flow battery energy storage equipment industrialization project has entered the sprint stage before production
- Allegro MicroSystems Introduces Advanced Magnetic and Inductive Position Sensing Solutions at Electronica 2024
- Car key in the left hand, liveness detection radar in the right hand, UWB is imperative for cars!
- After a decade of rapid development, domestic CIS has entered the market
- Aegis Dagger Battery + Thor EM-i Super Hybrid, Geely New Energy has thrown out two "king bombs"
- A brief discussion on functional safety - fault, error, and failure
- In the smart car 2.0 cycle, these core industry chains are facing major opportunities!
- Rambus Launches Industry's First HBM 4 Controller IP: What Are the Technical Details Behind It?
- The United States and Japan are developing new batteries. CATL faces challenges? How should China's new energy battery industry respond?
- Murata launches high-precision 6-axis inertial sensor for automobiles
- Ford patents pre-charge alarm to help save costs and respond to emergencies
- Today's Live Broadcast | Cytech: Hidden Costs of Isolation System Design
- Vehicle GPS Antenna Installation Location
- MSP430F5529 generates PWM waves with CCS
- FPGA Multiplier
- Quartus2 simulation can not produce waveform
- After the microcontroller is connected to the computer via a USB cable, the problem of "unrecognized USB device" appears
- 2. GD32L233C-START environment construction
- Commonly used algorithms for drones - Kalman filter (Part 2)
- STEVAL-IDB007V1_by cruefox
- AI automatically generates Spring Festival couplets to warm up for FZ5