[ieee 2009 xxii international symposium on information, communication and automation technologies...

5
Design of PLC- based PI Controller for the Permanent Magnet DC Motor under Real Constraints and Disturbances Jasmin Velagić, Kerim Obarčanin, Enisa Kapetanović, Senad Huseinbegović, Nedim Osmić Department for Automatic Control and Electronics Faculty of Electrical Engineering Sarajevo Sarajevo, Bosnia and Herzegovina [email protected] AbstractThe purpose of this paper is to analyse and implement PI control for the permanent magnet DC motor. The control algorithm is realised using Siemens S7-200 Programmable Logic Controller (PLC). The complex motor system is composed of DC motor, driver and tachogenerator. The main objective is to achieve a satisfactory time response of the system output under disturbances like death zone, nonlinearity, measurement noise and external load acting. The PI controller is designed in the programming enviroment on a previously identified nonlinear motor system. Then the PI controller is embedded into the S7-200 PLC. The effectiveness of this controller are tested in both simulation mode and experiments. I. INTRODUCTION Being simple, robust, effective and applicable to a broad class of system, PI and PID controllers have been the most widely used and well known controllers in industry for over 50 years [1]. In process industries, more than 97% of the regulatory controllers are of the PID or PI type [2]. Easy controlling and cheapness of the circuit drive of DC motors comparing to AC motors has lead to be chosen by the consumers and industries [3]. The permanent magnet DC motor becoming more popular in many control systems because of its high power density, large torque to inertia ratio, small and high efficiency [4], [5]. In that manner, analysis and implementation variations of PI DC motor control is of crucial importance, especially when we take into account widespread use of permanent magnet DC motors. This control systems exhibit good control performance without influences of significant disturbances and variation of controlling parameters [6]. It is known that moment of inertia of the DC motor always changed and does not produces properly system response. Also, the variation of the load torque can create some ripples in the rotor speed (or voltage). Therefore the PI controller should be designed which would not be sensitive to the system parameters and acting of input and output disturbances as much as possible. Also, auto tuning methods for adopting PI parameters are interesting for engineering because those methods ensure improvement in industry automation systems. The objective of this paper is to analyze and demonstrate velocity control for the permanent magnet DC motor with amplifier. The velocity of DC motor can be varied by controlling the field flux, the armature resistance or the terminal voltage [7]. In our case, velocity control would be realised with terminal voltage method. The aim is to obtain a fast and stable response nonsensitive to system's parameters changes and disturbances acting. The controller is realised by using PI control algorithm for DC motor under different constraints such as nonlinearities, death zone, measurement noise and external load. The complex DC motor system is composed of the DC motor with permanent stator magnet, the linear amplifier, the tachogenerator and the axel gear. The effectiveness of the controller is tested in both simulation mode and experiments. The paper is organised as follows. The structure and the elements of the complex DC motor system and overall control system are described in the Section II. The Section III describes identification procedure of the complex motor system needed for simulation purpose. The design of PI controller in PLC-based software (Siemens Step7 Micro/Win) is presented in Section IV. The essence of this paper is comparison of simulation and experimental results, shown in Section V. The conclusions are written in section VI. II. SYSTEM DESCRIPTION The DC control system based on the Siemens PLC is shown in Figure 1. The system contains two components, PLC based PI controller with analog input/output modul and the complex motor system. The PI controller is designed in mentioned software and downloaded to Siemens PLC S7-200 CPU 222. Figure 1. Block diagram of the control system 978-1-4244-4221-8/09/$25.00 ©2009 IEEE

Upload: nedim

Post on 14-Mar-2017

215 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: [IEEE 2009 XXII International Symposium on Information, Communication and Automation Technologies (ICAT 2009) - Sarajevo, Bosnia and Herzegovina (2009.10.29-2009.10.31)] 2009 XXII

Design of PLC- based PI Controller for the Permanent Magnet DC Motor under Real Constraints

and Disturbances

Jasmin Velagić, Kerim Obarčanin, Enisa Kapetanović, Senad Huseinbegović, Nedim Osmić Department for Automatic Control and Electronics

Faculty of Electrical Engineering Sarajevo Sarajevo, Bosnia and Herzegovina

[email protected]

Abstract— The purpose of this paper is to analyse and implement PI control for the permanent magnet DC motor. The control algorithm is realised using Siemens S7-200 Programmable Logic Controller (PLC). The complex motor system is composed of DC motor, driver and tachogenerator. The main objective is to achieve a satisfactory time response of the system output under disturbances like death zone, nonlinearity, measurement noise and external load acting. The PI controller is designed in the programming enviroment on a previously identified nonlinear motor system. Then the PI controller is embedded into the S7-200 PLC. The effectiveness of this controller are tested in both simulation mode and experiments.

I. INTRODUCTION Being simple, robust, effective and applicable to a broad

class of system, PI and PID controllers have been the most widely used and well known controllers in industry for over 50 years [1]. In process industries, more than 97% of the regulatory controllers are of the PID or PI type [2]. Easy controlling and cheapness of the circuit drive of DC motors comparing to AC motors has lead to be chosen by the consumers and industries [3]. The permanent magnet DC motor becoming more popular in many control systems because of its high power density, large torque to inertia ratio, small and high efficiency [4], [5]. In that manner, analysis and implementation variations of PI DC motor control is of crucial importance, especially when we take into account widespread use of permanent magnet DC motors. This control systems exhibit good control performance without influences of significant disturbances and variation of controlling parameters [6]. It is known that moment of inertia of the DC motor always changed and does not produces properly system response. Also, the variation of the load torque can create some ripples in the rotor speed (or voltage). Therefore the PI controller should be designed which would not be sensitive to the system parameters and acting of input and output disturbances as much as possible.

Also, auto tuning methods for adopting PI parameters are interesting for engineering because those methods ensure improvement in industry automation systems. The objective of

this paper is to analyze and demonstrate velocity control for the permanent magnet DC motor with amplifier. The velocity of DC motor can be varied by controlling the field flux, the armature resistance or the terminal voltage [7]. In our case, velocity control would be realised with terminal voltage method. The aim is to obtain a fast and stable response nonsensitive to system's parameters changes and disturbances acting. The controller is realised by using PI control algorithm for DC motor under different constraints such as nonlinearities, death zone, measurement noise and external load. The complex DC motor system is composed of the DC motor with permanent stator magnet, the linear amplifier, the tachogenerator and the axel gear. The effectiveness of the controller is tested in both simulation mode and experiments.

The paper is organised as follows. The structure and the elements of the complex DC motor system and overall control system are described in the Section II. The Section III describes identification procedure of the complex motor system needed for simulation purpose. The design of PI controller in PLC-based software (Siemens Step7 Micro/Win) is presented in Section IV. The essence of this paper is comparison of simulation and experimental results, shown in Section V. The conclusions are written in section VI.

II. SYSTEM DESCRIPTION

The DC control system based on the Siemens PLC is shown in Figure 1. The system contains two components, PLC based PI controller with analog input/output modul and the complex motor system. The PI controller is designed in mentioned software and downloaded to Siemens PLC S7-200 CPU 222.

Figure 1. Block diagram of the control system

Figure 1. Block diagram of the control system

978-1-4244-4221-8/09/$25.00 ©2009 IEEE

Page 2: [IEEE 2009 XXII International Symposium on Information, Communication and Automation Technologies (ICAT 2009) - Sarajevo, Bosnia and Herzegovina (2009.10.29-2009.10.31)] 2009 XXII

This model of PLC CPU has not included analog input/output pins so it was necessary to use EM235 as analog input/output modul. Using EM235 analog modul is acquired a response from DC motor as voltage signal in a range (0V, 10V). Also, using EM235 is generated control variable for the DC motor system control.

A. DC motor and linear amplifier

The DC motor is constructed of two main parts, armature (rotor) and stator. The stator consists of permanent magnets which create magnetic field [11]. The armature contains an electromagnet created by the coil wound around an iron core. The armature rotates due to the phenomenon of attracting and opposing forces of two magnetic fields. A magnetic field is generated by the armature by sending an electrical current through the coil and the polarity is constantly changed by alternating current through the coil cousing armature to rotate.

The electrical and mechanical characteristic of the permanent magnet DC motor are described by equation:

Ua=RaIa+La

dIadt

+e (1)

e=kvω (2)

τm=Jm

dωdt

+Dω+τt (3)

τm=ktIa (4)

where Ua is voltage applied on the armature, Ia is the armature current , Ra and La are the armature resistence and inductance, respectively, is rotational velocity of the armature, τm is the motor driving torque, τt is the mechanical torque load, Jm and D are moment of intertia and dumping coefficient at the motor shaft and Kv is the voltage constant and Kt is torque constant. In this paper we used the permanent magnet DC motor whose parametars are unknown. This motor is considered as a part of the complex DC motor system ilustrated in Figure 1.

The power amplifier represents a linear serial controller shown in Figure 2. The output voltage is calculated as follows: Uout=

R4R1+R4

1+ R2R3

Uc (5)

where is controled voltage ( from PLC S7-200/ MR253 modul ) and represents appropriate resistor. Transfer function of the power amplifier is : A= R4

R1+R41+ R2

R3 (6)

If R1= R4 and R2 R3 then Uout=Uc.

Altought, this amplifier represents a linear system which introduces a segnificant nonlinearity in the whole system due to own saturation. The output range of the amplifier Uout is limited under 1.5 V , Uin-1.5[V] .

The tachogenerator establishes relation between an output motor voltage E and rotary velocity of motor shaft as follows :

E=kΦω (7)

where k is tachogenerator constant and is magnetic flux. It is important to note that the magnetic flux of the DC motor with permanent magnets has a constant value.

B. Siemens PLC s7-200 + EM235 analog I/O modul

As PI controller it is used Siemens PLC S7-200, CPU 222. It is expendable, compact and very fast Siemens PLC, especially with respect to its real time performance [8]. Mentioned PLC does not have an integrated analog input / ouput and for that reason expansion modul for analog input / output EM235 has been used. The EM235 has 1 analog output ( ±10V, 0-20mA ) and 4 analog inputs with capability to select an voltage input range ±10V e.g.0-10V, 0-5V, ±10V, ±5V . The PLC is programmed using Step7 Micro/Win v4.0 software. More about PLC and analog I/O modul can be found on Siemens official web site (www. siemens.com).

III. IDENTIFICATION OF COMPLEX MOTOR SYSTEM The complex DC motor system is considered as black box.

Further, parametric identification procedure of this complex system is performed using dSPACE system for rapid control prototyping (RCP) [11].

The input signal is voltage applied to the power amplifier and output is voltage on the DC motor shaft which is mesured by tachogenerator. The choice of input data is essential for the process identification. In this paper the input signal is chosen to be band-limited white noise. The response of the complex

Figure 2. Power amplifier structure

Page 3: [IEEE 2009 XXII International Symposium on Information, Communication and Automation Technologies (ICAT 2009) - Sarajevo, Bosnia and Herzegovina (2009.10.29-2009.10.31)] 2009 XXII

system on the excitation is shown in Figure 3 and Figure 4. Identification process is perfomed using Box-Jenkins method achiving matching results of 92.65%. Results of this method are shown on Figure 5. Due to constraints of the dSPACE system, input and output values are scaled from [0,10] into [0,1] and from [0, 2.8] into [0,1], respectively. The transfer function of the complex motor system is :

G s = 2.1050.40337s+1

(8)

Figure 2.

Figure 3.

Figure 4.

Figure 5.

IV. PI CONTROLLER DESIGN

In the simulation mode the parameters of the PI controller are obtained under feedback motor control using an Internal Model Control (IMC) based tuning where controller setings are derived from a full-order controller. Simulations are done in Matlab / Simulink simulation environment (Section V, part A).

The IMC methodology has been widely adopted for the purpose of PID control tuning. The algorithm have the adventage of only using a single tuning parameter to achive a

clear trade-off between robustness and aggresiveness of the controller [9]. The block diagram of the control system and process is depicted in Figure 6.

In the Figure 6. denotes a model of the process, is an aproximate inverse of and is and low-pass filter [10]. If we assume that all disturbances present in the the process can be reduced to an equivalent disturbance d at the process output according to Figure 6,then the controller transfer function is :

Gc= GfGm

-1

1-GfGm-1Gm

. (9)

If the model matches the process, e.g. , the signal e is equal to the disturbance d for all control signals u.The filter is introduced to obtain a system that is less sensitive to modeling error. From these reasons the following transfer function of the filter is choosen:

Gf=

11+λs

. (10)

To obtaing the PI controller from the IMC principle,consider process with transfer function :

Gp= Kp

1+Ts=Gm.

(11)

An approximate inverse of (11) is given by :

Gm

-1= 1+TsKp

. (12)

The controller, in accordance to previously written relations, become :

Gc s = 1+sT

Kpsλ. (13)

The transfer function (13) can be rewritten in the form of an ideal PI controller :

Figure 3. Input data of complex motor system

Figure 4. Output data of the complex motor system

Figure 5. Measured and simulated motor system output

Figure 6. IMC based controller

Page 4: [IEEE 2009 XXII International Symposium on Information, Communication and Automation Technologies (ICAT 2009) - Sarajevo, Bosnia and Herzegovina (2009.10.29-2009.10.31)] 2009 XXII

Gc s = TKpλ

1+ 1sT

=kc 1+ 1sT

. 14

The dominant closed-loop time constants is set to be λ=0.079. For the experimental validation of the proposed PI controller the Siemens PLC with an appropriate software (Siemens Step7 Micro/Win) is used. The PI parameters achieved in the simulation mode are embedded into the PLC. The ladder diagram of this controller is shown in Figure 7.

This ladder diagram which represents PI algorithm, contains two lines. In the first line (Network 1) a scalling blok with purpose of converting integer type of variable into real variable type is used. The second (Network 2) implements the PID0_INT subroutine using PID Wizard.

In the next section the simulation and experimental results obtained using proposed system will be presented

V. SIMULATION AND EXPERIMENTAL RESULTS

A. Simulation results

The simulations of the DC motor control system has been done in Matlab / Simulink simulation environment using model shown in Figure 8.

The PI controller is realised using Compensator design tool as a part of Simulink simulation environment [12]. The parameters are determined using Internal Model Control

tunning algorithm, described in section IV. The following parameters values are obtained:

P=2.4285, I=6.0204.

The time response of the control system to step and pulse signals with PI controller in simulation mode are depicted in Figures 9. and 10.

Simulation results obtained demonstrate a satisfacory behavior of the DC motor control system.

B. Experimental results

It is very hard to control this nonlinear system with PI or PID controller especially when it is implemented as PLC-based controller [9]. Also, there are measurement noise and

Figure 7. Step 7 Micro/Win ladder diagram

Figure 8. Simulation model in programming enironment

Figure 9. Simulation model in the programming environment

Figure 9. Simulation in the programming environment

Figure 10. The time response to pulse signal – simulation mode

Page 5: [IEEE 2009 XXII International Symposium on Information, Communication and Automation Technologies (ICAT 2009) - Sarajevo, Bosnia and Herzegovina (2009.10.29-2009.10.31)] 2009 XXII

very large death zone (5V) what makes control real challenge. As can be seen in Figure 11., PLC is connected to DC motor system via analog I/O modul. Also, digital multimeter is used for control of a set point variable from the power unit.

The power unit (Tektronix CPS 250) is equiped with analog volmeter and potentiometer for setting voltage level. Manually altered value of set point introduces an additional noise on the actual output response (Figure 12.) Also, there is a load torque on a motor shaft that has a significant influence on the control performance and stability. Despite all constraints and disturbance, achieved system response using PLC as PI controller, is shown on Figure 12. The parameters of PI controller are manually adjusted.

As it can be seen in Figure 12., green line that represents actual value of the system response, satisfactory tracks the set point (blue line) under mentioned real time considerations and disturbance.

VI. CONCLUSIONS

In this paper the classical and robust PI controller has been developed for permament magnet DC motor control. The complex motor system contained of the tachogenerator, the linear amplifier and the permanent magnet DC motor, is nonlinear and very challenging to control, especially using classical PI controller. For purpose of the system control, it was identified first. Then the performance of designed PI controller is tested in simulation and experimental modes. In experiments the PLC-based PI controller was used. The simulation and experiment results demonstrated effectiveness of the proposed PI controller under feedback control of the complex nonlinear DC motor system under different types of internal and external disturbances.

REFERENCES

[1] Seun-Ming Beak, Tea-Yong Kuc, “An adaptive PI learning control of DC motor“, Computational Cybernetics and Simulation, 1997, IEEE International Conference

[2] Cheng-Ching Yu, „Autotuning of PID Controllers. A relay feedback approach“, 2nd edition, Springer-Verlag London Limited, 2006.

[3] H.R. Azevedo et al. “ A fuzzy logic controller for DC motor position control”, Technical reports no 0-7803-0985-5,pp 18.-25. 1993.

[4] G. R. Slemon, Electric machines and drives, New York: Addison-Wesley, 1992, pp. 503-510.

[5] M. A. Rahman and P. Zhou, “Field circuit analysis of brushless permanent magnet synchronous motors,“ IEEE Transactions on Industrial Electronics, vol. 43, no. 2, Apr. 1996, pp 256-267.

[6] P .H. Lin , S. Hwang , J. Chou, “Comparison on fuzzy logic and PID controls for a DC motor position controller,“ Technical Report no. 0-7803-1993-1, pp. 193-01935, 1994.

[7] S. Ayasun, G. Karbeyaz, „DC motor speed contol, Methods using Matlab / simulink and their integration into undergraduate electric machinery course“, Nigde University, Turkey, 2007

[8] Siemens S7-200 Programmable controller System manual, 09/2007 [9] A.Visioli, “Practical PID control”,Springer-Verlag London Limited,

2006. [10] K.Astrom, T.Hagglund, “PID controllers :Theory,Design and

Tuning”,2nd edition, Instrument Society of America, 1995. [11] J.Velagić, A. Galijašević, „Design of Fuzzy Logic Control of Permanent

magnet DC motor under real constraints and disturbance“, 3. IEEE Multi-conference on Systems and Control(MSC 2009), Saint Petesburg, Russia (in press), July 8-10, 2009

[12] The MathWorks Inc. , Matlab & Simulink R2008a. Control System Toolbox , Product help

Figure 11. Overall control and DC motor system

Figure 12. The time response of complex motor system