This article describes a simple continuity tester, based on an ATtiny85 and a piezo buzzer, designed for checking circuit wiring, or tracing out the tracks on a PCB:
It has a low threshold resistance of 50Ω to avoid false positives, and passes less than 0.1mA through the circuit under test, to avoid affecting sensitive components. It’s powered from a small button cell, and automatically switches itself off when not in use, avoiding the need for an on/off switch.
Introduction
I recently designed a PCB with very fine tracks for a project I’m planning for a future article, and thought it would be useful to have a small, portable continuity tester to help check for solder bridges on the SMD soldering. Although most multimeters include a continuity tester mode, I wanted to design a stand-alone tool with the following advantages:
- Smaller and more convenient than a multimeter.
- Low threshold resistance of 50Ω, avoiding false positives due to other components in the circuit.
- Fast response, so you can drag the probe across a line of pins to detect shorts.
- Low current, to avoid affecting sensitive components in the circuit under test. This circuit passes only 100µA through the probes, which is a factor of 10 less than most multimeters.
- No on/off switch, so there’s no danger of leaving it switched on and running down the battery. The circuit automatically goes to sleep if it’s unused for 60 seconds, and the standby power consumption is less than 1µA, giving a battery life of several years.
An LED shows when the circuit is switched on; this is optional, but I like having confirmation that it’s working.
At first sight, using a microcontroller for this application seems overkill; however, I think it would take quite a complex circuit of discrete components to meet all of these requirements.
How it works
The Continuity Tester uses the Analog Comparator in the ATtiny85 to detect the voltage on the probe; in fact, it’s the first project I’ve built that’s used the analog comparator. The circuit is equivalent to this:
When the voltage on the positive pin AIN0 is higher than the voltage on the negative pin AIN1, the Analog Comparator output, ACO, is set. Assuming a 5V supply, the voltage at AIN1 is held at 5V by the pullup resistor, and the voltage at AIN0 is held at 5mV by the resistor divider. If the resistance between the probes becomes less than 50Ω, the voltage on AIN1 will be lower than the voltage on AIN0, taking the output of the comparator high. This is then used to enable the oscillator driving the piezo speaker.
The advantage of using the analog comparator rather than a regular digital input is that it allows us to precisely set the point at which the input will be triggered.
In fact the two pullup resistors are unnecessary, as we can use the internal pullups on the inputs corresponding to AIN0 and AIN1. This has two benefits; first, it saves two resistors, but more importantly, it allows us to turn off the pullup on AIN0 when the processor goes to sleep, avoiding the current drain through the 50Ω resistor.
The circuit
Here’s the complete circuit of the Continuity Tester:
Read more: 10 or 12-bit DAC from the ATtiny85