1
\$\begingroup\$

I am trying to replace several transistors on my PCBs due to chip shortages. One such unit is a particular NPN transistor datasheet I cannot get my hands on these little guys anymore. But I figured this shouldn't be too hard to replace, but first I need to understand a few things about transistors and sizing the resistors around them before I select a candidate. This is long overdue for me because I have been using them with little understanding.

example

I am not using the unit for an amplifier but just as a switch. Above is an example circuit. Let's say there is 30mA going to the collector and the GPIO is at 3.3V. I look at the datasheet for this particular transistor and see that based on the collector emitter saturation voltage Ic/Ib = 10 which is beta. If my collector current will be 30mA then I need 3mA on the base? This means if I have a 3.3V pin on the base then I need a 3.3V/0.003A = 1.1K resistor but it would probably be a good idea to lower resistance slightly to ensure proper current. I am not sure if this is the correct procedure.

excerpt

Furthermore how do I know if a 3.3V GPIO can be on the base? I imagine there are some transistors that require a greater voltage on the base but how do I know? Is there a max and min voltage with respect to the collector? This NPN transistor is on the ground side of the circuit but I imagine I couldn't connect it to the ground side of a 1000V circuit, but I have no real justification for thinking this.

So this brings me to the root of the issue which is I am looking at this potential replacement transistor datasheet2 It appears to have a similar beta, but its reference saturation conditions are much higher although it is still Ic/Ib = 10. And I don't understand how to fully evaluate whether or not this is a replacement candidate for the example circuit.

excerpt2

\$\endgroup\$
2
  • \$\begingroup\$ I'm surprised you can't get your hands on MMBT3904s, considering they're one of the most common BJTs out there! '2222s or '4401s would be my first choice for a replacement, as similarly common transistors. \$\endgroup\$
    – Hearth
    Sep 18, 2021 at 3:32
  • \$\begingroup\$ Yea I've been trying on mouser and digikey no availability for months... \$\endgroup\$
    – Feynman137
    Sep 18, 2021 at 3:35

1 Answer 1

3
\$\begingroup\$

This means if I have a 3.3V pin on the base then I need a 3.3V/0.003A = 1.1K resistor but it would probably be a good idea to lower resistance slightly to ensure proper current. I am not sure if this is the correct procedure.

The base-emitter junction will drop about 0.9 volts when driving a current of around 3 mA into the base as per this: -

enter image description here

Hence, to calculate the base series resistor, you need to subtract 0.9 volts from the GPIO drive voltage of 3.3 volts then divide by 3 mA. So, I calculate that the resistor value is (3.3 - 0.9)/0.003 = 800 Ω.

Furthermore how do I know if a 3.3V GPIO can be on the base?

That is true, you cannot assume that a GPIO can deliver 3 mA into a load without that GPIO voltage dropping slightly so, you'd need to look in the data sheet for the GPIO driver or, just assume that it might drop to 3 volts when delivering 3 mA. Now, the series base resistor value becomes (3.0 - 0.9)/0.003 = 700 Ω. But, I'd probably go for 680 Ω.

I imagine there are some transistors that require a greater voltage on the base but how do I know?

The data sheet will provide that information.

This NPN transistor is on the ground side of the circuit but I imagine I couldn't connect it to the ground side of a 1000V circuit, but I have no real justification for thinking this.

As an example, the MMBT3904 data sheet tells you that the maximum collector-base voltage is 60 volts. It's a fundamental maximum limit specified in all BJT and MOSFET data sheets.

I am looking at this potential replacement transistor datasheet2 It appears to have a similar beta, but its reference saturation conditions are much higher although it is still Ic/Ib = 10.

You need 30 mA collector current so start there and look at DC current gain in figure 2 for 30 mA - it's still pretty high at around 250 with a half decent level of collector-emitter saturation voltage so, I'd make a reasonable jump and assume that it might be ten times lower i.e. to draw 30 mA into the collector (with the BJT acting nearly as a switch) would need a base current of about 1.2 mA.

Can you take it from here?

\$\endgroup\$
2
  • \$\begingroup\$ This was easy to follow for me except for the very last section. Two things first I don't understand where the 1.2mA came from. I was thinking because Ic/Ib = 10 we would use 3mA. I do see the h in figure 1 of the first transistor and figure 2 of the second transistor. The first having h of 200 and second 250 with the design collector current of 30mA, but because I will not be using these transistors as an amplifier what does this mean for me? \$\endgroup\$
    – Feynman137
    Sep 18, 2021 at 16:04
  • 1
    \$\begingroup\$ There's nothing wrong in using a hFE of 10 but you will probably be wasting a little bit of energy in driving the base this strongly. You can typically get away with a gain of 200 and expect the 3904 to switch down to about 1 volt between collector and emitter hence, go ten times the base current to get around 0.2 volts between collector and emitter when on. There are rules of thumb involved here and not hard science @Feynman137 \$\endgroup\$
    – Andy aka
    Sep 18, 2021 at 18:52

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.