Re: Q: Transistor as a switch with pull down ?
- From: Jonathan Kirwan <jkirwan@xxxxxxxxxxxxxx>
- Date: Wed, 27 Jun 2007 22:12:55 GMT
On Wed, 27 Jun 2007 14:28:31 -0700, Benjamin Sølberg
<benjamin.soelberg@xxxxxxxxx> wrote:
On 27 Jun., 23:11, Jonathan Kirwan <jkir...@xxxxxxxxxxxxxx> wrote:
On Wed, 27 Jun 2007 13:36:09 -0700, Benjamin Sølberg
<benjamin.soelb...@xxxxxxxxx> wrote:
On 27 Jun., 00:44, Eeyore <rabbitsfriendsandrelati...@xxxxxxxxxxx>
wrote:
Benjamin Sølberg wrote:
Hi all.
I am interfacing an PIC microchip to a relay by using a normal NPN
transistor. The relay is connected between +12v and collector. A
protection diode in reverse has also added. Emitter is grounded. My
concerne is that by only adding a 10k resistor between base and the
digital output pin (5v) the base will be floating if the PIC failes to
start as all IO pins are default input. Would it be correct to add a
pulldown resistor at 10k and replace the IO pin to base with say a 1k
resistor.
For what purpose ? The transistor's leakage current won't be enough to turn the
relay on.
Graham
You might be right. I just wanna make sure that the transistor doesn't
turn on because it is floating
as the microcontroller is defaulted to an input pin upon startup.
So to be short: Even if the micro controller does nothing else than an
infinit loop after startup and the IO pis is
defined as an input there are no chance of the base of the transistor
can go beyond 0,7v and thereby setting
the collector emitter in an on state, even so that no other resistor
is on the base except the one from base to
the IO pin (defined as an input) ?
I hope you don't mind my exact question. I am just trying to make sure
i understod everything.
Regards
Benjamin
I think he's basically saying that internal leaking in the BJT plus
any pin leakage (input pins still leak, though not all that much)
shouldn't be enough to cause the transistor to pass 100's of mA. Even
for a moment. Some folks may also worry about you rubbing your feet
on a carpeted floor on a cold dry day and static-zapping the higher
impedance base node of the BJT and doing something untoward. But it's
not exactly floating as there are protection diodes and other
impedances present on the node. So although I'm not an expert on the
details, my experience would say it's just fine without the pull-down.
But it won't hurt anything, either. And if this were pinned out to a
connector, I'd add the pull-down.
Jon- Skjul tekst i anførselstegn -
- Vis tekst i anførselstegn -
Hi
The uC (PIC12F508) has internal pullup but you must enable it first as
i understood from the spec.
Even without that enabled, there is leakage. The spec for the part
will disclose that value, too. The programable pull-up (weak mosfet)
just adds to that.
Ok so it looks like it is safe to just have the base to IO resistor.
I can't tell you professional practice. My knowledge is as a hobbyist
only. I have used pull-downs before, myself, just to make myself more
comfortable. And if I were sending this line to a connector, I'd
definitely use a pull-down. I want to KNOW where the input signal is
going to be at, in that case. The extra resistor gives me comfort, if
nothing else.
But I'm not a professional, so others will have to weigh in on that
score.
Say I remove the IC from the socket (to program it) and accidentally
powers on the circuit, nothing is now connected
to the base except for a resistor with one pin floating. Will it be
able to turn on in any way (without the pull down resistor) ?
If this is to an important relay, let's say, and you are likely to
have folks replacing microcontrollers while powered up, I'd add the
resistor. Yes, having a nice, low impedance to ground to hold the
base is a 'nice to have.' In hobby stuff, I do it sometimes when it
is convenient (I'm not wire-wrapping or point-to-point soldering it
all up, in other words.)
Again, I am just trying to learn something from you guys :-)
Well, if you are just asking if tethering the base to ground via a
nice resistor will cover more unintended ground, then yes it will.
Jon
.
- Follow-Ups:
- Re: Q: Transistor as a switch with pull down ?
- From: Benjamin Sølberg
- Re: Q: Transistor as a switch with pull down ?
- References:
- Q: Transistor as a switch with pull down ?
- From: Benjamin Sølberg
- Re: Q: Transistor as a switch with pull down ?
- From: Eeyore
- Re: Q: Transistor as a switch with pull down ?
- From: Benjamin Sølberg
- Re: Q: Transistor as a switch with pull down ?
- From: Jonathan Kirwan
- Re: Q: Transistor as a switch with pull down ?
- From: Benjamin Sølberg
- Q: Transistor as a switch with pull down ?
- Prev by Date: Analog Switch question
- Next by Date: Re: would you rather...
- Previous by thread: Re: Q: Transistor as a switch with pull down ?
- Next by thread: Re: Q: Transistor as a switch with pull down ?
- Index(es):
Relevant Pages
|