Re: Follow up on the Stepper Question: H-Bridge



On Mar 6, 7:28 am, John Fields <jfie...@xxxxxxxxxxxxxxxxxxxxx> wrote:
On Fri, 5 Mar 2010 19:50:37 -0800 (PST), HC <hboo...@xxxxxxx> wrote:
On Mar 5, 4:17 pm, John Fields <jfie...@xxxxxxxxxxxxxxxxxxxxx> wrote:
Errors:

1. Q1 is wired backwards.

2. R4 won't be needed with Q1 wired right.

3. With Q2's source grounded,and its drain connected to +12V, what's
likely to happen when its gate is driven high?

4. Even with the ground removed from Q2's source, since it's configured
as a follower, it's gate will need to be driven substantially more
positive than
+12V in order to get 12V into the stepper winding.

5. There probably isn't enough current out of your C to drive the opto
LED directly and get a snappy output from the optotransistor.

Plus, I'm pretty sure that in bipolar mode, in order to drive the
stepper backwards and forwards and maintain the high holding torque
you'll need _two_ full bridges...

View in Courier:

+12
|
+-------+------+
| |
[Q1A] [Q3A]
| +--------+ |
+--|--[L1]--|--+
| | | |
[Q2A]| |[Q4A]
| | | |
GND--+ | MOTOR | +-GND
| | | |
[Q2B]| |[Q4B]
| | | |
+--|--[L1]--|--+
| +--------+ |
[Q1B] [Q3B]
| |
+------+-------+
|
+12

JF- Hide quoted text -

- Show quoted text -

Hey, John, thank you for your reply.  First, you are correct (in my
understanding) that there will need to be two FULL bridges.  This part
of the circuit I'm floating out there is only one quadrant of one full
H Bridge.  The lower quadrants are easy, simply control two N-Channel
MOSFETs.  It's the upper quadrants that I'm not sure about and which I
have posted here (simply one, knowing I'll need one on each side of
the H).

Second, I realize in a point you made a mistake that I made.  In the
diagram where I show 'MOTOR HERE' what I meant to illustrate is that
the motor is actually there; the source of the MOSFET does *not* tie
directly to ground, it ties directly to the motor winding I'm testing
the circuit on which, in turn, is connected to ground.  When I was
using the diagramming software (my first time with it) I could not
find a motor symbol so I just used a wire and connected it in like a
label; I'm sorry, that was confusing and easily (and correctly) read
differently than I intended.

So, basically this is just one upper leg of an H and the motor winding
actually resides between the source of the MOSFET and ground.  In the
final design there will be two of these pieces for each of two H
bridges.  For testing there is simply the one.

I have built this circuit, but I'm not sure that it's right...it just
worked for the few minutes I played with it before seeking advice from
people who know more than I.  It might work for years in actual use or
it might fry after 10 minutes..but on the bench for about 2 minutes it
worked...I'm just not sure it's *right*.

That said:

1) Q1 is a 2N3906 PNP transistor so I have it in my mind that is
switching on and off current to the gate of the MOSFET which needs a
positive input to turn on.  Therefore it should be before the load I
thought.  The 1K above it is to limit current through it 'just in
case', and the 2K2 below it is to allow the gate of the MOSFET to go
HI when Q1 is on and to pull the gate of the MOSFET LO when Q1 is
turned off.  How should it be correctly wired (assuming the diagram/
circuit is viable at all)?

---
Responding to 1 and 5, View in Courier:

+12>----------------------------+-----------+-----+
                                |           |     |
                              [10K]         |     |
                    +-------+   |           E     |
+5>------[100]------|A     C|---+--[10K]--B PNP   |
                    | -->B  |               C     |
                 +--|K     E|               |     D
                 |  +-------+               +---G NCH
                 C                          |     S
C I/O>--[1K]--B NPN                       [1K]   |                  
                 E                          |   [LOAD]
                 |                          |     |
GND>-------------+--------------------------+-----+

---

2) Okay

3) Poor diagram convention on my part

---
OK
---

4) With the motor in place like I should have drawn it it should (and
has for brief tests) work.

