To get a base current from collector current in BC337.

MrChips

Joined Oct 2, 2009
34,882
That’s a good idea. I might be able to use a graph to show the value. Since we’ve been given the formula I thought we have to use formula to calculate the base value.
For the purpose of this exercise, it is ok to use the graph and work backwards.
0.8mA base current gives 140mA collector current.
hFE =140/0.8 = 175
The datasheet gives hFE min = 100 for Ic = 100mA.
Hence there is ample good reason to use hFE = 80-100 for this case.
 

panic mode

Joined Oct 10, 2011
5,026
or be more conservative....


given R_coil=85Ω and V_coil=12V from relay. I got the current flow through relay and collector which is 12V/85Ω=141mA. Then we need to choose a transistor from bunch of they provided ones (I chose BC337 as 141mA in the range) asked to find base current from previous calculations. But I’m not sure which hFE to use.

and yes I know hFE is not a constant value and all the parameters affect it that’s why I got confused
all parts have tolerances. what if the next relay is 82 Ohm or 86 Ohm or something around those numbers?
same is with the 12V supply, one of them may be 11.9V, the other may be 13.8V.
go with robust design... since you are using transistor as a switch, take consideration of the worst case scenario
13.8V/82 Ohm = 168mA
the point is that 141mA figure you got is way too idealistic.

so give yourself some breathing room. how about assuming another 25% or so just to cover all bases?
and now we are looking at current that is some 210mA.

and the hFE figure 100-630 is for Ic=100mA, but... it is lower for Ic=300mA (as low as 60).
well we do not have data for Ic=200mA so again go for the safer bet and choose 60.
in most cases even that may daring or ambitious. if you read carefully you would see post #5 where conservative value is often just 10-20. that should work as a rule of thumb even for larger transistor (they have lower gain). driving transistor hard into saturation has some characteristics such as:
lower Vce drop: this is good since closer to ideal switch. also tend to be lower heat dissipation
slower response time: in general this is not good but in this case this is completely irrelevant since relay is waaay slower
higher base current: also not ideal, in some cases second stage may be needed for buffering (normally Darlington or Sziklai). but those also have drawbacks...

so say you choose 60... and output current that can be up to 200mA
that means base current will need to be 3.33mA

Now you need to know input voltage and transistor Vbe to determine base resistor
 
Last edited:

Thread Starter

PorkChopJohn

Joined Feb 1, 2024
17
As others have stated, hFE is not some nice, fixed constant value for a given transistor part number. It varies all over the place, but within specified limits. Those limits are what the data sheet documents.

There are a number of ways that this information can be presented, and most data sheets show two or three. None of them is complete, so you have to make estimates for specific situations.

The above table gives a quick look and, if you look at the data sheet, you will probably discover that this table is specified as being at a particular junction temperature, probably 25°C.

The first line is saying that, if you take a whole bunch of these transistors, picked randomly from their production line over tiem, and put it into a circuit and adjust things to that the collector-emitter voltage is 1 V and the collector current is 100 mA, that the measured hFE should never be less than 100 nor should it ever be more than 630. Usually we only care about minimum hFE, but there are applications where too-high a gain can cause problems. Many data sheets don't specify max gains or, if they do, only do so at a few points. The second line tells you that, if the circuit is adjusted so that 200 mA of current is flowing, that the hFE should always be above 60, but they are not making any claims about what the maximum value it might be.

Many data sheets will tabulate min hFE values at four or five different collector currents (Vce=1 V is pretty common, but sometimes data at a higher voltage is also given).

Most good designs use the minimum value for design purposes, reducing it reasonably to reflect the range of Vce and Ic that the device is expected to operate at.

But sometimes you want to know what the typical values are, for instance to estimate total power consumption, on average. The data sheet may or may not list typical values.

If we look at an actual data sheet for the BC337 (from On Semiconductor -- different manufactures will present different information), we see the following graph:
View attachment 314135
This gives the typical hFE, again at that Vce = 1 V and junction temp of 25°C operating point. Here you can see that the typical hFE peaks at about 225 at about 100 mA, dropping steadily for lower currents and quite quickly for higher currents. You can also see that at very low currents the hFE can be less than any of the minimums listed in the table, so if you are going to be operating the device well away from the test conditions in the table, it's worth looking closely at the data sheet to see if you can get a better picture of the behavior.

Another graph that some, but not many, data sheets provide is the following one:

View attachment 314138
Again, these are typical values at 25°C.

