Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Simple h-bridge design

Status
Not open for further replies.

windozeuser

Member
Hello board, I am trying to contruct a simple H-Bridge using two TIP42 and two TIP3055 silicon power transistors. I want to control them using a basic stamp microcontroller. My question is, will the basic stamp ouput current/voltage be enough to turn the transistors on. Also, what kind of maximum PMDC motor can this handle? the collector current for the transistors is 10amps and the max power dissipation is 65 watts. Is there anything I have to watch out for like power spikes, and how can I protect the basic stamp from damage, do I just use diodes? Finally, if anyone can draw a simple schematic in their explanations I would appreciate it.

Btw. I'm using the TIP42 and TIP3055's because someone gave me about 20 of them. Free parts FTW

Thanks a lot :)
 
H Bridge Circuit

Constructing a h bridge circuit is quiet simple. H Bridge can be constructed either using transistor or relay. The only thing you need to consider is the current requirement of your motor, small dc motor can be operated by using simple transistro or if you need to control big motor then use power transistors or relay . H Bridge circuits can be found on any circuit site.
Try
http://explorecircuits.com/cir_control_controller_1.htm
 
No you need a separate output driver, the transistors will need a base current of up to an amp to fully saturate.
 
Thanks, but I never controlled an H-bridge before using a MCU specifically the Basic Stamp 2. How would I switch the power transistors into full saturation with the limited output currect from the stamp I/O pins? Would I just use a darlington pair config with like a 2n3906 and 2n3904

**broken link removed**

What should I use for the diodes?

Also, if the max Collector current is 10 amps, does this mean I can operate a motor up to around 9amps?

I/O A and I/O B are connected to a Basic Stamp 2 I/O pin

Vss is the basic stamp ground, and -6 is the battery ground

Well I hooked it up and tested it without the basic stamp, and the TIP transistors seem like they're overheating a little, but when I hooked it up to the Basic stamp (Junk spare) they operated normally. Can anyone explain why?

Also, what is the max frequency that I could PWM this with?
 
Last edited:
ok I have a new circuit using TIP 121's and TIP 125's with Darlington pair PN2222 transistors that the stamp controls. Now I'm using 1N4004 diodes for "Freewheeling" diodes, even though the TIP's have one built in? Also, I have the basic stamp Vss ground connected with the H-bridge ground. Is this wise, and what steps should I take to protect it if any?
 
windozeuser said:
ok I have a new circuit using TIP 121's and TIP 125's with Darlington pair PN2222 transistors that the stamp controls. Now I'm using 1N4004 diodes for "Freewheeling" diodes, even though the TIP's have one built in? Also, I have the basic stamp Vss ground connected with the H-bridge ground. Is this wise, and what steps should I take to protect it if any?
What are the 2222's for? Your power transistors are already Darlingtons.
 
The stamp I/O sink/source current is only 20mA/25mA I thought I needed the PN2222's because the one on the TIP's need atleast 120mA to fully saturate? Also there is a little problem, when I set the Basic stamp IO pin to LOW there is still a little current flowing(I am testing it with an LED rather than motor right now). Also when I touch the TIP's metal tab it automatically makes the LED turn on, actuall if I touch anything conductive it makes it turn on. What's wrong?

This is the circuit I'm testing with only one transistor first:

*NOTE: The TIP125 schematic symbol isn't quite right, the correct one is in the data sheet

P0 is connected to an I/O pin on the basic stamp II

**broken link removed**
 
Last edited:
**broken link removed**

The load will be a motor so anywhere between 100mA to 3 amps

Do you think the stamp will be able to switch the TIP's on without the PN2222's like in my schematic? Also is this correct, I'm just learning H-bridge design. I think I have floating IO pins?
 
Now the TIP125 darlingtons have the correct polarity but there is nothing to turn them off. Their base voltage needs to be nearly +12V to turn off which will not come from your stamp.

Your forward and reverse switching won't cause the motor to run. You need to turn on an upper transistor plus a lower transistor on the opposite side. Two inverters are needed to do it and two 2N2222 transistors can be the inverters and the shift to 12V level shifters.
 
audioguru said:
Now the TIP125 darlingtons have the correct polarity but there is nothing to turn them off. Their base voltage needs to be nearly +12V to turn off which will not come from your stamp.

