Download as pdf
Download as pdf
You are on page 1of 7
TUTORIAL DC MOTOR INTERFACING AND MOTOR DRIVER = =] 3) STUDENT NAME, ROLL NO ‘SEC SIGNATURE & DATE NATIONAL UNIVERSITY OF COMPUTER AND EMERGING SCIENCES (NUCES), KARACHI . ‘ Version: 2.0 Prepereiiby: Huge. Aamir AR Date: 07% Dec 2020 [DC MOTOR INTERFACING AND MOTOR DRIVER] [Fall 2020 - MPT LAB] Tatoria: DC MOTOR INTERFACING AND MOTOR DRIVER ol ive: + To lea about DC Motor and its connections + To learn controlling of DC motor via H-Bridge. + To learn Motor Driver IC and how it control DC Motors DC Motors: A direct current (DC) motor is a widely used device that translates electrical pulses into mechanical movement. In the DC motor we have only + and - leads. Connecting them to a DC voltage source moves the motor in one direction. By reversing the polarity, the DC motor will move in the opposite direction. One can easily experiment with the DC motor. Counter Clockwise Rotation The maximum speed of a DC motor is indicated in rpm and is given in the data sheet. The DC motor has two rpms: no-load and loaded. The manufacturer's datasheet gives the no-load rpm. The no-load rpm can be from a few thousand to tens of thousands. The rpm is reduced when moving a load and it decreases as the load is increased. For example, a drill tuming a screw has a much Lower rpm speed than when it is in the no- load situation. DC motors also have voltage and current ratings. ‘The nominal voltage is the voltage for that motor under normal conditions, and can be from 1 to 150 V, depending on the motor. As we inerease the voltage, the rpm goes up. The current rating is the current consumption when the nominal voltage is applied with no load, and can be from 25 mA toa few amps. As the load increases, the rpm is decreased, unless the current or voltage provided to the motor is increased, which in tum increases the torque. With a fixed voltage, as the load increases, the current (power) consumption of a DC motor is increased. If we overload the motor it will stall, and that can damage the motor due to the heat generated by high current consumption. Fart Ne. Nominal Vers Vote Tsav1ser 070 A 208 134923CP, (0.240 A 16,000 8.3 gem 177498CP, 0.150 A 10.300 33.3 pcr, Tsta1ice 0.470 A__10,000 18.8 gem Instructor: Aamir Ali National University of Computer & Emerging Sclences, Karachi [Fall 2020 - MPT LAB] [DC MOTOR INTERFACING AND MOTOR DRIVER] With the help of relays or some specially designed chips we can change the direction of the DC motor rotation. H-bridge control can be created using relays, transistors, or a single IC solution such as the L293D. When using relays and transistors, you must ensure that invalid configurations do not occur. Ww swircn, swrren swirch swish, MOTOR NOT Details of switching operation is as follows: Motor Operation SWI sw2 Sw3 sw4 Stop OPEN, OPEN OPEN, OPEN, Clockwise OPEN, CLOSED. CLOSED OPEN, Anti-clockwise CLOSED OPEN OPEN, CLOSED Break CLOSED OPEN CLOSED OPEN, OPEN: CLOSED OPEN, CLOSED x x CLOSED CLOSED Invalid CLOSED CLOSED x x CLOSED CLOSED CLOSED CLOSED 1.293D Motor Driver IC: This integrated circuit (IC) is a 2-channel full H-Bridge motor driver. That is capable of driving two distinct DC motors. It’s the easiest way to go around building a whole H-Bridge driver from scratch. It comes in a DIP package which fits nicely on a typical breadboard. The L293D provides an easy wire-up interface with some decent features as follows: Motor Channels: 2 Output Current Per Channel: 0.6. Output Peak Current (Non-Continuous): 1.2 Supply Voltage: up to 36v Switching Frequency: up to SkHz Thermal Shutdown (Overheat Protection) VVVVVY 9° J Page 20F6 | National University of Computer & Emerging Sciences, Karachi Instructor: Aamir Ali [DC MOTOR INTERFACING AND MOTOR DRIVER] [Fall 2020 - MPT LAB] Here is the pinout diagram for an L293D motor driver ic: HEAT SINK AND GROUND GROUND Here, Pin # Functionality of pin 1 Enable pin for 1* motor (used to control speed of motor via PWM) 2 1“ input\control (inl) channels for the 1“ motor. 3 1* output (OUTI) channels for the 1* motor 4.5.12,13 GND is common ground for Veci and Vec2 also works as heatsink (so, viei*"™ | preferably given large connected area on PCB. 6 2" output (OUT2) chamnels for the 1* motor 7 | 2™"input\control (in2) channels for the 1* motor | Vecris the pin from where the H-Bridge gets its power for driving the motors which can be 4.5V to 36V. 9 __ | Enable pin for 2™ motor (used to control speed of motor via PWM) 10 | I input\control (in!) channels for the 2°“ motor 11 __| 1" output (OUT!) channels for the 2™ motor 14 _ | 2" output (OUT2) channels for the 2“ motor 15 _ | 2" input\control (in) channels for the 2™ motor 16 | Veer is used for driving the internal logic circuitry which should be 5V. Details of Motor Operation w-r-t to input in L293D IC: Motor Operation inl In2 Motor OFF \ Break LOW LOW HIGH HIGH Clockwise HIGH LOW Anti-clockwise LOW HIGH, oO Instructor: Aamir Ali National University of Computer & Emerging Sciences, Karachi am [Fall 2020 - MPT LAB] [DC MOTOR INTERFACING AND MOTOR DRIVER] Sample connections of L293D, Motor and microcontroller (AVR ATmega8515 in this case) could be like this 2s) ext 7 f O44] reorooc 2 fing vss) vs oun rain he our u aaa Qa em Pasian pads ours ours 6 000 HEE 5 Be ma heel i 62 eke Teleelelefsle [27 Poona PCTIAISITDI p28 peoncor [3h eine | Reser peace P= Lab Task(s) TASK: Implement above given circuit on Proteus and write an Assembly code to drive motor clockwise when B1 is pressed and motor move anti-clockwise when B2 is pressed. Whereas motor should stop if both buttons are pressed or released simultaneously. 9° J Page aof6 | National University of Computer & Emerging Sciences, Karachi Instructor: Aamir Ali [DC MOTOR INTERFACING AND MOTOR DRIVER] [Fall 2020 - MPT LAB] Lab Report: (tis recommended to write Lab Report in bullet Form) oO National University of Computer & Emerging Sciences, Karachi [Fall 2020 - MPT LAB] [DC MOTOR INTERFACING AND MOTOR DRIVER] e Ea National University of Computer & Emerging Sciences, Karachi Instructor: Aamir Ali

You might also like