Shop OBEX P1 Docs P2 Docs Learn Events
h bridge with sx please help, another cat door project — Parallax Forums

h bridge with sx please help, another cat door project

CapdiamontCapdiamont Posts: 218
edited 2008-05-13 14:31 in General Discussion
I built a h bridge circuit, using the formula on the h bridge and prop topic. However it doesn't seem to have enough power. The motor is from a ink jet printer, and I measured .2 amps at 12vDC

The main transistors are capable of 2-3 amps.

I figured 7.5 ohm for r1/r2 used 7 ohm(used 5 resistors in series, and measured it)

I figured 95 ohm for r3/r4 used 100 ohm. I used 5v since it was coming from the SX.

Running straight from the power supply, the motor runs fine at 5v, or 12v. So I think I don't have something quite right.

Post Edited (Capdiamont) : 5/4/2008 6:59:04 PM GMT

Comments

  • Beau SchwabeBeau Schwabe Posts: 6,568
    edited 2008-04-21 14:17
    Capdiamont,
    ·
    Only thing that I can suggest is to double check your wiring and your calculations, and make sure that the E-B-C of the transistors is correct.

    7.5 Ohms seems a little low.... more like 750 Ohms·· ...·· same with the 95 Ohms.... more like 9.5K Ohms

    H-Bridge Primer·


    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Beau Schwabe

    IC Layout Engineer
    Parallax, Inc.

    Post Edited (Beau Schwabe (Parallax)) : 4/21/2008 2:23:49 PM GMT
  • CapdiamontCapdiamont Posts: 218
    edited 2008-04-21 15:20
    I'm tempted to just try your values,

    double the measured amps .2 is .4 amps. / 10 hfe = .04amp(40miliamps)

    12v-1.8 drop/.04=255 (a little error here, hummm) r1/r2

    .04/10 hfe = .004

    5v-1.2 drop/.004 = 950 (another error here)

    if the above math is correct I need to redo things. I still don't get K ohms on the 2nd one, though.

    so 250 ohm, for the r1/r2?

    and 1k for the 2nd?
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2008-04-21 17:34
    Is this thread SX related? The subject line indicates it is but it seems you're having issues not related to the use of the SX chip.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
  • CapdiamontCapdiamont Posts: 218
    edited 2008-04-21 19:56
    Well, this is my 2nd sx project. The project is another cat door one. I had built the h bridge, then did some programming, then added a load to the motor, when I noticed the lack of pep. It uses rb.0 and rb.1 for control. I have this odd problem with it not being able to program when the, motor and driver is connected, but don't want to cover that yet, until I get the driver circuit fixed. I think it maybe due to the resistors on the output pins being too low. Thus, the 1 k pins might fix that. I can't wait for the USB key.

    I'm trying to keep things modular, debug them, then move on. It should help to figure out where I went wrong. This is my 1st h bridge circuit.

    One question about the H bridge circuit. Why isn't the current needed to drive the drive/main transistors times two, since you are driving two transistors from the initial transistor?
  • RobotWorkshopRobotWorkshop Posts: 2,307
    edited 2008-04-21 20:03
    Do you have a schematic of the H-Bridge that you are trying to build? It will help anyone reading your posts follow exactly what is going on if you have one. Also, what transistors (part #) are you using?

    If you haven't done a lot with H-Bridges before you may want to consider adding opto-isolators in between the SX chip and your H-Bridge. That way if anything goes wrong with the H-bridge you'll just be replacing the opto instead of the SX chip.....

    Robert
  • Beau SchwabeBeau Schwabe Posts: 6,568
    edited 2008-04-21 20:15
    "...double the measured amps .2 is .4 amps." - Just curious, what method are you using to measure the current?


    "Why isn't the current needed to drive the drive/main transistors times two, since you are driving two transistors from the initial transistor?"
    The PNP transistor(motor drive) B-E junction, R1 or R2, NPN transistor(control) C-E junction, and NPN transistor(motor drive) B-E junction·are all in series with one another... each·of them ·"see" the same amount of current through this path.


    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Beau Schwabe

    IC Layout Engineer
    Parallax, Inc.
  • CapdiamontCapdiamont Posts: 218
    edited 2008-04-22 00:27
    I'm using the schematic Beau posted in his attachment.

    I'm using the amp meter on my multimeter(cheap), and stalling the motor.

    I measured 30.5 ohm on the motor, for .39 amps.
  • Beau SchwabeBeau Schwabe Posts: 6,568
    edited 2008-04-22 03:06
    Capdiamont,

    Silly question... you do have the ground connections shared between the SX and the H-Bridge correct?

    Also, what transistors are you using for the·main "drive" NPN and PNP transistors?


    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Beau Schwabe

    IC Layout Engineer
    Parallax, Inc.
  • RobotWorkshopRobotWorkshop Posts: 2,307
    edited 2008-04-22 03:26
    Providing some actual part #'s for the transistors you are using is important. It will quickly allow others to get the real specs on the transistors to help determine if they will really work for what you want to do. Are you using regular transistors, Darlington transistors, or are they FET's?? FET's can work great but some circuits need a voltage higher than the voltage you have for you motors in order to fully turn on.

    When you measured the current of the motor was that free running on the bench or was there a load on it? You'll want to make sure you test the motor to see what it will draw when it has real work to do and use that as a starting point to size your H-Bridge.

    Another option is one of the H-Bridge chips like the SN754410, L298, or LMD18200 which can simplify things a lot!
  • CapdiamontCapdiamont Posts: 218
    edited 2008-04-22 03:57
    I'll have to get you the transistors tomorrow, I think they are just generic transistors.

    The ground is shared.

    The the motor was stalled/stopped to obtain the load of .2

    Thanks! You all can't be thanked enough for all the help you give everybody.
  • CapdiamontCapdiamont Posts: 218
    edited 2008-04-24 19:48
    ok, main transistors are to 220 style, from jim pak

    NPN are TIP31A 10-50 hFE

    PNP TIP32AJP

    The smaller ones are radio shack,

    pnp markings:
    8827 tip32a, and 909 tip32a q r

    npn:
    hsmc tip31c 5es, same

    smaller npn:
    curved side on both, has red on top, blue on bottom
    w209 2 n 3904 and same
  • CapdiamontCapdiamont Posts: 218
    edited 2008-04-26 18:14
    I like the SN754410 chip, cheap! Not sure to make that one work exactly. Can you run two or one motor off it?

    The motor I'm using is from a ink jet printer. My thought was to attach an arm(metal) to in one position, it blocks the door, the other, unblocks the door. I think this should be good enough for the mechanics.
  • CapdiamontCapdiamont Posts: 218
    edited 2008-05-04 18:53
    I added code, which I think is attached, not sure though. One other thing I'm trying to do, as things get more complex, is to make sure formating and commenting is good, to make things easier in the long run.

    Though the code so far seems to work. Will be getting in to new territory when adding the rfid via serial. I haven't done serial comms yet. So we will see how things will go. Still can someone please review the transistor specs to see if they would work?
  • BeanBean Posts: 8,129
    edited 2008-05-05 10:51
    Capdiamont,
    · Cool project.

    · Can you not use a hobby servo for the motor ? Either normal or continuous rotation ?
    Bean.

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
    Did you know that 111,111,111 multiplied by 111,111,111 equals 12345678987654321 ?

    www.iElectronicDesigns.com



    Post Edited (Bean (Hitt Consulting)) : 5/5/2008 11:16:23 AM GMT
  • CapdiamontCapdiamont Posts: 218
    edited 2008-05-05 13:51
    Bean,
    There is no reason I can't use a servo, I just don't have any. However I have a few DC motors, and more stepper motors. I've torn apart a bunch of bad printers, for parts.
    -Larry
  • CapdiamontCapdiamont Posts: 218
    edited 2008-05-06 05:03
    Another rfid cat door project http://forums.parallax.com/forums/default.aspx?f=25&m=189227&p=2

    diy Cloning verichip 134 khz http://www.cq.cx/vchdiy.pl read distance of the glass tag is one inch

    How much would it cost for someone to design/make a 134 khz reader with about seven inches of read distance? I want it to read the cat's embedded glass tag. Be nice in the future to read a dogs embedded glass tag on a another door. I need two to four, depending on if it can use a switchable ant.
  • CapdiamontCapdiamont Posts: 218
    edited 2008-05-09 04:20
    One oem module that had a good read distance, and could do 134 khz, plus as a bonus, 125 khz, the us distributer wanted $559.00 plus freight from Germany. Not including an antenna.
  • CapdiamontCapdiamont Posts: 218
    edited 2008-05-13 14:31
    Ok, 220 ohm, and 1k resistors worked! Not sure how I messed up my math.
Sign In or Register to comment.