Thursday, May 31, 2012

0 Making An H-Bridge Motor Driver

Need of an H-bridge

When driving the motor in only one direction, we only need an on/off switch. But in most of robotics applications, we need to reverse the motion of the motor many a times. This is accomplished by what is called an a Half-Bridge or a push/pull driver.

Circuitry of the H-bridge

2 Switch Bridge

The simplest of the H-bridge uses two switches, which provide a path to either the positive terminal or the negative terminal, due to which the motor is able to turn in either directions. By using only one of the switches at a time, a short circuit is avoided. The other terminal of the motor is permanently connected to the GND.(Ground 0V). If both the terminals of the motor are connected to the positive or negative supply, we obtain a condition known as an Electric Brake.

4 Switch H-Bridge

For the motor to spin, the battery current must flow from the Positive supply, through the Motor,
and to the Ground supply to complete the circuit. To make this happen we must open one switch from each side of the bridge, one Low-side and an opposite High-side—that means we can either turn on S1 and S4 to go Forward, or we can turn on S2 and S3 to go in Reverse. The direction of the current flow through the motor terminals determines the direction that the motor spins. We can manipulate the flow of the current by closing the two corresponding switches together to give us directional control of the motor. If all four switches are open (disconnected), the motor is coasting, meaning there is no path for the current to travel.

Full Bridge Configurations

Shoot Through Configurations ( NOT okay!)

Implementation

The Simplest of all H-bridges


We can make a full H-bridge using 2 three-way (SPDT) switches, a DC motor, and a 9v battery. It can be placed into any acceptable H-bridge state: forward, reverse, electric brake (positive), electric brake (negative), or neutral. Each switch in the circuit has three positions, On/Off/On, and switches the center contact between the two outer contacts (or in this case, the positive and negative battery wires). This method shows the simplicity of a basic H-bridge circuit, but does not provide speed control (it is either on or off). Although this might be a rugged circuit, its use is limited, so it is usually only good for testing and educational purposes.

DPDT (Double pole double throw) Relay H-Bridge

Here we combine the two SPDT switches and use one DPDT Relay, so it can be controlled by the Arduino. Also we can use the Arduino or PICAXE to provide a simple PWM signal for speed control of the motor. The simplest way to do this is to add a Logic-level N-channel mosfet (or several in parallel) to control the entire circuit’s path to ground. By using a PWM signal on the Ground supply to the H-bridge (Relay), we can control the speed of the motor from 0– 100%, whereas the relay switches the motor’s direction. The relay acts as both the High-side and Lowside switches in the bridge, so there are actually two low-side switches in this configuration—the relay used to route the power terminals and the N-channel mosfet used to provide the PWM speed control. This provides complete 0–100% speed control and requires as few as four parts other than the relay: (2) logic level N-channel mosfets, (1) diode (for relay coil), and (1) small prototyping PCB (or you can make your own). Depending on the mosfet, you can expect to carry about 10 amperes at 24vdc with no heatsink or fan; I usually select power mosfets with the highest amperage rating (anything above 75 amps), higher voltage rating than I plan to use in the project (usually 30v–55v is good), and the lowest possible on-state resistance. We can build this circuit with (2) FQP50N06L N-channel mosfets. One mosfet is needed to provide PWM speed control, and the other mosfet is needed to interface the relay coil to the
Arduino for direction control.The relay mosfet can be controlled by any Arduino digital output pin, whereas the speed control mosfet should be controlled by an Arduino PWM output. Next we connect the mosfet Drain pin to the Relay as shown in Figure 3-14, and the mosfet Source pin to the main Ground supply. The prototyping PCB makes this easier to put together and you can add screw-terminals for easy wiring. The voltage and current limits of this circuit are dependent on the mosfet and relay ratings, giving this circuit potential despite using a mechanical relay switch.
The Code for this bridge will be given later.
And don't worry if you do not get this right away! Take your time. You can also build the circuit, and then understand its functioning. 

H-Bridge ICs

To build your own H-bridge, but leave the designing to a professional, you might be interested in an Hbridge
IC. An H-bridge IC is a complete H-bridge circuit that is contained on a tiny integrated circuit
chip. These are usually fitted into a circuit with very few extra components, typically only a few resistors
and a regulated power supply for the logic controls. When using an H-bridge IC, you can usually expect
shoot-through protection, thermal overload protection, and high frequency capabilities. Although these
H-bridge chips are far less likely to be destroyed by user error than a completely homemade design, they
also have much lower power ratings than a homemade H-bridge, typically under 3amps of continuous
current. There are several H-bridge IC chips that include all four switches and a method of controlling them
safely. The L293D is a Dual H-bridge IC that can handle up to 36 volts and 600 milliamp per motor. The
L298N is a larger version of the L293D that can handle up to 2amps (see Figure 3-16). There are a few ICs that can control up to 25amps, but they are expensive and hard to find. There are several H-bridge ICs
that work for some of the smaller projects i will post(hopefully), but the larger bots require a higher powered H-bridge capable of conducting 10amps or more.

0 comments:

Post a Comment

Do Comment on Anything you like or dont like!

 

The Engineer's Spot! Copyright © 2011 - |- Template created by O Pregador - |- Powered by Blogger Templates