The bipolar transistor is one of the oldest, but the most famous type of transistors, and is still used in modern electronics. The transistor is indispensable when it is necessary to control a sufficiently powerful load for which the control device cannot provide sufficient current. They are of different types and capacities, depending on the tasks performed. Basic knowledge and formulas about transistors can be found in this article.
Before we begin the lesson, let’s agree that we are discussing only one type of method for switching on the transistor. The transistor can be used in an amplifier or a receiver, and, as a rule, each model of transistors is manufactured with specific characteristics to make it more specialized for better performance in a particular switch.
The transistor has 3 outputs: base, collector and emitter. It is impossible to say unequivocally which one of them is the input, and which is the output, since they are all connected and influence each other in one way or another. When you turn on the transistor in the switch mode (load control), it acts like this: the base current controls the current from the collector to the emitter or vice versa, depending on the type of transistor.
There are two main types of transistors: NPN and PNP. To understand this, we can say that the main difference between these two types is the direction of the electric current. This can be seen in the picture.
For simplicity, we will study only NPN transistors, but all of this applies to PNP, taking into account that all currents are reversed.
The figure below shows the analogy between the switch (S1) and the transistor switch, where it can be seen that the base current closes or opens the way for the current from the collector to the emitter:
Knowing the characteristics of the transistor, you can get the most out of it. The main parameter is the DC gain of the transistor, which is usually designated Hfe or β. It is also important to know the maximum current, power and voltage of the transistor. These parameters can be found in the documentation for the transistor, and they will help us determine the value of the resistor on the base, as discussed later.
Using NPN transistor as a switch
The figure shows the inclusion of NPN transistor as a switch. You will find this inclusion very often when analyzing various electronic circuits. We will study how to run the transistor in the selected mode, calculate the base resistor, the transistor’s current gain and load resistance. I offer the easiest and most accurate way to do this.
1. Suppose that the transistor is in saturation mode: In this case, the mathematical model of the transistor becomes very simple, and we know the voltage at the point Vc. We will find the value of the base resistor at which everything will be correct.
2. Determination of the collector saturation current: The voltage between the collector and the emitter (Vce) is taken from the transistor documentation. The emitter is connected to GND, respectively Vce = Vc – 0 = Vc. When we know this value, we can calculate the collector saturation current using the formula:
Sometimes, the load resistance of the RL is unknown or may not be as accurate as the resistance of the relay coil; In this case, it is enough to know the current required to start the relay. Make sure that the load current does not exceed the maximum collector current of the transistor.
3. Calculation of the required base current: Knowing the collector current, it is possible to calculate the minimum required base current to achieve this collector current using the following formula:
From it follows that:
4. Exceeding the allowable values: After you have calculated the base current, and if it turned out to be lower than the one indicated in the documentation, then you can overload the transistor by multiplying the calculated base current, for example, by 10 times. Thus, the transistor switch will be much more stable. In other words, the transistor performance will decrease if the load increases. Be careful not to exceed the maximum base current specified in the documentation.
5. Calculation of the required Rb value: Given the overload 10 times, the resistance Rb can be calculated by the following formula:
where V1 is the transistor control voltage (see fig
But if the emitter is connected to ground, and the base-emitter voltage is known (about 0.7V for most transistors), and also assuming that V1 = 5V, the formula can be simplified to the following:
It is seen that the base current is multiplied by 10 taking into account the overload. When the value of Rb is known, the transistor "is configured" to work as a switch that is also called "saturation and cutoff mode "where "saturation" – when the transistor is fully open and conducts current, and "clipping" – when it is closed and does not conduct current.
Note: When we say, we do not say that the collector current should be equal. It simply means that the collector current of the transistor can rise to this level. The current will follow Ohm’s laws, like any electric current.
When we considered the transistor to be in saturation mode, we assumed that some of its parameters did not change. This is not entirely true. In fact, these parameters varied mainly due to an increase in the collector current, and therefore it is safer for overloading. The documentation indicates the change in the parameters of the transistor during overload. For example, in the table in the figure
HFE (β) varies with collector current and VCEsat voltage. But VCEsat itself changes depending on the collector current and base, as shown in the table below.
The calculation can be very difficult, since all the parameters are closely and complexly interrelated, so it is better to take the worst values.
Typical transistor switch application
1. Relay control
In modern electronics, a transistor switch is used to control electromagnetic relays, which consume up to 200 mA. If you want to control the relay logic chip or microcontroller, the transistor is indispensable. On the picture
2. Connecting an open collector transistor:
Many devices, such as the 8051 microcontroller family, have open collector ports. The resistance of the external transistor base resistor is calculated as described in this article. Note that the ports can be more complex, and often use field-effect transistors instead of bipolar ones and are called open drain outputs, but everything remains exactly the same as in the figure.
3. Creating a logical element OR NOT (NOR):
Sometimes in the circuit it is necessary to use one logical element, and you do not want to use a 14-pin chip with 4 elements either because of cost or place on the board. It can be replaced by a pair of transistors. Note that the frequency characteristics of such elements depend on the characteristics and type of transistors, but usually below 100 kHz. Decreasing the output resistance (Ro) will increase the power consumption, but will increase the output current. You need to find a compromise between these parameters.
The figure above shows the logical element OR NOT built using 2x transistors 2N2222. This can be done on PNP 2N2907 transistors, with minor modifications. You just have to take into account that all electrical currents then flow in the opposite direction.
Search for errors in transistor circuits
If a problem occurs in circuits containing many transistors, it can be very difficult to know which one is faulty, especially when they are all soldered. I give you some tips that will help you find the problem in such a scheme quickly enough:
1. Temperature: If the transistor gets very hot, there’s probably a problem somewhere. Not necessarily what the problem is in the hot transistor. Usually the defective transistor does not even heat up. This increase in temperature may be caused by another transistor connected to it.
2. Measurement of VCE transistors: If they are all of the same type and all work, then they should have approximately the same VCE. Finding transistors with different VCEs is a quick way to detect defective transistors.
3. Voltage measurement on the base resistor: The voltage across the base resistor is important enough (if the transistor is turned on). For a 5 V transistor NPN control device, the voltage drop across the resistor must be more than 3V. If there is no voltage drop across the resistor, then either the transistor or the transistor control device is defective. In both cases, the base current is 0.