Book Read Free

Make: Electronics

Page 17

by Charles Platt


  When I’m working on this kind of project, I like to place it (with the vise attached) on a soft piece of polyurethane foam—the kind of slab that is normally used to make a chair cushion. The foam protects the components from damage when the board is upside-down, and again helps to prevent the work from sliding around unpredictably.

  Step by Step

  Here’s the specific procedure for building this circuit:

  1. Cut the small piece of perfboard out of a sheet that has no copper traces on it. You can cut the section using your miniature hobby saw, or you may be able to snap the board along its lines of holes, if you’re careful. Alternatively, use a small ready-cut piece of perfboard with copper circles on it that are not connected to one another. You’ll ignore the copper circles in this project. (In the next experiment, you’ll deal with the additional challenge of making connections between components and copper traces on perforated board.)

  2. Gather all the components and carefully insert them through holes in the board, counting the holes to make sure everything is in the right place. Flip the board over and bend the wires from the components to anchor them to the board and create connections as shown. If any of the wires isn’t long enough, you’ll have to supplement it with an extra piece of 22-gauge wire from your supply. You can remove all the insulation, as we’ll be mounting the perfboard on a piece of insulating plastic.

  3. Trim the wires approximately with your wire cutters.

  4. Make the joints with your pencil soldering iron. Note that in this circuit, you are just joining wires to each other. The components are so close together that they’ll prevent each other from wiggling around too much. If you are using board with copper pads (as I did), and some solder connects with them, that’s OK—as long as it doesn’t creep across to the neighboring component and create a short circuit.

  5. Check each joint using a close-up magnifying glass, and wiggle it with pointed-nosed pliers. If there isn’t enough solder for a really secure joint, reheat it and add more. If solder has created a connection that shouldn’t be there, use a utility knife to make two parallel cuts in the solder, and scrape away the little section between them.

  Generally, I insert three or four components, trim the wires approximately, solder them, trim their wires finally, then pause to check the joints and the placement. If I solder too many components in succession, there’s a greater risk of missing a bad joint, and if I make an error in placing a component, undoing it will be much more problematic if I have already added a whole lot more components around it.

  Figures 3-80 and 3-81 show the version of this project that I constructed, before I trimmed the board to the minimum size.

  Figure 3-80. Components mounted on a piece of perforated board.

  Figure 3-81. The assembly seen from below. The copper circles around the holes are not necessary for this project. Some of them have picked up some solder, but this is irrelevant as long as no unintentional short circuits are created.

  Flying Wire Segments

  The jaws of your wire cutters exert a powerful force that peaks and then is suddenly released when they cut through wire. This force can be translated into sudden motion of the snipped wire segment. Some wires are relatively soft, and don’t pose a risk, but harder wires can fly in unpredictable directions at high speed, and may hit you in the eye. The leads of transistors are especially hazardous in this respect.

  I think it’s a good idea to wear safety glasses when trimming wires.

  Finishing the Job

  I always use bright illumination. This is not a luxury; it is a necessity. Buy a cheap desk lamp if you don’t already have one. I use a daylight-spectrum fluorescent desk lamp, because it helps me identify the colored bands on resistors more reliably. Note that this type of fluorescent lamp emits quite a lot of ultraviolet light, which is not good for the lens in your eye. Avoid looking closely and directly at the tube in the lamp, and if you wear glasses, they will provide additional protection.

  No matter how good your close-up vision is, you need to examine each joint with that close-up magnifier. You’ll be surprised how imperfect some of them are. Hold the magnifier as close as possible to your eye, then pick up the thing that you want to examine and bring it closer until it comes into focus.

  Finally, you should end up with a working circuit. You can insert the wires from your power supply into two of the tiny power sockets, and plug a red LED into the remaining two sockets. Remember that the two center sockets are negative, and the two outer sockets are positive, because it was easier to wire the circuit this way. You should color-code them to avoid mistakes.

  So now you have a tiny circuit that pulses like a heartbeat. Or does it? If you have difficulty making it work, retrace every connection and compare it with the schematic. If you don’t find an error, apply power to the circuit, attach the black lead from your meter to the negative side, and then go around the circuit with the red lead, checking the presence of voltage. Every part of this circuit should show at least some voltage while it’s working. If you find a dead connection, you may have made a bad solder joint, or missed one entirely.

  When you’re done, now what? Well, now you can stop being an electronics hobbyist and become a crafts hobbyist. You can try to figure out a way to make this thing wearable.

  First you have to consider the power supply. Because of the components that I used, we really need 9 volts to make this work well. How are you going to make this 9-volt circuit wearable, with a bulky 9-volt battery?

  I can think of three answers:

  1. You can put the battery in a pocket, and mount the flasher on the outside of the pocket, with a thin wire penetrating the fabric. Note that the tiny power connector on the perforated board will accept two 22-gauge wires if they are solid core, or if they are stranded (like the wires from a 9-volt battery connector) but have been thinly coated with solder.

  2. You could mount the battery inside the crown of a baseball cap, with the flasher on the front.

  3. You can put together three 3-volt button batteries in a stack, held in some kind of plastic clip. If you try this option, it may not be a good idea to try to solder wire to a battery. You will heat the liquid stuff inside the battery, which may not be good for it, and may not be good for you if the liquid starts boiling and the battery bursts open. Also, solder doesn’t stick easily to the metallic finish on most battery terminals.

  Most LEDs create a sharply defined beam of light, which you may want to diffuse to make it look nicer. One way to do this is to use a piece of transparent acrylic plastic, at least 1/4 inch thick, as shown in Figure 3-82. Sandpaper the front of the acrylic, ideally using an orbital sander that won’t make an obvious pattern. Sanding will make the acrylic translucent rather than transparent.

  Drill a hole slightly larger than the LED in the back of the acrylic. Don’t drill all the way through the plastic. Remove all fragments and dust from the hole by blasting some compressed air into it, or by washing it if you don’t have an air compressor. After the cavity is completely dry, get some transparent silicone caulking or mix some clear five-minute epoxy and put a drop in the bottom of the hole. Then insert the LED, pushing it in so that it forces the epoxy to ooze around it, making a tight seal. See Figure 3-82.

  Figure 3-82. This cross-sectional view shows a sheet of transparent acrylic in which a hole has been drilled part of the way from the back toward the front. Because a drill bit creates a hole with a conical shape at the bottom, and because the LED has rounded contours, transparent epoxy or silicone caulking can be injected into the hole before mounting the LED.

  Try illuminating the LED, and sand the acrylic some more if necessary. Finally, you can decide whether to mount the circuit on the back of the acrylic, or whether you want to run a wire to it elsewhere.

  Because the LED will flash at about the speed of a human heart while the person i
