The Celtic Engineer is a weekly newsletter produced by Celtic Engineering Solutions. We hope you enjoy it. If you have any suggestions for topics, would like to give feedback or want your email added to the distribution list please send an email to [email protected].
Of course it will work
In the first ten issues, we have been talking about specific pieces of the circuit: filters, caps, buses, resistors and LED’s. This week I wanted to talk about that day when the board is done. It is populated and ready to be powered for the first time. It will turn on and run perfectly and you will be on to your next project. Yeah, we have all had that happen – once. The reality is you should plan on things going wrong and proceed carefully. For example, when you are ready to power up the board, a bad idea is to just plug it in assuming it will work. A better way of proceeding is to measure the resistance on the board from power to ground. While this does not give an accurate picture of the actual power that will be drawn, because of regulators and switches in the system, if you read a dead short you can be sure there is a problem. And that is what I want to discuss today. What do you do when things go wrong, to rapidly find and correct the problem?
Just a ‘short’ hunt
The first line of defense is a visual inspection of the board using a tool scope. I look for imperfections in the board, the solder mask and the solder. Is the solder smooth and shiny or is it clumpy with gaps and pockets? Dead shorts are usually the easiest to find. And most of the time you can do so visually. On the occasions when you can’t, I have had success using a very high accuracy ohm-meter. It must be capable of submilliohms. An enlarged printout of the board is very important. Usually you have an idea where the short might be based on how the circuit behaves. I start taking resistance readings from a specific location on the ground plane to different power locations (if the short is from power to ground). I make a map of the board. The resistance will only be a few milliohms. Since the power and ground are connected at a point, the closer you are to that point the lower the overall resistance. When I find the short it will either be a bridge I missed with the visual inspection or a faulty part. You should always prove to yourself that you found the short by removing it or the suspect part and checking for the short again. It is a very gratifying feeling when your meter reads 10’s of kilohms all of a sudden.
The root cause
Shorts are not the only problem that will sabotage your board. One of the easiest traps to fall into when testing out a problem board is to get bogged down in the mud. All you will see is it not doing what you want it to do. It is helpful to take step back and see what is working. Check out the whole circuit and see what works and what does not. This often provides helpful clues to solving the overall board problems. If there are two subsystems that do not work and they interact, it may be that interaction that is causing the issue. Find out what works and what does not, then make a list of all the symptoms of what is going wrong. Look for common causes. In circuits, as in life it is all about telling a convincing story of what is going on. Be methodical. Come up with several hypotheses about what could be causing the problem. Then rank them according to the likelihood of them actually being the problem. Usually you will go right down the list until you find it. But if one idea is costly or time consuming or destructive, you may choose to knock a few of the other things off the list first.
Don’t work in a vacuum. Use the resources around you. This is a balancing act. If you are responsible for solving the problem then you must do the work and figure out the answer, but time is a valuable commodity. If you are stuck, talk it out with someone you think may have some insight into the problem. Sometimes just the act of explaining out loud the process you are working on can help point you in the right direction.
No, really, you touch it.
Look for temperature variations. If you have a thermal imager you will get great information about how the circuit is working. If a thermal imager is not in your budget, use the end of your finger (assuming you are working on low voltage circuits). I have burned the end of my finger lots of times discovering a component that has gotten uncomfortably warm, but you do what you have to do, right?
I feel like I have been here before
As long as we are talking about temperature. If you don’t already know, every circuit is a thermometer, whether you want it to be or not. Sometimes just the heat of your hand is enough to change the value of a parameter, other times a heat gun or freeze spray are useful for ferreting out problems. Finding the problem is usually the hard part. Once you understand the problem, the solution is quite often obvious.
Which one of these is not like the other?
If you have a golden unit life becomes much easier. You can compare the two units and look for differences. Even if you only have one board, I like to write the voltage levels on a schematic. Then I ask myself if those values are reasonable, given what I know about the circuit. Many times, you will need to read, and re-read, the datasheets. Other times the answer jumps off the schematic at you. If the inputs of an op amp are not the same value, you should know you are very close to solving the problem. A 5-volt zener has 10-volts across it. Or a transistor that should be off but is conducting.
You can’t drive a nail with a tomato
Use a variety of tools. VOM’s are great but use a scope as well. You won’t see the noise on the VOM, or the glitch. Look for AC on what you are sure should be a DC signal. I have debugged an I2C line lots of times with a scope, but having a I2C analyzer to tell you when you are sending the signal correctly is so much easier. You may still need the scope, but the time to a working solution has just dropped. Using a variety of tools or just the proper tool will give you great insight into the working of your circuit. Understand how and why the circuit behaves as it does is the key to success. Remember, the circuit never lies.
This newsletter is sponsored by Celtic Engineering Solutions LLC, a design engineering firm based out of West Jordan, Utah, which can be found on the web at www.celticengineeringsolutions.com. You can find the newsletter on the company blog, LinkedIn or by subscribing. Send your emails to The Celtic Engineer at [email protected].