---
No offense intended, but you miss the point.

The reason it seems to work is because it turns the motor, but An N
channel enhancement mode MOSFET requires that its gate be driven more
positive than its source in order for the channel to be fully enhanced,
and using it with the load in the source lead means that as voltage is
dropped across the load the source voltage "follows" that voltage, with
the result that gate voltage must be driven higher than that in order to
increase the current into/voltage across the load.

The TIP11 requires the gate to be some 4 volts more positive than the
source in order to drive Rds to its minimum, so if you've got a 12V
supply that you want to use to drive a 12V motor AT 12V, (minus the I R
loss across the channel) you'll need to put >= 16V on the gate in order
to do that, like this:

+12v>------+        
           |
           D
+16V>----G
           S
           |
           +--~12v
           |
         [LOAD]  
           |
GND>-------+
---

5) I have not measured the current draw of the optoisolator.  That is
a good point and something I will need to do.  I could add *another* Q
to drive that load ... but that seems to be getting a lot of
components involved to avoid using one P-Channel MOSFET.  

---
That's the nature of the game, ;), but you're not adding another Q to
avoid using a P channel MOSFET, you're doing it to make sure you can get
enough drive out of the opto to saturate Q1 and drive the MOSFET
adequately.
---

First I'll
see where the end of my current circuit design ends (either I scrap it
or it lives) and then I'll check that.  I'd still like to go forward
with my circuit for now if for no other reason that I'll learn more as
I go through it.

---
Good idea. :-)
---

Okay, I looked at the diagram you posted.  That would be the complete
pseudo circuit for a bipolar reversing stepper motor driver.  With
that diagram as reference, the little circuit I have drawn (and am
trying to design/hammer out) would be in the positions of Q1A, Q3A,
Q1B, and Q3B, each one an instance of the circuit I have 'designed'
and am discussing here.

That image was a pill to get to (thank you for your efforts).  I tried
the link and I'm not happy with it.  Here's a tinyurl that may make it
easier to get there:http://tinyurl.com/yhv2onr

Thank you again for your time and help.

---
My pleasure. :-)

JF- Hide quoted text -

- Show quoted text -

Hi, John, thank you for your reply. I have posted a new diagram at
that link with the motor winding in proper place. I did not make the
change to the transistor because I'm sure there will be more changes
yet; I just wanted to get the original idea documented correctly.
(edit, now I have added a new drawing with the PNP oriented correctly)

In the diagram you've sent the emitter from the optoisolator is not
connected; I assume that would still be connected to ground.

No offense taken, thank you for your help and there's lots I don't
understand...even some of the basics, see below.

An admission on my part; I didn't understand how the transistors
should be wired in (to my surprise). I took quite a bit of time to go
and read and re-read about transistors, particularly PNP transistors
since your post and found my basic understanding was wrong. First, I
didn't know that the emitter went to the +V. It's frustrating when
schematic convention is to have +V at the top and -V or Gnd at the
bottom and the emitter is shown at the bottom of the schematic symbol
yet it is to be connected to +V at the top. My datasheet on the
2N3906 did not have example or test circuit schematics in it for me to
use as a guideline so I just used my experience (+ up and - down) and
that's how I got it the way it was (wrong). Since my reading I know
how to orient it correctly as you show. Another frustrating thing is
that I found some circuits with the PNP before the load and some with
it after the load; I thought a transistor acted as a switch and either
switched the load to ground (NPN) or switched the positive to the load
(PNP). But some schematics show the load before the PNP. Having a
NPN before the load or having the load before a PNP would seem to make
biasing the transistor (getting the right amount of current to flow
through the base) difficult (since the base would need to be more
positive than the emitter on a NPN but with the emitter before the
load (the voltage drop) would be at V+ and vice versa for a PNP).

I don't know but it was a frustrating misunderstanding on my part.

