Archive: Ask MAKE
March 18, 2010
Ask MAKE: Hidden LCD screen?
Ask MAKE is a weekly column where we answer reader questions, like yours. Write them in to mattm@makezine.comor drop us a line on Twitter. We can't wait to tackle your conundrums!
Liz writes:
I'd like to install an outdoor wired (or wireless) low light stationary camera outside my residence - I'd like it to annunciate to a mirror sort of similar to the rear view mirror camera that only activates once the vehicle is in reverse. Is there a way to develop a mirror capable of switching to the camera on cue by using a light switch or something along those lines? The "mirror" would be located adjacent to my front door and framed aesthetically as it's primary role would essentially be a mirror until you needed to access the camera. Thank you in advance for giving us a heads up!
Oh, that sounds like a fun project! You can't really buy a mirror that can be turned on or off (at least to my knowledge). Instead, what you want is a 'one-way' or half-silvered mirror. These are the kind of mirror that you might see featured in a movie about an interrogation room, where observers can hide in an an adjacent room and look through.
The mirror doesn't really only allow light to pass in one direction, though. Instead, it has a fine metal coating on it that reflects one half of the light that goes through it, and lets the other half pass through as if it were a regular pane of glass. The trick is that the secret observation room is kept much darker than the investigation room, so that any light that does make it the wrong way through the mirror is overpowered by the reflection from the main room. If the observers mistakenly turned on their lights (or lit a cigarette), the people in the investigation room would be able to see them!
If you build a little cabinet to hide the display for your camera, and put a piece of one-way mirror glass over the front, then I think you will get the effect that you want. To be able to see the feed from the camera, just turn on the display, and it will instantly visible. Look for TV mirror glass- it's a product designed to do exactly what you are looking for. I was able to find a few manufacturers that are selling small sample sizes for ~$20, which should be more than adequate for a small camera monitor. Good luck with your project!
Posted by Matt Mets |
Mar 18, 2010 01:30 PM
Ask MAKE |
Permalink
| Comments (0)
| Email Entry |
Suggest a Site
February 18, 2010
Ask MAKE: Why are some LEDs tinted?
Ask MAKE is a weekly column where we answer reader questions, like yours. Write them in to mattm@makezine.comor drop us a line on Twitter. We can't wait to tackle your conundrums!
Jacob asks:
I'm new to electronics, and am interested in LEDs. One thing I can't figure out is why some of them are colored, while others are clear. What's the deal with that?
Hey, good question! I'd never actually thought about it before, and now that you mention it, it does seem a bit confusing. My initial guess was that the coloring might be used as a filter to block out other colors, but that doesn't make sense- in general, LEDs put out a very narrow spectrum of light, so they shouldn't need filters (and it would probably be difficult to build a filter with that narrow of a cutoff range). One exception would be more complicated LEDs such as white ones, which normally start with blue light and then use a phosphor to convert it to white light. It seemed possible that at least for those, the color could be part of the phosphor- except that white LEDs are almost always clear! Besides, the phosphor part turns out to be located right on top of the dye.
So, the best I can tell is that the tinting is added to make it easier to tell them apart when they are off. The clear ones are a pain to sort out, because you have to plug them in to figure out what color they might be. Kind of funny, but I guess that's how it goes!
Posted by Matt Mets |
Feb 18, 2010 01:30 PM
Ask MAKE |
Permalink
| Comments (3)
| Email Entry |
Suggest a Site
February 11, 2010
Ask MAKE: Cleaning an old motor?
Ask MAKE is a weekly column where we answer reader questions, like yours. Write them in to mattm@makezine.comor drop us a line on Twitter. We can't wait to tackle your conundrums!
Andy writes:
Recently I acquired a vintage Leslie speaker cabinet. The speaker cabinet uses ac motors to turn baffles and horns to create a Doppler effect. Upon opening up the speaker, I found that the motors were working, but very dirty and coated with gunk. What is the best way to clean a motor with an excess of build up?
Congratulations on your acquisition! Since the motors seem to be working fine, my guess is that it might be best to clean them cosmetically, but not to try and take them apart and rebuild them. Even though they are electrical devices, you should be able to clean them like anything else, using some form of solvent and a brush. Just make sure to let them dry out completely before you power them up!
I would start a mild detergent (soap and water). If that doesn't do the job (which it probably won't), try mineral spirits or a specialized electric motor cleaner. The biggest things I can think to look out for when using a solvent to clean the motor are that it doesn't damage the varnish on the motor windings or get into any greased bearings. The varnish is used as a coating on the motor windings, to keep them from touching each other and shorting out, so removing it would not be a great thing to do. If the motor does have greased bearings, you might want to lubricate them as well.
I've taken apart a few motors, but admittedly don't have a lot of experience in this field. Does anyone have a favorite technique or solvent that they use to restore vintage machines like this?
Posted by Matt Mets |
Feb 11, 2010 02:00 PM
Ask MAKE |
Permalink
| Comments (10)
| Email Entry |
Suggest a Site
January 15, 2010
Ask MAKE: Continous rotation potentiometer?
Ask MAKE is a weekly column where we answer reader questions, like yours. Write them in to mattm@makezine.comor drop us a line on Twitter. We can't wait to tackle your conundrums!
Paul asks:
I'm a museum educator, and working on an exhibit where I want to have a knob that you can spin around to change the color of an exhibit. I thought about using a potentiometer, but I am worried that it might break if people try to turn it too far. Any idea what I could use? Do they make a potentiometer that you can keep turning?
Interesting question. I now know that museums are pretty tough environments, so I understand your concern about it breaking. I can think of three options that might work:
- Rotary encoder
- Continuous turn potentiometer
- Regular potentiometer, with a slip clutch
Using a rotary encoder is the first thing that comes to mind. These devices have a disc with markings in them that spins when their shaft is turned, and have a sensor (usually optical) that detects when the marking move by. Because the sensor part is non-contact, they are generally more robust and can last longer than, say, potentiometers. The downsides to using them is that they are more complicated to use, and have a lower resolution than a potentiomer solution. The Arduino playground has a nice example of using a rotary encoder with a microcontroller.
A continuous turn potentiometer is an interesting option; I actually didn't know they existed until now. They certainly solve the issue of breaking by turning too far, because they don't have a hard stop. The only issue that I can think of is that their value will will probably jump suddenly from full on to full off as they make a complete revolution, which may require special handling. Actually, there is a second issue- I don't know where to buy them! Anyone have some pointers?
If you can't find a continuous turn potentiometer, a final idea might be to use a regular potentiometer, but connected indirectly through a slip clutch. The idea is to use something that will limit the amount of torque that the user can put on the potentiometer, which will prevent them from turning it too far and breaking it. You can purchase a special mechanical device that will do this, or perhaps even use a loose belt that will slip when the knob is turned too far.
Good luck with your project, and be sure to let us know how it turns out!
Have a different way to do this that you think might work better? Sound off in the comments!
Posted by Matt Mets |
Jan 15, 2010 01:00 PM
Ask MAKE |
Permalink
| Comments (23)
| Email Entry |
Suggest a Site
December 18, 2009
Ask MAKE: How to wire up LEDs?
Ask MAKE is a weekly column where we answer reader questions, like yours. Write them in to mattm@makezine.comor drop us a line on Twitter. We can't wait to tackle your conundrums!

