Make: Electronics

Home > Other > Make: Electronics > Page 12
Make: Electronics Page 12

by Charles Platt


  Theory

  See the current (continued)

  In my little experiment, I found that the maximum current at A2 was 33mA. A simple calculation using Ohm’s Law showed me that this meant the transistor’s internal resistance was near zero. This is why you should protect a transistor with some additional resistance in the circuit. If you don’t, its low internal resistance would allow a huge current flow that would immediately burn it out.

  What about the other end of its range? When it passes only 1.9 mA, the transistor has an internal resistance of around 6,000Ω. The conclusion is that depending how much current you apply to this transistor, its internal resistance varies between zero and 6,000Ω, approximately.

  So much for the theory. Now what can we do with a transistor that’s fun, or useful, or both? We can do Experiment 11!

  Figure 2-95. This is basically the same as the previous circuit, with a potentiometer added and the LED removed. Component values:

  R1: 180Ω

  R2: 10K

  R3: 180Ω

  R4: 10K

  P1: 1M linear potentiometer

  Q1: 2N2222 transistor

  Figure 2-96. The meter is measuring current flowing from the potentiometer into the base of the transistor at position A1 (see Figure 2-95).

  Figure 2-97. One end of resistor R3 has been unplugged from the breadboard so that the meter now measures current flowing out through the emitter of the transistor, into R3, at position A2.

  Experiment 11: A Modular Project

  You will need:

  AC adapter, breadboard, wire, and meter.

  LED. Quantity: 1.

  Resistors, various.

  Capacitors, various.

  Transistor, 2N2222 or similar. Quantity: 2.

  2N6027 programmable unijunction transistor (PUT). Quantity: 2.

  Miniature 8Ω loudspeaker. Quantity: 1.

  So far, I’ve described small circuits that perform very simple functions. Now it’s time to show how modules can be combined to create a device that does a bit more.

  The end product of this experiment will be a circuit that makes a noise like a small siren, which could be used in an intrusion alarm. You may or may not be interested in owning an alarm, but the four-step process of developing it is important, because it shows how individual clusters of components can be persuaded to communicate with each other.

  I’ll begin by showing how to use a transistor to make a solid-state version of the oscillating circuit that you built with a relay in Experiment 8. The relay, you may remember, was wired in such a way that the coil received power through the contacts of the relay. As soon as the coil was energized, it opened the contacts, thus cutting off its own power. As soon as the contacts relaxed they restored the power, and the process repeated itself.

  There’s no way to do this with a single bipolar transistor. You actually need two of them, switching each other on and off, and the way that this works is quite hard to understand. An easier option is to use a different thing known as a programmable unijunction transistor, or PUT.

  Unijunction transistors were developed during the 1950s, but fell into disuse when simple silicon chips acquired the ability to perform the same kinds of functions, more accurately and more cheaply. However, the so-called programmable unijunction transistor is still widely available, often used in applications such as lamp dimmers and motor controllers. Because its primary use is in generating a stream of pulses, it’s ideal for our purposes.

  If you put together the components shown in Figure 2-98, the LED should start flashing as soon as you apply power.

  Figure 2-98. Assemble these components, apply power, and the LED should start flashing.

  R1: 470K

  R2: 15K

  R3: 27K

  C1: 2.2 μF electrolytic capacitor

  D1: LED

  Q1: 2N6027 programmable unijunction transistor

  Note that this circuit will work on 6 volts. You won’t damage anything if you run it with 12 volts, but as we continue adding pieces to it, you’ll find that it actually performs better at 6 volts than at 12. If you read the next section, “Essentials: All about programmable unijunction transistors,” you’ll find out how the circuit works.

  Essentials

  All about programmable unijunction transistors

  The schematic symbol for a programmable unijunction transistor, or PUT, looks very different from the symbol for a bipolar transistor, and its parts are named differently, too. Nevertheless, it does have a similar function as a solid-state switch. The symbol and the names of the three connections are shown in Figure 2-99.

  Note that this is a rare case (maybe the only one in the whole of electronics!) in which you won’t run into confusing variations of the basic schematic symbol. A PUT always seems to look the way I’ve drawn it here. Personally I think it would be clearer if we added a circle around it, but no one seems to do that, so I won’t, either.

  The 2N6027 is probably the most common PUT, and seems to be standardized in its packaging and pin-outs. I’ve only seen it in a plastic module rather than a little tin can. Figure 2-100 shows the functions of the leads if your 2N6027 is manufactured by Motorola or On Semiconductor. If you have one from another source, you should check the data sheet.

  Note that the flat side of the plastic module faces the opposite way around compared with the 2N2222 bipolar transistor, when the two devices are functioning similarly.

  The PUT blocks current until its internal resistance drops to allow flow from the “anode” to the “cathode.” In this way, it seems very similar to an NPN transistor, but there’s a big difference in the circumstances that cause the PUT to lower its resistance. The voltage at the anode determines when the PUT allows current to flow.

  Suppose you start with, say, 1 volt at the anode. Slowly, you increase this voltage. The transistor blocks it until the anode gets close to 6 volts. Suddenly this pressure breaks down the resistance and current surges from the anode to the cathode. If the voltage goes back down again, the transistor reverts to its original state and blocks the flow.

  I’ve included another version of the “finger on the button” drawing to convey this concept. The voltage on the anode is itself responsible for pushing the button that opens the pathway to the cathode. See Figure 2-101.

  Figure 2-99. The schematic symbol for a PUT.

  Figure 2-100. In PUTs manufactured by On Semiconductor and Motorola, the leads have these functions.

  Essentials

  All about programmable unijunction transistors (continued)

  This may cause you to wonder what the function of the gate is. You can think of it as “assisting” the finger on the button. In fact, the gate is the “programmable” part of a PUT. By choosing a voltage for the gate, you establish the threshold point when current starts to flow.

  Here’s a simple take-home summary:

  The anode has to be more positive than the cathode, and the gate should be between those two extremes.

  If anode voltage increases above a threshold point, current bursts through and flows from the anode to the cathode.

  If anode voltage drops back down below the threshold, the transistor stops the flow.

  The voltage you apply to the gate determines how high the threshold is.

  The gate voltage is adjusted with two resistors, shown as R1 and R2 in the simple schematic in Figure 2-102. Typically, each resistor is around 20K. The PUT is protected from full positive voltage by R3, which can have a high value, 100K or greater, because very little current is needed to bias the transistor.

  You add your input signal in the form of positive voltage at the anode. When it exceeds the threshold, it flows out of the cathode and can work some kind of output device.

