DC motor measurement and control system based on single chip PID algorithm


With the rapid development of electronic technology, DC motor measurement and control has gradually changed from analog to digital. The DC motor measurement and control system realized by the hardware circuit has complicated circuit, difficult adjustment and low reliability, and lacks control flexibility. In industrial control, PID regulators controlled by the ratio of deviation P, integral I and differential D are now widely used. Prior to the use of small microcomputers in the production process, pneumatic, hydraulic and electric PID regulators used in continuous process systems were almost monopolized. It can be proved by the optimal control theory that it can adapt to the control requirements of many industrial objects. The development of single-chip microcomputer control technology, especially the use of software PID algorithm controller, has replaced many of the original hardware PID regulators, and has been widely used in industrial control systems and embedded systems. The DC motor measurement and control technology based on software PID algorithm controller and hardware PWM technology is developing in digital, intelligent and high reliability.
1 system hardware composition DC motor measurement and control system as shown. The system is a closed-loop real-time measurement and control system composed of Cygnal C8051F020. It is a code that can realize speed preset and speed display, and can accurately measure and control the speed.
The sampling pulse generated by the Hall speed measuring circuit is sent to an external interrupt, and is counted by a counter to calculate the rotational speed. This speed value is compared with the preset speed value to obtain the difference. C8051 obtains the control increment by performing PID operation on the difference, and then the control parameter is output by C8051. The PWM circuit changes the effective voltage across the motor, and finally achieves the purpose of controlling the speed.
The schematic diagram of the DC motor measurement and control system keyboard and display circuit uses the 7279 control circuit of the serial interface.
Enter the control command on the function keyboard and the motor speed is displayed on the seven-segment display.
The direction of the PWM controller is computer measurement and control technology.
The p%Ms controller consists of a pwM wave open generator and a pwm delay protection t and a power amplifier circuit. The speed measurement part of the system uses the timer T0. If the PWM waveform is generated by the C8051, the software will increase the task of the software, thus affecting the real-time control effect of the entire system. Therefore, the PWM waveform is generated by an external circuit, and the C8051 only provides control parameters to change the pulse width duty cycle to achieve frequency conversion regulation of the motor speed. The PWM waveform generator is as shown.
The speed and frequency can be calculated from the period and frequency of the output pulse. In order to improve the accuracy of the motor speed measurement, multiple magnets can be evenly fixed on the motor turntable. Each time the motor rotates, the Hall sensor will generate multiple pulses, and the motor speed can be accurately measured by software calculation.
Since the pulse peak of the Hall sensor output is small and the edge of the waveform is incomplete, the Schmitt trigger circuit is used to pulse and output to the C8051 external interrupt INTO. The Schmitt trigger input and output waveforms are as shown.
u. In the PWM waveform generator, U1 is a 10-bit counter, and the clock input terminal CP of the counter is connected to the XTAL2 terminal of the C8051 crystal oscillator. The crystal frequency of the main frequency used in this system is 12MHz, and the frequency division of the PWM waveform is obtained after dividing by U1. U2's person>Bout terminates a zero-crossing comparator whose output is a PWM wave. The pulse width of the PWM wave can be changed by outputting the value from the P0 port.
The PWM wave output load capacity is too small to directly drive the motor, so we used a bipolar pulse width modulation power amplifier. It is necessary to consider that it takes a certain time for the high-power transistor to conduct from saturation to saturation, and prevent all the power amplifier tubes from being turned on at the same time. Therefore, a logic delay and a chain protection circuit are realized by using several gate circuits. At the same time, in order to make the motor work safely, the resistor and capacitor are connected at both ends of the motor. The resistance value and the capacitance are related to the motor parameters and the PWM waveform frequency, which can be calculated.
The L2 Hall detection circuit speed is a commonly used parameter in engineering. There are many methods for measuring the speed. The application of the Hall switch sensor is one of them. The Hall switch sensor is made of a semiconductor material whose output voltage is proportional to the magnitude of the external magnetic field. Due to its small size, no contact, good dynamic performance and long service life, it is widely used in measuring the rotational speed of rotating objects. This system uses the 3000 series Hall switch sensor produced by SPRAGUE Company of the United States.
According to the Hall effect principle, a permanent magnet is fixed on the edge of the rotating shaft of the motor shaft, and the magnetic steel rotates with the motor. A Hall switch sensor is installed in the vicinity of the motor relative to the rotating shaft. The Hall sensor should be in the effective range of the magnetic field of the magnetic steel. Inside. When the motor rotates, it is affected by the magnetic field generated by the magnetic steel. The Huo 2 system software design software design is based on the Cygnal IDE integrated development environment and the KeilC51 language. The main modules of this system include main program, INT0 interrupt subroutine, T0 interrupt subroutine, PID algorithm subroutine and display keyboard processing subroutine. After the main program performs a series of initializations, it transfers to the "PWM drive, keyboard control processing, and display" loop waiting interrupt; the external interrupt INT0 interrupt service subroutine counts the speed pulse outputted by the Hall circuit; T0 generates 50ms timer interrupt, T0 interrupt The service subroutine counts the number of interruptions, reads the speed pulse count value every 20 interruptions (1 second), calculates the rotation speed n times / s and sends the display buffer. At the same time, the PID subroutine is called to calculate the difference between the test speed and the set speed, and the control parameters are obtained, and sent to the PWM controller by the P0 port to adjust the motor speed. In the DDC system, the analog regulator is replaced by a computer, and the implementation of the control law is done by computer software. Therefore, the design of the digital controller in the system is the design of the computer algorithm in time. The author will focus on solving the PID algorithm and its implementation.
PID algorithm design idea In the automatic control system, PID controller is a widely used control method. Since the motor speed is basically proportional to the magnitude of the applied voltage of the armature, this forms the basis of PID regulation. At the sampling time *=ixT is the sampling period, i is a positive integer), the mathematical model of the analog PID controller adjustment law can be expressed by differential equation: u(1)=Kp. Beijing: Beijing University of Aeronautics and Astronautics Press, 2002. Wang Jianxiao, Yang Jianguo. 51 series MCU and C51 program design. Beijing: Science Press, 2002. Pan Yijin, Shi Guojun. Principle and application of C8051Fxxx high speed SOC microcontroller. Beijing: Beijing University of Aeronautics and Astronautics Press, 2002. Sun Chuanyou, Sun Xiaobin. Principle and design of measurement and control system. Beijing: Beijing Aerospace University Press, 2002.