Bjorn writes in:
I'm wondering if you could help me out with resistors. I'm a computer science guy and am very new to electronics. Most of my resistor usage in my experimentation has been because I read about situations when I should use them online and just used a specific resistor because it was recommended. Obviously this only gets me so far. How do you go about determining what level of resistance you need and when you should or need to use resistors? I didn't know I was supposed to be hooking up LEDs to my Arduinos with resistors until I started burning out LEDs and read somewhere what type of resistor someone recommended. I know it has to do with the Arduino running at 5V and most LEDs being lower voltage, but how do you know what voltage an LED is if it's not labeled? And more importantly (like my question above), even if you know what voltage and LED is how are you supposed to figure out what kind of resistor to use?
Sure thing! This question actually comes up quite a bit, and it's a good thing to understand.
Putting a resistor in series with an LED limits the amount of current that can flow through it, preventing it from blowing up. It's nice to be able to figure out an exact resistance to use, but if you aren't too worried about your light being a bit dim, you can always just stick in a largish resistor, and you will get some light. For instance, if I am making a prototype circuit and just want an indicator light that I can control from an Arduino, I'll grab a 220 ohm resistor and put it in series with the first LED I can find. It's probably fine for a quickie circuit, but if you are soldering up a project that you intend to keep around, it's probably a better idea to actually calculate the correct amount of resistance to use.
So, how do you do it? Well, for a single LED, you can use the LED circuit equation:

![]()
Unfortunately, this only helps if you know the forward voltage and current rating of your diode. So, how can one figure those out? You can make an estimate abut the forward voltage of the diode based on it's color, because the wavelength of the color and the forward voltage are roughly inversely proportional to one another. Some typical forward voltages are: Red:1.8V, Green: 2V, Blue: 3.4V. Once you have an estimate, you can measure the forward voltage of your LED by hooking it up with the suggested resistor value, and measuring the voltage across it. Then, if you were way off, you can re-calculate the resistance with the actual voltage to get a better result.
Once you know the forward voltage drop, you can choose a current value based on how bright you want the LED to be, as long as it is lower than the current rating of the device. Unfortunately, it's a little bit harder to figure out the current rating, because most LEDs will continue to operate at higher than the recommended amount. If they are, though, their lifetime will be much shorter, and they won't be as efficient at producing light. If you don't have the specifications for your LED, 20ma is probably a safe maximum.
If you don't feel like solving all of that by hand, or have a more complicated design involving multiple LEDs, you could also use an online LED calculator. This one looks nice, because it will also tell you how to hook up multilple LEDs.
Ok, enough calculations. This is what can happen if you don't connect the LED up properly:
Boom! Engineers sometimes call these 'unauthorized thermal events'
Related:
Posted by Matt Mets |
Dec 18, 2009 01:00 PM
Ask MAKE |
Permalink
| Comments (6)
| Email Entry |
Suggest a Site
December 10, 2009
Ask MAKE: Liquid level sensor for brewing system?
Ask MAKE is a weekly column where we answer reader questions, like yours. Write them in to mattm@makezine.comor drop us a line on Twitter. We can't wait to tackle your conundrums!
Brett writes in:
Hi, I am building an automated brewing system for home brew beer. It will be controlled via an Arduino and network interface. I am using 15 gallon stainless steel kegs as brewing vessels. What is the best method or type of sensor to use to accurately detect liquid levels in the kegs? The liquid won't be water alone, and all three vessels will be heated. I was thinking of using an external sight glass + a pressure sensor of some kind. Maybe someone in the Make community has a better idea or has done this before?
I have been a Make subscriber for the last two years(since I found out about you guys) keep up the great work!
Thanks Brett! So, you want to measure the level of a liquid in a tank. These are some of the ways that I can think of to do this:
- Capacitive: Measure difference in dielectric constant between air and water
- Differential pressure measurement: Measure pressure at bottom of liquid
- Optical: Use an array of light sensors to sense where liquid is/isn't
- Float: Put a float on a stick, then measure the displacement of the stick
- Weight: Weigh the liquid, and calculate volume based on density
- Conductivity: Measure liquid conductivity at a few discrete points
Out of these options, what would be best? I think for your project, the best way to go is probably to use a differential pressure sensor, like you suggested. It seems like it would be the most reliable and least invasive method. Also, it just so happens that the folks who wrote the Practical Arduino book have a Water Tank Depth Sensor project that might be a good starting point.
If you only want an approximation of the amount of liquid in a tank, a simpler way to go would be to test for conductivity at a few points along the side of the tank. You wouldn't be able to sense the exact amount of liquid present, but it would be a fine way to check if the tank is half-full or not. The folks at electronics labs built a single-point Water level detector using a PIC microcontroller, which could be expanded to measure multiple points
Capacitive sensors might work, but might be hard to set up in a metal tank. Optical sensors work the same way as the conductivity sensors, and would be more expensive, so they probably aren't worth the trouble. A float could potentially work, but could get gummed up by hops or dead yeast, so it might be unreliable. The weight sensor could also work, but I think it might be tricky to keep it calibrated.
Good luck, and remember to let us know when you have it working!
Have you attempted a system like this before? Have some experience to share, or a better way to accomplish this? Sound off in the comments!
Posted by Matt Mets |
Dec 10, 2009 01:00 PM
Ask MAKE |
Permalink
| Comments (26)
| Email Entry |
Suggest a Site
December 3, 2009
Ask MAKE: Three leaded piezo?
Ask MAKE is a weekly column where we answer reader questions, like yours. Write them in to mattm@makezine.comor drop us a line on Twitter. We can't wait to tackle your conundrums!

