File preview
Cyberphysical
System
Topics
in
an
Embedded
Control
Class
at
the
University
of
Michigan
Embedded Control Systems
• Background:
– University of Michigan and Ford Motor Company, 1998 (Dr. Ken Butts) – Control engineers and computer engineers: Why can’t they talk to each other?
J. S. Freudenberg and J. A. Cook, EECS Dept., University of Michigan, Ann Arbor MI 48109 jfr@umich.edu jeffcook@umich.edu
Embedded Control Lab: UM and ETH Lectures (I)
• • • • • • • • • Quantization Sampling Linear filtering Quadrature decoding DC motors Pulse Width Modulation (PWM) amplifiers Motor control: current (torque) vs. speed MPC5553 architecture. Peripherals: eTPUs, eMIOS, eDMA,… Haptic interfaces.
– virtual wall – virtual spring/mass/damper
4
UM Project: Adaptive Cruise Control
• Driving simulator • Bicycle model of vehicle • 6 vehicles interacting over CAN network • Lane centering • ACC algorithm: 3 states
– manual (sliding pot) – constant speed – constant distance
f() Trigger
enable Desired Speed ring angle) radians ual_torque (throttle) (s,n,psi,us)1..5 enable Force desired speed steering angle throttle delta (s,n,psi,us)1..5 s,n,psi,us u Steering Actuator Torque
• Characteristics:
– Interface with external environment – Real time critical – Hybrid behavior – Distributed, networked control
Force Steering Torque
Steering Torque
delta
s,n,psi,us
s,n,psi,us(s,n,psi,us)1...6
1 (s,n,psi,us)1...6
C_INPUTS
Steering Actuator Torque u
(s,n,psi,us)1..5
!
Cyber-Physical Systems
1
• Simulink/Stateflow modeling of hybrid dynamical systems • Numerical integration.
C_ACC
P_CAR
C_OUTPUTS
7
10
Outcome: Two Courses
• UofMichigan: EECS 461, Embedded Control Systems
– 11 years as regular course – 150+ students/year – Student body: • EE and CE seniors and some grads • occasional grads from Mechanical, Civil, Aerospace, Biomedical, Naval Architecture and Marine Engineering
Haptic Interface
behavior sensor (taction and kinesthesia) position velocity force sensor (encoder)
Lectures (II)
• Networking:
– Control Area Network (CAN) protocol. – Bus utilization
Controller Block Diagram
Human
actuators (muscles)
Haptic Device CPU
algorithm (virtual environment)
force actuator (DC motor)
• Interrupt routines: timing and shared data • Software architecture
– – – – Round robin Round robin with interrupts Real time operating systems (RTOS) Multitasking
• ETH Zurich: Embedded Control Systems
– five years as an intensive two week block course – 33 students/year – Student body: • Mechanical Engineering Graduate Students
2
!
Cyber-Physical-Physiological System
5
• • • • •
Shared data: semaphores, priority inheritance, priority ceiling Real time computation. Rate monotonic scheduling. Rapid prototyping. Autocode generation. Model based embedded control software development PID control design
11
8
Industry Trends
Harvard Business Review, 2010:
Laboratory Overview
• MPC5553 Microcontroller (Freescale)
– Originally automotive control, now used in many applications
Laboratory Exercises
• Each lab exercise teaches
– a peripheral on the MPC5553 – a signals and systems concept – uses concepts (and code!) from the previous labs – Labs 1-7: program in C – Lab 8: autocode generation
%#!"
/+0%$$%$'12&".23'/&.233+%&"4'56'*&$'/78'
• Development Environment
– Debugger (P&E Micro) – Codewarrior C compiler (Freescale)
%!!"
$#!"
• Haptic Interface
– Force feedback system for human/computer interaction
• Rapid Prototyping Tools
2005 2009 2010
“GM's biggest engineering recruiting challenges are software and controls engineering”
Detroit Free Press, October 2012
3
– Matlab/Simulink/Stateflow, Real Time Workshop (The Mathworks) – RAppID Toolbox (Freescale)
• Real Time Operating System
– OSEKturbo RTOS (Freescale)
6
• • • • • • • •
Lab 1: Familiarization and digital I/O Lab 2: Quadrature decoding using the eTPU Lab 3: Queued A-D conversion Lab 4: Pulse Width Modulation and virtual worlds without time Lab 5: Interrupt timing and frequency analysis of PWM signals Lab 6: Virtual worlds with time. Lab 7: Controller Area Network (CAN) Lab 8: Rapid Prototyping
9
!"#$%&"!'
./00"12345" 6789:;"122<6"()$5" =9:>?8"122<6()$5" $!!" ./00"122<6"()$5"" ./00"122<6"(,+5"
#!"
!" "!!&!$" "!$&!%" "!%&!'" "!'&!(" "!(&!#" "!#&!)" "!)&!*" "!*&!+" "!+&!," "!,&$!" "$!&$$" "$$&$%" "$%&$'-" ()*$%+,)'-%*.'
72"*3'/&.233+%&"4'9:;;<'$%"
System
Topics
in
an
Embedded
Control
Class
at
the
University
of
Michigan
Embedded Control Systems
• Background:
– University of Michigan and Ford Motor Company, 1998 (Dr. Ken Butts) – Control engineers and computer engineers: Why can’t they talk to each other?
J. S. Freudenberg and J. A. Cook, EECS Dept., University of Michigan, Ann Arbor MI 48109 jfr@umich.edu jeffcook@umich.edu
Embedded Control Lab: UM and ETH Lectures (I)
• • • • • • • • • Quantization Sampling Linear filtering Quadrature decoding DC motors Pulse Width Modulation (PWM) amplifiers Motor control: current (torque) vs. speed MPC5553 architecture. Peripherals: eTPUs, eMIOS, eDMA,… Haptic interfaces.
– virtual wall – virtual spring/mass/damper
4
UM Project: Adaptive Cruise Control
• Driving simulator • Bicycle model of vehicle • 6 vehicles interacting over CAN network • Lane centering • ACC algorithm: 3 states
– manual (sliding pot) – constant speed – constant distance
f() Trigger
enable Desired Speed ring angle) radians ual_torque (throttle) (s,n,psi,us)1..5 enable Force desired speed steering angle throttle delta (s,n,psi,us)1..5 s,n,psi,us u Steering Actuator Torque
• Characteristics:
– Interface with external environment – Real time critical – Hybrid behavior – Distributed, networked control
Force Steering Torque
Steering Torque
delta
s,n,psi,us
s,n,psi,us(s,n,psi,us)1...6
1 (s,n,psi,us)1...6
C_INPUTS
Steering Actuator Torque u
(s,n,psi,us)1..5
!
Cyber-Physical Systems
1
• Simulink/Stateflow modeling of hybrid dynamical systems • Numerical integration.
C_ACC
P_CAR
C_OUTPUTS
7
10
Outcome: Two Courses
• UofMichigan: EECS 461, Embedded Control Systems
– 11 years as regular course – 150+ students/year – Student body: • EE and CE seniors and some grads • occasional grads from Mechanical, Civil, Aerospace, Biomedical, Naval Architecture and Marine Engineering
Haptic Interface
behavior sensor (taction and kinesthesia) position velocity force sensor (encoder)
Lectures (II)
• Networking:
– Control Area Network (CAN) protocol. – Bus utilization
Controller Block Diagram
Human
actuators (muscles)
Haptic Device CPU
algorithm (virtual environment)
force actuator (DC motor)
• Interrupt routines: timing and shared data • Software architecture
– – – – Round robin Round robin with interrupts Real time operating systems (RTOS) Multitasking
• ETH Zurich: Embedded Control Systems
– five years as an intensive two week block course – 33 students/year – Student body: • Mechanical Engineering Graduate Students
2
!
Cyber-Physical-Physiological System
5
• • • • •
Shared data: semaphores, priority inheritance, priority ceiling Real time computation. Rate monotonic scheduling. Rapid prototyping. Autocode generation. Model based embedded control software development PID control design
11
8
Industry Trends
Harvard Business Review, 2010:
Laboratory Overview
• MPC5553 Microcontroller (Freescale)
– Originally automotive control, now used in many applications
Laboratory Exercises
• Each lab exercise teaches
– a peripheral on the MPC5553 – a signals and systems concept – uses concepts (and code!) from the previous labs – Labs 1-7: program in C – Lab 8: autocode generation
%#!"
/+0%$$%$'12&".23'/&.233+%&"4'56'*&$'/78'
• Development Environment
– Debugger (P&E Micro) – Codewarrior C compiler (Freescale)
%!!"
$#!"
• Haptic Interface
– Force feedback system for human/computer interaction
• Rapid Prototyping Tools
2005 2009 2010
“GM's biggest engineering recruiting challenges are software and controls engineering”
Detroit Free Press, October 2012
3
– Matlab/Simulink/Stateflow, Real Time Workshop (The Mathworks) – RAppID Toolbox (Freescale)
• Real Time Operating System
– OSEKturbo RTOS (Freescale)
6
• • • • • • • •
Lab 1: Familiarization and digital I/O Lab 2: Quadrature decoding using the eTPU Lab 3: Queued A-D conversion Lab 4: Pulse Width Modulation and virtual worlds without time Lab 5: Interrupt timing and frequency analysis of PWM signals Lab 6: Virtual worlds with time. Lab 7: Controller Area Network (CAN) Lab 8: Rapid Prototyping
9
!"#$%&"!'
./00"12345" 6789:;"122<6"()$5" =9:>?8"122<6()$5" $!!" ./00"122<6"()$5"" ./00"122<6"(,+5"
#!"
!" "!!&!$" "!$&!%" "!%&!'" "!'&!(" "!(&!#" "!#&!)" "!)&!*" "!*&!+" "!+&!," "!,&$!" "$!&$$" "$$&$%" "$%&$'-" ()*$%+,)'-%*.'
72"*3'/&.233+%&"4'9:;;<'$%"