embedded systems exercise session 4 power interface circuits
TRANSCRIPT
![Page 1: Embedded systems Exercise session 4 Power interface circuits](https://reader034.vdocuments.us/reader034/viewer/2022051204/62782aa0b038ea522c143183/html5/thumbnails/1.jpg)
Embedded systemsExercise session 4
Power interface circuits
![Page 2: Embedded systems Exercise session 4 Power interface circuits](https://reader034.vdocuments.us/reader034/viewer/2022051204/62782aa0b038ea522c143183/html5/thumbnails/2.jpg)
Driving a power load
MCU
Max output current exceeded.MCU power supply voltage probably inadequate for the load.
![Page 3: Embedded systems Exercise session 4 Power interface circuits](https://reader034.vdocuments.us/reader034/viewer/2022051204/62782aa0b038ea522c143183/html5/thumbnails/3.jpg)
Solution 1: Use a MOSFET
D
S
G
MCUBAT46
2N7000
+12V
100K
2N7000: VDS = 60 V, ID = 200 mA, Vth = 2.1 V, RDS = 1.2 Ω
![Page 4: Embedded systems Exercise session 4 Power interface circuits](https://reader034.vdocuments.us/reader034/viewer/2022051204/62782aa0b038ea522c143183/html5/thumbnails/4.jpg)
Solution 2: Use a dedicated IC
MCU
+12V
17× ULN2003
GND
COMMON
IN1 OUT1
ULN2003: Vmax = 50 V, Imax = 500 mA
![Page 5: Embedded systems Exercise session 4 Power interface circuits](https://reader034.vdocuments.us/reader034/viewer/2022051204/62782aa0b038ea522c143183/html5/thumbnails/5.jpg)
Heavier load:
D
S
G
MCUMBR3045
IRL540N
+12V
100K
IRL540N: VDS = 100 V, ID = 36 A, Vth = 2 V, RDS = 63 mΩ
![Page 6: Embedded systems Exercise session 4 Power interface circuits](https://reader034.vdocuments.us/reader034/viewer/2022051204/62782aa0b038ea522c143183/html5/thumbnails/6.jpg)
If fast switching is needed→ use a driver!
LO
VCC
VS
D
S
G
+12V+12V
MCU IR2110
LIN
VSS COM
VDD
+5V
+
MBR3045
IRL540N
100K1N4148
10ΩnF10010
µF
![Page 7: Embedded systems Exercise session 4 Power interface circuits](https://reader034.vdocuments.us/reader034/viewer/2022051204/62782aa0b038ea522c143183/html5/thumbnails/7.jpg)
Pulse-Width Modulation (PWM)
50%:
25%:
75%:
0
1
0
1
0
1
Frequency must be
sufficiently high to smooth out current
sufficiently low to achieve efficient switching
(Typically: 10–80 kHz)
![Page 8: Embedded systems Exercise session 4 Power interface circuits](https://reader034.vdocuments.us/reader034/viewer/2022051204/62782aa0b038ea522c143183/html5/thumbnails/8.jpg)
Full drive: H-Bridge
V+
V-
HA
LA
HB
LB0
0 0
0
![Page 9: Embedded systems Exercise session 4 Power interface circuits](https://reader034.vdocuments.us/reader034/viewer/2022051204/62782aa0b038ea522c143183/html5/thumbnails/9.jpg)
Full drive: H-Bridge
Forward mode:
V+
V-
HA
LA
HB
LB
1
0
0
1
![Page 10: Embedded systems Exercise session 4 Power interface circuits](https://reader034.vdocuments.us/reader034/viewer/2022051204/62782aa0b038ea522c143183/html5/thumbnails/10.jpg)
Full drive: H-Bridge
Reverse mode:
V+
V-
HA
LA
HB
LB
0
1
1
0
![Page 11: Embedded systems Exercise session 4 Power interface circuits](https://reader034.vdocuments.us/reader034/viewer/2022051204/62782aa0b038ea522c143183/html5/thumbnails/11.jpg)
Full drive: H-Bridge
Current recirculation:
V+
V-
HA
LA
HB
LB
1
0
1
0
![Page 12: Embedded systems Exercise session 4 Power interface circuits](https://reader034.vdocuments.us/reader034/viewer/2022051204/62782aa0b038ea522c143183/html5/thumbnails/12.jpg)
Full drive: H-Bridge
Current recirculation:
V+
V-
HA
LA
HB
LB1
0
1
0
![Page 13: Embedded systems Exercise session 4 Power interface circuits](https://reader034.vdocuments.us/reader034/viewer/2022051204/62782aa0b038ea522c143183/html5/thumbnails/13.jpg)
Full drive: H-Bridge
Regeneration:
V+
V-
HA
LA
HB
LB0
0
0
0
![Page 14: Embedded systems Exercise session 4 Power interface circuits](https://reader034.vdocuments.us/reader034/viewer/2022051204/62782aa0b038ea522c143183/html5/thumbnails/14.jpg)
Full drive: H-Bridge
Regeneration:
V+
V-
HA
LA
HB
LB0
0
0
0
![Page 15: Embedded systems Exercise session 4 Power interface circuits](https://reader034.vdocuments.us/reader034/viewer/2022051204/62782aa0b038ea522c143183/html5/thumbnails/15.jpg)
Locked antiphase: PWM command alternating between forward andreverse modes.
V+
V-
HA
LA
HB
LB
1
0
0
1
V+
V-
HA
LA
HB
LB
0
1
1
0
100% duty cycle: full forward50% duty cycle: stationary0% duty cycle: full backward
(Other command strategies exist.)
![Page 16: Embedded systems Exercise session 4 Power interface circuits](https://reader034.vdocuments.us/reader034/viewer/2022051204/62782aa0b038ea522c143183/html5/thumbnails/16.jpg)
H-Bridge: Practical implementation
Main problem: Driving the high-side MOSFETs.
Solution: Use a dedicated IC.
+
D
S
G
D
S
G MBR3045
MBR3045
+12V
+
+12V
MCU
LIN
VSS COM
VDD
+5V
nF10010
µF
HIN
LO
VS
HO
VB
1N4148
10Ω
1N4148100K
10Ω
IRL540N
IRL540N
100K
VCCIR2110
22µF
1N4148
Note: With this solution, the PWM duty cycle cannot be close to 0% or 100%.
![Page 17: Embedded systems Exercise session 4 Power interface circuits](https://reader034.vdocuments.us/reader034/viewer/2022051204/62782aa0b038ea522c143183/html5/thumbnails/17.jpg)
Simpler solution: Use a H-Bridge IC.
V+
MCU
12 LM293
![Page 18: Embedded systems Exercise session 4 Power interface circuits](https://reader034.vdocuments.us/reader034/viewer/2022051204/62782aa0b038ea522c143183/html5/thumbnails/18.jpg)
Driving a 220V power load
!!! Stay safe !!!
Solution 1: Use a relay.
D
S
G
MCU
+12V
100K
BAT46
2N7000
220V AC (line)
220V AC (neutral)
![Page 19: Embedded systems Exercise session 4 Power interface circuits](https://reader034.vdocuments.us/reader034/viewer/2022051204/62782aa0b038ea522c143183/html5/thumbnails/19.jpg)
Solution 2: Use a triac with a zero-cross driver.
220V AC (neutral)
MCU
220Ω 1/4 W
330Ω
A2
A1G
BTA10-600 (10A)BTA16-600 (16A)
4
6
2
1
MOC3041
220V AC (line)
360Ω
1/4 W
![Page 20: Embedded systems Exercise session 4 Power interface circuits](https://reader034.vdocuments.us/reader034/viewer/2022051204/62782aa0b038ea522c143183/html5/thumbnails/20.jpg)
Driving a stepper motor
Two types of stepper motors:
Unipolar:
(can be driven by a ULN2003)
Bipolar:
(needs two H-Bridges)
![Page 21: Embedded systems Exercise session 4 Power interface circuits](https://reader034.vdocuments.us/reader034/viewer/2022051204/62782aa0b038ea522c143183/html5/thumbnails/21.jpg)
Half-step sequence
V+B1 B2
V+A1
A2
A1 0 0 0 0 0 1 1 1A2 0 1 1 1 0 0 0 0B1 1 1 0 0 0 0 0 1B2 0 0 0 1 1 1 0 0
→ ↑ ← ↓
![Page 22: Embedded systems Exercise session 4 Power interface circuits](https://reader034.vdocuments.us/reader034/viewer/2022051204/62782aa0b038ea522c143183/html5/thumbnails/22.jpg)
Full-step sequence
V+B1 B2
V+A1
A2
A1 0 0 1 1A2 1 1 0 0B1 1 0 0 1B2 0 1 1 0
![Page 23: Embedded systems Exercise session 4 Power interface circuits](https://reader034.vdocuments.us/reader034/viewer/2022051204/62782aa0b038ea522c143183/html5/thumbnails/23.jpg)
Driving a hobby servomotor
MCU
+5V
PWM frequency: 50 HzDuty cycle: 5% (1 ms on): 0
7.5% (1.5 ms on): 90
10% (2 ms on): 180