Chris writes in:
I have been experimenting with my Arduino and piezo buzzers as simple speakers - noisy and fun. But one question has been bugging me, what on earth is the third blue lead for on some piezos? If I leave the blue lead disconnected, the piezo seems to behave identically to its two-lead cousins. Am I missing out on some noise making opportunities?
Aha, good question. The short answer is no- the third lead is most likely used for feedback in an oscillator circuit, so leaving it disconnected shouldn't affect your circuit. The long answer is, well, maybe, if want to make your piezo into a buzzer.
There are two kinds of piezoelectric devices that are commonly sold as piezos: buzzers and transducers. Though they both use the same kind of ceramic disc to make noise, the difference is in how they are controlled. A piezo buzzer already contains some circuitry to create a buzzing noise, so all you have to do to make it work is connect it to a power source. The buzz can range from a tolerable alert to signal that your clothes are dry, to the ear-splitting noise of a fire alarm. A piezo transducer works more like a speaker, where you have to feed it an audio signal to get it to make noise. This is what you are using if you are generating your own frequencies with your Arduino.
So what does this have to do with your question? Well, it turns out that a really simple way to make a piezo buzzer is to use the feedback electrode that you were talking about to make a Harley oscillator circuit. As an example, I found this schematic in Murata's (a piezo manufacturer) Piezo Electric Sound Components Applications Manual:

The circuit is a little advanced, however the basic idea is that a small amount of the energy fed into the piezo device is fed into the input of the transistor, which amplifies the signal and feeds it back into the piezo. If the component values are chosen correctly, the resonation can be very efficient and loud, perfect for that fire alarm!
[title photo by Flickr user Josh Kopel]
Related:
Posted by Matt Mets |
Dec 3, 2009 01:30 PM
Ask MAKE |
Permalink
| Comments (1)
| Email Entry |
Suggest a Site
November 19, 2009
Ask MAKE: Software for designing circuits
Ask MAKE is a weekly column where we answer reader questions, like yours. Write them in to mattm@makezine.comor drop us a line on Twitter. We can't wait to tackle your conundrums!

Bjorn writes in:
I'm doing my 2nd Arduino project (and 2nd electronics project ever) and am trying to design some of the circuit stuff on computer instead of just wiring it up or scribbling some stuff on paper. I'm trying out Fritzing and am wondering if you have any other suggestions for software that can be used for breadboard, schematic and/or PCB design. I would like to maybe figure out/learn/teach myself enough about electronics to be able to design my own PCBs, so it'd be nice if I could do all the types of designing in one program. I downloaded Eagle but haven't really tried that out yet and am not entirely sure what that's used for, but I think it relates to PCBs.
You sound like you are off to a good start. The kind of programs you are looking for are referred to as Electronic Design Automation (EDA) tools, and traditionally allow you to draw out a symbolic representation of a circuit using a schematic capture interface, (sometimes) simulate it with a circuit simulator, and then finally lay out the circuit on a printed circuit board (PCB). In the commercial world, many companies use tools designed by Synopsys, Cadence or Mentor graphics, but these are prohibitively expensive and overly complex for most hobbyist use. You are on the right track with Fritzing and Eagle. They are both good choices for documenting your circuits and designing PCBs, although they have been designed for somewhat different purposes.

