Lab 2: Identification of the Transfer Function of a DC Motor
Theodore Hintz

Lab 2: Identification of the Transfer Function of a DC Motor

Theodore Hintz

Electrical Engineering Department

University of Texas Arlington

Arlington, Texas USA

Abstract—The purpose of this lab experiment is to extract the parameters necessary to approximate the behavior of a DC motor. These parameters will then be used to simulate a DC motor plant and compare them to the actual DC motor plant they were extracted from. It was found that the extracted parameters accurately characterized the DC motor plant.

IndexTerms—DC Gain, Rise Time, Dead Zone, Linear, Nonlinear

Introduction

In order to precisely control a DC motor in real world applications, certain parameters must be extracted from a given motor to approximate its real world behavior. Often times, the DC gain and rise time of a motor are sufficient parameters to accurately describe the behavior of a motor.

The DC gain relates the input voltage of a motor to the output voltage of a motor, thus relating the input voltage of a motor to the output speed. The rise time is a measurement of the amount of time it takes for the motor to reach approximately 63.2% of its steady state response with the steady state response of a motor being the output voltage as t → ∞. The transfer function of a DC motor given τ = rise time and g = DC gain is shown below.

During this lab experiment both of these parameters will be extracted using a SIMULINK computer/plant interface. With these parameters a DC motor can besufficiently and accurately described.

Parameter extraction

DC GAIN

First the DC motor plant is connected to SIMULINK using an NI-1200 card in a computer. Through this card and SIMULINK an input voltage can be sent to the plant and the resulting output data can be viewed. First, to extract the DC gain parameter, an input voltage is swept from -5V to 5V.From -2V to 2V the voltage is stepped in 0.2V increments, between -5V to -2V and 2V to 5V the voltage is stepped in .5V increments. Each time the voltage is incremented, the steady state DC value of the output voltage is recorded. Once the voltage sweep is complete, Vout vs. Vin can be plotted and the DC gain can be calculated from the slope of the resulting line.

For the sweep to be accomplished in SIMULINK, the block diagram in Figure 1 is used. By allowing the step input amplitude to equal one, the slider gain is equal to the input voltage applied to the motor.

Figure 1: SIMULINK Motor Plant Control

Using the slider gain pictured above, the input voltage is incremented and the output voltage recorded throughout the sweep. The resulting plot of Vout vs. Vin is shown below in Figure 1.

Figure 2: Vout Vs. Vin

When calculating the DC gain, the dead zone cannot be included in the slope calculation because it has nonlinear behavior. The dead zone of a DC motor is defined as a certain range of input voltages that cause no output voltage. This occurs because this certain range of input voltages is not high enough to cause the DC motor to overcome its internal mechanical resistances, thus causing no output voltage. In Figure 2, the dead zone can clearly be seen between -1V and 1V.

The saturation region must also be excluded when calculating the DC gain. The saturation region occurs when the change in output voltage to input voltage approaches zero. This region can be clearly seen for input voltages less than -4V and greater than 4V.

In order to calculate the DC gain, values from the linear region must be used. The linear region for positive input voltages is approximately between 1V and 4V. The DC gain can be calculated using the formula below.

Using experimental data the DC gain g is calculated.

RISE TIME

The rise time is the approximate time it takes the system to achieve 63.2% of its steady state response. This number is approximated by τ = 1-1/e ≈ 63.2%. τ then corresponds to fc = 1/(2πτ), the cutoff frequency of a first order system. The cutoff frequency occurs when a given system drops 3db from its stead state value or equivalently, when it reaches half power.

In order accurately approximate the rise time of the DC motor, it is calculated for three different input voltages and then averaged. For each input voltage, the step response of the motor is observed.Then,the time at which an output voltage is 63.2% of the steady state output voltage is observed, and this is recorded as the rise time. The resulting data is shown below in Table 1.

Vin / Vout / τ
5V / 2.946V / .208s
3V / 1.9679V / .200s
-5V / -3.1689V / .200s
Avg. Rise Time / .202s

Table 1: Rise Time

Comparing real model and simulation

In order to test the transfer function and the simulations validity, the step response of the real motor and the step response of the motor transfer function are observed and compared.

In this model, g = .77 and τ = .202s, these parameters are then plugged into a SIMULINK simulation and the step response is compared to the motors at the same input voltage.Here, a 5V input is used for both the simulation and the real motor response.The resulting data and the SIMULINK block diagram are shown below.

Figure 4: SIMULINK Simulated Motor

Figure 5: Step Response of Real Vs. Simulated Models