s resting, it may look as if it’s measuring your pulse, especially if you mount it on the center of your chest or in a strap around your wrist. If you enjoy hoaxing people, you can suggest that you’re in such amazingly good shape, your pulse rate remains constant even when you’re taking strenuous exercises.

  To make a good-looking enclosure for the circuit, I can think of options ranging from embedding the whole thing in clear epoxy to finding a Victorian-style locket. I’ll leave you to consider alternatives, because this is a book about electronics rather than handicrafts.

  However, I will address one final issue: how long will this gadget continue flashing?

  If you check the following section “Essentials: Battery life,” you’ll find that a regular alkaline 9-volt battery should keep the LED flashing for about 50 hours.

  ESSENTIALS

  Battery life

  Any time you finish a circuit that you intend to run from a battery, you’ll want to calculate the likely battery life. This is easily done, because manufacturers rate their batteries according to the “ampere hours” they can deliver. Keep the following in mind:

  The abbreviation for amp-hours is Ah, sometimes printed as AH. Milliampere-hours are abbreviated mAh.

  The rating of a battery in amp-hours is equal to the current, in amps, multiplied by the number of hours that the battery can deliver it.

  Thus, in theory 1 amp-hour can mean 1 amp for 1 hour, or 0.1 amp for 10 hours, or 0.01 amp for 100 hours—and so on. In reality, it’s not as simple as this, because the chemicals inside a battery become depleted more quickly when you draw a heavy current, especially if the battery gets hot. You have to stay within limits that are appropriate to the size of the battery.

  For instance, if a small battery is rated for 0.5 amp-hours, you can’t expect to draw 30 amperes from it for 1 minute. But you should be able to get 0.005 amps (i.e., 5 milliamps) for 100 hours without any trouble. Remember, though, that the voltage delivered by a battery will be greater than its rated voltage when the battery is fresh, and will diminish below its rated voltage while the battery is delivering power.

  According to some test data that I trust (I think they are a little more realistic than the estimates supplied by battery manufacturers), here are some numbers for typical batteries:

  Typical 9 volt alkaline battery: 0.3 amp-hours, while delivering 100 mA.

  Typical AA size, 1.5-volt alkaline battery: 2.2 amp-hours, while delivering 100 mA.

  Rechargeable nickel-metal hydride battery: about twice the endurance of a comparably sized alkaline battery.

  Lithium battery: maybe three times the endurance of an alkaline battery.

  Background

  Maddened by measurement

  Throughout most of this book, I’ve mostly used measurements in inches, although sometimes I’ve digressed into the metric system, as when referring to “5-mm LEDs.” This isn’t inconsistency on my part; it reflects the conflicted state of the electronics industry, where you’ll find inches and millimeters both in daily use, often in the very same data sheet.

  The United States is the only major nation still using the old system of units that originated in England. (The other two holdouts are Liberia and Myanmar, according to the CIA’s World Factbook.) Still, the United States has led many advances in electronics, especially the development of silicon chips, which have contacts spaced 1/10 inch apart. These standards became firmly established, and show no sign of disappearing.

  To complicate matters further, even in the United States, you can encounter two incompatible systems for expressing fractions of an inch. Drill bits, for instance, are measured in multiples of 1/64 inch, while metal thicknesses may be measured in decimals such as 0.06 inch (which is approximately 1/16 inch).

  The metric system is not necessarily more rational than the U.S. system. Originally, when the metric system was formally introduced in 1875, the meter was defined as being 1/10,000,000 of the distance between the North Pole and the equator, along a line passing through Paris—a quixotic, Francocentric conceit. Since then, the meter has been redefined three times, in a series of efforts to achieve greater accuracy in scientific applications.

  As for the usefulness of a 10-based system, moving a decimal point is certainly simpler than doing calculations in 64ths of an inch, but the only reason we count in tens is because we happen to have evolved with that number of digits on our hands. A 12-based system would really be more convenient, as numbers would be evenly divisible by 2 and 3.

  As we’re stuck with the whimsical aspects of length measurement, I’ve created the charts in Figures 3-83 and 3-84 to assist you in going from one system to another. From these you will see that when you need to drill a hole for a 5 mm LED, a 3/16-inch drill bit is about right. (In fact, it results in a better, tighter fit than if you drill an actual 5 mm hole.)

  Figure 3-83. Because units of measurement are not standardized in electronics, conversion is often necessary. The chart on the right is a 5x magnification of the bottom section of the chart on the left.

  Figure 3-84. This chart allows conversion between hundredths of an inch, conventional U. S. fractions of an inch, and fractions expressed in thousandths of an inch.

  Experiment 15: Intrusion Alarm Revisited

  Time now to add some of the enhancements to the intrusion alarm that I discussed at the end of Experiment 11. I’m going to show you how the alarm can be triggered if you install various detectors on windows and doors in your home. I’ll also show how the alarm can be wired so that it locks itself on and continues to make noise even after a door or window is reclosed.

  This experiment will demonstrate the procedure for transferring a project from a breadboard to a piece of perforated board that has copper connections laid out identically to the ones inside the breadboard, as shown earlier in Figure 3-72. And you’ll mount the finished circuit in a project box with switches and connectors on the front.

  When all is said and done, you’ll be ready for wholesale circuit building. The explanations in the rest of this book will get gradually briefer, and the pace will increase.

  You will need:

  15-watt pencil-type soldering iron

  Thin solder (0.022 inches or similar)

  Wire strippers and cutters

  Perforated board etched with copper in a breadboard layout

  Small vise or clamp to hold your perforated board

  The same components that you used in Experiment 11, plus:

  2N2222 NPN transistor. Quantity: 1.

  DPDT relay. Quantity: 1.

  SPDT toggle switch. Quantity: 1.

  1N4001 diode. Quantity: 1.

  Red and green 5mm LEDs. Quantity: 1 each.

  Project box, 6 × 3 × 2 inches.

  Power jack, type N, and matching power socket, type N.

  Binding posts.

  Stranded 22-gauge wire, three different colors.

  Magnetic sensor switches, sufficient for your home.

  Alarm network wiring, sufficient for your home.

  Magnetic Sensor Switches

  A typical alarm sensor switch consists of two modules: the magnetic module and the switch module, as shown in Figures 3-85 and 3-86. The magnetic module contains a permanent magnet, and nothing else. The switch module contains a “reed switch,” which makes or breaks a connection (like a contact inside a relay) under the influence of the magnet. When you bring the magnetic module close to the switch module, you may faintly hear the reed switch click as it flips from one state to the other.

  Figure 3-85. In this simple alarm sensor switch, the lower module contains a magnet, which opens and closes a reed switch sealed into the upper module.

  Like all switches, reed switches can be normally open or normally closed. For this project, you w