For people who don't already have a strong background in electronics, Fritzing is a great place to start. Instead of forcing you to understand the circuit schematics for each piece, you can use it's pictorial 'breadboard' mode to connect drawings that look like the actual pieces that you would place on your breadboard. It sounds kind of cutesy, but it is pretty powerful because it also generates a schematic view of your circuit. This way, you can learn what the symbols for all of your parts look like by just connecting them up and flipping between the two views. You can either leave it at that to document a project that you made on a breadboard, or try out the PCB mode to design a simple 1-layer board that you can then etch yourself. To get started, check out their tutorials.

While Fritzing is a great way to get started with electronics, if you start to do more complex things, you will eventually need to turn to a more powerful tool. The second program that you mentioned, Eagle (Easily Applicable Graphical Layout Editor), is a good choice for this. It isn't open source software, however they offer a freeware version that is powerful enough to build many useful circuits. It doesn't have a breadboard mode, so you have to start by making your circuit as a schematic. Once you have a schematic drawn up and have checked to make sure everything is connected properly, you create a new PCB and lay the components out. To get started, check out this tutorial by the folks at Sparkfun.
There are a multitude of other free PCB design programs out there. For instance, ExpressPCB is a proprietary schematic capture/PCB layout program that is closely integrated with the companies PCB fabrication service. gEDA aims to be a comprehensive open source circuit simulation/design environment, but appears to be quite complex. FreePCB looks good for designing PCBs, however it doesn't appear to include a schematic capture program.
My advice would be to stick with Fritzing and Eagle for a while, use them to design and build a few PCBs, and if you aren't satisfied with them, try out one of the other tools to see if it works better for you. Good luck!
[photo by Flickr user Zach Hoeken]
Related:
Posted by Matt Mets |
Nov 19, 2009 01:00 PM
Ask MAKE |
Permalink
| Comments (14)
| Email Entry |
Suggest a Site
November 12, 2009
Ask MAKE: Repurposing electronic detritus
Ask MAKE is a weekly column where we answer reader questions, like yours. Write them in to mattm@makezine.comor drop us a line on Twitter. We can't wait to tackle your conundrums!

Jon writes in:
I saw the tweet about sending questions to MAKE and I've got kind of a big one.
I have all this electronic detritus that I would like to re-purpose (i.e. a couple old Compaq iPaqs, a bunch of cell phones, several laptops, several old desktop computers and monitors).
I don't code but I can run a soldering iron. Short of sending this heap off to the landfill what are my options? I would like to make something cool that used all of the little screens (cell phone and iPaq) and I have seen (I don't remember where) somebody had morphed a cellphone screen (I think) into a laptop on the outside.
Sure, there are lots of options for them. If the hardware still works and you don't want it around, you can donate it to a charity. Otherwise, here are some ideas.
Mobile devices
The LCD displays on mobile electronic devices can difficult to interface directly. Your best bet may be to put new software on it. Here are some possibilities:
- Identifying Nokia LCDs: If you have a Nokia phone, you might be able to control the LCD from a microcontroller.
- PalmOrb: Turn an old palm pilot into a serial LCD.
- Linux on an iPAQ: Smartphone magazine has a nice article about getting extra life out of old Pocket PCs by installing Linux.
- PdPod: Convert an old iPod into a portable synthesizer.
- Reware: Tips and tricks for unlocking old phones and installing new firmware
Laptops
The canonical use for an old laptop is to make it into a picture frame. You can convert an older laptop into a second monitor for your desktop using some simple software. If the laptop still works but is just slow, try turning it into an internet device by installing a lightweight Linux distro such as Xubuntu. If the laptop is broken but the screen still works, you might be able to program an FPGA to control it, but note that it is not easy or cheap to do.
Desktops
The advice for usable but slower laptops holds for desktops as well- they can make a nice internet kiosk, if given a software update. If the computer is really old or broken, though, you can try to salvage components from it. The power supply can be converted into a bench supply. 5.25" floppy drives (from really old computers) usually have excellent stepper motors in them. Many PCs have a nice speaker mounted to the case, and sometimes have neat power switches. Old CRT monitors can used for art projects, such as displaying glitchy video. Personally, I've been considering using a bank of them as (very inefficient) color-controlled mood lighting.
This is a pretty open-ended question, and I'm sure that I have barely scratched the surface of what can be done with old electronic junk. Do you have a favorite use for a cast-off bit of electronics? Sound off in the comments!
Photo by Flickr user Victoria Reay
Posted by Matt Mets |
Nov 12, 2009 10:30 AM
Ask MAKE |
Permalink
| Comments (2)
| Email Entry |
Suggest a Site
November 5, 2009
Ask MAKE: Image sensors: CCD vs CMOS
Ask MAKE is a weekly column where we answer reader questions, like yours. Write them in to mattm@makezine.comor drop us a line on Twitter. We can't wait to tackle your conundrums!

