Sensor Less Speed Control of IM Using VHDL
Sensor Less Speed Control of IM Using VHDL
Abstract
1
Chapter 1
Introduction
1.1 Historical Review
The history of electrical motors goes back as far as 1820, when
Hans Christian Oersted discovered the magnetic effect of an electric
current. One year later, Michael Faraday discovered the electromagnetic
rotation and built the first primitive D.C. motor. Faraday went on to discover
electromagnetic induction in 1831, but it was not until 1883 that Tesla
invented the A.C asynchronous motor. In 1882, Nikola Tesla identified the
rotating magnetic field principle, and pioneered the use of a rotary field of
force to operate machines. He exploited the principle to design a unique two-
phase induction motor in 1883. In 1885, Galileo Ferraris independently
researched the concept. In 1888, Ferraris published his research in a paper to
the Royal Academy of Sciences in Turin. Introduction of Tesla's motor from
1888 onwards initiated what is known as the Second Industrial Revolution,
making possible the efficient generation and long distance distribution of
electrical energy using the alternating current transmission system, also of
Tesla's invention (1888). Before the invention of the rotating magnetic field,
motors operated by continually passing a conductor through a stationary
magnetic field (as in homopolar motors). Tesla had suggested that the
commutators from a machine could be removed and the device could operate
on a rotary field of force. Professor Poeschel, his teacher, stated that would
be akin to building a perpetual motion machine. This classic alternating
current electro-magnetic motor was an induction motor. In the induction
motor, the field and armature were ideally of equal field strengths and the
field and armature cores were of equal sizes. The total energy supplied to
2
operate the device equaled the sum of the energy expended in the armature
and field coils. The power developed in operation of the device equaled the
product of the energy expended in the armature and field coils. The main
advantage is that induction motors do not require an electrical connection
between stationary and rotating parts of the motor. Therefore, they do not
need any mechanical commutator (brushes), leading to the fact that they
are maintenance free motors. Induction motors also have low weight and
inertia, high efficiency and a high overload capability. Therefore, they are
cheaper and more robust, and less prone to any failure at high speeds.
Furthermore, the motor can work in explosive environments because no
sparks are produced.
3
primary. That is why such motors are known as induction motors. In fact, an
induction motor can be treated as a rotating transformer i.e. one in which
primary winding is stationary but the secondary is free to rotate. Induction
motor is the most common type of AC motor used in the world. It can be
single phase or three phase. They are widely used for different applications
ranging from small induction motors in washing machines, household fans
etc to vary large induction motors which are capable of tens of thousands of
kW in output, for pipeline compressors, wind-tunnel drives and overland
conveyor systems. Through electromagnetic induction, the rotating magnetic
field induces a current in the conductors in the rotor, which in turn sets up a
counterbalancing magnetic field that causes the rotor to turn in the direction
the field is rotating. The rotor must always rotate slower than the rotating
magnetic field produced by the polyphase electrical supply; otherwise, no
counterbalancing field will be produced in the rotor. Induction motors are
the workhorses of industry and motors up to about 500 kW (670
horsepower) in output are produced in highly standardized frame sizes,
making them nearly completely interchangeable between manufacturers.
4
rotor, and usually only the end rings will be visible. The vast majority of the
rotor currents will flow through the bars rather than the higher-resistance and
usually varnished laminates. Very low voltages at very high currents are
typical in the bars and end rings; high efficiency motors will often use cast
copper in order to reduce the resistance in the rotor. In operation, the squirrel
cage motor may be viewed as a transformer with a rotating secondary - when
the rotor is not rotating in sync with the magnetic field, large rotor currents
are induced; the large rotor currents magnetize the rotor and interact with the
stator's magnetic fields to bring the rotor into synchronization with the
stator's field. An unloaded squirrel cage motor at synchronous speed will
consume electrical power only to maintain rotor speed against friction and
resistance losses; as the mechanical load increases, so will the electrical load
- the electrical load is inherently related to the mechanical load. This is
similar to a transformer, where the primary's electrical load is related to the
secondary electrical load. This is why, as an example, a squirrel cage blower
motor may cause the lights in a home to dim as it starts, but doesn't dim the
lights when its fan belt (and therefore mechanical load) is removed.
Furthermore, a stalled squirrel cage motor (overloaded or with a jammed
shaft) will consume current limited only by circuit resistance as it attempts
5
to start. Unless something else limits the current (or cuts it off completely)
overheating and destruction of the winding insulation is the likely outcome.
Virtually every washing machine, dishwasher, standalone fan, record player,
etc. uses some variant of a squirrel cage motor.
6
supply), reduced voltage starting using a series inductors, an
autotransformer, thyristors, or other devices are used. A technique
sometimes used is star-delta starting, where the motor coils are initially
connected in wye for acceleration of the load, then switched to delta when
the load is up to speed. This technique is more common in Europe than in
North America. Transistorized drives can directly vary the applied voltage as
required by the starting characteristics of the motor and load. This type of
motor is becoming more common in traction applications such as
locomotives, where it is known as the asynchronous traction motor.
7
Percentage slip = (N s −Nr) / Ns * 100
Where
Nr = Rotational speed, in revolutions per minute.
S = Normalized Slip, 0 to 1.
For motoring action 0 <slip <1
For generator action slip > 1
For braking action slip < 0
As an example, a typical four-pole motor running on 60 Hz might
have a nameplate rating of 1725 RPM at full load, while its calculated speed
is 1800 RPM. The speed in this type of motor has traditionally been altered
by having additional sets of coils or poles in the motor that can be switched
on and off to change the speed of magnetic field rotation. However,
developments in power electronics mean that the frequency of the power
supply can also now be varied to provide a smoother control of the motor
speed.
A 3-φinduction motor is practically a constant speed machine, more or
less like a dc shunt motor. The speed regulation of an induction motor (having a
low resistance) is usually less then 5 % at full load. In the case of induction
motor when the load is increased then speed will decrease and the speed
reduction is accompanied by a corresponding loss of efficiency and good speed
regulation. So it is quite difficult to build a good adjustable speed induction
motor. Different methods by which speed control of induction motor is achieved
are as follows
8
By changing the number of stator poles
Control from the rotorside-
Rotor rheostat control
By operating two motorin concatenation or cascade
By injecting an emf in the rotorcircuit
9
wiring are a significant source of failure, additional cost, and additional
weight. Numerous approaches have been proposed to estimate the rotor
velocity and/or position from the machine terminal properties, such as the
stator current or voltage. Sensorless speed control drives have reached the
status of a maturing technology in a broad range of applications ranging
from low-cost to high-performance systems. Eliminating the speed sensor on
the motor shaft represents a cost advantage, which combines favorably with
increased reliability due to the absence of this mechanical component and its
sensor cable. This project presents the mathematical principles and algorithm
underlying a new sensorless control strategy for a three phase squirrel cage
induction motor. The control method comprises of two elements: the stator
current control strategy and sensorless speed control strategy both of them
based on equivalent 3-φR-L-e circuit where parameter are designed from
space vector model of the induction motor. The neural network algorithm is
used to generate 3-bit code associated with the output voltage generated by a
PWM inverter. The neural network size and architecture is determined based
on the necessary calculations precision and available hardware resemblance.
A new sensorless speed control method is formulated and tested by
simulation. The motor controller structure developed in this project uses
FPGA (field programmable gate array) implemented neural network
alongside pipelined digital structure to carryout the computationally
intensive task of controlling the stator current. The use of specialized digital
structure ensures fast operation and allows speed control and current control
algorithm to be performed in parallel. The VHDL design and FPGA
implementation are presented including simulation result.
10
Chapter 2
Mathematical Equations and algorithms
2.1 Equivalent Circuit of Induction motor
The induction motor can be treated essentially as a transformer for
analysis. The equivalent circuit of the induction motor is very similar to that
for a transformer. Although the rotor currents are at slip frequency, the rotor
is incorporated into the circuit in a simple way. Recognizing the fact that the
stator and rotor windings have resistances and leakage inductances and that
the mutual inductance for modeling the mutual flux links the stator and rotor
winding. The parameters are stator resistance per phase, Rs rotor resistance
per phase, R rr mutual inductance, Lm stator leakage inductance per phase L 1s,
rotor leakage reactance per phase, L1rr stator turns per phase T1,rotor turns
per phase T2 , induced emf in the stator per phase, E1 , and induced emf in the
rotor phase, E2 , Effective stator or rotor turns per phase is equal to the
product of the number of turns per phase and the winding factor of the stator
and rotor and respectively, is denoted as Kw1 and Kw2. The winding factor is
the product of pitch and distribution factors that account for the specific
winding characteristics. The transformer in the centre of the equivalent
11
circuit can be eliminated by adjusting the values of the rotor components in
accordance with the effective turn’s ratio of the transformer. From the
equivalent circuit and a basic knowledge of the operation of the induction
motor, it can be seen that the magnetizing current component and the iron
loss of the motor are voltage dependant, and not load dependant.
Additionally, the full voltage starting current of a particular motor is voltage
and speed dependant, but not load dependant. The magnetizing current
varies depending on the design of the motor. For small motors, the
magnetizing current may be as high as 60%, but for large two pole motors,
the magnetizing current is more typically 20 - 25%. At the design voltage,
the iron is typically near saturation, so the iron loss and magnetizing current
do not vary linearly with voltage with small increases in voltage resulting in
a high increase in magnetizing current and iron loss. The relationship
between the induced emfs is
……(2.1)
(2.2)
Where T1e and T 2e are the effective stator and rotor turns per phase, and the
turns ratio, a, between the stator to rotor effective turns per phase is given as:
The rotor current Irr, then is
(2.3)
Substituting for E2 from equation 2.1 into equation 2.3, the rotor current is
12
(2.4)
Equation is incorporated into the equivalent circuit as shown in Fig 2.2. Note
that both the rotor and stator uniformly have the same frequency, which is
that of the stator in equation (2.4). The rotor current reflected into the stator
is denoted as I r in figure 2.2 and is given in terms of the rotor current Irr as
… (2.5)
Note that the slip does not enter in this the ratio between the stator and rotor
induced emfs viewed at stator frequency does not contain it and rotor
independence absorbs this slip. Substitution of equation (2.4) into equation
yields.
(2.6)
Where Rr and Lrr are the stator referred rotor resistance and leakage
inductance respectively, given as
(2.7)
As the fictitious rotor and stator at the air gap have the same induced emf, E1
the physical isolation can be removed to get a connected circuit. The final
equivalent circuit, referred to the stator. Magnetization is accounted for by
the magnetizing branch of the equivalent circuit, consisting of the
magnetizing inductance can represented the core losses. This core – less
13
resistance is in parallel to the magnetizing inductance, because the core
losses are dependant on the flux and hence proportional to the flux linkages
and the resulting air gap voltage E 1. The self – inductances of the stator
phase winding. L r and of the rotor phase winding referred to the stator, Lr are
obtained as the sum of the magnetizing inductance and respective leakage
inductances.
.. (2.8)(2.9)
The corresponding reactances are obtained by multiplying the inductances
by the stator angular frequency. A simple phasor diagram of induction motor
is drawn by using the equivalent circuit given in Figure 2.2. The basis is
provided by the following relationships.
When the machine is energized with no load on the rotor, then the
rotor circuit is open – circuited because the stop is zero. The stator current
drawn during this condition, known as the no-load current, contributes to the
magnetization of the machine and resulting core losses. Then this no – load
current is viewed as the sum of the magnetizing and core – loss components
of the current and accordingly is written as
14
(2.10)
Where Irr is the no – load phase current I m is the magnetizing current, and Ir
is the core – loss current. The magnetizing current in terms of the air gap
voltage and the magnetizing reactance is written as
(2.11)
Where E 1 is the air gap voltage and Xm is the magnetizing reactance,
similarly, the core – loss component of the stator current is written as
(2.12)
Where R c is the resistance to account for the core losses. The rotor phase
current is given by
(2.13)
Where I r is the rotor phase current. The stator phase current then is
(2.14)
In terms of the induced emf stator current and stator parameters, the applied
stator voltage is expressed as the sum of the induced emf and stator
impedance voltage drop and is given by
(2.15)
Where Vas is the stator phase voltage
The phasor diagram is shown in figure 2.3. The angle φbetween the
stator input voltage and the stator current is the power factor angle of the
15
stator and λ
m is the mutual flux. The steady – state performance is taken up
..(2.16)
Neglecting the core losses, the air gap power is equal to the total power
dissipated in R1/s in the three phases of the machine; there is no other
element to consume power in the rotor equivalent circuit. It is given as
… (2.17)
Which could be written alternatively as
… (2.18)
16
2
The I rRr term is recognized as rotor copper loss, and hence the remainder.
I 2rRr (1 – S) / S, gives the power converted into mechanical form. The rotor
copper losses are equal to the product of slip and air gap power from
equation (2.17) and this is referred to as slip power. The common term of
three in equations (2.17) and (2.18) accounts for the number of phases in the
machines, which throughout taken as three. The mechanical power output Pm
is obtained as
… (2.19)
Alternately, in terms of the electromagnetic torque and rotor speed, the
mechanical powder output is equal to their product:
…(2.21)
Where Te is the internal or electromagnetic torque, derived from equations
…(2.22)
Substituting for the rotor speed in terms of the slip and stator frequency,
given by
..(2.23)
Into, the electromagnetic or air gap torque is obtained as
…(2.24)
To obtain the shaft output power of the machine, Ps , the windings and
friction losses of the rotor, denoted as Pfw have to be subtracted from the
mechanical output power of the machine, symbolically given as follows:
17
…. (2.25)
18
the general case. Derivations for electromagnetic torque involving the
currents and flux linkages are given. The differential equations describing
the induction motors are nonlinear. For stability and controller design
studies, it is important to linearize the machine equation around a steady –
state operating point to obtain small signal equations. The space model
powerfully evokes the similarly and equivalence between the induction
machines and de machines from the modeling and control points of view.
19
mmf equality. The d and q axes mmfs are found by resolving the mmfs of
the three phases along the d and q axes.
The common term, the number of turns in the winding, is canceled on
either side of the equations, leaving the current equalities. The q axis is
assumed to be lagging the a axis by ec' The relationship between dqo and abc
currents is as follows:
The current is represents the imbalances in the a, b, and c phase currents and
can be recognized as the zero-sequence component of the current.
Where
And the transformation from abc to qdo variables is
The zero – sequence current is does not produce a resultant magnetic field.
The transformation from two-phase currents to three–phase currents can be
obtained as
20
Where
The power input to the three-phase motor has to be equal to the power
input to II" two-phase machine to have meaningful interpretation in the
21
modeling, analysis and simulation. Such an identity is derived in this
section. The three-phase instantaneous power input is
From above equation, the abc phase currents and voltages are transformed
into their equivalent qd-axes currents and voltages as
Expanding the right-hand side of the equation gives the power input in dqo
variables:
The model development has so far kept the d and q axes stationary with
respect to the stator. These axes or frames are known as reference frames. A
generalized treatment where the speed of the reference frames is arbitrary is
derived in the next section. The input power given be equation (5.98)
22
remains valid for all occasions, provided that the voltages and currents
correspond to the frames under consideration.
2.5 Generalized Model in Arbitrary Reference Frames
Reference frames are very much like observer platforms. in that each
of the platforms gives a unique view of the system at hand as well as a
dramatic simplification of the system equations. For example, consider that.
for the purposes of control, it is desirable to have the system variables as dc
quantities, although the actual variables are sinusoidal. This could be
accomplished by having a reference frame revolving at the same angular
speed as that of the sinusoidal variable. As the reference frames are moving
at an angular speed equal to the angular frequency of the sinusoidal supply,
say, then the differential speed between them is reduced to zero, resulting in
the sinusoid being perceived as a de signal from the reference frames.
Th1en. by moving to that plane. it becomes easier to develop a small-signal
the sinusoid being perceived as a de signal from the reference frames.
Th1en. by moving to that plane. it becomes easier to develop a small-signal
equation out of a nonlinear equation, as the quiescent or operating point is
described only by dc values; this then leads to the linearized system around
an operating ·point. Now, it is easier to synthesize a compensator for the
system by using standard linear control-system techniques. Likewise, the
independent rotor field position determines the induced emf and affects the
dynamic system equations of both the wound-rotor and permanent-magnet
synchronous machines. Therefore, looking at the entire system from the
rotor, i.e., rotating reference frames, the system inductance matrix becomes
independent of rotor position, thus leading to the simplification and
compactness of the system equations. Such advantages are many from using
reference frames. Instead of deriving the transformations for each and every
23
particular reference frame, it is advantageous to derive the general
transformation 'for an arbitrary rotating reference frame. Then any particular
reference frame model can be derived by substituting the appropriate frame
speed and position in the generalized reference model.
Reference frames rotating at an arbitrary speed are hereafter called
arbitrary reference frames. Other reference frames are particular cases of
these arbitrary reference frames. The relationship between the stationary
reference frames denoted by d and q axes and the arbitrary reference frames
C C
denoted by d and q axes are shown in Figure 2.5.1. From now on, the
three-phase machine is assumed to have balanced windings and balanced
inputs, thus making the zero-sequence components be zero and eliminating
the zero-sequence equations from further consideration. Note that the zero-
sequence equations have to be included only for unbalanced operation of the
motor, a situation common with a fault in the machine or converter.
24
Assuming that the windings have equal number of turns on both of the
reference frames, the arbitrary reference froame currents are resolved on the
d and q axes to find the currents in the stationary reference frames. The
relationships between the currents are written as
Where
and
The speed of the arbitrary reference frames is
c = c
Similarly, the fictitious rotor currents are transformed into arbitrary frames
by using tc, and they are written as
where
25
Where
Where
r = r
Where ωr = θr
r is the rotor speed in electrical radians/sec. The relationship between the
arbitrary reference frame variables and the a, b, and c variables is derived by
using
26
where [0] is a 1 x 2 null vector. Note that the zero-sequence currents remain
unchanged in the arbitrary reference frames. This transformation is valid for
currents, voltages, and flux-linkages for both the stator and the rotor.
Particular cases of the reference frames are derived in a later section. The
next section contains the derivation of the electromagnetic torque in terms of
the current variables in the arbitrary reference frames.
27
where the vectors and matrices are identified by observation.
Premultiplying the equation by the transpose of the current vector gives the
instantaneous input power as,
where the [R] matrix consists of resistive elements, the [L] matrix
consists of the coefficients of the derivative operator p, the [G] matrix has
elements that are the coefficients of the electrical rotor speed r and [F] is
the frame matrix in terms of the coefficients of the reference frame speed,
c' The term it [R] i gives stator and rotor resistive losses. The term i t [F] ci
is the reference frame power, and upon expansion is found to be identically
equal to zero, as it should be, because there cannot be a power associated
with a fictitious element introduced for the sake of simplifying the model
and analysis. The term it [L] pi denotes the rate of change of stored magnetic
energy. Therefore, what is left of the power component must be equal to the
air gap power, given by the term i t [G] ri. From the fundamentals, it is
known that the air gap power has to be associated with the rotor speed. The
air gap power is the product of the mechanical rotor speed and air gap or
electromagnetic torque. Hence air gap torque, T e, is derived from the terms
involving the rotor speed, m in mechanical rad/sec, as
mTe = Pa = it[G] i x r
Substituting for r in terms of Wm leads to electromagnetic torque as
28
The factor 3/2 is introduced into the right-hand side of equation from the
power-equivalence condition between the three-phase and two-phase
induction motors. The next section considers the frequently used models in
various reference frames and their derivation from the generalized induction-
motor model in arbitrary reference frames.
29
The zero-sequience flux linkages are
Substituting from the defined flux-linkages into the voltage equation yields
Similarly, the stator d axis voltage, the d and q axes rotor voltages, and the
zero-sequence voltage equations are derived as
30
Where b is the base frequency in rad/sec. Similarly the other modified flux
linkages are written as
Substituting the flux linkages in terms of the modified flux linkages yields
The rotor currents can be substituted in terms of the stator currents and stator
flux linkages from the basic definitions of the flux linkages. From equation ,
Hence,
Similarly,
31
The electromagnetic torque can be expressed in only rotor variables and in
many other forms.
Where Vb3 and I b3 are three-phase base voltage and current respectively.
Selecting the base quantities in dq frames denoted by Vb and Ib to be equal to
the peak value of the phase voltage and current in abc vrames, we get
Vb = 2vb3
I b = 2Ib3
Hence, the base power is defined as
32
Substituting for base voltage in terms of base current, Ib, and base
impedance, Zb , as follows,
Vb = I bZb
33
from which the normalized electromagnetic torque is obtained as
where
34
to the equation 2.26. A is a space vector associated with scalar quantities Aa,
Ab, and A c. The vector components along the real axis (axis‘d’) and on the
imaginary axis (axis ‘q’) are given in equation (2.27)
……. (2.26)
..(2.27)
In practical calculations, the space vectors are represented either by
2*1 matrices or by complex quantities. Using matrix notation equation 2.27
becomes equation 2.28 while equation 2.29 represents the complex approach
to space vector model.
..(2.28)
…(2.29)
The transformation of the set of the three scalar variables into a space vector
is equivalent to a transformation from a three phase system to a two phase
system. The inverse transformation can be calculated based on the property
that the algebraic sum of the three scalar values is always null. This property
is shared by all the electromagnetic quantities related to individual phases
(current, voltages, and magnetic fluxes) if the power supply generates
symmetric voltages and the load is symmetric and Y- connected.
35
Aa + Ab + Ac = 0 ….. (2.30)
Combining 2.30 with 2.27, the system 2.31 is generated from which 2.32 is
derived. The system 2.32 describes the inverse transformation of a space
vector into the corresponding set of three scalar phase quantities.
.. (2.31)
… (2.32)
36
2.9.1 Space vector model of a three phase induction motor:
The space vector model of
the induction motor is the lumped-
parameter model with the largest
use in the study and design of
electrical drive applications. The
induction motor space vector
model is derived from the basic
electrical equations describing
each of the stator winding and
rotor winding. The stator 2.9.1.1 the fixed stator reference frame and the
winding equations are given in general mobile θreference frame
2.33 while where uas, ubs, and ucs are the phase voltages, ias, ibs, and ics are the
phase currents, while Ψas, Ψbs, and Ψcs are the phase magnetic fluxes.
…. (2.33)
The associated space vectors (expressed as complex numbers) are
obtained by multiplying the second equation in 2.33 with єand the third
2,
equation by є after which all the three equations are added together. The
conversion of the three scalar quantities into one space equation is given in
the equation 2.34 and 2.35.
37
…(2.34)
…(2.35)
Different reference frames (still or rotating) can be used to calculate the
coordinates of the electromagnetic space vector.
Any rotating reference frame is defined by the electrical angle
function θ(t) that indicates the relative position to the still reference frame.
Alternatively, it can be defined by the electrical rotation speed ωe(t) and the
initial electrical angle .For a general rotating frame the equations (2.35) are
transformed into (2.36). The fourth equation in 2.35 can be rewritten as 2.37.
jθ
Equation 2.38 is eventually obtained by dividing 2.36 with e .
… (2.36)
…(2.37)
38
A similar complex equation describes the rotor circuit with the
difference that the reference frame rotation speed relative to the rotor ωe –
ωer instead of ωe (ωer is te electrical rotor angular speed). Moreover, the
rotor voltage is always zero for the squirrel cage induction motor.
…(2.38)
The individual phase fluxes that are used to calculate the magnetic
flux vectors are each composed of six components. The flux components are
generated by the electromagnetic interaction between the three rotor
windings and the three stator windings.
..(2.39)
In the equation above each flux component is identified by four
indicies: the first two indicates the winding where the magnetic flux is
measured while the last two indicates the winding that generates it, for
instances Ψsarb is the flux generated into stator winding ‘a’ by the rotor
winding ‘b’.
The induction motor equations formulated for a reference frame
defined by the angle θ(t) and the rotation speed ω(t), are:
39
…(2.40)
…….. (2.41)
40
… (2.42)
…(2.43)
The referred rotor flux can be expressed as a function of the stator current
and the referred rotor current vector 2.44
.. (2.44)
The inductance lms, lmr, and lmsr are always related by equation 2.45. The
relationship allows the rewriting the equation 2.44 as 2.46 and 2.47.
… (2.45)
..(2.46)
..(2.47)
The significance of the symbols in the previous equations is:
The simplified induction motor space vector equations can be written as:
41
… (2.48)
This model will be used in the neural induction motor control strategy
developed in this project.
42
stator power can be calculated as indicated by 2.50. The calculation can be
performed in any reference frame defined by the time function θ(t).
… (2.49)
Therefore,
..(2.50)
Where:
.(2.51)
The equations 2.52 are obtained by substituting general equations 2.48
into 2.50. Thus the three power components are calculated according to 2.53.
…(2.52)
..(2.53)
43
The imaginary number j in the expression of the mechanical power
component PM can be eliminated using the general algebraic property (2.54)
..(2.54)
The two components of the imaginary part in 2.54 can be rewritten as
in 2.55 so that the mechanical power equation becomes 2.56
(2.55)
(2.56)
Based on the mathematical property 2.57 equation 2.56 is further
transformed into 2.58.
(2.57)
(2.58)
Therefore, the motor torque may be expressed by 2.59 it is seen that the
motor torque depends only on the rotor current vector and on the stator
current vector.
.. (2.59)
Alternatively, the torque can be expressed as a equivalent function of the
stator magnetic flux and or the rotor magnetic flux as shown in 2.54 where δ
is the angle between the stator flux and the rotor flux.
44
.. (2.60)
Relations 2.59 and 2.60 directly or indirectly underlie all induction motor
control strategies.
45
Chapter 3
The sensorless control scheme
3.1 Basic block diagram for the control scheme:
The proposed motor control strategy uses the classical sensorless
drive system structure with the motor supplied by a VSI-PWM inverter
which is controlled by a digital circuit based only on the stator current
feedback information. The predictive current control method uses an
…(3.2)
46
The complete sensorless induction motor control scheme includes a
speed controller, a current controller and a conversion block that interfaces
the two controllers. The block diagram is as shown in Fig 3.1. In the control
strategy a 3-phase squirrel cage induction motor fed by a VSI-PWM inverter
is taken and the control factor stator current is taken in the analog form and
converted to digital form by the A/D conversion block, now these converted
quantities are fed to the current controller and speed controller as shown in
Fig 3.1. The inputs to the speed controller block are the reference angular
frequency and the angular slip speed. These quantities are then converted as
per the input from the A/D converter and are transferred to the current
controller block through the conversion block which acts as the interface
between the current controller and speed controller blocks as shown in Fig.
3.1. As no sensors are used so the speed estimation is done by mathematical
equations which are developed based on the state space vector model of the
3-phase induction motor.
A VHDL model of three phase induction motor has been created
using the mathematical space vector model of the motor. In the VHDL code
given in the appendices 1, the motor model is entity having two input ports
(the stator voltage and load torque) and two output port(the stator current
and rotor angular frequency). All data regarding the motor operation during
the simulation is stored in an output ASCII file (motor.txt). The file contains
numerical data in matrices format. Each line in the matrix contains the set of
quantities that characterize the motor operation at a certain moment: current,
voltage, speed and torque.
The design and simulation of the motor controller is carried out using
two main software resources Xilinx ISE 7.1 and modelsim which are the
sophisticated tools for the design, simulation and testing of FPGA
47
implemented circuits. The VHDL description of the complete motor
controller includes the current control strategy and the sensorless speed
control algorithm. The model has been developed using a hierarchical
approach and contains four tiers that consists of specialized logic block. The
VHDL code related to these blocks utilizes generic parameters to define the
size of the register, adders, subtractors, buses and other elements involved,
this allows recalling of the controller hardware structure according to the
calculation precision imposed by the available types of FPGA circuits.
48
circuitry contains the four tiers 0, 1, 2, and 3. Each of the four tiers performs
specific tasks:
Tier1 caries out the algebraic calculations required by the control algorithm
and controls the operation of A/D converters that provides information on
the motor currents. It determines the reference current space vector by
multiplying the unit space vector generated by tier 0 with the amplitude of
reference stator current. It also calculates the vectors Vni and VΔinvolved in
the current control algorithm and in the online inductance estimation
process.
Tier2 contains the neural network that generates the PWM switching pattern
based on the space vectors Is and Vni. The angle calculation sub network,
which is a part of the complex neural network, is involved in the online
inductance estimation algorithm. It also calculates the motor slip angle
αequivalent that is used by tier 3.
Tier3 generates the reference stator angular frequency and the reference
stator current amplitude using the external reference rotor speed and the
motor slip angle as input information.
49
3.2 Functions of tier1:
Following are some of the important functions performed by the tier1:
Controls the operation of the two A/D converters connected to hall
sensors that measure the stator currents of the motor.
It uses the digital output from the A/D converters to calculate the
stator current space vectors.
Determines the derivative of the current space vector and uses this
information to calculate the non-inductive space vector Vni .
Calculates the space vector Va = u(k) - Vni(k-1) which is used by tier2
to estimate the inductance in equivalent R-L-e circuit.
Performs adjustment of the numerical values supplied to the neural
network located in tier2 so that the network operation speed is
maximized.
50
same power of two, the adapter amplifies the module of the vector but leaves
the vector argument unchanged. The VHDL code for the adapter block is
given in the appendices 1. The VHDL model of the adapter has two main
input ports inbusa and inbusb (the initial two coordinates) and two main
outputs outbusa and outbusb as shown in code for adapter in appendices 1.
The generic parameter n defines the width of the input and output buses. It
has to be set in accordance with the width of the VHDL signals to which it is
connected. All the signals in this tier have correlated widths that are
primarily determined by a generic parameters n which determines the width
of the buses i a and ib . The additional input ld triggers the input process,
while ready signals the moment when the process is finished. Each step of
the process is synchronized by the clock signal clk. The method to determine
the end of the process is to test the most significant two bits in each of the
two partial results if any of the two pairs contains different bits then the
process must stop to avoid an overflow that would change the sign of at least
one of the coordinates. The process must also be stopped if all the bits are
zero at the same time, this happens when both input coordinates are
simultaneously zero which would cause an infinite shifting process.
The architecture of the adapter contains two VHDL processes: The
first shifts the two input values in a synchronized manner. The second
verifies the existence of nonzero bits and communicated the result through
the internal signal not_all_zero.
51
3.2.1.1 The RTL logic schematic of the adapter block
52
interconnects allows the logic blocks of an FPGA to be interconnected as
needed by the system designer, somewhat like a one-chip programmable
breadboard. These logic blocks and interconnects can be programmed after
the manufacturing process by the customer/designer (hence the term "field
programmable", i.e. programmable in the field) so that the FPGA can
perform whatever logical function is needed. FPGAs are generally slower
than their application-specific integrated circuit (ASIC) counterparts, can't
handle as complex a design, and draw more power. However, they have
several advantages such as a shorter time to market, ability to re-program in
the field to fix bugs, and lower non-recurring engineering costs. Vendors can
sell cheaper, less flexible versions of their FPGAs which cannot be modified
after the design is committed. The development of these designs is made on
regular FPGAs and then migrated into a fixed version that more resembles
an ASIC. Complex programmable logic devices, or CPLDs, are another
alternative.
To define the behavior of the FPGA the user provides a hardware
description language (HDL) or a schematic design. Common HDLs are
VHDL and Verilog. Then, using an electronic design automation tool, a
technology-mapped netlist is generated. The netlist can then be fitted to the
actual FPGA architecture using a process called place-and-route, usually
performed by the FPGA company proprietary place-and-route software. The
user will validate the map, place and route results via timing analysis,
simulation, and other verification methodologies. Once the design and
validation process is complete, the binary file generated (also using the
FPGA company's proprietary software) is used to reconfigure the FPGA.
53
3.3.1 FPGA design and programming:
In an attempt to reduce the complexity of designing in HDLs, which
have been compared to the equivalent of assembly languages, there are
moves to raise the abstraction level of the design. Companies such as
Cadence, Synopsys and Celoxica are promoting SystemC as a way to
combine high level languages with concurrency models to allow faster
design cycles for FPGAs than is possible using traditional HDLs.
Approaches based on standard C or C++ (with libraries or other extensions
allowing parallel programming) are found in the Catapult C tools from
Mentor Graphics, and in the Impulse C tools from Impulse Accelerated
Technologies. Annapolis Micro Systems, Inc.'s CoreFire Design Suite and
National Instruments LabVIEW FPGA provide a graphical dataflow
approach to high-level design entry. Languages such as SystemVerilog,
SystemVHDL, and Handel-C (from Celoxica) seek to accomplish the same
goal, but are aimed at making existing hardware engineers more productive
versus making FPGAs more accessible to existing software engineers. There
is more information on C to HDL and Flow to HDL on their respective
pages. To simplify the design of complex systems in FPGAs, there exist
libraries of predefined complex functions and circuits that have been tested
and optimized to speed up the design process. These predefined circuits are
commonly called IP cores, and are available from FPGA vendors and third-
party IP suppliers (rarely free and typically released under proprietary
licenses). Other predefined circuits are available from developer
communities such as OpenCores (typically "free", and released under the
GPL, BSD or similar license), and other sources. In a typical design flow, an
FPGA application developer will simulate the design at multiple stages
throughout the design process. Initially the RTL (register transfer level)
54
description in VHDL or Verilog is simulated by creating test benches to
simulate the system and observe results. Then, after the synthesis engine has
mapped the design to a netlist, the netlist is translated to a gate level
description where simulation is repeated to confirm the synthesis proceeded
without errors. Finally the design is laid out in the FPGA at which point
propagation delays can be added and the simulation run again with these
values back-annotated onto the netlist.
55
4. Conclusion
56
5. APPENDICES 1
library IEEE;
use STD.TEXTIO.all;
use IEEE.math_complex.all;
use IEEE.math_real.all;
use IEEE.numeric_std.all;
use IEEE.std_logic_1164.all;
use IEEE.std_logic_textio.all;
entity motor is
port(
us : in complex;
Tload : in real;
ist : out complex;
omegar : out real
);
end motor;
57
constant d_space: string :=" ";
BEGIN
if next_step=1 then
write (my_line,us.re);
write (my_line,d_space);
write (my_line,us.im);
write (my_line,d_space);
write (my_line,ist1.re);
write (my_line,d_space);
write (my_line,ist1.im);
write (my_line,d_space);
write (my_line,ir1.re);
write (my_line,d_space);
write (my_line,ir1.im);
write (my_line,d_space);
write (my_line,T);
write (my_line,d_space);
write (my_line,omegar1);
writeline (outf,my_line);
end if;
ist1:=ist2;
ir1:=ir2;
Fist1:=Fist2;
Fir1:=Fir2;
omegar1:=omegar2;
Fist2:= Fist1 + (us-Rs*ist1)*dt;
Fir2:= Fir1+(omegar1*Fir1-Rr*ir1)*dt;
ist2:= (Lr*Fist2-Lm*Fir2)/(Lr*Ls-Lm*Lm);
ir2:= (Ls*Fir2-Lm*Fist2)/(Lr*Ls-Lm*Lm);
z:= ist1*conj(ir1);
T:= 3.0/4.0*p*Lm*(z.im);
omegar2:= omegar1 + (T- Tload)/Jr;
if next_step<1000 then
next_step<=next_step+1 AFTER deltat;
else
next_step<=1 AFTER deltat;
end if;
ist<=ist1;
omegar<=omegar1;
end process;
58
end arch_motor;
library IEEE;
use IEEE.STD_LOGIC_1164.ALL;
use IEEE.STD_LOGIC_ARITH.ALL;
use IEEE.STD_LOGIC_UNSIGNED.ALL;
entity adapter is
generic (n: integer :=20);
port(
inbusa : in std_logic_vector(n-1 downto 0);
inbusb : in std_logic_vector(n-1 downto 0);
outbusa : out std_logic_vector(n-1 downto 0);
outbusb : out std_logic_vector(n-1 downto 0);
clk: in std_logic;
ld: in std_logic;
ready: out std_logic
);
end adapter;
59
elsif (int_busa(n-1) = int_busa(n-2)) and (int_busa(n-1) =
int_busa(n-2)) and (not_all_zero = '1') then
int_busa <= int_busa(n-1) & int_busa(n-3 downto 0) & '0';
int_busb <= int_busb(n-1) & int_busb(n-3 downto 0) & '0';
else
ready <= '1';
end if;
end if;
end process;
process (int_busa, int_busb)
variable x: std_logic;
begin
x:= '0';
for i in 0 to n-1 loop
x:= x or int_busa(i);
x:= x or int_busb(i);
end loop;
not_all_zero <= x;
end process;
outbusa<= int_busa;
outbusb<= int_busb;
end adapter_arch;
60
6. APPENDICES 2
VHDL
(Very high scale integrated circuit Hardware Description
Language)
WHAT IS VHDL?
VHDL is a language for describing digital electronic systems. It arose
out of the United States Government’s Very High-Speed Integrated Circuits
(VHSIC) program, initiated in 1980. In the course of this program, it became
clear that there was a need for a standard language for describing the
structure and function of integrated circuits (ICs). Hence the VHSIC
Hardware Description Language (VHDL) was developed, and subsequently
adopted as a standard by the Institute of Electrical and Electronic Engineers
(IEEE) in the US.
VHDL is designed to fill a number of needs in the design process.
• Firstly, it allows description of the structure of a design that is how it
is decomposed into sub-designs, and how those sub-designs are
interconnected.
• Secondly, it allows the specification of the function of designs using
familiar programming language forms.
• Thirdly, as a result, it allows a design to be simulated before being
manufactured, so that designers can quickly compare alternatives and test for
correctness without the delay and expense of hardware prototyping.
Generally, a synthesis based design flow comprises of a number of stages
right from the Design Creation/Verification, Implementation, Programming
the device and finally the System Verification. The first step in this process
is the “HDL Design Source Entry” wherein you enter your HDL code using
a text editor or a context-sensitive HDL editor. We will glance through the
61
other steps later, and right now concentrate on writing efficient and
synthesizable VHDL design descriptions.
VHDL TERMS
Entity:
An entity is the most basic building block in a design. The entity is a module
which may be used as a component in a design, or which may be the top-
level module of the design. Entities contain the input and output definitions
of the design. In VHDL designs that contain a hierarchy of lower-level
circuits, the entity functions very much like a block symbol on a schematic.
An entity usually has one or more ports, which are analogous to the pins on
a schematic symbol. It also has a mode that defines the direction and type of
ports.
Here is a simple example of an entity:
Entity mux is
port ( a, b, c, d : in bit;
s0, s1 : in bit;
x : out bit);
end mux;
The keyword entity specifies the start of an entity statement. The name of
the entity is mux. This entity has seven signals in the port clause; six of them
are of input type and one of output type. The data type of the i/p and o/p port
here is bit. The different modes that define direction are in, out, inout, or
buffer.
Architecture:-
The architecture is the actual description of the design. If the entity is
a functional block symbol on a schematic, then architecture describes what's
inside the block. It contains statements that model the behavior of the entity.
62
You can freeze the abstract entity which gives the list of the i/o ports and
later on choose any architecture that fits in to the entity holder. Architecture
consists of two pieces: the architecture declaration section and the
architecture body. The declaration section of the architecture is the area
between the keyword architecture and the keyword begin. Here the objects
that are local to the architecture are declared. After the declaration section
comes the architecture body, which is where the behavior of the architecture
is specified.
There are three basic kinds of statements in VHDL:
• Declaration Statements
• Concurrent Statements
• Sequential Statements
Declaration Statements:
Declaration statements are used to define constants, types, objects and
subprograms that will be used in the design. Declarations can be made in
many different locations within a VHDL design, depending on the desired
scope of the item being declared.
Concurrent and Sequential Statements:
Concurrent and sequential statements are the fundamental building
blocks of a VHDL design description. These statements, which represent the
actual logic of a design, include such things as signal assignments,
component instantiations, and behavioral descriptions. There are important
distinctions to be made between concurrent and sequential statements, as
discussed below.
Concurrent Statements:
Concurrent statements are evaluated independently of the order in
which they appear. Concurrent statements define logic, typically in the form
63
of signal assignments (identified by the symbol <=) that include
combinational logic, which is inherently parallel. With concurrent
statements, values are carried on signals, which may be the actual input and
output ports of the design or local signals declared using a signal declaration
statement.
64
7. REFERENCES
65