Your forward and reverse switching won't cause the motor to run. You need to turn on an upper transistor plus a lower transistor on the opposite side. Two inverters are needed to do it and two 2N2222 transistors can be the inverters and the shift to 12V level shifters.


I don't quite understand, but will this work:

**broken link removed**

If I just use 4 I/O pins from the stamp. Also, is this circuit safe for the stamp? As in, will the stamp's 20mA be able to saturate the darlington paired transistor, because in the data sheet it saids Ib is 120mA?
 
Last edited:
Why don't you upload your schematics to here?

The output voltage from a stamp cannot go up to +12V to turn off the TIP125 transistors.

Transistors are all different. The datasheet shows that some of them saturate well and others saturate poorly with an input current of only 20mA with a load of 3A. 120mA is their absolute max input current. They saturate much better if the load current is only 1A.
 
The TIP125 is turned off when its base voltage is the same as its emitter voltage, +12V. The max output voltage from a stamp is only +5V so the TIP125 would be turned on all the time.
 
Then what solution is there to turn it off?

*PS- Wait would I just use a Pull up resistor like say 10k Ohm from the base to +12 VCC, then send a Logic LOW from the Basic Stamp?

then a pull down resistor between the base and emitter to pull the TIP120's to ground? Does this mean I need those PN2222's after all?
 
Last edited:
A pullup resistor on the base of a TIP125 will also pullup the output of a stamp to a voltage that is much too high, or the output of the stamp will limit the pullup voltage to only +5V to protect itself. Then the TIP125 won't turn off.

The output of a stamp is fine to go to +5V to turn on a TIP120 and go to 0V to turn it off.
You need a 2N2222 transistor to shift the 0V to +5V output of the stamp to 0V to +12V for the input of the TIP125.
 
windozeuser said:
Then what solution is there to turn it off?

*PS- Wait would I just use a Pull up resistor like say 10k Ohm from the base to +12 VCC, then send a Logic LOW from the Basic Stamp?

then a pull down resistor between the base and emitter to pull the TIP120's to ground? Does this mean I need those PN2222's after all?
Here ya go.
You obviously want to avoid the smoke-making codes.
You can use 2N2222 instead of 2N3904.
If you want to use PWM for speed control, it gets a lot more complicated. BJTs turn off slower than they turn on. Darlingtons turn off a lot slower than they turn on. This causes shoot-through currents in the legs on each side when you try to switch them simultaneously. This is probably not a problem if you are just doing occasional forward, reverse, and stop, but it could be a problem with PWM, where the switching frequency is much higher. In this case, you have to build in dead time (coast=0000) between each operation that could cause shoot-through.
EDIT: If this is homework, I guess I blew it. :(
 

Attachments

  • h-bridge3.PNG
    h-bridge3.PNG
    24.8 KB · Views: 2,098
Last edited:
Thank you all for your help, no this isn't homework, I'm doing small models for h-bridge design cause I want to go large scale in the future for a robot I want to make. I can't thank you enough for you going out of your way for me. The smoke all functions help in creating the software protections Thanks ;P. What is the max you think I could pulse the motor with this design roughly?

Thanks a lot
 
windozeuser said:
Thank you all for your help, no this isn't homework, I'm doing small models for h-bridge design cause I want to go large scale in the future for a robot I want to make. I can't thank you enough for you going out of your way for me. The smoke all functions help in creating the software protections Thanks ;P. What is the max you think I could pulse the motor with this design roughly?

Thanks a lot
Ah, crap, You caught me.:eek: I don't have any experience actually running H-bridges. I'm just an old engineer with a lot of experience. I ran a sim and got shoot-through currents on the order of 6 amps, lasting around 10usec. Not a lot of current, but the transistors will have 12 volts across them during this time, so the instantaneous total dissipation is ~ 70 watts (split, probably unevenly, between the two trannies). Keep in mind this was a simulation. Predicting device failure is one of the weaker points of simulators, because in cases like this, it depends on the accuracy of the models. BJT turn-off time and beta-limited current are hard to model accurately, and tend to vary a lot from part to part and from manufacturer to manufacturer.
Since you have the ability to build in dead time, I would just do it. It might take a little more programming time up front, but it might save your trannies, or at least make your battery (if you are using one) last a little longer.
 
Last edited:
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top