Ian writes in:
I was looking at buying a digital camera, and read that there are two kinds of sensors that they can use to take a picture- CMOS and CCD. Can you tell me what the difference is, and if one is better to get?
Sure! It's actually a pretty topical question, as the inventors of the CCD just won this year's Nobel Prize! As you mentioned, there are two basic kinds of image sensor that are used in today's digital cameras, CCD (charge-coupled device) and CMOS (complementary metal oxide semiconductor). They both work by converting light energy (photons) into electric charge (electrons), and the difference is in how this charge is read out.
To start, both kinds of sensor are made of a grid of 'buckets' placed evenly across a flat semiconductor surface. Each bucket acts as an individual sensor, which only sees a tiny portion of the image. By displaying a bunch of these tiny points in a grid (using a computer monitor or printer), we see the image.
Making color images is a bit more complicated. Because the buckets are sensitive to any wavelength of visible light, if we just looked at the results we would see a monochrome image. To get color information, we arrange the sensors into groups of four, and place tiny red, green, and blue color filters over them. Each group of four sensors is what we call a pixel, and it is interesting to note that modern cameras have millions of them.
Ok, so both CCD and CMOS sensors are basically just big arrays of individual sensors, so how are they different? The difference is in how the charges are collected and read out. In a CCD, the 'bucket' that collects charge is just a capacitor. To read the image data out of the CCD, the charge in each bucket is pumped individually over to an ADC (analog to digital converter), which actually measures charge. In a CMOS sensor, each bucket contains a photodiode and some amplifier circuitry. To read the image data out, the output of each amplifier is connected to an ADC through a multiplexer, which measures the voltage at each cell.
I don't think that either technology is necessarily better, but each has its own quirks. There is an interesting site at dvxuser which talks about the different kinds of sensor artifacts associated with each kind of sensor. For most cases, though, I think that other specifications, such as ease of use and sensitivity to light, are probably more important to think about when choosing a digital camera. Good luck!
[photo by SarahCartwright]
Posted by Matt Mets |
Nov 5, 2009 10:30 AM
Ask MAKE |
Permalink
| Comments (4)
| Email Entry |
Suggest a Site
October 29, 2009
Ask MAKE: Playing back a recorded sound
Ask MAKE is a weekly column where we answer reader questions, like yours. Write them in to mattm@makezine.comor drop us a line on Twitter. We can't wait to tackle your conundrums!

George writes in:
I've been wanting to make a prank project, that I can leave somewhere to play back a recorded sound and flash some lights. I'll use LEDs for the lights, but don't know how to play back sound. Do you have any suggestions?
Aha, this sounds like it could be a fun project. I'm going to assume you are using a microcontroller to monitor an input (sound? light? time? vibration?), and then initiate a sequenced event. It's a bit late for Halloween, but this would be a good way to make lawn props that react when someone comes near your house.
Because playing back sound takes a reasonable amount of memory and speed, it's not something that can be done easily with a standard microcontroller. Instead, the best way to handle this would be to hook up another device, that can be started by the micro and then do the heavy lifting of actually playing back a sound. At least three possibilities come to mind: using a Wave Shield, hacking an MP3 player, or hacking a cheap toy with a sound recorder.
If you are using an Arduino, the Wave Shield might be an ideal solution to your problem. It is an expansion module that allows you to play sounds off of an SD card, and there is a nice library to control it as well. It runs in at about $22 bucks, which seems pretty reasonable for what you get.
If you aren't using an Arduino, or already have an old MP3 player and don't want to spend the bucks on a project you will only use once, then you can try to use that. The best way to do this is probably to wire an optocoupler to the play button on the MP3 player, and then trigger that with your microcontroller. If you have more than one sound track that you want to trigger, you could also wire up the next button, but that might get tricky. The bonus for going this way is that you could recycle some electronics junk that would otherwise go to the scrap heap.
Either of the two above solutions are great if you are only thinking of making one or two of the devices, but what if you want to make a bunch of them? In that case, it might be more economical to try hacking a cheap toy, such as this one. Somehow these are still available, and are less than $2 in quantity. The sound quality probably won't be anywhere as good, but hey, the're cheap! If you are in a rush, you could also try hacking a voice recording card that you can pick up at a local store. Good luck!
In the Maker Shed:

Posted by Matt Mets |
Oct 29, 2009 10:00 AM
Ask MAKE |
Permalink
| Comments (6)
| Email Entry |
Suggest a Site
October 22, 2009
Ask MAKE: Debouncing a switch
Ask MAKE is a weekly column where we answer reader questions, like yours. Write them in to mattm@makezine.comor drop us a line on Twitter. We can't wait to tackle your conundrums!

Jen writes in:
I'm making a circuit to blink an LED at different speeds, that I can control using a button switch. It wouldn't work until I added added some 'debounce' code. What does that mean, and why did I have to add it?
Good Question! Switch bounce is one of those rare electronic effects that is actually caused by a mechanical shortcoming. The issue is in the way the switch works. When you flip a switch (or press down on a button), you're really pushing one piece of metal against another. If this happens with sufficient force, one or both of the pieces will deform slightly, and then bounce back in the other direction. Depending on how well the switch was designed, this could go on for a number of times before both pieces stop moving. Now, all of this bouncing means that from an electrical perspective, the switch looks like it is opening and closing rapidly until the bouncing dies down. It happens very quickly, however digital electronics are fast enough to see this as a bunch of switch presses!
There are three ways to deal with this: mechanically (building a better switch), electrically (building a filter out of discrete electric components), or digitally (with software).
In your question, you mentioned that you used some debounce code, which is probably the best solution for you. For this solution, you write a software routine that runs when someone presses a button, then waits for a short time (long enough for the bouncing to have stopped) before reading the switch state. This effectively ignores any spurious signals from the switch contacts bouncing without any extra hardware. If you happen to be using the Arduino platform, try this tutorial.
If you aren't using a microcontroller, though, software isn't going to help, and you will have to try one of the other solutions. The traditional way to handle switch bounce on a breadboard is to use a resistor-capacitor (RC) filter in a low pass configuration. What this does is prevent the output of the switch from going high too quickly, which effectively filters out any high-speed signals. Check out this tutorial if you'd like to try out this method.
So, how could you re-design the switch to prevent bounce? It turns out that the most common thing to do is to wet the contacts with mercury. Because mercury is a liquid at room temperature, its surface tension keeps the contacts connected even when they bounce. The only issue with this is that mercury is pretty toxic, so you should only use this if you absolutely need to, such as when you're controlling high-power machines at fast speeds.
[photo by Flickr user russ_j_taylor]
Posted by Matt Mets |
Oct 22, 2009 10:00 AM
Ask MAKE |
Permalink
| Comments (7)
| Email Entry |
Suggest a Site
October 15, 2009
Ask MAKE: Using an optocoupler
Ask MAKE is a weekly column where we answer reader questions, like yours. Write them in to mattm@makezine.comor drop us a line on Twitter. We can't wait to tackle your conundrums!

