Shop OBEX P1 Docs P2 Docs Learn Events
Turning on my robot via the stamp... schematic — Parallax Forums

Turning on my robot via the stamp... schematic

ArchiverArchiver Posts: 46,084
edited 2003-07-28 06:45 in General Discussion
Here is a jpeg of the schematic you proposed.

besides the fact that the only visio stencil i have with electronics
only has a pnp trasistor, tell me what if I got it right.

thanks lots

http://www.cnosupport.com/images/poweron.jpg



--- In basicstamps@yahoogroups.com, "Randy Jones" <randyjones@w...>
wrote:
> You will connect the P-channel MOSFET between Battery + and the
load you
> want to power, with the MOSFET "source" pin to B+ and "drain" pin
to the
> load. For the MOSFET to be off, its gate must be at the same
voltage as its
> source pin (B+). To turn on the MOSFET, the gate voltage must be
more
> negative than the source -- in other words, closer to ground.
>
> If you were switching a +5V power source, you could drive the
MOSFET gate
> directly from the Stamp pin... When the Stamp pin was high (+5V),
the
> MOSFET would be off, since the gate and source pins would be at the
same
> voltage. Remember that the source is connected to B+, which would
be 5V in
> this case. When the Stamp pin was driven low, the MOSFET gate
would be at
> 0V and the source still at 5V. So the gate would be more negative
than the
> source by 5V, and the MOSFET would turn on.
>
> Since your battery supply is 7.2V, you can't connect the MOSFET gate
> directly to a Stamp pin, because you would never be able to fully
turn the
> MOSFET off... When the Stamp pin is high at 5V, there is still a
2.2V
> difference between B+ and the Stamp pin, which would make the gate
2.2V
> negative relative to the source. Fortunately, there is an easy
solution...
>
> We will use one more transistor, and it can be a dirt-cheap NPN
such as a
> 2N3904, PN2222, or whatever. First, connect a resistor between the
MOSFET
> gate and B+ to pull-up the gate voltage so the MOSFET will be
normally off
> until we turn it on. This is important since the Stamp initially
powers up
> with all pins as high-impedance inputs, and noise could turn on the
MOSFET.
> The resistor value isn't critical; lower values provide more noise
immunity
> but will consume more current when we switch on the MOSFET.
Something in
> the 10k to 50k range should be fine.
>
> The NPN transistor's base will be connected to the stamp pin
through a base
> resistor to limit the current. Since the transistor will be
switching very
> little current, the base resistor can be fairly large -- 10k, or
> considerably higher, should work fine. Connect the NPN's emitter
pin to
> ground and its collector to the MOSFET gate. That's it.
>
> When the Stamp pin is driven high, a small current will flow
through the
> resistor and the NPN's base, turning it on. This effectively
connects the
> MOSFET gate to ground, turning on the MOSFET. When the Stamp pin
is made
> low, there is no current flowing through the NPN's base, and it
turns off
> (very high resistance). Now the MOSFET's gate is pulled to B+ by
its
> gate-source resistor, and the MOSFET is turned off.
>
> I would probably start with 10k resistors in both places, which
would result
> in current consumption of a couple milliamps total for this part of
your
> circuit. If you wanted to play with larger resistor values, it
could
> probably be reduced even more. With the amount of power used by
the 'bot,
> this is just a drop in the bucket and probably not worth worrying
about.
>
> Randy
>
> www.glitchbuster.com
>
>
>
Original Message
> From: "nestlerv" <nestlerv@a...>
> To: <basicstamps@yahoogroups.com>
> Sent: Saturday, July 26, 2003 11:51 PM
> Subject: [noparse][[/noparse]basicstamps] Re: Turning on my robot via the stamp...
>
>
> > Well thank you to all for your much valued input.
> >
> > FYI the 3000 mAh battery lasts about 25 to 30 min on a full
charge.
> >
> > The mosfet stratedy sounds the most advantageous for the reasons
you
> > mentioned, no power consumption of the battery and better able to
> > handle the current, oh and the cost. As they say, "you da man."
> >
> > So the mosfet IRF9530 can be controlled with the stamp output?
> >
> > I will draft a schematic of what Randy described for your
critiquing.
> >
> >
> >
> >
> >
> > --- In basicstamps@yahoogroups.com, smartdim@a... wrote:
> > > In a message dated 7/26/2003 1:56:08 PM Pacific Daylight Time,
> > > randyjones@w... writes:
> > >
> > > > Another good method would be a p-channel MOSFET power
> > transistor, which
> > > > would be more compact and probably less expensive than the
> > relay. Also, the
> > > > relay coil would consume battery power, while the MOSFET would
> > not, since it
> > > > requires no current to keep it turned on.
> > > >
> > > > Matt Gilliland's books, The Microcontroller Application
> > Cookbook, and The
> > > > ... Cookbook 2 have many circuit examples like this. They're
> > very handy
> > > > when you know what you want to do, but need to see how it's
> > commonly done.
> > > > His examples show the IRF9520 p-ch MOSFET in positive side
> > switching
> > > > applications like this, but I prefer the IRF9530 which is
only a
> > few cents
> > > > more and has much higher rated current and lower on
resistance.
> > For
> > > > example: max continuous current = 14A, max pulsed current =
> > 56A, max
> > > > operating voltage = 100, etc. You can get them for under a
buck
> > if you know
> > > > where to look ;-)
> > > >
> > > > Randy
> > > >
> > > > www.glitchbuster.com
> > >
> > >
> > > Randy brings up excellent points......much cleaner than a relay
> > >
> > >
> > > [noparse][[/noparse]Non-text portions of this message have been removed]
> >
> >
> > To UNSUBSCRIBE, just send mail to:
> > basicstamps-unsubscribe@yahoogroups.com
> > from the same email address that you subscribed. Text in the
Subject and
> Body of the message will be ignored.
> >
> >
> > Your use of Yahoo! Groups is subject to
http://docs.yahoo.com/info/terms/
> >
> >