&n
bsp; The only remaining question is how we make a PUT oscillate, to create a stream of on/off pulses. The answer is the capacitor that you included in the circuit that you breadboarded at the beginning of Experiment 11.

  Figure 2-101. When voltage at the anode of a PUT crosses a threshold (determined by a preset voltage at the gate), current breaks through and surges from the anode to the cathode. In this sense, the anode voltage acts as if it presses a button itself to open a connection inside the PUT, with some assistance from control voltage at the gate.

  Figure 2-102. This simple schematic shows how a PUT is used. R1 and R2 determine the voltage at the gate, which sets the threshold point for the input at the anode. Above the threshold, current flows from anode to cathode.

  Step 1: Slow-Speed Oscillation

  Figure 2-103 is a schematic version of the previous PUT breadboard circuit shown in Figure 2-98, drawn so that the layout looks as much like the breadboard as possible.

  Figure 2-103. This makes it easier to see what’s happening in the breadboard version.

  The 15K resistor and 27K resistor establish the voltage at the gate. The 470K resistor supplies the anode of the PUT, but the PUT begins in its “off” condition, blocking the voltage. So the voltage starts to charge the 2.2 μF capacitor.

  You may remember that a resistor slows the rate at which a capacitor accumulates voltage. The bigger the resistor and/or the larger the capacitor, the longer the capacitor takes to reach a full charge. In this circuit, the capacitor takes about five seconds to get close to 6 volts.

  Theory

  Capacitor Charge Time

  The amount of time it takes for a capacitor to reach its threshold is calculated with 5RC, where R is the resistance (in ohms) of the resistor, and C is the capacitance (in farads) of the capacitor. So in this case, you’d multiply 5 by 470,000 by 0.0000022, which gives us 5.17 seconds.

  But notice that the PUT is connected directly with the capacitor. Therefore, whatever voltage accumulates on the capacitor is also experienced by the PUT. As the voltage gradually increases, finally it reaches the threshold, which flips the PUT into its “on” state. The capacitor immediately discharges itself through the PUT, through the LED (which flashes), and from there to the negative side of the power supply.

  The surge depletes the capacitor. The voltage drops back down, and the PUT returns to its original state. Now the capacitor has to recharge itself all over again, until the whole process repeats itself.

  If you substitute a 22 μF capacitor, the charge/discharge cycle should take about 10 times as long, which will give you time to measure it. Set your meter to measure volts DC and place its probes on either side of the capacitor. You can actually watch the charge increasing until it reaches the threshold, at which point the capacitor discharges and the voltage drops back down again.

  So now we have an oscillator. What’s next?

  Step 2: Beyond the Persistence of Vision

  If you substitute a much smaller capacitor, it will charge much more quickly, and the LED will flash faster. Suppose you use a capacitor of 0.0047 μF (which can also be expressed as 47 nanofarads, or 4.7 nF). This seems like an odd number, but it’s a standard value for a capacitor. This will reduce the capacitance by a factor of more than 500, and therefore the LED should flash about 500 times as fast, which should be about 1,000 times per second. The human eye cannot detect such rapid pulses. The human ear, however, can hear frequencies up to 10,000 per second and beyond. If we substitute a miniature loudspeaker for the LED, we should be able to hear the oscillations.

  Figure 2-104 shows how I’d like you to make this happen. Please leave your original, slow-flashing circuit untouched, and make a duplicate of it farther down the breadboard, changing a couple of component values as indicated. In the schematic in Figure 2-105, the new part of the circuit is in solid black, while the previous section is in gray.

  Figure 2-104. The extra components which have been added at the lower half of the breadboard have the same functions as the components at the top, but some values are slightly different:

  R4: 470K

  R5: 33K

  R6: 27K

  R7: 100Ω

  C2: 0.0047 μF

  Q2: 2N6027

  L1: 8Ω 1-inch loudspeaker

  Figure 2-105. The previous section that you built is shown in gray. Just add the new section in black.

  I want you to keep the slow-flashing circuit separately, untouched, because I have an idea to make use of it a little later. You can leave the LED blinking.

  The loudspeaker should be wired in series with a 100Ω resistor to limit the current that flows out of the PUT. The loudspeaker doesn’t have any polarity, even though it is fitted with a red wire and a black wire. You can connect it either way around.

  Initially, you may be disappointed, because the circuit will not seem to be doing anything. However, if you place your ear very, very close to the loudspeaker, and if you wired the circuit correctly, you should hear a faint buzz, like a mosquito. Obviously, this isn’t loud enough to serve any practical purpose. We need to make it louder. In other words, we need to amplify it.

  Maybe you remember that the 2N2222, which you played with previously, can function as an amplifier. So let’s try using that.

  Step 3: Amplification

  Disconnect the loudspeaker and its 100Ω series resistor. Then add the 2N2222, which is linked with the output from the PUT via a 1K resistor to protect it from excessive current. See Figure 2-107.

  The emitter of the 2N2222 is connected to ground, and the collector is supplied through the loudspeaker and its 100Ω series resistor. This way, small fluctuations in the output from the PUT are sensed by the base of the 2N2222 which converts them into bigger fluctuations between the collector and the emitter, which draw current through the loudspeaker. Check the schematic in Figure 2-108.

  Now the sound should be louder than an insect buzz, but still not really loud enough to be useful. What to do?

  Well—how about if we add another 2N2222? Bipolar transistors can be placed in series, so that the output from the first one goes to the base of the second one. The 240:1 amplification of the first one is multiplied by another 240:1, giving a total amplification of more than 50,000:1.

  There are limits to this technique. The 2N2222 can only conduct so much current before getting overloaded, and excess amplification can cause distortion. But when I built this circuit, I used a meter to verify that we’re still within the design limits of a 2N2222, and for this project, I don’t care whether the sound is slightly distorted.

  Background

  Mounting a loudspeaker

  The diaphragm or cone of a loudspeaker is designed to radiate sound, but as it oscillates to and fro, it emits sound from its back side as well as its front side. Because the sounds are opposite in phase, they tend to cancel each other out.

  The perceived output from a loudspeaker can increase dramatically if you add a horn around it in the form of a tube to separate the output from the front and back of the speaker. For a miniature 1-inch loudspeaker, you can bend and tape a file card around it. See Figure 2-106.

  Better still, mount it in a box so that the box absorbs the sound from the rear of the loudspeaker. For purposes of these simple experiments, I won’t bother to go into the details of vented enclosures and bass-reflex designs.

  Figure 2-106. A loudspeaker emits sound from its bottom surface as well as its top surface. To increase the perceived audio volume, use a cardboard tube to separate the two sound sources, or mount the speaker in a small box.

  Figure 2-107. By adding a 2N2222 general-purpose transistor, we amplify the signal

  from Q2:

  R8: 1K

  Q3: 2N2222

  Other components are the same as in the previous step
in constructing this circuit.

  Figure 2-108.

  Add the second 2N2222 as shown in Figure 2-109. In Figure 2-110, once again the previously wired section is in gray.

  If the accumulation of electrical components is beginning to seem confusing, remember that each cluster of parts has a separate defined function. We can draw a block diagram to illustrate this, as in Figure 2-112.

  Using the second 2N2222, you should find that the output is more clearly audible, at least within the limits of your tiny 1-inch loudspeaker. Cup your hands around it to direct the sound, and you’ll find that the volume seems to increase. You can also try using a 3-inch loudspeaker, which will create a generally better audio output while still remaining within the limits of the little 2N2222 transistor. See Figure 2-106, shown previously, and Figure 2-111.

  Figure 2-109. Q4 is another 2N2222 transistor that further amplifies the signal. It receives power through R9: 2.2K.

  Figure 2-110. This schematic is comparable with the component layout in Figure 2-109.

  Figure 2-111. The 2N2222 transistor is quite capable of driving a 3-inch loudspeaker, which will create much better sound than a 1-inch speaker.

  Step 4: Pulsed Output

  If you wanted to use this audio signal as some kind of an alarm, a steady droning noise is not very satisfactory. A pulsing output would be a much better attention-getter.

 

‹ Prev