Matt writes in:
We are working on a project to control a CW ham radio keyer using a computer, and are concerned about protecting the computer from the radio. We heard that an opto-isolator could be used for this, but aren't sure how to go about it.
Good question! An opto-coupler is a device that can be used to electrically isolate two circuits, so that a voltage spike or other problem on one side will not destroy the circuit on the other side. A common use for them is when you want to interface a computer to an AC-powered device, such as a light or a motor. Usually, the opto-coupler will not be used to control the device directly, and instead will just transfer a signal from one circuit to another.

So, how does it work? You can think of an optocoupler as a combination of an LED and a phototransistor. To send a signal, the transmitting side power the internal LED, just as you would power a regular LED. This lights up and causes the phototransistor on the other to start conducting current. You can think of it as kind of a switch at this point, and use it to turn on a low-power device directly, or turn on a relay to turn on a higher-powered device. The above circuit diagram should work for an automatic keyer. Choose the resistor based on your microcontroller voltage and the current draw of the optocoupler chip that you use. One thing to remember is that the output is polarized, so you have to make sure to connect it up so that the high voltage side is on the collector, and the low voltage side on the emitter. Good luck with your keyer!
Posted by Matt Mets |
Oct 15, 2009 10:00 AM
Ask MAKE |
Permalink
| Comments (2)
| Email Entry |
Suggest a Site
October 8, 2009
Ask MAKE: Getting started with physical computing
Ask MAKE is a weekly column where we answer reader questions, like yours. Write them in to mattm@makezine.comor drop us a line on Twitter. We can't wait to tackle your conundrums!

John writes in:
I am an artist in Santa Fe, NM. Much of my work is assemblage using old salvaged electronic equipment. I would like to start using interactive electronics. I have some electronics knowledge but am a newbie with microcontrollers, etc. I would like to know what is the best way to get started in this area of physical, interactive microcontrollers. Can some one point me in the right direction?
Sure thing! For your first time, I recommend getting a kit that is specifically designed to get you up and going with physical computing. We sell some nice Arduino-based kits in the Maker Shed -- take a look at the Getting Started with Arduino Kit and Advanced Arduino Starter Kit. These bundles are useful because they include enough instructions and parts to give you a good feel for what you can accomplish. Another good way to go might be with a BASIC stamp -- they seem to have been eclipsed in popularity by Arduino lately, but are still very capable systems.
If you would like to get some hands-on instruction, try looking for a local group that has microcontroller classes. We covered how to find them a while back.
Finally, if you want to read up a bit first, there are bunch of good books on the subject. Here are a few: Physical Computing: Sensing and Controlling the Physical World with Computers, Making Things Talk, and Getting Started with Arduino.
Got a great resource that I overlooked? Abhor Arduinos and have a better suggestion? Sound off in the comments!
Posted by Matt Mets |
Oct 8, 2009 01:00 PM
Ask MAKE |
Permalink
| Comments (11)
| Email Entry |
Suggest a Site
October 3, 2009
The Mummy's "Book of The Dead" prop
We recently had a question from a reader about this prop. "Connie" wrote in wanting to know how to replicate the mechanism that, in the movie, is used to unlock The Book's cover. Never having seen The Mummy, I went into research mode and enqueued it from Netflix. Then I watched it. Big mistake.
But, you know, to each his or her own. And "The Book of the Dead," with its ornate clasps and intricate star-shaped key, is admittedly an awesome prop. The scene Connie is referring to, I believe, occurs at almost exactly one hour into the "Deluxe Edition" cut of the film, and shows the intrepid but remarkably foolish archeologists inserting the aforementioned star-shaped key into a correspondingly star-shaped opening in the book's cover, turning it, and thereby releasing the spring-loaded cover clasps and, with them, all manner of unpleasant whatnot.
So I started Googling around, looking for dweebs enthusiasts that might have already built such a thing. And while I did not find any working mechanical replicas of the prop, I did discover the remarkably beautiful static replica shown in the photo at the top of this post by Jeff Stelter of Stelter Creative Woodworks.
I also found this video by YouTuber oneandonlyJadedMonk showing his working mechanical replica of the star-shaped key used to open the book. Connie, if you're looking for a real expert, I think this might be the man to talk to.
But as for completely working cover locks, I'm afraid I have to admit defeat. Having watched the scene a few times, I'm completely confident that a suitable lockwork could be designed and built, but actually doing either is well above my pay grade. But something I've learned writing for this blog is what an incredible resource the MAKE readership can be, and so I'm going to throw the question out to them.
How 'bout it, folks? Anybody know how this thing works? Or know of somebody's who has built one? Or, even better, know anything about the original prop?
Make: Halloween Contest 2009
Microchip Technology Inc. and MAKE have teamed up to present to you the Make: Halloween Contest 2009! Show us your embedded microcontroller Halloween projects and you could be chosen as a winner.
Posted by Sean Michael Ragan |
Oct 3, 2009 06:00 AM
Ask MAKE, Halloween, How it's made, Remake |
Permalink
| Comments (8)
| Email Entry |
Suggest a Site
October 1, 2009
Ask MAKE: Kid-powered battery charger
Ask MAKE is a weekly column where we answer reader questions, like yours. Write them in to mattm@makezine.comor drop us a line on Twitter. We can't wait to tackle your conundrums!
Phil writes in with an interesting question:
When I found out about this neat Ubuntu tablet that is powered by AA batteries, I started wondering if it's possible to recharge those batteries using the musclepower of kids.
Sure, it's easy enough for adult muscle power to generate some electricity, but could there be some ways for kids' musclepower to be harnessed (gently) to recharge AA batteries?
What kind of not-very-tiring machines could be devised that could store mechanical energy in such a way that the energy could later be released more quickly to recharge AA batteries via a cordless power drill running in reverse?
Of all the possible machines that could be set up (pulley systems, water pumps, hydraulic lifts), which would be the simplest, least costly and least dangerous to set up? Are there any kinds of contraptions that could be created so that even a five year old could be involved in creating electricity to recharge AA batteries?
While this would be a potentially fun tool for families to use here in the United States, this could be a vital energy production/computing/education tool for families where there is no existing electrical infrastructure.
The idea of storing up a bunch of mechanical energy in order to power a high-torque generator is a good start, but I don't think it is the right way to go. Instead, it would probably be better to skip the cordless drill, and use something designed to be a crank generator. Most rechargeable batteries can be trickle charged, or charged slowly, so it is probably better to design a hand crank that is easy to turn, and just puts out lower current. Of course, the the trade-off is that it will take longer to charge the batteries. I would start with this design for an ipod charger.
Another alternative might be to make a kid-sized pedal-powered generator, and use that to charge the batteries. David Butcher made one that looks really nice, and sells plans from his website.
Anyone have other ideas about how to harness kid power to charge batteries? How about a giant hamster wheel?
Posted by Matt Mets |
Oct 1, 2009 05:20 PM
Ask MAKE |
Permalink
| Comments (10)
| Email Entry |
Suggest a Site
September 24, 2009
Ask MAKE: Get your project featured on Make
Ask MAKE is a weekly column where we answer reader questions, like yours. Write them in to mattm@makezine.comor drop us a line on Twitter. We can't wait to tackle your conundrums!