In Figure 5 it is observed that the gain of the simulated motor is significantly higher than that of the actual motor. If the gain of the simulated motor is tweaked to g = .59 then the step responses match as shown in Figure 6 below.

Figure 6: Modified Gain Step Response

From Figure 6 it is observed that the gains and rise time of both the real and simulated motor step responses match. It can be concluded that the gain parameter extracted was inaccurate but the rise time was accurate.

Troubleshooting inaccuracies

As inaccuracies were observed, the original data used for the gain parameter was remeasured and rechecked, ultimately yielding the same inaccurate results. Further troubleshooting involved the inspection of the plant used. All power supply voltages were measured but the 5V power supply used for the plants measuring equipment checked in at .9V, far from nominal. After this was observed a new power supply was put in its place but the same inaccurate results were found. Whenever a power supply was connected to the plant being used, the measurement equipment power supply measured .9V, if the power supply was connected to a different plant, it measured 5V. From the troubleshooting performed it can be deduced that a component in the plant used for measuring has likely failed or is malfunctioning.

data and discussion

DATA

All of the data used for parameter extraction and the resulting parameter are shown in the table below.

Vin / Vout / τ
5V / 2.946V / .208s
3V / 1.9679V / .200s
-5V / -3.1689V / .200s
Avg. Rise Time / .202s
Vout 2 / 2.7V
Vout1 / .38V
Vin 2 / 4.0V
Vin1 / 1.0V
Avg. Gain / .77

Table 2: Parameter Extraction Data

The gain can be sufficiently described with two significant figures. Since there are many environmental variables when recording input voltage and output voltage, the second decimal place would surely change for a given set of data generated

from the same plant. Two significant figures would also be a valid estimate for the rise time given the amount of environmental variables, but since an average rise time is the calculation used, more significant figures were used to produce a more accurate result.

If the plant was able to provide SIMULINK with the measured input voltage, a more accurate gain and rise time could be calculated. Since a power supply is usually a few decimal places off of its intended value, a small amount of error will be introduced into the gain calculation.

DISCUSSION

If the motor were to be used in a control system, it would be most effect if it was operated in the linear region, from approximately 1V to 4V or -4V to -1V. In these regions, the first order transfer function model will be most accurate, thus a more effective control system can be designed.

If one were to design a speed controller for the motor the dead zone should be accounted for. If the dead zone were not accounted for, a controller might expect a speed from the motor at a given input voltage that occurs in the dead zone, according to the linear relationship of g. If this were the case, a controller would have a period where no output voltage occurred. To design around this, a threshold input voltage could be set for each side of the dead zone so that when the controller detected it, it could suddenly switch the input voltage as to avoid the dead zone and continue operation.

If a normal operating speed were to correspond to 2V output, it would be most effective to approximate the gain using values just greater than and just less than 2V. For example, if Vout = 2.1V and Vout = 1.9V were used in the gain approximation, the final result would be an accurate linear approximation of the gain at Vout = 2V.

By using a first order transfer function to model the plant, the parameters for the model can easily be experimentally extracted. If a second order model were used it would be difficult to experimentally extract all of the parameters necessary to describe the behavior of the plant. With this first order approximation it is an accurate description and easy to describe.

The above transfer function has no zeros but has 1 pole. This pole occurs at s = - 1/.202 = - 4.95 which is approximately the minimum input voltage. Since this pole is in the left half plane (LHP), the system is stable

conclusion

During this lab experiment the methodology used to extract the DC motors parameters was executed correctly. Through troubleshooting it was concluded that the inaccurate gain calculated was attributed to equipment malfunction. Overall it was an effective tool in the methodology of motor parameter extraction and testing the validity of the derived models.

References

[1]Gene F. Franklin, J. David Powell and AbbasEmami-Naeini, Feedback Control of Dynamic Systems, 6th edition, Pearson Higher Education, 2010.

APPENDICIES

The only code used in this experiment was the code used to plot, this code is shown below.

Figure 2:

ylabel('Vout')%Label y axis

xlabel('Vin')%Label x axis

title('Vout Vs. Vin')%Title graph

plot(speed(:,1),speed(:,2))%Plot real motor step response

Figure 5 and 6

plot(speed(:,1),speed(:,2))%Plot real motor step response

hold on%Hold graph for second graph

plot(scope(:,1),scope(:,2),'--')%Plot simulated motor step response

xlabel('Time (s)')%Label x axis

ylabel('Voltage (V)')%Label y axis

leg = legend('Real Motor','Simulated Motor')%Label different lines