ant the kind of switch that is normally open, and closes when the magnetic module is close to it.

  Attach the magnetic module to the moving part of a door or window, and attach the switch module to the window frame or door frame. When the window or door is closed, the magnetic module is almost touching the switch module. The magnet keeps the switch closed until the door or window is opened, at which point the switch opens.

  The only question is: how do we use this component to trigger our alarm? As long as a small current flows through all our magnetic sensor switches, the alarm should be off, but if the flow of current stops, the alarm should switch on.

  We could use a relay that is “always on” while the alarm is armed. When the circuit is interrupted, the relay relaxes and its other pair of contacts closes, which could power up the alarm noisemaker.

  But I don’t like this idea. Relays take significant power, and they can get hot. Most of them are not designed to be kept “always-on.” I’d prefer to handle the task using a transistor.

  Figure 3-86. This cutaway diagram shows a reed switch (bottom) and the magnet that activates it (top), inside an alarm sensor. The switch contains two flexible magnetized strips, the upper one with its south pole adjacent to an electrical contact, the lower one with its north pole adjacent to an electrical contact. When the south pole of the magnet approaches the switch, the magnetic force (shown as dashed lines) repels the south contact and attracts the north contact, causing them to snap together. Two screws on the outside of the casing are connected with the strips inside.

  A Break-to-Make Transistor Circuit

  First, recall how an NPN transistor works. When the base is not sufficiently positive, the transistor blocks current between its collector and emitter, but when the base is relatively positive, the transistor passes current.

 

‹ Prev