Carl writes in with a good question:
I make cool projects (I think so anyway), and I would really like them to be on Make. What do I need to do?
We occasionally receive really cool projects that we would like to publish, however they just don't have quite enough information for us to figure them out. So, here are some tips about documenting your projects in a way that makes them accessible.
The first step is to document your project during your build. The final product is what most people will see, however the build process can be equally interesting. I learn a lot from looking at the tools and techniques others use to construct their projects, and suspect many other makers do as well. Take some photos, comment some code, record some sound- whatever is appropriate for your project. For extra points, making a timelapse of your construction can be really fun to watch. The important thing is to keep the documenting process simple so that you don't get bogged down with it and forget to finish your project.
Once you have all of your cool documentation, you probably want to put it on the web somewhere. A great way to go is with Instructables, which is a site dedicated to hosting DIY projects. Another option is to use a more traditional blogging site. My favorite is WordPress, however Blogger is also a good alternative. If you have constructed your own website, that is great too, just make sure that each project has its own page. This is important, because it creates a permanent link to your project, making it possible for us to link to.
If you have taken video of your project, then by all means upload it to a free video hosting service. This allows us to embed your video in a post, which will greatly increase the chance that people will watch it. Again, there are a number of free services that you can use; Youtube and Vimeo are popular options.
The final step is to submit it to us! We have a nice tip line, try it out and don't be afraid to promote yourself!
Posted by Matt Mets |
Sep 24, 2009 10:00 AM
Ask MAKE |
Permalink
| Comments (0)
| Email Entry |
Suggest a Site
September 17, 2009
Ask MAKE: Why do flourescent lights buzz?
Ask MAKE is a weekly column where we answer reader questions, like yours. Write them in to mattm@makezine.comor drop us a line on Twitter. We can't wait to tackle your conundrums!