Service Scope: Steam Turbine spare parts supply; steam turbine installation, inspection & overhaul, technological upgrading, turbine technology training, turbine low oil pressure renovation, turbine rotor shaft bend restoration, lower turbine`s vibration and noise, remove speed governing system abnormal volatility or load swing, solve turbine insufficient output, discontent load or other common/exceptional faults.


  Contract to overhaul and all kinds of turbine`s remould, turbine dynamic balance and so on, for satisfying practical operation requirements.


   Provide technical support and service for operation, inspection, maintenance, accident treatment and so on.


1. Steam Turbine Maintenance/Overhaul Service

 

   Steam turbine normal overhaul, failure treatment; main body components repair, heat exchange tubes of cooler replacement and so on.


2. Technical guidance


   Generating or Industrial driving turbine inspection, overhaul, upgrading and other items technical guidance.


3. Thermodynamic System Optimizing Services


   For operating or planning projects or equipment, according to end users` actual CHP(or heat-work cooling) requirements, make cycle efficiency analysis, provide system optimizing service.


4. Speed Governing System Remould

 

   Upgrade old hydraulic governing system to digital electro-hydraulic governing system, satisfy flexi-ble configuration all kinds of control strategy requirement.


5. Flow Passage Optimization and Modification


Total modification for steam turbine shall increase old turbine`s economic efficiency with advanced technology, service life also shall be extension.


6. Turbine Parameters Remold and Modification


Apply to processing or procedure transformation (or project site change) cause turbine operation parameters` change.


7. Uncontrolled extraction steam reconstruction


Consideration of turbine security and economic, open a hole for extraction steam normally in order to heat supply reformation.


8. Steam Turbine Engineering Service


Provide small & middle size Steam Turbine Generator or industrial steam turbine complete set engineering, project design and project installation service.


9. Vibration Analysis and Rotor Dynamic Balance

24Hours Service for emergency vibration analysis and wide range rotor dynamic balance service at project site or back to factory.


10. Condensing (extraction condensing) type remodel to back pressure type


Condensing (extraction condensing) steam turbine remodel to back pressure steam turbine


11. Steam Turbine Vacuum System Upgrade


Condenser three-dimension design and upgrade, reduce heat-transfer temperature difference, increase steam exhaust vacuum degree, improve turbine economic efficiency. Water cooling remodel to air cooling.


12. Steam Turbine Enlargement Capacity Reconstruction


Reconstruct the turbine`s capacity which are caused by system or equipment changing.


