EEVblog Electronics Community Forum

Electronics => Beginners => Topic started by: kicken on November 20, 2016, 08:38:56 am

Title: Understanding comparator output current
Post by: kicken on November 20, 2016, 08:38:56 am
Having finally gotten the hang of 555-timer circuits (i think) I thought I'd expand my knowledge a bit by trying to incorporate some binary counter ICs and a comparator.  I create a circuit that I think should roughly count seconds using two 4-bit counters.  I'm also using two 4-bit comparators to determine when the count has reached 59.  At that point I want to turn on a transistor.

I got confused however when trying to figure out a resistor value for the transistor base.  I went to the datasheet ( for my comparator to see what the current limit is on it's output and it listed a bunch of negative values for the output high and also no maximum value.  I was planning on using a 5V source for my circuit, and if I am understanding the datasheet correctly that means the output pin in a high state has a typical current of -1mA. 

I did a bunch of reading regarding negative current, sink vs source current, active high vs active low, etc and so far things are not much clearer to me than before.  If my understanding is correct the the datasheet is saying that roughly 1mA would be provided by the comparator to drive the transistor.  Does this also mean I don't actually need a current limiting resistor on the transistor base as the current is already limited?

Would appreciate any insight into this datasheet.  I'm having a hard time understanding what it's saying and what it means for my circuit planning. 
Title: Re: Understanding comparator output current
Post by: evb149 on November 20, 2016, 10:09:36 am
It will not limit the current for you reliably.  They give typical and minimum but no maximum though you can see from the temperature variation related figures that you could expect somewhere between 1mA and 6.8mA plus or minus source or sink given the particular test conditions.  But a BJT's base will draw "lots" of current when the VBE is forward biased more than about 600mA and there is not external emitter resistance.
So the best way to calculate the base series resistor is to assume that the comparator is sending 1mA or less current to the BJT base.  Given your supply voltage and the slight (0.5V, 0.4V?) voltage drop of the comparator when sourcing/sinking 1mA, and given around 650mV to 750mV VBE figure out what the voltage drop of the resistor at 1mA must be to drop the rest of your maximum supply voltage's potential besides what the comparator VOH/VOL drops and what the VBE value may be.  V = I*R so R=V/I and V is your desired voltage drop of the mimumum supply voltage - the comparator drop - the VBE drop and I=1mA.

Of course for a reasonable transistor 1mA base current is much more than you need to have heavy collector to emitter current flow if the Beta is 50 or 100 or more.. so you could really reduce the base current to maybe 0.5mA or 0.1mA or whatever depending on your BJT hFE / Beta range and temperature and the desired collector current.

Title: Re: Understanding comparator output current
Post by: danadak on November 20, 2016, 02:23:44 pm
For bipolar transistor as switch -

If you are trying to use the transistor s a switch then preferably you want it
saturated. To do that rule of thumb is to "force beta" to ~10, eg. Ibsat =
Icsat / 10

That will minimize Pdiss in the transistor switch and realize Vcesat. Not their
are some transistor if you interchange collector and base youc an get even
lower Vcesat values.

Regards, Dana.
Title: Re: Understanding comparator output current
Post by: Zero999 on November 20, 2016, 11:25:51 pm
How much current do you need the transistor to switch?

Perhaps you should consider a logic level MOSFET, rather than a BJT? MOSFETs don't draw any current from the control circuit, apart for a short length of time when it's switched on/off.
Title: Re: Understanding comparator output current
Post by: kicken on November 21, 2016, 03:37:20 am
I'm basically just using the transistor as a switch to pull the load pin on my counter ICs to ground so they will reset to 0 on the next clock cycle.  To do this I just connected the collector to my +5v along with a 1k resistor and tied the reset line in just after the resistor.  If my understanding is correct then when the transistor turns on the line will be pulled low and about 5mA will be flowing through the transistor.  I mostly just stuck in a 1k because it's what I have on hand.  I'm guessing I could use a higher value and reduce the current even more yet still have it work ok.  I've not yet bought any of the counter or comparator parts  yet so I could add some bigger resistors to the list.