Okay, so if I apply +V plus 4 to the gate I should get it fully
(enhanced?) switched on. I'm confused reading the datasheet; it says
that the threshold voltage between the gate and source Vgs(th) is
between 2.1 and 4 volts. I took that to mean that it began to switch
on at between 2.1 and 4 volts (variance by each part I presume) across
the gate-source junction. I do not recognize a parameter in the list
that to me equates to the Vbe(sat) saturation voltage spec I find in
the 2N3906 datasheet. That is, to my reading, a 'threshold voltage of
2.1 to 4 volts' is not synonymous with 'this device is fully enhanced
when 2.1 to 4 volts is placed across the gate-source pins.' Should it
be? Should I read 'threshold voltage of gate-source juncture' to be
'the device is fully switched on when the gate-source juncture has
between 2.1 and 4 volts'?

I understand the bit about the 16 volts; the source, connected to the
motor winding would be at +12V when energized (before the voltage drop
of the load) so 12+4, no sweat. But in order to pull that off I need
three voltages for this circuit: 5V for the TTL/IC end, 12V for the
motor, and 16V for driving an N-Channel MOSFET in the positive
supply. Since it uses very little current I could use two 8V regs
(78L08 I think is the part ID I'm referring to) with one floating on
the first (there's a PIC programmer called the PIC16PRO40 that uses a
similar setup for achieving 13Vdc with one 8V reg riding on the output
of a 5V reg (13Vdc output).

Okay, then I need another Q to switch the optoisolator. I checked the
draw of my optoisolator and it's roughly 34mA. Maximum source/sink
current on any IO, according to the datasheet on the PIC16F684 I'm
using, is 25mA. Good call on the Q to switch that. I've redrawn the
circuit now using your suggestions. The PNP is correctly oriented, I
upped the pull-up from 3k3 to 10k, added the NPN for the optoisolator,
removed the unnecessary resistor on the PNP, tightened the drawing up
to make more room and then added a voltage supply that uses the two
78L08's I mentioned. I left off any and all filter capacitors just to
keep the drawing tidy for now and because I may have to make numerous
changes yet and I don't want to have to shuffle filter caps around the
screen. Suffice it to say, if I build this new circuit I will use
filter caps as per the datasheet for the 78L08's. http://tinyurl.com/yhv2onr

Oh, and when I said something about doing all this to avoid using a P-
Channel, what I meant was all this time and effort and the components
here exist because I don't want to use a P-Channel MOSFET to switch
the high-side of the H-Bridge. I still want to use the all-N-Channel
solution and, if nothing else, I've learned a lot in the process.

Thanks again for your help and time.

--HC


.



Relevant Pages

  • Tektronix 2235 Oscilloscope Troubles
    ... - Visually inspected the circuit boards for obvious component failures ... provide the proper voltage to turn on the CRT. ... Does this load current sound about right for the outputs of these supplies? ... overload condition somewhere in the HV supply which allowed it to operate ...
    (sci.electronics.repair)
  • Re: heat and more heat with heatsinks? what do you think?
    ... The idea was to keep the voltage regulators from drifting ... The worst was a drift of 5 volts in under 3 minutes while the best ... a tenth of a volt under no load or full load for several *days*, ... a complementary task was to make a circuit WORK with a wide ...
    (alt.comp.hardware.pc-homebuilt)
  • Re: heat and more heat with heatsinks? what do you think?
    ... The idea was to keep the voltage regulators from drifting ... a tenth of a volt under no load or full load for several *days*, ... a complementary task was to make a circuit WORK with a wide ... It wasn't until I was pretty much out of the business of designing audio ...
    (alt.comp.hardware.pc-homebuilt)
  • Re: LM828 voltage converter question
    ... that the IC must then have an interal micropower voltage inverter to ... generate the proper gate drive voltages for the "main" circuit? ... When the right-side switches turn on, the CAP- node jumps to -V. ... can be an n-channel fet with positive voltage on its gate; ...
    (sci.electronics.design)
  • Re: Need EL34 grounded-grid curves
    ... soundcard into the amp. ... I reduced voltage and bias current about 7% ... There are 2 x EL34 and 28 SS devices in that circuit of yours. ... mutually coupled load from anode, collector or drain as you have with an ...
    (rec.audio.tubes)