<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-8863086593416362725</id><updated>2012-02-16T13:30:11.776-08:00</updated><title type='text'>Chakshika</title><subtitle type='html'></subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://chakshika.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8863086593416362725/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://chakshika.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><author><name>chakshika</name><uri>http://www.blogger.com/profile/03807698239431781686</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='28' height='32' src='http://bp0.blogger.com/_d8KBby4IkU0/SH2-WAC5GFI/AAAAAAAAAAU/QqgRWEHL9d0/S220/chak+pic.jpg'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>2</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-8863086593416362725.post-6348960723369941392</id><published>2008-07-22T01:58:00.000-07:00</published><updated>2008-07-22T02:01:35.760-07:00</updated><title type='text'>The L298 Motor Driver</title><content type='html'>The L298 Motor Driver Kit allows the user to safely interface two DC&lt;br /&gt;motors to a host microcontroller using only 4 control lines. The motor&lt;br /&gt;driver isolates the host and controls continuous currents of up to 2&lt;br /&gt;Amps per motor (4 Amps total). Short peaks (spikes) up to 3 Amps per&lt;br /&gt;motor can be tolerated without damage.&lt;br /&gt;While ideally suited for use with a microcontroller, the kit may also be&lt;br /&gt;used with just about any form of 0-5 Volt signal (i.e. manual switches,&lt;br /&gt;TTL logic gates, relays etc).&lt;br /&gt;Assembling the Board&lt;br /&gt;Assembly of the kit is straight forward; the silkscreen (white printing on&lt;br /&gt;the circuit board) shows where each component belongs and it’s&lt;br /&gt;orientation. Make sure you install each diode so that the white ring on&lt;br /&gt;the diode is aligned with the white bar on the diode symbol on the&lt;br /&gt;silkscreen. The diodes are sometimes a tight fit in their holes and you&lt;br /&gt;might find a pair of small pliers useful in installing them.&lt;br /&gt;This kit now comes with a 78L05 +5 Volt voltage regulator. The&lt;br /&gt;regulator takes power from the Motor Battery terminals and steps it&lt;br /&gt;down to +5 Volts for the logic circuits of the L298N chip (this assumes&lt;br /&gt;that your Motor Battery voltage is at least 6 Volts). If you are using a&lt;br /&gt;Motor Battery that is less than 6 Volts, the 78L05 will not be able to&lt;br /&gt;supply the necessary +5 volts to the L298. In this case, you will need to&lt;br /&gt;supply this voltage to the Logic Battery terminals yourself (if you do&lt;br /&gt;this, do not install the 78L05 and remove it if it is already installed). If&lt;br /&gt;you have doubts, measure the voltage across the Logic Battery&lt;br /&gt;terminals while both motors are running -there should be a minimum of&lt;br /&gt;+4.5 Volts. If there is less, the L298N may behave erratically.&lt;br /&gt;The 0.01uF tantalum capacitors (marked “103”) are used to suppress&lt;br /&gt;transients (spikes).&lt;br /&gt;The kit includes 2 black terminal blocks. These terminal blocks provide&lt;br /&gt;an easy and conveneint way to connect to the L298 kit; simply ‘poke’ a&lt;br /&gt;solid wire into the terminal holes to make a connection. If you want a&lt;br /&gt;more permanent connection, you can choose not to install the terminal&lt;br /&gt;blocks and solder your control lines directly to the board.&lt;br /&gt;A Bit About Motor Current&lt;br /&gt;Motors are inductive devices; they draw much more current at startup&lt;br /&gt;than when they are running at a steady speed. Before connecting any&lt;br /&gt;motor to the L298 you should know a few things about the motor:&lt;br /&gt;- What voltage it is designed to work at&lt;br /&gt;- How much current it draws when running (unloaded)&lt;br /&gt;- How much curent it draws at stall.&lt;br /&gt;The “stall current” is the current the motor draws when you stop (stall)&lt;br /&gt;the output shaft (if you can). Stalling a motor is very hard on the motor&lt;br /&gt;and can burn open the motor windings and ruin the motor. If you want&lt;br /&gt;to test for stall current, grab the output shaft with your hand while&lt;br /&gt;measuring the current drawn. As the motor approaches stall, the&lt;br /&gt;current will climb.&lt;br /&gt;The L298N can safely handle 2 Amps of continuous current for each&lt;br /&gt;motor. Short surges up to 3 Amps as the motor starts can be tolerated.&lt;br /&gt;A heatsink would be a good idea in situations that see the current surge&lt;br /&gt;above 2 Amps.&lt;br /&gt;Connecting the Motors&lt;br /&gt;A DC motor has 2 terminals on it. If you take the positive and negative&lt;br /&gt;leads from a power source (battery, power supply etc.) and connect&lt;br /&gt;them to the terminals of the motor, the motor will spin in one direction. If&lt;br /&gt;you swap the connections, the motor will spin in the opposite direction.&lt;br /&gt;You will want to wire your motors to the L298 board in such a way that&lt;br /&gt;the motor spins in the direction you call ‘forward’ when the Fwd line is&lt;br /&gt;activated and ‘reverse’ when the Back line activated.&lt;br /&gt;When connecting the motors to the circuit board, use as thick a wire as&lt;br /&gt;is practical. The thicker the wire, the less the voltage drop and the more&lt;br /&gt;power is delivered to the motor. We recommend a minimum of 18&lt;br /&gt;gauge stranded wire. Solid wire is fine, but will break if flexed too often.&lt;br /&gt;Solder the Positive and negative motor leads for the ‘left’ motor to&lt;br /&gt;Motor Left + and - solder pads. Repeat for the ‘right’ motor.&lt;br /&gt;Connect the + and - leads from your motor battery to the Motor&lt;br /&gt;Battery + and - solder pads -again, use as thick a wire as it practical.&lt;br /&gt;A Note on ‘Motor Battery’ Voltages: There is a 1.4V drop associated&lt;br /&gt;with the L298. This means that if your motor runs on 12 VDC, you&lt;br /&gt;should use a 13.4 VDC supply in order to get full power to the motor.&lt;br /&gt;Operation&lt;br /&gt;Control is accomplished by grounding the control pin(s) for the desired&lt;br /&gt;function/motor. This is usually done by putting a logic LOW (i.e. 0V or&lt;br /&gt;ground) on an output pin of your host microcontroller, which is in turn&lt;br /&gt;connected to the appropriate control connection (Fwd, Back, Enable).&lt;br /&gt;Fwd&lt;br /&gt;To make a motor move forward, ground the ‘Fwd’ connection on the&lt;br /&gt;appropriate connector (left / right). To stop, un-ground the connection.&lt;br /&gt;The photo below shows how both motors would be made to go&lt;br /&gt;‘forward’.&lt;br /&gt;Back (Reverse)&lt;br /&gt;To drive the motor in reverse, ground the appropriate Back connection.&lt;br /&gt;To stop, unground the connection.&lt;br /&gt;Gnd&lt;br /&gt;Gnd is a ground connection. The L298 Controller board and your control&lt;br /&gt;circuit must share the same gound.&lt;br /&gt;Enable&lt;br /&gt;The Enable connection is an active LOW connection that is pulled&lt;br /&gt;HIGH for you on the circuit board. Ground this connection to disable a&lt;br /&gt;motor. Note: While disabled, commands from the host microcontroller&lt;br /&gt;(grounding/un-grounding the control connections) will have no effect on&lt;br /&gt;that motor. Disabling a motor shuts-down the L298’s internal circuits,&lt;br /&gt;putting it into a low current consumption mode (for that channel). When&lt;br /&gt;both channels are disabled, the motor controller will consume approx.&lt;br /&gt;10 mA.&lt;br /&gt;www.HVWTech.com 5 L298 Kit Manual v3.1&lt;br /&gt;Pulse-Width Modulation (PWM)&lt;br /&gt;Pulse-Width Modulation is a method of controlling the speed of a motor&lt;br /&gt;by turning the power on and off at varying speeds. If you have a 12 Volt&lt;br /&gt;motor and turn it on 50% of the time and turn it off 50% of the time&lt;br /&gt;(switching it at several KHz) then the effective voltage you are applying&lt;br /&gt;to the motor is 6 Volts. As the voltage to the motor varies, so does its’&lt;br /&gt;speed.&lt;br /&gt;It should be noted that the L298 Kit was not intended for high-speed&lt;br /&gt;PWM operation. The diodes in the kits are general purpose rectifier&lt;br /&gt;diodes intended for 60 Hz operation. If you want to experiment with&lt;br /&gt;PWM and you don’t get the kind of results you want, try exchanging the&lt;br /&gt;diodes for ‘fast recovery Schottky’ models.&lt;br /&gt;Heat Sinks&lt;br /&gt;The L298 has internal thermal protection circuitry that shuts down the&lt;br /&gt;chip if it becomes too hot (when you try to draw too much current). If&lt;br /&gt;you find this happening, you should add some kind of heat sink to the&lt;br /&gt;L298. A simple heat sink can be made from a piece of scrap aluminum&lt;br /&gt;by cutting as big a piece as you have room for and drilling a 1/8” hole&lt;br /&gt;into it (for a bolt to hold it to the L298). If available, a thin smear of&lt;br /&gt;thermal compound (white, greasy stuff, available at Radio Shack) on&lt;br /&gt;the back of the L298’s metal tab (i.e. between it and the heat sink) will&lt;br /&gt;maximize heat dissipation. Of course, you should always make sure&lt;br /&gt;that air can circulate freely around the L298 and it’s heatsink.&lt;br /&gt;NOTE: If a motor behaves erratically i.e. turning on and off rapidly, it is&lt;br /&gt;likely the L298 senses that it is being overloaded. This usually means&lt;br /&gt;that you are drawing too much current. Either add a heat sink to the&lt;br /&gt;L298 and/or reduce the current being drawn.&lt;br /&gt;Caution: The L298’s heat sink (the metal tab) is at ground potential. Do&lt;br /&gt;not allow any ground-referenced voltage source to touch it or any heat&lt;br /&gt;sink connected to it, or you will cause a short.&lt;br /&gt;H-Bridge Theory&lt;br /&gt;Figure 1 shows the basic schematic for a typical H-Bridge along with it’s&lt;br /&gt;truth table. In order to make a motor turn, we need to apply a voltage to&lt;br /&gt;it. We do this by turning certain NPN transistors on. By looking at the&lt;br /&gt;truth table, we can see that in order to make a motor go forward&lt;br /&gt;www.HVWTech.com 6 L298 Kit Manual v3.1&lt;br /&gt;(NOTE: ‘Forward and ‘Reverse’ are arbitrary directions for purposes of&lt;br /&gt;illustration. In your application, forward and reverse will be determined&lt;br /&gt;by how the motors are mounted with respect to each other and the&lt;br /&gt;polarity of the voltage) we must turn on Q1 and Q4. This puts the Motor&lt;br /&gt;Battery Positive on the left side of the motor (through Q1) and grounds&lt;br /&gt;the other side of the motor (through Q4).&lt;br /&gt;To go in the opposite direction, we must turn off these transistors and&lt;br /&gt;turn on Q2 and Q3. Now, the Motor Battery Positive will be on the right&lt;br /&gt;side of the motor (through Q3) and ground is on the left (through Q2).&lt;br /&gt;You have now reversed the polarity of the motor’s supply voltage and&lt;br /&gt;the motor will spin in the opposite direction.&lt;br /&gt;Figure 1.&lt;br /&gt;You will notice that each time a motor is turned on, current passes&lt;br /&gt;through 2 NPN transistors. Each transistor has (approximately) 0.7 Volt&lt;br /&gt;drop across it, so the motor will see about 1.4 Volts LESS than the&lt;br /&gt;Motor Battery Voltage across it’s terminals. This means that if you have&lt;br /&gt;a 12 Volt motor, and you want it to receive maximum power, you should&lt;br /&gt;use a 13.4 Volt battery.&lt;br /&gt;Also notice that if transistors Q1 and Q2 (or Q3 and Q4) were turned&lt;br /&gt;on, that you would make a short circuit across the battery. For this&lt;br /&gt;reason, the L298N has internal logic that prevents this from happening.&lt;br /&gt;Further Information&lt;br /&gt;A complete datasheet for the L298N can be found on the HVW&lt;br /&gt;Technologies web site, on the L298 product page&lt;br /&gt;FWD REV STOP&lt;br /&gt;Q1 1 0 0&lt;br /&gt;Q2 0 1 0&lt;br /&gt;Q3 0 1 0&lt;br /&gt;Q4 1 0 0&lt;br /&gt;Truth Table&lt;br /&gt;Motor Battery +&lt;br /&gt;( Motor Batte ry - )&lt;br /&gt;Motor&lt;br /&gt;Q4&lt;br /&gt;Q3&lt;br /&gt;Q2&lt;br /&gt;Q1&lt;br /&gt;www.HVWTech.com 7 L298 Kit Manual v3.1&lt;br /&gt;Specifications&lt;br /&gt;Max supply voltage: 46 V&lt;br /&gt;Max current (per channel): 2 A (DC); Non-repetitive (t=100 uS): 3A;&lt;br /&gt;Repetitive (80% on, 20% off, ton=10 ms): 2.5 A&lt;br /&gt;Total Power Dissipation: 25W&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8863086593416362725-6348960723369941392?l=chakshika.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://chakshika.blogspot.com/feeds/6348960723369941392/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8863086593416362725&amp;postID=6348960723369941392' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8863086593416362725/posts/default/6348960723369941392'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8863086593416362725/posts/default/6348960723369941392'/><link rel='alternate' type='text/html' href='http://chakshika.blogspot.com/2008/07/l298-motor-driver.html' title='The L298 Motor Driver'/><author><name>chakshika</name><uri>http://www.blogger.com/profile/03807698239431781686</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='28' height='32' src='http://bp0.blogger.com/_d8KBby4IkU0/SH2-WAC5GFI/AAAAAAAAAAU/QqgRWEHL9d0/S220/chak+pic.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-8863086593416362725.post-4179591396158531426</id><published>2008-07-16T02:21:00.001-07:00</published><updated>2008-07-16T02:21:56.536-07:00</updated><title type='text'>Hi All</title><content type='html'>Welcome to Chakshikas Blog&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/8863086593416362725-4179591396158531426?l=chakshika.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://chakshika.blogspot.com/feeds/4179591396158531426/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=8863086593416362725&amp;postID=4179591396158531426' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/8863086593416362725/posts/default/4179591396158531426'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/8863086593416362725/posts/default/4179591396158531426'/><link rel='alternate' type='text/html' href='http://chakshika.blogspot.com/2008/07/hi-all.html' title='Hi All'/><author><name>chakshika</name><uri>http://www.blogger.com/profile/03807698239431781686</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='28' height='32' src='http://bp0.blogger.com/_d8KBby4IkU0/SH2-WAC5GFI/AAAAAAAAAAU/QqgRWEHL9d0/S220/chak+pic.jpg'/></author><thr:total>0</thr:total></entry></feed>
