When it works well nobody notices!

bustlingdivisionElectronics - Devices

Nov 15, 2013 (3 years and 8 months ago)

107 views

Digital control systems
Control is a hidden technology:
When it works well nobody notices!
Espresso machine:1 or 2 loops (temperature,pressure).
Automobile:5 to 20 control loops (engine,climate,brakes,ra dio)
Mars rovers:10 to 20 control loops (navigation,speed contro l)
Aircraft:50 or more loops (flight control,servos,redundancy )
Process control:100 to 1000 control loops (levels,temperature,pressures)
And when it doesn’t the results can be catastrophic.
Saab aircraft crash:pilot/control system interaction
Chernobyl nuclear reactor:operation at an unstable condition
Roy Smith:ECE 147b 1:2
Discrete-time systems
Objective:Designing digital control systems.
These typically arise in one of two ways:
• The system we wish to control is digital.
For example:
− NYSE end of day prices;
− Internet traffic;
− Number of students in ECE 147b.
• The system is continuous and we are sampling it via an A/D board and actuating it via
a D/A board.
For example:
− Electromechanical systems (robots,motors,vehicles);
− Complex chemical production processes.
− Biological processes.
The measurements and the actuation are also quantized.This may or may not be a
significant issue in the control design.
Roy Smith:ECE 147b 1:1
Digital control systems
A few examples:
Roy Smith:ECE 147b 1:4
Digital control systems
Why digital?
Key aspects:
− Easily reprogrammed (cf.changing resistors/capacitors in an analog control circuit).
− Easier to implement complicated algorithms.
− Integration with remote systems and digital communication.
− More detailed user interface (terminal or web based).
− Cost is going down and speed is going up.
Why analog?
Some applications are still analog:
− Simple,mass produced systems (toaster,thermostat).
− Very high frequency control loops.
− Highly reliable simple control systems.
− On-chip integrated systems (e.g.electrostatic gyroscopes).
Roy Smith:ECE 147b 1:3
Components
Sampler:y(k) = y(t) |
t=kT
,k = 0,1,2,....T is the sampling period.
Continuous signal:
0
T
2T
3T
4T
5T
6T
-2
-1
0
1
2
3
4
Time: t
y(k)
y(t)
Discrete sequence:
0
1
2
3
4
5
6
-2
-1
0
1
2
3
4
Time index: k
y(k)
Roy Smith:ECE 147b 1:6
Digital control systems
Typical digital control system
P(s)
ZOH
C(z)


T
✒✑
✓✏
+









r(k)u(k)u(t)y(t)y(k)
Components:
− Plant:P(s),continuous time
− Controller:C(z),discrete-time
− Sampler (A/D board):y(k) = y(t) |
t=kT
for k = 0,1,2,...
− Zero-order-hold (D/A) board:u(t) = u(kT) for kT ≤ t < kT +T.
Roy Smith:ECE 147b 1:5
Consequences
ZOH


T



u(t)u(k)y(t)
Input signal:u(t)
0
T
2T
3T
4T
5T
6T
-2
-1
0
1
2
3
4
Time: t
y(k)
y(t)
Output signal:y(t)
0
T
2T
3T
4T
5T
6T
-2
-1
0
1
2
3
4
Time: t
u(k) u(t)
Roy Smith:ECE 147b 1:8
Components
Zero-order hold:u(t) = u(k),for kT ≤ t < kT +T.
Discrete sequence:
0
1
2
3
4
5
6
-2
-1
0
1
2
3
4
Time index: k
u(k)
Continuous signal:
0
T
2T
3T
4T
5T
6T
-2
-1
0
1
2
3
4
Time: t
u(k)
u(t)
Roy Smith:ECE 147b 1:7
Design Approaches
Objective:Design C(z)
P(s) C(s)
C(z)
P(z)
Approximation
of C(s) with C(z)
Model P(s), and
sample/hold as
P(z)
Continuous-time
design
Discrete-time
design
Roy Smith:ECE 147b 1:10
More consequences
Quantization
ZOH


T



u(t)u(k)y(t)
u(t)
y(t)
1 LSB
spacing
Potential error of ±1/2 LSB in the best case.
Example:12 bit A/D and D/A on a ±10 volt scale:1 LSB = 0.00488 volts.
Roy Smith:ECE 147b 1:9
Design Approaches
Approach:Model P(z) (equivalent to P(s) at samples),and design C(z).
P(s)
ZOH
C(z)


T
✒✑
✓✏
+









r(k)u(t)y(t)y(k)
P(z)
P(s)
ZOH


T




u(k)u(t)y(t)y(k)
=
P(z)


u(k)y(k)
Roy Smith:ECE 147b 1:12
Design Approaches
Approach:Design C(s) and choose C(z) to approximate C(s)
P(s)
ZOH
C(z)


T
✒✑
✓✏
+









r(k)u(k)y(k)
C(s)
C(s)


e(t)u(t)

ZOH
C(z)


T




e(t)e(k)u(k)u(t)
Roy Smith:ECE 147b 1:11
Experiments
Preview:Inverted pendulum experiment
Balance the pendulum,θ = 0,in the center of the track,p = 0.
Control is via a motor driven cart carrying the pendulum.
θ
p
Pendulum
Cart
Track
Roy Smith:ECE 147b 1:14
Design Approaches
Objective:Design C(z)
P(s) C(s)
C(z)
P(z)
Approximation
of C(s) with C(z)
Model P(s), and
sample/hold as
P(z)
Continuous-time
design
Discrete-time
design
Roy Smith:ECE 147b 1:13
Experiments
Preview:A successful design
Roy Smith:ECE 147b 1:16
Experiments
Preview:A successful design
0
0.5
1
1.5
2
2.5
3
3.5
4
- 0.02
0
0.02
0.04
0.06
Position (meters)
time (seconds)
Measured
Measured
Estimated
Estimated
0
0.5
1
1.5
2
2.5
3
3.5
4
0
0.02
0.04
0.06
0.08
0.1
Angle(radians)
time (seconds)
Roy Smith:ECE 147b 1:15