Comments

  • ArchiverArchiver Posts: 46,084
    edited 2003-07-28 06:21
    Pretty close...

    The 10k resistor connected to the MOSFET source pin needs to be disconnected
    from the source pin and connected between the MOSFET gate and B+ instead.
    Then run a connection directly from the MOSFET source pin to B+ and you're
    set.

    Another way to draw it would be to connect that 10k resistor between the
    MOSFET gate pin and source pin, since the source pin is connected directly
    to B+.

    Randy

    www.glitchbuster.com


    > Here is a jpeg of the schematic you proposed.
    >
    > besides the fact that the only visio stencil i have with electronics
    > only has a pnp trasistor, tell me what if I got it right.
    >
    > thanks lots
    >
    > http://www.cnosupport.com/images/poweron.jpg
    >
  • ArchiverArchiver Posts: 46,084
    edited 2003-07-28 06:32
    Ok

    If I read you correctly, here is the changed schematic...

    http://www.cnosupport.com/images/poweron.jpg


    --- In basicstamps@yahoogroups.com, "Randy Jones" <randyjones@w...>
    wrote:
    > Pretty close...
    >
    > The 10k resistor connected to the MOSFET source pin needs to be
    disconnected
    > from the source pin and connected between the MOSFET gate and B+
    instead.
    > Then run a connection directly from the MOSFET source pin to B+ and
    you're
    > set.
    >
    > Another way to draw it would be to connect that 10k resistor
    between the
    > MOSFET gate pin and source pin, since the source pin is connected
    directly
    > to B+.
    >
    > Randy
    >
    > www.glitchbuster.com
    >
    >
    > > Here is a jpeg of the schematic you proposed.
    > >
    > > besides the fact that the only visio stencil i have with
    electronics
    > > only has a pnp trasistor, tell me what if I got it right.
    > >
    > > thanks lots
    > >
    > > http://www.cnosupport.com/images/poweron.jpg
    > >
  • ArchiverArchiver Posts: 46,084
    edited 2003-07-28 06:45
    Looks great!

    I haven't done the power calculations (based on the battery capacity and the
    time it takes to run down) but you may need a small heatsink for the MOSFET.

    Randy

    www.glitchbuster.com

    > Ok
    >
    > If I read you correctly, here is the changed schematic...
    >
    > http://www.cnosupport.com/images/poweron.jpg
Sign In or Register to comment.