140 likes | 149 Views
Learn about driving MOSFETs, the pin-out of the H-Bridge, and connecting it to the PIC board for motor drives in this sophomore clinic.
E N D
Sophomore ClinicENGR 01-202 5, CRN 20686Integrating the PIC and the H-Bridge James K. Beard, Ph.D.
Topics • Driving the MOSFETs from 5 Volts • The pin out of the H-bridge • Connecting the H-bridge and the PIC board Sophomore Clinic II
MOSFETs in Switching • Switching properties • Off • When they’re off, they’re off • Gate-source voltage must be below threshold voltage • On • When they’re on, the drain-source resistance is very, very low • The achieved on resistance is a function of the drive voltage • Drive must be much higher than the threshold voltage • 5 Volts drive provides sufficient drive Sophomore Clinic II
On V-I Characteristics N-Channel P-Channel Sophomore Clinic II
Conclusion • Typical characteristics from the IRC data sheets • N-channel is IRFZ24N • P-channel is IRF9Z24NPbF • Data sheet shows • N-channel on resistance of 1/8 Ohm • P-channel on resistance of 2/5 Ohm • Both limit current to about 2.5 A • Good to go for Sophomore Clinic Project motor drives • A good choice for magnet drive – switch directly from the PIC Sophomore Clinic II
Pin-Out of the H-Bridge Board • Power connector • +5 Volts, ground from the rails • Power to the motors comes from here • Connectors for the motors • Three redundant ground connections • Eight lines to the PIC board Sophomore Clinic II
VDD H78 H56 H12 H34 G3 G1 H12 H34 G3 G5 G2 G1 G8 G4 G6 G7 G4 G2 7 3 5 1 2 6 4 8 A B C D G 5 Sophomore Clinic II
The H-Bridge Drive • The MOSFETs are complementary – The P-channel is driven by the reverse polarity signal to the gate • +5 Volts is OFF • Ground is ON • We want to drive them form the PIC hardware, not the software • Solution • We use the PWM output of the PIC • We use the motor direction toggle from the PIC • We drive the H-bridge with hardware using these signals Sophomore Clinic II
G3 G5 G2 G1 G8 G4 G6 G7 Interface Circuitry From PIC Toggle PWM G1 G4 To H-Bridge G3 G2 Sophomore Clinic II
The Chips • CMOS to provide full 5 Volt swing on logic one • 4000 series to allow use in other circuits up to 15 Volts • Two-chip solution for both motors • CD4011 or MC14011 quad NAND • CD4069 or MC14069 hex inverter Sophomore Clinic II
Chip Pin-Outs Sophomore Clinic II
14 13 12 11 10 9 8 14 13 12 11 10 9 8 CD4011 CD4069 1 2 3 4 5 6 7 1 2 3 4 5 6 7 C0 C1 C2 C3 C4 ... ... ... Wiring the Interface Logic: On both ICs: PIN 14: HOOK TO +5VDC PIN 7: HOOK TO GND G2 G4 G1 G3 G6 G8 G5 G7 TAKE YOUR TIME – TRIPLE CHECK EVERY CONNECTION! Errors here can cause permanent damage to the uC board and/or H-Bridge! Sophomore Clinic II
The Interface Logic Wired Sophomore Clinic II
Electromagnet +5 Volts From Rail Or H-Bridge D G S D IRFZ24N N-Channel MOSFET (same one that the H-bridge uses) Output From PIC G S Electromagnet Drive Circuit Sophomore Clinic II