Here you can get a feel for what kind of Vce voltage you can expect (on average -- don't ever loose sight of the fact that a given transistor will pretty much never be average) when you are trying to use it as a switch. The bottom end of each curve is for an hFE of 10 (the 500 mA curve goes down a bit more than that).

You might be wondering how the parameters change at different temperatures. Most data sheets are very thin on this information (this one has essentially no such information), so you are left searching for data sheets that do and then making assumptions about how the trends shown for that device can be applied to this device, or looking for general behaviors verses temperature for these types of devices.

Usually, if you need that information bad enough to go to this effort, you are probably in the realm where you really need to consider taking your own measurements to get the data you need that is germane to your specific needs.

Now, having said all that, how do you go about answering the question asked on your homework?

There isn't going to be a single, correct answer (and if your instructor thinks there is, then it is highly likely that they have never actually designed a transistor-circuit in the real world). Your best answer is going to be a range, and will be backed up by a description of the assumptions you are making to come up with it.
Thank you so much for your very detailed and cleared explanations!!
 

Thread Starter

PorkChopJohn

Joined Feb 1, 2024
17
you see that supply is 12V and load (for transistor) is the relay coil. so you need to see current drawn by relay. then knowing the worst case transistor gain, you can calculate base current. from that (and what ever is driving it) you can derive base resistor value. and don't be shy to use some decent margins. don't live on the edge...
Thank you!!
 

Thread Starter

PorkChopJohn

Joined Feb 1, 2024
17
The rule of thumb is that you use 10 as the Hfe for a saturated switch. Design for a base current of 1.4 mA and you are safe. Seriously, that is all you need to do.
Ah this was what I’ve got in my project. Just wasn’t sure if it’s correct. Thank you!!
 

Thread Starter

PorkChopJohn

Joined Feb 1, 2024
17
For the purpose of this exercise, it is ok to use the graph and work backwards.
0.8mA base current gives 140mA collector current.
hFE =140/0.8 = 175
The datasheet gives hFE min = 100 for Ic = 100mA.
Hence there is ample good reason to use hFE = 80-100 for this case.
Yes I think I used 100 for hFE. Just wasn’t sure and wanted to confirm if I’m on the right track. Thank you!!
 

WBahn

Joined Mar 31, 2012
32,930
Yes I think I used 100 for hFE. Just wasn’t sure and wanted to confirm if I’m on the right track. Thank you!!
NO!

Do NOT use a value for hFE that only applies when you are in the linear mode of operation. You are trying to use the transistor as a SWITCH, which means you want to be in either CUTOFF or SATURATION. In saturation, you want sufficient base current for FORCE a low value of beta to ensure that the Vce is very low. Us a value between 10 and perhaps 25. Don't go above that without some careful thought. Remember, the data sheet values are for the TYPICAL transistor and the transistor you will be using is guaranteed to be nontypical. Also, the hFE values in the data sheet are at a Vce of 1 V. That means your coil will not get the full voltage across it, so if you are going to intentionally design for your switch to be in the active region, you need to take that into account. You also have to take into account the power dissipated in the transistor.

Consider two cases:

Let's say that, at 130 mA that the hFE is 100 at a Vce of 1 V. (130 mA is basically 11 V across 85 Ω). So that would be a base current of 1.3 mA. The power dissipated in the decide is therefore

P = (130 mA)(1 V) + (1.3 mA)(0.8 V) = 131 mW

Now let's run it with a base current of 14 mA. The Vce is going to be well under 0.1 V, so the Ic will be about 140 mA. The Vbe will be a bit higher, probably around 0.82 V (let's call it 0.85 V). The power will not be

P = (140 mA)(0.1 V) + (14 mA)(0.85 V) = 26 mW

Not only are you getting nearly full voltage across the relay coil, but you have reduced the heat dissipation in the transistor by 80%.
 

WBahn

Joined Mar 31, 2012
32,930
The datasheet uses an hFE of 10 for saturation mode.

I found that curious because BC547 specifies an hFE of 20 and I thought that would apply to BC337.
The BC547 is a much more fully characterized device. Notice that the Collector Saturation Region chart still goes out to hFE = 10.

If they have the data to claim that a higher beta can be used in saturation, they want to use that in their spec because it reduces the power consumption (the base-emitter power starts becoming dominant at some point).

Notice that their data sheet has some inconsistencies. The table says that the typical Vcesat at Ic =100 mA, Ib = 5 mA, Tj = 25°C is 0.2 V, but their chart shows that it is a bit over 0.4 V.
 

Thread Starter

PorkChopJohn

Joined Feb 1, 2024
17
NO!

