Uploaded by kodeeg

Selected electrical drive topics

advertisement
Selected electrical drive topics
April 2017, Gilze The Netherlands
DC Drives, encoderless FOC control of Drones,
Hybrid stepper motors and BLDC machines using StEmbed
Instructor:
Prof. Dr. ir. D.W.J. Pulle
- University Professor : RWTH-ISEA, Aachen Germany
- CEO EMsynergy, Sydney Australia
- Member of the Texas Instruments InstaSPIN™ development team
Duco W.J. Pulle
1
Details
• Reference Textbooks :
– Primary Textbook: Pulle D.W.J., Darnell P. and Veltman A. ‘Applied control of
Electrical Drives’, 1st edition, 2015 Springer
– Secondary Textbook: Veltman A., Pulle D.W. J. and De Doncker R.W.
'Fundamentals of Electrical Drives', 2nd edition, 2016 Springer
– Additional Textbook: De Doncker R.W., Pulle D.W.J. and Veltman A. 'Advanced
Electrical Drives', 1st edition, 2010 Springer
• Hardware and Software
– Software: Embed and Code Composer Studio (CCS version 6.2)
– Laptop with the above mentioned software
– Converters:
• Texas Instruments LaunchXL-069M module, with
8301 boost pack and 24V supply unit
•
Texas Instruments DRV 8301-HC module with F28069 ISO control board
• Texas Instruments DRV8312 module with F28069 ISO control board
– Motors: Anaheim salient PM motor, DC motor ( inside linear actuator), Drone
motor, Walkera helicopter motor and 2-phase hybrid stepper motor
– Session supported by:
– PowerPoint slides
– Embed project lab files
Duco W.J. Pulle
Outline
• Drive demonstrations using Embed
– Current control of a DC motor drive using a LaunchXL-boost converter
– Encoderless FOC control of a drone motor using InstaSPIN and
a LaunchXL-boost converter
– Encoderless FOC control of a salient PM machine using InstaSPIN and a
DRV-8312EMV converter
– Encoderless FOC control of a two-phase hybrid stepping motor using
InstaSPIN and a DRV-8312EMV converter
– Encoderless FOC control of a Walkera V450BD5 model helicopter using
InstaSPIN and a DRV-8301-HC converter
Duco W.J. Pulle
DC motor drive demo
Introduction
Experimental drive setup:
•
Texas Instruments LaunchXL with 8301
boostpack
•
12 V DC supply
•
Linear actuator with DC motor inside
DC motor parameters (measured with L-C-R
meter and Ohm meter) :
•
Armature resistance: 3.0 𝛀
•
Armature inductance: 838 𝝁𝑯
Aim:
•
Current control of a linear actuator using
StEmbed
Duco W.J. Pulle
4
DC motor drive demo
C2000 MCU
+
Tx
Rx
SIMO
SOMI
CLK
STE
Serial coms
(UART)
SPI
Serial coms
Timers
and PWM
Compare
Units
Capture
Unit
ADC
ADC channels
shown here may
not match those
actually in use
DC Bus
PWM1
PWM2
PWM3
PWM4
PWM5
PWM6
PWM1
PWM3
PWM5
PWM2
PWM4
PWM6
CAP/QEP
ADCIN0
ADCIN1
ADCIN2
ADCIN3
ADCIN4
ADCIN5
ADCIN6
DC motor
Shunt
resistor
ADCIN2
Phase
Voltage
Meas
ADCIN1
ADCIN3
Signal
Conditioning
Duco W.J. Pulle
ADCIN4
ADCIN5
5
DC motor drive demo
Overall representation of MCU based drive: demo_DCdrive_launchXLphCv1
•
•
Inputs to this module are:
–
per unit reference armature current
– 'speed_loop_on: activates FOC with speed control when on and FOC in torque mode when 'off'
– 'conv _on' : activates converter
– 'chan_sel' : selects diagnostic channels to be viewed: ch1-2 or ch3-4
Outputs are:
– per unit, DC bus voltage
– per unit, armature voltage
– per unit, armature current
What does the 'controller' module look like internally ?
Duco W.J. Pulle
6
DC motor drive demo
One level down into the 'controller'
Modules present are:
•
Dialog boxes: 'operation variables' and
'Converter variables'
•
Main motor control unit: triggered by the ADC
conversion unit, running at 15 kHz
•
100Hz unit: controls LEDS which show that
MCU is operating and current trip on/off.
Also executes all background task of the drive.
•
Diagnostic tool unit: used to look at 4 'test'
signals real time , 2x2.
User can place 'test' variables to desired
locations within 'main motor control unit' to
examine signals and set triggering.
next: what is the content of the dialog boxes?
Duco W.J. Pulle
7
DC motor drive demo
Operational Variables Dialog box: motivation for entries shown
•
•
•
•
•
•
•
FullscaleVoltage(V)= 48: value chosen should be higher then highest bus voltage and less then
twice the ADC full-scale voltage of 26.32 V.
FullscaleCurrent(A)=20: value higher then the higher then the highest expected current . Value
should be less then twice the ADC full-scale current of 33.0 A
Max_Duty_cycle_CC= 0.8: maximum value for linear operation (with SVM active) is 1.15. However
this converter makes use of shunt resistors for measuring the currents and this limits the duty
cycle as a minimum ‘on time’ of the lower switches is required for getting reliable current
samples
User current_ramp= 500: rate of armature current change
Currentcontroller_Kp(V/A)=3.14: Current controller gain set by armature inductance and sample
frequency
Currentcontroller_wi(rad/s)=2000: Current controller bandwidth set by armature resistance and
inductance
Current trip(A)=10: software current trip where converter shuts down
Duco W.J. Pulle
8
DC motor drive demo
Converter Variables Dialog box: motivation for entries shown
•
•
ADC_Fullscale_voltage(V)= 26.314: which corresponds with the LaunchXL-boost hardware setup
ADC_Fullscale_current(V)= 33.0: which corresponds with the LaunchXL-boost hardware setup
Duco W.J. Pulle
9
DC motor drive demo
Overall representation of 'main motor control' module
Modules present are:
•
‘Current controller', which
provides the modulation
reference values for the two half
bridges that control the motor
•
‘Shunt Select', that identifies
which of the two half-bridge
shunts are used as an input for
the current controller (value
represents the measured
armature current)
•
‘ADC-PWM’, which measure the
half-bridge currents and lowpass filtered converter voltages
•
'Current trip', which shuts down
converter if absolute user set
value is exceeded
next: one level into the ‘Drive Controller'
Duco W.J. Pulle
10
DC motor drive demo
Implementation of the drive controller
Details controller:
•
inputs: normalized reference current (iddn),measured current (imeas) and the DC bus
voltage (Vdcn)
•
outputs: modulation indices (nmr_ref), (nms_ref) used to drive the half-bridges connected
to terminals A and B repectively, of the boost module
•
'C-Ramp' controls rate of current change (user defined)
next: phase C+, running the drive
Duco W.J. Pulle
11
DC motor drive demo
Final step needed to achieve real time control: demo_DCdrive_launchXLphCv1_d
We need a '-d' version of the previous simulation that can run the 'xxx.out' file
Example
per unit armature voltage (blue) and armature current
Duco W.J. Pulle
12
Drone motor drive demo
Introduction
Experimental drive setup:
•
Texas Instruments LaunchXL with 8301
boostpack
•
12 V DC supply
•
EMax2213 motor
BLDC motor parameters (measured with L-C-R
meter and Ohm meter) :
•
Stator resistance: 0.1 𝛀
•
Stator inductance: 11.4 𝝁𝑯
•
PM flux: 0.95 mWb (measured with
InstaSPIN)
•
Pole pairs: 7
Aim:
•
Sensorless (encoderless) FOC and speed
control of a drone motor using StEmbed
with InstaSPIN
•
Stator resistance measurement prior to
startup
•
Measurement of torque and shaft speed
Duco W.J. Pulle
13
Drone motor drive demo
C2000 MCU
+
Tx
Rx
SIMO
SOMI
CLK
STE
Serial coms
(UART)
SPI
Serial coms
Timers
and PWM
Compare
Units
Capture
Unit
ADC
ADC channels
shown here may
not match those
actually in use
Drone
Motor
example
DC Bus
PWM1
PWM2
PWM3
PWM4
PWM5
PWM6
PWM1
PWM3
PWM5
PWM2
PWM4
PWM6
CAP/QEP
ADCIN0
ADCIN1
ADCIN2
ADCIN3
ADCIN4
ADCIN5
ADCIN6
Shunt
resistor
ADCIN2
Phase
Voltage
Meas
ADCIN1
ADCIN3
Signal
Conditioning
Duco W.J. Pulle
ADCIN4
ADCIN5
ADCIN6
14
Drone motor drive demo
Overall representation of MCU based drive: Drone_LaunchXLphCv1
•
•
Inputs to this module are:
–
per unit reference frequency, direct and quadrature values
– ‘speed_loop_on’ : activates FOC with speed control when ‘on’ and torque control when ‘off‘
– ‘encoderless_on’: use of FAST when ‘on’ and open loop current & frequency control when 'off‘
– ‘force_ang_on’: activates force angle function which simplifies motor start up
– ‘Rs_Recalb_on’: enables measurement of the stator resistance prior to startup
– ‘Enable_Rs_actual_on’: allows FASt to make use of the measured Rs value
– ‘conv _on’ : activates converter
– ‘chan_sel’ : selects diagnostic channels to be viewed: ch1-2 or ch3-4
Outputs are:
– per unit, DC bus voltage, flux, shaft speed and torque
– VR1, Vr2 the stator inductance and stator resistance value in use by FAST
– Rs_recalb: measured stator resistance, Ivec: vector current amplitude, CPU_act: percentage CPU time
What does the 'controller' module look like internally ?
Duco W.J. Pulle
15
Drone motor drive demo
One level down into the 'controller'
Modules present are:
•
Dialog boxes: 'operation variables' and
'Converter/FAST variables'
•
Main motor control unit: triggered by the ADC
conversion unit, running at 15 kHz
•
100Hz unit: controls LEDS which show that
MCU is operating and current trip on/off.
Also executes all background task of the drive.
•
Diagnostic tool unit: used to look at 4 'test'
signals real time , 2x2.
User can place 'test' variables to desired
locations within 'main motor control unit' to
examine signals and set triggering.
next: what is the content of the dialog boxes?
Duco W.J. Pulle
16
Drone motor drive demo
Operational Variables Dialog box: motivation for entries shown
•
•
•
•
•
•
•
FullscaleVoltage(V)= 24: value chosen should be higher then highest bus voltage and less then
twice the ADC full-scale voltage of 26.32 V (Boost XL module)
FullscaleCurrent(A)=20: value higher then the higher then the highest expected current . Value
should be less then twice the ADC full-scale current of 33.0 A (Boost XL module)
Max_Duty_cycle_CC= 0.8: maximum value for linear operation (with SVM active) is 1.15. However
this converter makes use of shunt resistors for measuring the currents and this limits the duty
cycle as a minimum ‘on time’ of the lower switches is required for getting reliable current
samples
User current_ramp= 100: rate of direct and quadrature reference current change
Currentcontroller_Kp(V/A)=0.04: Current controller gain set by stator inductance and sample
frequency
Currentcontroller_wi(rad/s)=2000: Current controller bandwidth set by stator resistance and
statorinductance
Current trip(A)=14: software current trip where converter shuts down
Duco W.J. Pulle
17
Drone motor drive demo
Operational Variables Dialog box: motivation for entries shown (continued)
•
•
•
•
•
•
User frequency ramp(Hz/s)= 4000: rate of frequency change of reference speed.
Speed controller limit =10: maximum speed controller quadrature current limit (absolute value)
Res_est_current A)=1.0: DC current value used to measure the stator resistance at startup
User current_ramp= 100: rate of direct and quadrature reference current change
Currentcontroller_Kp(V/A)=0.04: Current controller gain set by stator inductance and sample
frequency
Currentcontroller_wi(rad/s)=2000: Current controller bandwidth set by stator resistance and
stator inductance
Duco W.J. Pulle
18
Drone motor drive demo
Converter and FAST Variables Dialog box: motivation for entries shown
•
•
•
Voltage_filter(Hz) =364.69: value chosen must match the corner frequency of the converter
low-pass filters used to measure the voltages. The hardware corner frequency should
typically be chosen in a range set by the full-scale frequency value and the PWM frequency/10,
hence 400-3000 Hz in this case.
Speed filter pole(Hz) =50: corner frequency of a low-pass filter that filters the estimated shaft
speed. Value should be chosen 5-10 times the bandwidth of the speed controller.
Force_angle_freq (Hz)=0.5: The force-angle function assists with start-up and speeds up the
synchronizing process between estimated EMF and actual machine EMF vectors.
Function must be turned off when speed reversals are required.
Duco W.J. Pulle
19
Drone motor drive demo
Converter and FAST Variables Dialog box: motivation for entries shown
(continued)
•
•
•
•
•
•
•
•
•
Direction pole (Hz)= 6: a low-pass filter that filters the estimated EMF waveforms to determine
the rotational direction of the shaft.
Flux pole(Hz)= 100: a low-pass filter that filters the estimated flux.
Flux_est_hold_freq (Hz)= 0.15: this sets a frequency band -0.15 to 0.15 where the estimator
‘freezes’ the estimated flux value.
DC bus pole(Hz)=20: a low-pass filter that filters the measured per unit inverse DC bus
voltage value 𝟏 𝒖𝑫π‘ͺ.
ADC_offset pole (Hz)=1: a low-pass filter that is used to determine the ADC offsets. With a
setting of 1 sec, sufficient time should be allowed for the ADC offset routine to determine the
steady-state offset values
PWMFreq(Hz)=45000: PWM frequency required for the converter, set to 45 kHz.
Fsampling(Hz)=15000: Sampling frequency used by the current controller. The ratio between
the PWM frequency and the Sampling frequency must be an integer value. Presently this is 3.
Fest_Fsampling=1: variables set the sampling frequency used by the FAST estimator. With a
value of 1 the estimator frequency is set equal to the current controller value, which is the
preferred setting. In this case the estimator frequency will therefore be 15 kHz.
Fspeed_Fsampling=15: variables set the sampling frequency used by the speed controller.
With a value of 15 the sampling frequency is set to 1/15th of current controller value. In this
case the speed controller frequency will be 1 kHz.
Duco W.J. Pulle
20
Drone motor drive demo
Converter and FAST Variables Dialog box: motivation for entries
shown(continued)
•
•
•
•
•
•
•
•
Convergence factor=1.5: a factor which influences the time needed to synchronize the
estimated EMF vector with the actual EMF vector.
ADC_Fullscale _voltage(V)=26.314: value set by hardware (Boost XL in this case)). Its value
must be greater than the highest DC voltage.
ADC_Fullscale _current(A)=33.0: value set by hardware (Boost XL in this case). Its value must
be greater than the highest current of the motor.
Lq(H)=11.4e-6: quadrature axis inductance value of the machine, which in a non-salient PM
machine is simply the stator inductance Ls. Its value can be found by using an L-C-R meter or
estimated via InstaSPIN.
Ld(H)=11.4e-6: direct axis inductance value of the machine, which in a non-salient PM
machine is simply the stator inductance Ls.
Rs(Ohms)=0.1: Stator resistance of the machine. Its value should be the value measured
during Rs recalbration at startup. If Rs recalibration is NOT used, FAST will use this value and
this can lead to start up problems in the event that the used value is greater then the actual
resistance value (hence better to do Rs estimation at startup if possible)
PM_flux_est(Wb)=1.0e-3: the estimated PM flux value of the machine. Found either by motor
identification using InstaSPIN or by running the machine ‘open loop’ and estimating the flux
level on the basis of the observed peak filtered voltage and known shaft speed.
p=7: pole pair number of the machine which is either known, or must be experimentally found.
Duco W.J. Pulle
21
Drone motor drive demo
Overall representation of 'main motor control' module
Modules present are:
•
‘Drive controller', which
provides the modulation
reference values for the halfbridges that control the motor
•
‘Amp’ that calculates the current
vector amplitude
•
‘ADC-PWM’, which measures the
half-bridge currents and lowpass filtered converter voltages
•
'Current trip', which shuts down
converter if absolute user set
value is exceeded
next: one level into the ‘Drive Controller'
Duco W.J. Pulle
22
Drone motor drive demo
Implementation of the drive controller
Details controller:
•
Speed controller, provides
reference quadrature current
on the basis of the reference
shaft speed and FAST
generated measured speed
•
FOC controller generates the
modulation indices for the
converter based on the
measured currents and
direct/quadrature current
setpoints
•
InstaSPIN module, generates
the flux, angle, frequency
and torque of the machine
•
Rs_estimation module,
generates the excitation
needed to measure the stator
resistance at start up and
also measures the stator
resistance value
FOC controller
next: phase C+, running the drive
Duco W.J. Pulle
23
Drone motor drive demo
Final step needed to achieve real time control: Drone_LaunchXLphCv1_d
We need a '-d' version of the previous simulation that can run the 'xxx.out' file
Example
per unit armature voltage (blue) and armature current
Duco W.J. Pulle
24
Salient PM motor drive demo
Introduction
Experimental drive setup:
•
Texas Instruments DRV8312EMV unit with
F2806x ISO control board
•
24 V DC supply
•
Anaheim BLY341S-24V-3000 motor
Motor parameters (measured with L-C-R meter
and Ohm meter) :
•
Stator resistance: 0.12 𝛀
•
Stator inductance direct axis: 284 𝝁𝑯
•
Stator inductance quadrature axis: 320 𝝁𝑯
•
PM flux: 8.12 mWb (measured with
InstaSPIN)
•
Pole pairs: 4
Aim:
•
Sensorless (encoderless) FOC and speed
control of a salient PM motor using
StEmbed and InstaSPIN
•
Stator resistance measurement prior to
startup
•
Measurement of torque and shaft speed
Duco W.J. Pulle
25
Salient PM motor drive demo
Introduction
What types are available?
•
Classic ‘flux-weakening’ IPM machine:
–
–
–
•
‘Flux-enhancement ‘ IPM machine:
–
–
–
–
•
direct axis inductance 𝑳𝒅
LESS then quadrature axis inductance 𝑳𝒒
Use of expensive ‘rare earth’ magnets
Negative direct axis current required to
provide a positive torque contribution to the
electrodynamic torque ( hence PM fluxweakening)
direct axis inductance 𝑳𝒅 GREATER then
quadrature axis inductance 𝑳𝒒
Use of low cost ‘Ferrite’ magnets
Positive direct axis current required to
provide a positive torque contribution to the
electrodynamic torque ( hence PM fluxenhancement)
New machine range 1-30 kW being
developed by ABB referred to as: π‘Ίπ’šπ’π‘Ήπ‘΄πŸ
Salient issues:
–
Both require an efficient controller that
optimizes the currents for a given torque
reference value
Next: Current Controller for Salient PM
Duco W.J. Pulle
Reference: ABB Australia, 2014 IEE Aust Lecture Series
26
Salient PM motor drive demo
Current Controller for Salient PM
Basic machine equations:
πŸ‘
•
Torque equation: 𝑻𝒆 = (𝝍𝒇 π’Šπ’’ − πŸπŒπ’Šπ’… π’Šπ’’ )
•
Use of ‘Saliency factor’ : 𝝌 =
hence
πŸπ‘³π’…
𝝌 > 𝟎, 𝒇𝒐𝒓 𝒇𝒍𝒖𝒙 − π’˜π’†π’‚π’Œπ’†π’π’Šπ’π’ˆ π’Žπ’‚π’„π’‰π’Šπ’π’†π’”
𝟐
𝑳𝒒 −𝑳𝒅
Optimum drive condition : to maximize Torque per Amp ratio
Optimum
control point
non-salient machine: 𝝌 = 𝟎
salient machine: 𝝌 > 𝟎
Where 𝑻𝒆 is the reference torque value and π’Šπ’… , π’Šπ’’ are the required direct axis and
quadrature axis current values.
Duco W.J. Pulle
27
Salient PM motor drive demo
Overall representation of MCU based drive: Anaheim_FAST_8312phCv1
•
•
Inputs to this module are:
–
per unit reference frequency freq_n, amplitudes: id_n, iq_n and speed slider gains: Kpn, Kin
– 'speed_loop_on: activates FOC with speed control when ‘on’ and Torque control when ‘off’
– 'encoderless_on': uses angle estimate from FAST when 'on' and Current & frequency control when 'off'
– 'Force_ang_on': activates 'zero speed start' when 'on'
– 'conv _on' : activates converter
– ‘Rs_Recal’: activates the Rs measurement algorithm at start up
– 'chan_sel' : selects diagnostic channels to be viewed: ch1-2 or ch3-4
Outputs are:
– Per unit, DC bus voltage, PM flux, shaft speed and torque
– Two test variables : vr1, vr2 , that show the direct axis inductance and stator resistance values used by FAST
– Id_ref: the direct axis current value generated by the salient current controller
– Rs_Recal: the Rs value estimated prior to startup
What does the 'controller' module look like internally ?
Duco W.J. Pulle
28
Salient PM motor drive demo
One level down into the 'controller'
Modules present are:
•
Dialog boxes: 'operation variables' and
'Converter/FAST variables'
•
Main motor control unit: triggered by the ADC
conversion unit, running at 15 kHz
•
100Hz unit: controls LEDS which show that
MCU is operating and current trip on/off.
Also executes all background task of the drive.
•
Diagnostic tool unit: used to look at 4 'test'
signals real time , 2x2.
User can place 'test' variables to desired
locations within 'main motor control unit' to
examine signals and set triggering.
next: what is the content of the dialog boxes?
Duco W.J. Pulle
29
Salient PM motor drive demo
Operational Variables Dialog box: motivation for entries shown
•
•
•
•
•
•
FullscaleVoltage(V)= 35: value chosen should be higher than highest bus voltage and less
than twice the ADC full-scale voltage of 66.32 V (DRV8312EMV unit).
FullscaleCurrent(A)=10: value higher than the highest expected current . Value should be
less than twice the ADC full-scale current of 17.277 A (DRV8312EMV unit).
FullscaleFrequency(Hz)= 400: value set by highest expected electrical frequency, which is
determined by the largest expected shaft speed, typically the rated motor value.
Max_Duty_cycle_CC= 0.8: maximum value for linear operation (with SVM active) is 1.15.
Userfrequency Ramp(Hz/s)= 20000: value determines the rate of frequency change
User Current Ramp(A/s)= 100: value determines the rate of current change for the slider
inputs
Duco W.J. Pulle
30
Salient PM motor drive demo
Operational Variables Dialog box: motivation for entries shown (continued)
•
•
•
•
•
Current controller_Kp (V/A) =4.0: the upper limit gain is set by product of stator d-axis
inductance and controller sampling frequency, hence πŸπŸ–πŸ’ 𝝁𝑯 x 15 kHz=4.26. Typically a
value in the order of 25% of the maximum value is used for entry.
Current controller_wi (rad/s) =425: the upper limit bandwidth is set by ratio of stator
resistance and d-axis stator inductance , hence 𝟎. 𝟏𝟐/πŸπŸ–πŸ’ 𝝁𝑯=422.
Speed controller_limit (Nm)=0.25: value sets shaft torque limit. Shaft torque is
determined by π‘»π’Žπ’† = 𝟏. πŸ“ 𝐩 π’Šπ’’ (𝝍𝑷𝑴 −( 𝑳𝒒 -𝑳𝒅 )π’Šπ’… ) . The controller sets the required direct
and quadrature values based on the PM flux and saliency term: ( 𝑳𝒒 -𝑳𝒅 ).
Res_est_current A)=0.5: DC current value used to measure the stator resistance at
startup
Current trip (A) =8: value monitors the currents π’ŠπœΆ , π’Šπœ· and trips the converter when the
set value is exceeded.
Duco W.J. Pulle
31
Salient PM motor drive demo
Converter and FAST Variables Dialog box: motivation for entries shown
•
•
•
•
•
Voltage_filter(Hz) =714.4: value chosen must match the corner frequency of the DRV8312EMV
converter low-pass filters used to measure the voltages.
Speed filter pole(Hz) =50: corner frequency of a low-pass filter that filters the estimated shaft
speed. Value should be chosen 5-10 times the bandwidth of the speed controller.
Force_angle_freq (Hz)=0.5: The force-angle function assists with start-up and speeds up the
synchronizing process between estimated EMF and actual machine EMF vectors. Function
must be turned off when speed reversals are required.
Direction pole (Hz)= 6: a low-pass filter that filters the estimated EMF waveforms to determine
the rotational direction of the shaft.
Flux pole(Hz)= 100: a low-pass filter that filters the estimated flux.
Duco W.J. Pulle
32
Salient PM motor drive demo
Converter and FAST Variables Dialog box: motivation for entries
shown(continued)
•
•
•
•
•
•
•
•
•
•
Flux_est_hold_freq (Hz)= 0.2: this sets a frequency band -0.2 to 0.2 where the estimator
‘freezes’ the estimated flux value.
DC bus pole(Hz)=20: a low-pass filter that filters the measured per unit inverse DC bus
voltage value 𝟏 𝒖𝑫π‘ͺ.
ADC_offset pole (Hz)=1: a low-pass filter that is used to determine the ADC offsets.
PWMFreq(Hz)=30000: PWM frequency required for the converter, set to 30kHz.
Fsampling(Hz)=15000: Sampling frequency used by the current controller. The ratio between
the PWM frequency and the Sampling frequency must be an integer value. Presently this is 2,
Fest_Fsampling=1: variables set the sampling frequency used by the FAST estimator. With a
value of 1 the estimator frequency is set equal to the current controller value, which is the
preferred setting. In this case the estimator frequency will therefore be 15 kHz.
Fspeed_Fsampling=15: variables set the sampling frequency used by the speed controller.
With a value of 15 the sampling frequency is set to 1/15th of current controller value. In this
case the speed controller frequency will be 1 kHz.
Convergence factor=1.5: a factor which influence the time needed to synchronize the
estimated EMF vector with the actual EMF vector.
ADC_Fullscale _voltage(V)=66.32.314: value set by hardware (DRV8312 in this case).
ADC_Fullscale _current(A)=17.277: value set by hardware (DRV8312 in this case).
Duco W.J. Pulle
33
Salient PM motor drive demo
Converter and FAST Variables Dialog box: motivation for entries
shown(continued)
•
•
•
•
•
Lq(H)=320e-6: quadrature axis inductance value of the machine. Its value can be found by
using an L-C-R meter.
Ld(H)=284e-6: direct axis inductance value of the machine. Its value can be found by using an
L-C-R meter or estimated via InstaSPIN.
Rs(Ohms)=0.12: Stator resistance of the machine. Its value can be found by using the Rs
recalibration routine prior to startup.
PM_flux_est(Wb)=8.12e-3: the estimated PM flux value of the machine. Found by motor
identification using InstaSPIN.
p=4: pole pair number of the machine which is either known, or must be experimentally found.
Duco W.J. Pulle
34
Salient PM motor drive demo
Overall representation of 'main motor control' module
Modules present are:
•
'Drive controller', in this case a
d,q synchronous current
controller, speed controller and
FAST software encoder module
•
'ADC-PWM unit', which
measures the voltages from the
shunt resistors, conv. phases
and DC bus and controls the
three half bridges of the
converter
•
'Current trip', which shuts down
converter if absolute user set
value is exceeded
next: one level into the ‘Drive Controller'
Duco W.J. Pulle
35
Salient PM motor drive demo
One level into ‘Drive Controller’ module
Details :
•
FOC controller:
–
•
Speed controller:
–
•
Open loop
From FAST (ang)
InstaSPIN module that
generates:
–
–
–
–
–
•
provides the shaft
torque reference value
which is used by the
‘Salient controller’ that
generates the
direct/quadrature
current references for
the FOC controller
Angle selection:
–
–
•
provides the
modulation indices for
the converter
Inverse DC bus voltage
Estimate for flux angle
Estimate for flux
Estimate for speed
Estimate for torque
Rs estimation module
that generates:
–
Dc current and Rs
value prior to start-up
Duco W.J. Pulle
36
Salient PM motor drive demo
Final step needed to achieve real time control: Anaheim_FAST_8312phCv1_d
We need a '-d' version of the previous simulation that can run the 'xxx.out' file
Example
per unit π’ŠπœΆ , π’Šπœ· currents, with applied ‘hand’ load
Duco W.J. Pulle
37
Hybrid stepper motor drive demo
Introduction
Experimental drive setup:
•
Texas Instruments DRV8312EMV unit with
F2806x ISO control board
•
24 V DC supply
•
Fulling FL57STH5-2804AC-04 stepper motor
Motor parameters (measured with L-C-R meter
and Ohm meter) :
•
Stator resistance: 0.984 𝛀
•
Stator inductance direct axis: 2.86 m𝑯
•
Stator inductance quadrature axis: 2.0 m𝑯
•
PM flux: 6.2 mWb (measured with InstaSPIN)
•
Pole pairs: 50
Aim:
•
Sensorless (encoderless) FOC and speed
control of a hybrid PM stepper motor using
StEmbed and InstaSPIN
•
Stator resistance measurement prior to
startup
•
Measurement of torque and shaft speed
Duco W.J. Pulle
38
Hybrid stepper motor drive demo
Introduction
Motor concept:
•
Toothed rotor and stator
•
Axially oriented magnet
between two toothed rotor
sections
•
Rotor sections displaced by
1.8 degrees (200 steps)
•
Winding 1: consists of 4 pole
‘red’ windings
•
Winding 2: consists of 4 pole
‘black’ windings
•
Windings interconnected to
form a two-phase machine
with terminals A-B-C that are
connected to a three-phase
converter
•
‘Micro-stepping’ type
operation assumed with
sinusoidal currents
•
Operation identical to a 50
pole pair salient two- phase
synchronous PM machine
A
C
Next : How to connect a
2-phase motor to a 3-phase
converter
B
Duco W.J. Pulle
39
Hybrid stepper motor drive demo
C2000 MCU
+
Tx
Rx
Serial coms
(UART)
Timers
and PWM
Compare
Units
SPI
Serial coms
Capture
Unit
ADC
ADC channels
shown here may
not match those
actually in use
2-phase
Stepper
Motor
PWM1
PWM2
PWM3
PWM4
PWM5
PWM6
PWM1
SIMO
SOMI
CLK
STE
DC Bus
PWM3
PWM5
CAP/QEP
A
ADCIN0
ADCIN1
ADCIN2
ADCIN3
ADCIN4
ADCIN5
ADCIN6
PWM2
PWM4
C
PWM6
B
Shunt
resistor
ADCIN2
Phase
Voltage
Meas
ADCIN1
ADCIN3
Signal
Conditioning
Duco W.J. Pulle
ADCIN4
ADCIN5
ADCIN6
40
Hybrid stepper motor drive demo
How to connect a 2 phase motor to a three-phase converter
Use of ‘2-phase’ space
vector modulation :
•
inputs: m_alp (u1),
m_beta (u2)
•
Outputs: m_a (u1c),
m_b(u2c) and m_c (u3c)
m_alp
m_beta
m_a
m_b
m_C
SVM
2-ph module
Micro-stepping example:
•
inputs:
m_alp (red) , m_beta (blue)
•
Outputs:
m_a (red), m_b (blue), and m_c (green)
Duco W.J. Pulle
41
Hybrid stepper motor drive demo
Overall representation of MCU based drive : Stepper_FAST_8312phCv2
•
•
Inputs to this module are:
–
per unit reference frequency freq_n, amplitudes: id_n, iq_n and speed slider gains: Kpn, Kin
– 'speed_loop_on: activates FOC with speed control when ‘on’ and Torque control when ‘off’
– 'encoderless_on': uses angle estimate from FAST when 'on' and Current & frequency control when 'off'
– 'Force_ang_on': activates 'zero speed start' when 'on'
– 'conv _on' : activates converter
– ‘Rs_Recal’: activates the Rs measurement algorithm at start up
– 'chan_sel' : selects diagnostic channels to be viewed: ch1-2 or ch3-4
Outputs are:
– Per unit, DC bus voltage, PM flux, shaft speed and torque
– Two test variables : vr1, vr2 , that show the direct axis inductance and stator resistance values used by FAST
– Ivec: vector current amplitude
– Rs_Recal: the Rs value estimated prior to startup
What does the 'controller' module look like internally ?
Duco W.J. Pulle
42
Hybrid stepper motor drive demo
One level down into the 'controller'
Modules present are:
•
Dialog boxes: 'operation variables' and
'Converter/FAST variables'
•
Main motor control unit: triggered by the ADC
conversion unit, running at 15 kHz
•
100Hz unit: controls LEDS which show that
MCU is operating and current trip on/off.
Also executes all background task of the drive.
•
Diagnostic tool unit: used to look at 4 'test'
signals real time , 2x2.
User can place 'test' variables to desired
locations within 'main motor control unit' to
examine signals and set triggering.
next: what is the content of the dialog boxes?
Duco W.J. Pulle
43
Hybrid stepper motor drive demo
Operational Variables Dialog box: motivation for entries shown
•
•
•
•
•
•
•
FullscaleVoltage(V)= 35: value chosen should be higher than highest bus voltage and less than
twice the ADC full-scale voltage of 66.32 V (DRV8312EMV unit).
FullscaleCurrent(A)=10: value higher than the highest expected current . Value should be less
than twice the ADC full-scale current of 17.277 A (DRV8312EMV unit).
FullscaleFrequency(Hz)= 400: value set by highest expected electrical frequency, which is
determined by the largest expected shaft speed, typically the rated motor value.
Max_Duty_cycle_CC= 0.8: maximum value for linear operation (with SVM active) is 1.15.
Userfrequency Ramp(Hz/s)= 20000: value determines the rate of frequency change
User Current Ramp(A/s)= 100: value determines the rate of current change for the slider inputs
Rs_est_current(A)=0.5: current value used for stator resistance measurement prior to start-up
Duco W.J. Pulle
44
Hybrid stepper motor drive demo
Operational Variables Dialog box: motivation for entries shown (continued)
•
•
•
•
•
•
Userfrequency Ramp(Hz/s)= 20000: value determines the rate of frequency change (and
therefore speed change). With a full-scale frequency of 400 Hz , it would take
πŸ’πŸŽπŸŽ 𝟐𝟎𝟎𝟎𝟎 = 𝟐𝟎 π’Žπ’” to reach this value.
User Current Ramp(A/s)= 100: value determines the rate of current change (and
therefore torque change as the quadrature reference will be limited by this setting).
With a full-scale current of 20 A , it would take 𝟐𝟎 𝟏𝟎𝟎 = 𝟎. 𝟐 𝒔 to reach this value.
Current controller_Kp (V/A) =40: the upper limit gain is set by product of stator
inductance and controller sampling frequency, hence 2.68 π’Žπ‘― x 15 kHz=40.2 Typically a
value in the order of 25% of the maximum value is used for entry.
Current controller_wi (rad/s) =400: the upper limit bandwidth is set by ratio of stator
resistance and stator inductance , hence 𝟎. πŸ—πŸ–πŸ’/𝟐. πŸ”πŸ– π’Žπ‘―= 367.1
Speedcontroller_limit (A)=2.5: value set the quadrature current reference limit and
therefore the shaft torque limit. Shaft torque is determined by π‘»π’Žπ’† = 𝟏. πŸ“ 𝐩 π’Šπ’’ 𝝍𝑷𝑴 , hence
with π’Šπ’’ = 𝟐. πŸ“, PM flux 𝝍𝑷𝑴 =6.2 mWb, 𝒑 = πŸ“πŸŽ the torque will be limited to ±πŸ. πŸπŸ” π‘΅π’Ž.
Current trip (A) =8: value monitors the currents π’ŠπœΆ , π’Šπœ· and trips the converter when the
set value is exceeded.
Duco W.J. Pulle
45
Hybrid stepper motor drive demo
Converter and FAST Variables Dialog box: motivation for entries shown
•
•
•
Voltage_filter(Hz) =714.4: value chosen must match the corner frequency of the converter
low-pass filters used to measure the voltages. The hardware corner frequency should
typically should typically be chosen in a range set by the full-scale frequency value and the
PWM frequency/10, hence 400-3000 Hz in this case.
Speed filter pole(Hz) =50: corner frequency of a low-pass filter that filters the estimated shaft
speed. Value should be chosen 5-10 times the bandwidth of the speed controller.
Force_angle_freq (Hz)=0.8: The force-angle function assists with start-up and speeds up the
synchronizing process between estimated EMF and actual machine EMF vectors
Function must be turned off when speed reversals are required.
Duco W.J. Pulle
46
Hybrid stepper motor drive demo
Converter and FAST Variables Dialog box: motivation for entries
shown(continued)
•
•
•
•
•
•
•
•
•
•
•
Direction pole (Hz)= 6: a low-pass filter that filters the estimated EMF waveforms to determine
the rotational direction of the shaft
Flux pole(Hz)= 100: a low-pass filter that filters the estimated flux.
Flux_est_hold_freq (Hz)= 0.2: this sets a frequency band -0.2 to 0.2 where the estimator
‘freezes’ the estimated flux value.
DC bus pole(Hz)=20: a low-pass filter that filters the measured per unit inverse DC bus
voltage value 𝟏 𝒖𝑫π‘ͺ.
ADC_offset pole (Hz)=1: a low-pass filter that is used to determine the ADC offsets.
PWMFreq(Hz)=30000: PWM frequency required for the converter, set to 30kHz.
Fsampling(Hz)=15000: Sampling frequency used by the current controller. The ratio between
the PWM frequency and the Sampling frequency must be an integer value. Presently this is 2.
Fest_Fsampling=1: variables set the sampling frequency used by the FAST estimator. With a
value of 1 the estimator frequency is set equal to the current controller value, which is the
preferred setting. In this case the estimator frequency will therefore be 15 kHz.
Fspeed_Fsampling=15: variables set the sampling frequency used by the speed controller.
With a value of 15 the sampling frequency is set to 1/15th of current controller value. In this
case the speed controller frequency will be 1 kHz.
Convergence factor=1.5: a factor which influence the time needed to synchronize the
estimated EMF vector with the actual EMF vector.
ADC_Fullscale _voltage(V)=66.32: value set by hardware (DRV8312EVM) .
Duco W.J. Pulle
47
Hybrid stepper motor drive demo
Converter and FAST Variables Dialog box: motivation for entries
shown(continued)
•
•
•
•
•
•
ADC_Fullscale _current(A)=17.277: value set by hardware (DRV8312EVM).
Lq(H)= 2.0e-3: quadrature axis inductance value of the machine.
Ld(H)= 2.68e-3: direct axis inductance value of the machine.
It value can be found by using an L-C-R meter or estimated via InstaSPIN.
Rs(Ohms)=0.984: Stator resistance of the machine. Its value can be found using the Rs
recalibration routine prior to start up.
PM_flux_est(Wb)=6.2e-3: the estimated PM flux value of the machine.
p=50: pole pair number of the machine which is either known, or must be experimentally found.
Duco W.J. Pulle
48
Hybrid stepper motor drive demo
Overall representation of 'main motor control' module
Modules present are:
•
'Drive controller', in this case a
d,q synchronous current
controller, speed controller and
FAST software encoder module
•
'ADC-PWM unit', which
measures the voltages from the
shunt resistors, conv. phases
and DC bus and controls the
three half-bridges of the
converter
•
‘amp’ module that calculates the
current vector amplitude
•
'Current trip', which shuts down
converter if absolute user set
value is exceeded
next: one level into the ‘Drive Controller'
Duco W.J. Pulle
49
Hybrid stepper motor drive demo
Implementation of the
drive controller
Details controller:
•
inputs: normalized
reference frequency,
current amplitudes
and DC bus voltage as
well as measured
two-phase currents
and filtered voltages.
•
outputs: modulation
index, three-phase
and FAST variables
•
'C-Ramp' and 'FRamp' control rate of
current and frequency
change (user defined)
•
FAST software
encoder module, set
to operate at 15 kHz,
and active when
'estimator' on line :
state=3
•
Rs_estimation
module, estimates the
Rs value
FOC controller
next: One level into the ADC-PWM modules
Duco W.J. Pulle
50
Hybrid stepper motor drive demo
Changes to the ADC-PWM module for two –phase drives
Details :
•
inputs: m_a , m_b, m_c
•
Outputs: u_bus_n,
u_alp_n, u_beta_n,
i_alp_n and i_beta_n
m_a
m_b
m_C
u_bus_n
u_alp_n
u_beta_n
i_alp_n
i_beta_n
not used
ADC module
next: C+ implementation ?
Duco W.J. Pulle
51
Hybrid stepper motor drive demo
Final step needed to achieve real time control: Stepper_FAST_8312phCv2_d
We need a '-d' version of the previous simulation that can run the 'xxx.out' file
Example
per unit π’ŠπœΆ , π’Šπœ· currents, with ‘hand applied’ load
Duco W.J. Pulle
52
Model helicopter drive demo
Introduction
Experimental drive setup:
•
Texas Instruments DRV8301-HC unit
with F2806x ISO control board
•
11.1 V DC supply Li-Po Battery
•
Walkera V450BD5 model helicopter
Motor parameters (measured with L-C-R
meter, without motor lead) :
•
Stator resistance: 3.2 m𝛀
•
Stator inductance : 2.0 𝝁𝑯
•
PM flux: 0.55 mWb (measured with
InstaSPIN)
•
Pole pairs: 3
Aim:
•
Sensorless (encoderless) FOC
torque and speed control of the WKWS-28-007A PM motor using
StEmbed and InstaSPIN
•
Stator resistance measurement prior
to startup
•
Measurement of rotor torque and
rotor blade speed
Duco W.J. Pulle
53
Model helicopter drive demo
Overall representation of MCU based drive : Heli_8301phCv7
•
•
Inputs to this module are:
–
per unit reference frequency freq_n, amplitudes: id_n, iq_n and speed slider gains: Kpn, Kin
– 'speed_loop_on: activates FOC with speed control when ‘on’ and Torque control when ‘off’
– 'encoderless_on': uses angle estimate from FAST when 'on' and Current & frequency control when 'off'
– 'Force_ang_on': activates 'zero speed start' when 'on'
– 'conv _on' : activates converter
– ‘Rs_Recal’: activates the Rs measurement algorithm at start up
– 'chan_sel' : selects diagnostic channels to be viewed: ch1-2 or ch3-4
– ‘ext_spd_pot_on’: activates potentiometer on 8301 board for speed control
Outputs are:
– Per unit, DC bus voltage, PM flux, shaft speed and torque
– Two test variables : vr1, vr2 , that show the direct axis inductance and stator resistance values used by FAST
– Ivec: vector current amplitude, Rs_Recal: the Rs value estimated prior to start
– Pot_sp_ref: the per unit shaft speed set by external speed potentiometer
Duco W.J. Pulle
54
Model helicopter drive demo
Final step needed to achieve real time control: Heli_8301phCv7_d
We need a '-d' version of the previous simulation that can run the 'xxx.out' file
Example
per unit π’ŠπœΆ , π’Šπœ· currents rotor blade torque (Nm) and speed (krpm)
Duco W.J. Pulle
55
Model helicopter drive demo
Current measurements: existing and new drive
Use of Tektronix DC current probe to measure phase current under partial load
(helicopter-ground operation)
Standard drive
Operation with
InstaSPIN and FOC
Example
drive under speed control
Duco W.J. Pulle
56
Download