A few weeks ago, we looked at why dimmer switches cause incandescent light bulbs to buzz. We subsequently received a number of questions about why flourescent bulbs vibrate, such as this comment by snarkyFish:
It might be nice to have another one of these that explains why fluorescent lights / ballasts hum and buzz as well. I imagine it's a very similar explanation, but a much more complicated fix.
You are right, they do buzz for a similar reason, which is the mechanical components being vibrated by electromagnetic waves. In this case, however, it is probably not the bulb itself that buzzes, but the ballast.
Fluorescent bulbs are made up of a glass tube that is filled with a low-pressure inert gas and a small amount of mercury, have a phosphor coating on the inside, and have an electrode on each end. When a large enough voltage is applied across the electrodes, the gas begins to conduct, which allows an electric current to flow from one electrode to the other. This current causes collisions between gas molecules and the mercury, which creates UV energy that is then converted to visible light by the phosphor coating on the tube.
This is all well and good, however as the gas heats up, it's resistance goes down, which means that it becomes a better conductor and subsequently draws even more current. If this were left unchecked, the bulb would quickly heat up and self destruct, so a ballast is placed in series with the bulb to limit the current draw. There are a number of different kinds of ballast design, but the simplest one is to just use an inductor. An inductor will certainly limit the rate at which current can travel to the light, however it does so by absorbing magnetic fields into it's core. This absorption, which causes magnetostriction, is probably the source of your hum- it literally causes the inductor to expand and contract at twice the AC frequency, which creates an audible sound wave (at 120Hz in the US or 100Hz in most of Europe).
I don't think there is a safe way to fix this besides getting a new ballast. Newer ballasts use an electronic controller instead of an inductor for the ballast, so they shouldn't be susceptible to the same buzzing problem. Making your own is certainly a possibility, but as with any high-voltage project, you better know what you are doing first.
Any other tips for how to fix a buzzing fluorescent light? Let us know in the comments!
[CC licensed photo by adotjdotsmith]
Posted by Matt Mets |
Sep 17, 2009 10:00 AM
Ask MAKE |
Permalink
| Comments (12)
| Email Entry |
Suggest a Site
September 10, 2009
Ask MAKE: Simple proximity sensors
Ask MAKE is a weekly column where we answer reader questions, like yours. Write them in to
mattm@makezine.com
or drop us a line on
Twitter. We can't wait to tackle your conundrums!
Aaron writes in with a question about short-range sensors:
My question is really more of a search for direction. I have exhausted several approaches and could use advice. The goal is to create several simple, cheap sensors that have only the ability to sense that there is another one of them next to eachother. I need a range around 5 feet. It would need to have an id. For instance sensor 1 could see sensor 2 and 3 within 5 feet but no other and sensor 2 could see sensor 1 and 4, and so on.
I have considered rfid most intensly, but I find noise and cost go up at this range and I have had issues with consistancy. Laser requires line of site not be interrupted, blue tooth has too great a range, and so on.
Interesting question! I've actually been thinking about this for a project as well. There are three types of signal that I can imagine using for this application: RF, audio, and optical. Because you mention that maintaining line-of-sight is an issue, let's stick to a radio based solution. To make things simple, lets assume that each node is identical. Then, we need a protocol for each node to take turns transmitting their IDs to the other nodes. We also need to figure out how far away the transmitting node is, which we can estimate using the received signal strength if we make each node transmit at the same power. This is possible because radio waves follow the inverse square law.
Now, there are many different ways to build a radio system to do this, however a nice off-the-shelf part that will work is the xBee. Each node would then consist of a microcontroller (whichever you fancy) and an xBee radio. Program them so that they transmit their own ID at random intervals, and spend the rest of the time listening for other radio's IDs. Measure the signal strength of the received ID using the RSSI indicator, and if it is above a certain value (determine experimentally), then add the ID and time of reception to a list. If the same ID is received again, update that entry with the latest time a signal was received. Then, go through the list periodically, and remove any ID that hasn't been heard from in a while (longer than the longest time between random transmissions). This way, you will always have a list of devices that are nearby. By having them transmit their IDs at random intervals, you will minimize the chance that two transmit at the same time without having to deal with synchronization issues.
That's the easiest way I can think of to do this, however it is still pretty complex. Have a better solution? Sound off in the comments!
Posted by Matt Mets |
Sep 10, 2009 05:00 PM
Ask MAKE |
Permalink
| Comments (9)
| Email Entry |
Suggest a Site
September 3, 2009
Ask MAKE: Where to find an Arduino class?
Ask MAKE is a weekly column where we answer reader questions, like yours. Write them in to
mattm@makezine.com
or drop us a line on
Twitter. We can't wait to tackle your conundrums!

Bruce writes in:
Do you know of any Arduino efforts in San Diego, CA? Do you know of anyone who might know?
Well Bruce, I understand how difficult it can be to find local DIY events, so I compiled a list of the places I would look. The first thing I would do is search google, however there is a good chance that local events might not show up if they haven't been widely publicized. The next places I would check are Hackerspaces (neat map here) and Dorkbot. If there is a hackerspace in your area, there is a good chance that they will be holding classes about the Arduino or similar devices. Dorkbot groups seem to be more focused on presentations, however the participants can probably help point you in the right direction.
Another great possibility is a Make: group. There are a bunch of them popping up across the country (and hopefully across the world- let us know where you are!). Here are the ones that I know about:
- Make: SF
- Make: DC
- Make: NYC
- Make: Philly
- Make: PDX
- Make: KC
- Make: Denver
- Twin Cities Maker
- GO-Tech Ann Arbor
- MAKE Out Sessions
- Make: KW
- Make: Raleigh/Durham
Besides the more obvious tech-focused groups, many artists organizations and collaboratives are also hosting Arduino classes, such as AS220 in Providence, RI, Machine Project in Los Angeles, CA, and The Crucible in Berkeley, CA.
However, don't give up if you don't see anything listed for your city. Try asking around at a local college, check http://www.meetup.com/, chime in on the Make forum, take a glance at the official Arduino calender and the Make Events page, or just find some friends and host an event yourself, and be sure to tell us about it!
Know of any other good resources? Have any San Diego leads for Bruce? Want to see your group listed? Chime in in the comments!
The above photo of an Arduino class at Hack Pittsburgh is by Marty McGuire.
Update 11/24/09: Added Make:RDUPosted by Matt Mets |
Sep 3, 2009 11:18 AM
Ask MAKE, Events |
Permalink
| Comments (9)
| Email Entry |
Suggest a Site































Recent Comments