H-bridge problemas..

Discussion in 'General Electronics Chat' started by Captain E, Jul 1, 2015.

  1. Captain E

    Thread Starter Member

    Jun 16, 2015
    81
    6
    Hi..
    Having some problem learning how to use the H-bridge I have indeed.
    I have read and looked at a few tutorials on H-bridges, and on what I know, I think this should be working. I know what all the ports are for and what you do with them, so I wanted to make it simple for starters: turn the motor on any way around.
    There is something I'm missing.

    My circuit:
    [​IMG]
    My code:
    Code (Text):
    1. void setup() {
    2.   pinMode(9, OUTPUT);    //enable pin
    3.   digitalWrite(9, HIGH); //Motor is ON
    4.   pinMode(8, OUTPUT);    //Control pin n.1
    5.   digitalWrite(8, HIGH); //..set to HIGH
    6.   pinMode(7, OUTPUT);    //Control pin n.2
    7.   digitalWrite(7, LOW);  //..set to LOW
    8. }                        // =>motor should be spinning?
    9.  
    10. void loop() {
    11.   // no need for this, JUST GET THE MOTOR SPINNING D':
    12. }
    TEACH ME THE WAY OF CORRECT CIRCUITS MASTERS :C
    The arduino projects book I got isn't covering a lot of this :/

    Q1: What am I doing wrong?
    Q2: Why is there four ground pins on the bridge? Can I use one of them for connecting to ground with both my 9V power supply and the Arduino's ground?

    Thank you!
     
  2. pwdixon

    Member

    Oct 11, 2012
    488
    56
    You need to tell us what h-bridge chip you are using.
    I expect that you need to connect more GNDs on the chip perhaps.
     
  3. Captain E

    Thread Starter Member

    Jun 16, 2015
    81
    6
    Sry for the delay I went to the hardware store ^^

    It's a L2930NE and I still need help :/
     
  4. pwdixon

    Member

    Oct 11, 2012
    488
    56
    It looks like all four grounds on the chip must be connected for it to work correctly although the datasheet is not greatly forthcoming on the subject.
     
  5. uzair shahzad

    New Member

    Jul 1, 2015
    2
    0
    Bro that chip is using circuit for running motor ... study data sheet for this IC.... Do not use high amp rating motor be care full and strict to IC rating
     
  6. Captain E

    Thread Starter Member

    Jun 16, 2015
    81
    6
    All GND pins are now connected, but still not working :/
     
  7. Captain E

    Thread Starter Member

    Jun 16, 2015
    81
    6
    For running motor, yes I know, that's what I'm trying to do. Data sheet and I dont get along.. The motors are fine :3
     
  8. Captain E

    Thread Starter Member

    Jun 16, 2015
    81
    6
    Still no progress.. Been sitting here for some time now with the damn bridge... :C
    Have anyone of you used these ones before?
     
    Last edited: Jul 1, 2015
  9. shortbus

    AAC Fanatic!

    Sep 30, 2009
    4,004
    1,525
    The grounds on the 293 serve two functions, they are grounds and 'heat sinks' for the chip. Don't know anything about Ardino's or any micro's, but looks like you have the 293 "en1-2" pin wired to a PWM output from the micro. If the output is a PWM it won't work, it needs a steady voltage of at least 3V minimum, to enable the 293.

    And those chips are notorious for the voltage they drop across them. Your 9V is that from a "transistor radio" PP3 battery? If so they are not really suited for motors, not enough power from them. They can measure 9V and still not have enough current for a motor.
     
    Last edited: Jul 1, 2015
  10. Captain E

    Thread Starter Member

    Jun 16, 2015
    81
    6
    Thanks alot for helping me. All outputs from the micro is now digital 0V/5V. Unfortunately it is still not working :/

    I checked with a multimeter on the outputs from the bridge, and I noticed that BOTH of the outputs gives ~0.8V to both poles of the motor.
    Shouldn't just one of them do this and the other one work as the ground pin for the motor? Still 0.8 is to small, but this might be some error that will take us to the fix?
     
  11. shortbus

    AAC Fanatic!

    Sep 30, 2009
    4,004
    1,525
    OK new question for you, are you making both 1A and 2A pins on the 293 high at the same time? If so that could be your problem. One of the "A" pins should be high and the other low for motor opperation. The outputs of the 293 are 'totem pole', so one of them has to be off to complete the circuit. If both "A" pins are high there is no path to ground for the motor. Check out figure #5 on page #9 of this data sheet. Especially the 'truth table' used for the circuit.
    http://www.google.com/url?sa=t&rct=...odSPGOdUTVnna3Sv2uDP0_A&bvm=bv.96952980,d.eXY
     
  12. Captain E

    Thread Starter Member

    Jun 16, 2015
    81
    6
    Nope, the control pins for the motor is different. One HIGH and one LOW.

    Thanks tho :/
     
  13. Captain E

    Thread Starter Member

    Jun 16, 2015
    81
    6
    My circuit is still exactly like the circuit I posted as an image, and to me it looks like it should be working, but nah :/

    What I'm sure of:

    - the enable pin is given 5V/HIGH constantly.
    - the battery gives about 7V to the external power spot, bridge-pin 8.
    - the 5V for operating the bridge is given to the correct spot, bridge-pin 16.
    - one of the two control-pins is given 5V constantly, and the other one 0V constantly.
    - both grounds (bridge-pin 4 & 5) are connected to a common ground with the battery and arduino.

    so basically still the same circuit as the image I posted, and the output and inputs are correct.

    Maybe the bridge is broken? =0
     
    Last edited: Jul 2, 2015
  14. shortbus

    AAC Fanatic!

    Sep 30, 2009
    4,004
    1,525
    Is this on a breadboard? Or soldered on vero or strip board? Some times a low priced breadboard doesn't make good contact with pins of a chip. Or the h-bridge chip could be fried.

    Isn't 7V the minimum voltage rating from the data sheet? If not a name brand chip(TI or the like) the minimum voltage might not be enough.

    Running out of ideas for you.:) I'm not an engineer just a hobby type guy.
     
  15. Captain E

    Thread Starter Member

    Jun 16, 2015
    81
    6
    I'm using the breadboard that comes with the the starters kit of Arduino UNO, which the bridge came with aswell, so that would be weird :0


    From its datasheet:
    It should work with 5V :/


    I appreciate that you give me the help you can =)

    Today is electronics-shopping-mania and I'll get a socket for the bridge, and maybe it will work then, if fitting in the breadboard is the problem.
    I'll try and post back how it went later today :)
     
  16. pwdixon

    Member

    Oct 11, 2012
    488
    56
     
  17. PeterCoxSmith

    Member

    Feb 23, 2015
    148
    38
    Have you tried to run the motor directly from the battery? That is a simple test to start with. Disconnect the motor from the circuit and make sure there is no mechanical load and the shaft is free to turn. Apply the battery and see the shaft spin. It should spin at maximum unloaded speed and draw a lowish current. You could measure the current too.
     
  18. Captain E

    Thread Starter Member

    Jun 16, 2015
    81
    6
    this just in:
    BREAKING NEWS:
    After a nice electronics shopping day, I got home with a few sockets that fits with the bridge.
    I attached it on the sock, but realiced it then got worse connection to the breadboard. I took it out, got some problem tho which ended up with a few of the bridge pins was bent, so I simple bended them back.
    I once again connected the h-bridge the same way as I have done before, with the help from you guys: all four bridge-grounds connected to the common ground, pushing at the bridge and such,

    ..AND IT WORKED THIS TIME!! ヽ(◉◡)ノ
    (the motor is now going vroooom the way it should!)

    I dont know why though, the only things different this time was:
    - a completely new battery and a new manufacturer (still a 9V alkaline though)
    - some bending on the pins..


    But also as you guys said, it needs a little push, as the broadband connection of it is terrible. (I did this earlier aswell, but that time it didn't work)

    Another discovery:
    Only ONE ground had to be connected for it to work, any of the four grounds, even on the other side of the bridge.. :0


    Thank you guys for your friendly and helpful support! You guys rock

    [​IMG]
     
    shortbus likes this.
  19. shortbus

    AAC Fanatic!

    Sep 30, 2009
    4,004
    1,525
    The four grounds being hooked to a pad on a pcb is to act like a heatsink for the chip. Glad you got it to work!
     
    Captain E likes this.
Loading...