13. Motor Speed Governing Variable-frequency Remould

 

 Variable-frequency drive remould for pump systems of all kinds of industrial and mining enterprises.


14. Domestic Equipment Reconstruction


Domestic equipment reconstruction for imported turbine


15. Circulating Cooling Water System Optimization and Modification


Optimization and modification of operating circulating cooling water system, reduce operation energy consumption rate.


16. Waste Heat Steam Turbine Gland Seal System Upgrade


After upgrade, steam leakage ( effect gear box oil quality) shall be improved by the reason of waste heat parameters are not stable.


17. Spare Parts Marketing


Normal easily damaged parts warehouse, shorten delivery time.

Case 1


   A fertilizer company has 2 sets of steam turbine, model are: CB6-3.43/1.27/0.294 and CB6-3.43/1.17/0.294. Because end user`s power load and steam consumption are changed, the turbines must be reconstructed according to steam parameters, flow change and guarantee high efficiency.


   Remould Parameters: turbine max. inlet steam is 100t/h, when inlet steam is 97t/h and inlet pressure is 3.15MPa(g), its extraction steam is 62t/h extraction pressure is 1.51MPa(g), exhaust pressure is 0.21MPa(g), guarantee output is 5800KW (deviation±5% ).


   Main job of remould and overhaul:


   1. Casing was sent back to manufacture`s factory for rebuilding 2 valve seat hole, expand nozzle block steam passage.


   2. Change nozzle block, take out guide blade carrier.


   3. The original double row governing stage impeller and blade was changed to single row governing stage impeller and blade, add governing stage sheath, parts of rotor sleeve need to be changed and adjusted.


   4. LP stage 3rd diaphragm steam passage inspection optimization.


   5. Casing and rotor dismounting and assembling in factory with comprehensive inspection.


   6. Rotor low speed dynamic balance test.


   7. Governor static test in factory, overspeed test.


   8. Dismount & assembly, overhaul at project site.


   9. Clear incrustation for steam governing valve, nozzle and blade.


   10. Gland seal inspection and replacement, gland sealing clearance adjustment, change the seal block which was severe wear, spring leaf which are damaged should be changed.


   11. Every bearing repair and adjust.


   12. HP & LP governing steam valve grinding, stroke adjustment.


   13. Front bearing pedestal dismounting and inspection, patch oil leaking points.


   14. Inspection and patching steam leaking of HP steam governing valve link rod.


   15. Turbine mainbody troubleshooting.

   After remolding is complete, the 2 turbine sets are running very well.


Case 2

There is a paper mill which has a set of steam turbine: B6-3.43/0.981. Due to processing consumption in workshop and load were changed, the end user request reset new back pressure and achieve the best efficiency within the shortest time.


   Parameters reform to: when rated inlet flow: 55t/h, inlet pressure: 3.43±0.2MPa(a), exhaust pressure: 0.59MPa(a), steam rate guarantee value must be 11.65kg/(kw·h), output power must be 4700KW under rated working condition. The reconstruction project is a turnkey project, from preparing components to dismount heat material, equipment dismounting and installation, till to equipment commissioning successfully.


   For reducing the work amount, keep casing and pipelines still, main jobs are following:


   1. Change front & rear gland seal and diaphragm seal.


   2. Change main shaft assembling (keep mail oil pump and coupling still).


   3. Change HP nozzle block, HP guide blade carrier and original 2 stage diaphragm, add 3 stage diaphragm, 5 stage diaphragm adopts special design for satisfy the requirement.


   4. Change the original 3 stage impeller and add another 3 stage impeller.


   5. Steam governing valve link rod adjust inlet steam, check all butterfly valves matching conditions, improper ones should be changed.


   6. Original rotor`s coupling, MOP shall be mounted in new rotor.


   7. Rotor balance.


   8. Change sylphon of governing system.


   9. Change pressure transducer sleeve, adjust hydraulic servo-motor stroke.


   10. Governor static test in factory.


   11. Clear oil system.


  The reconstructed steam turbine is B4.7-3.43/0.59, end user evaluates steam rate, vibration, exhaust temperature very strictly, but the reconstructed steam turbine is running very well and fully meet the design performance.



Steam Turbine Care

Steam Turbine Care,Steam Turbine Services

Shandong Qingneng Power Co., Ltd. , https://www.steamturbine.be