Do NOT use a value for hFE that only applies when you are in the linear mode of operation. You are trying to use the transistor as a SWITCH, which means you want to be in either CUTOFF or SATURATION. In saturation, you want sufficient base current for FORCE a low value of beta to ensure that the Vce is very low. Us a value between 10 and perhaps 25. Don't go above that without some careful thought. Remember, the data sheet values are for the TYPICAL transistor and the transistor you will be using is guaranteed to be nontypical. Also, the hFE values in the data sheet are at a Vce of 1 V. That means your coil will not get the full voltage across it, so if you are going to intentionally design for your switch to be in the active region, you need to take that into account. You also have to take into account the power dissipated in the transistor.

Consider two cases:

Let's say that, at 130 mA that the hFE is 100 at a Vce of 1 V. (130 mA is basically 11 V across 85 Ω). So that would be a base current of 1.3 mA. The power dissipated in the decide is therefore

P = (130 mA)(1 V) + (1.3 mA)(0.8 V) = 131 mW

Now let's run it with a base current of 14 mA. The Vce is going to be well under 0.1 V, so the Ic will be about 140 mA. The Vbe will be a bit higher, probably around 0.82 V (let's call it 0.85 V). The power will not be

P = (140 mA)(0.1 V) + (14 mA)(0.85 V) = 26 mW

Not only are you getting nearly full voltage across the relay coil, but you have reduced the heat dissipation in the transistor by 80%.
I didn’t think about power dissipation. Thank you!!
 

Thread Starter

PorkChopJohn

Joined Feb 1, 2024
17
Thank you all for your help!! It took me a few days to read all valuable info you provided and actually understand where they come from. I’m quite new to electronics and I found it’s a bit overwhelming at beginning.

Now can I say we want the transistor stays in saturation mode? And when the saturation mode it doesn’t matter if the base current (or V_be) a bit higher or lower, it will not affect the collector current (or V_ce)?
 

WBahn

Joined Mar 31, 2012
32,930
Thank you all for your help!! It took me a few days to read all valuable info you provided and actually understand where they come from. I’m quite new to electronics and I found it’s a bit overwhelming at beginning.

Now can I say we want the transistor stays in saturation mode? And when the saturation mode it doesn’t matter if the base current (or V_be) a bit higher or lower, it will not affect the collector current (or V_ce)?
Yes, in saturation the exact base current doesn't matter too much, as long as it is at least enough to place the device in hard saturation.
 

dl324

Joined Mar 30, 2015
18,363
Now can I say we want the transistor stays in saturation mode? And when the saturation mode it doesn’t matter if the base current (or V_be) a bit higher or lower, it will not affect the collector current (or V_ce)?
If you use the data from the manufacturer datasheet, you'll be guaranteed that the device will saturate if you use an hFE of 10.

That doesn't mean that you can't use higher values (or that you can). I've used more like 60 for 2N3904 when I was switching a relay because I didn't need the transistor to be in hard saturation.
 

WBahn

Joined Mar 31, 2012
32,930
If you use the data from the manufacturer datasheet, you'll be guaranteed that the device will saturate if you use an hFE of 10.
Are you talking about in general, or for THIS particular transistor?

Power transistors can have quite low hFE values in the active region that fall below 10 at higher currents and to get good saturation you need to force them to betas in the 3 to 5 range.
 

dl324

Joined Mar 30, 2015
18,363
Are you talking about in general, or for THIS particular transistor?
In general. I've built dozens of a relay switching circuit using randomly selected 2N3904 or a house marked NPN I have and it has always worked. I have no idea what house marked transistor is equivalent to, but it has higher beta and breakdown voltages than 2N3904.
Power transistors can have quite low hFE values in the active region that fall below 10 at higher currents and to get good saturation you need to force them to betas in the 3 to 5 range.
The OP isn't using a power transistor, so it isn't relevant to his problem.
 

WBahn

Joined Mar 31, 2012
32,930
In general. I've built dozens of a relay switching circuit using randomly selected 2N3904 or a house marked NPN I have and it has always worked. I have no idea what house marked transistor is equivalent to, but it has higher beta and breakdown voltages than 2N3904.
The OP isn't using a power transistor, so it isn't relevant to his problem.
So, in other words, NOT in general.

If you tell someone that is brand new to electronics that they are guaranteed the device will saturate if they use an hFE = 10, they will likely take you at your word and, quite reasonably, interpret it as meaning that any BJT transistor is guaranteed to saturate if they use an hFE of 10.
 

dl324

Joined Mar 30, 2015
18,363
So, in other words, NOT in general.

If you tell someone that is brand new to electronics that they are guaranteed the device will saturate if they use an hFE = 10, they will likely take you at your word and, quite reasonably, interpret it as meaning that any BJT transistor is guaranteed to saturate if they use an hFE of 10.
I'm not going to play a semantic pissing game with you.
 
Top