Prevent signal when device is turned on

I have one of the output pins of a 16F84A hooked up to a transistor which in turn drives a relay. Though the software can drive that pin low, my concern is that during power up there might be enough current to switch the transistor.

Since this is a kit-type project I can not do major modifications, so is there a simple way to bypass the base for a brief period of time and only when the signal is high for a longer time will it actually switch the transistor ?

Reply to
grubertm
Loading thread data ...

Hm...have you noticed that that the transistor is turnin on when during power up ? From what i recall, the pins are in high Z until confired to be either input or output. There shouldnt be any current.

Seems > I have one of the output pins of a 16F84A hooked up to a transistor

Reply to
reperera

--- Yes. View in Courier:

+V | +------+ |K | [DIODE] [COIL] | | +------+ | C PICI0----[R]-----------+------B | E C | Vcc>--[C1]--+--[R1]--B 2N3904 | |K E Q1 | [CR1] | | | | | GND>--------+----------+--------+

-- JF

Reply to
John Fields

Hang a capacitor on the connection between the transistor base and it's base resistor and the 0V. (something like 1uF).

--
Posted via a free Usenet account from http://www.teranews.com
Reply to
john jardine

--
Well, of course, your highness.  Your wish is our command.  BTW,
since you\'re new here and posting from Google groups, it\'d be nice
if you\'d learn to bottom post like most of the rest of the
non-cretins on USENET do.

Thank you.
Reply to
John Fields

--
Oops... to keep the base from floating:


                                  +V 
                                   |
                                   +------+
                                   |K     | 
                                [DIODE] [COIL]   
                                   |      |
                                   +------+
                                   | 
                                   C
PICI0----[R]--------------+------B
                          |        E
                          C        |
Vcc>--[C1]--+--[R1]--+--B 2N3904   |
            |K       |    E Q1     |
          [CR1]     [R2]  |        |
            |        |    |        |
GND>--------+--------+----+--------+
Reply to
John Fields

Thanks! What is CR1 and what is it doing?

Reply to
grubertm

Okay, I see how that takes care of things while the signal is briefly high. But what happens if the pin goes low or high impedance? Won't the capacitor then discharge via the Base-Emitter ?

Reply to
grubertm

--- It's a diode like a 1N4148 and it's in there to keep the Q1 base-to emitter junction from being reverse-biased by more than about -0.7V if Vcc shuts off abruptly. It's probably not needed, but I like bulletproof when I can get it.

-- JF

Reply to
John Fields

base

(assuming of course an NPN transistor) PIC pin high for a decent period and the cap sits about 0.7V with the transistor ON. (same action with or without the capacitor) PIC pin low for a decent period and the capacitor discharges via the resistor to 0V and the transistor goes OFF. (same action with or without the capacitor)

If transistor is ON and PIC pin switched to high impedance then capacitor discharges via BE till transistor switches OFF (about 0.5V on capacitor)

If transistor is OFF and PIC pin switched to high impedance then transistor stays off. The capacitor even provides some noise filtering.

But ... If the PIC pin is liable to be switched from output to input, then there should (capacitor or no capacitor) also be an additional pullup or pulldown resistor fitted somewhere, sufficient to define the transistor ON-OFF state, under this rather odd operating condition.

--
Posted via a free Usenet account from http://www.teranews.com
Reply to
john jardine

does startup take long enough for the relay to respond? IOW: does that really matter?

huh?

a capacitor to ground will slow the response a bit.

Bye. Jasen

Reply to
jasen

ElectronDepot website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.