Electronic Projects Online - Diode and LED Tester
Originally published by Paul Stenning in ETI, August 1996


The polarity markings on LEDs (Light Emitting Diodes) seem to be a common cause of confusion.  The polarity may be indicated by a flat section on one side of the body or by one lead being shorter than the other, but different manufacturers are not consistent as to which lead they are marking!

Rectangular and other shaped LEDs often rely on lead lengths as the only indication, which is not very helpful if the component has been used previously and the leads shortened.  Sometimes you can peer at the innards through the casing and establish the polarity from this, but you still have to remember which bit is which electrode - and some LEDs do not have see-through bodies.  The connections of LED displays can be particularly difficult to establish - especially those with several digits.

You could connect the LED to a battery via a suitable resistor, but this can be fiddley and is not much help with infra-red devices.  Also the maximum rated reverse voltage for an LED is about 4V, so you could damage it if you are using a 9V battery for testing.

Diode and LED Tester

The simple Diode and LED Tester presented here costs under £5 to build (including all components, the battery and a cheap case) and will indicate the polarity of almost all types of LED and other diodes with no risk of damage.  The average test current is about 5mA (10mA pulses), which is sufficient to illuminate the LED being tested.

The unit has two test probes and two indicator LEDs.  The diode or LED to be tested is simply connected either way round between the test probes, and the cathode connection is indicated by the LED closest to that connection illuminating.  My original prototype has been used regularly for several years, and has saved me a lot of time and irritation.

The unit can be used to test all conventional LEDs including the multi-colour types and IR devices.  The only types of LED that cannot be tested are those containing additional circuitry, such as the flashing and constant-current types.

It can also be used to check most silicon and germanium diodes and rectifiers providing they can withstand a test current of 10mA.  Zener diodes can be tested for forward drop but not for zener effect, although this is sufficient to prove if they are alive or dead.  The unit can also be used for basic diode tests on bipolar transistors, although the test current may be too high for the base connection of some devices.

Circuit Operation

The circuit was designed to be simple and low cost.  A simple transistor circuit was used because the components (or suitable alternatives) are more likely to be in the constructors "junk box".  A brief discussion of the IC based alternatives that could have been used is given later.

The circuit consists of a standard two transistor astable multivibrator arrangement, the operation of which will be described shortly.  The outputs on the collectors of the two transistors are a square wave signal of about 200Hz.  The two outputs are out of phase with each other - when one output is high the other is low and vice-versa.

Between these two outputs are connected two LEDs (D1 and D2), back-to-back, with series diodes (D3 and D4) to increase the forward voltage drop.  When Q1 is on and Q2 is off, current flows through D2, causing it to illuminate - the current being limited to about 10mA by R4.  When Q1 is off and Q2 is on, D1 illuminates.  Although the LEDs are flashing, the 200Hz rate is sufficiently fast that they both appear to be continuously illuminated.  Since the test current is 10mA for 50% of the time, the average is 5mA.

When the diode to be tested is connected between TP1 and TP2 it will bypass either D1 or D2 depending on the polarity.  The test current will therefore flow through the diode being tested instead of through the bypassed LED on the unit.  The series diodes (D3 and D4) ensure that the voltage drop of D1 and D2 are greater than the forward drop of any diode being tested.

When the diode being tested is reverse biased the remaining LED on the unit will illuminate.  The diode being tested receives a reverse voltage of about 2.5V (1.9V from the LED plus 0.6V from the series diode) which is insufficient to cause damage.

If the diode being tested was short-circuited neither LED on the unit would light.  The astable multivibrator would also stop oscillating in this case, but this is not a problem.  If the diode being tested were open-circuit both LEDs on the unit would remain lit.

Astable Multivibrator

The trouble with describing the operation of an oscillator circuit is defining a suitable starting condition!  We will assume that Q1 has just switched on and therefore Q2 has just switched off.

Just prior to the change of state, C1 would have charged such that its left plate is positive relative to the other plate.  When Q1 switched on the left plate of C1 would have been taken to about 0V and therefore the right plate would have gone negative, switching Q2 off.

C1 will then charge in the opposite direction via R3.  The time taken for this to happen affects the frequency of the oscillator.  When the right plate of C1 reaches about 0.6V there will be sufficient base bias for Q2 which will turn on.  The charge on C2 will cause Q1 to turn off, and the sequence of events will continue with each transistor being switched on in turn.

C3 decouples the supply, to ensure correct operation as the battery runs down and its internal resistance increases.  The total supply current is about 20mA at 9V.  A standard PP3 battery can supply this current intermittently and still give a reasonable life.  The circuit will operate down to about 4V so the battery has to run fairly flat before it needs replacing.

Alternative Oscillator Circuits

This two transistor astable multivibrator circuit was used extensively some years ago, but has largely fallen into disuse due to a couple of shortcomings.  The frequency of oscillation varies with changes in the supply voltage and output loading, and the output waveform is not quite a true square wave.  Also two resistors or two capacitors must be altered to change the frequency is the mark-space ratio is to be kept constant.  None  of these problems are relevant in this application.

A more modern approach might have been to use an IC based oscillator.  The requirement for two anti-phase outputs rules out timer ICs such as the 555 unless they are used with an additional inverter circuit.  A suitable circuit could be constructed using CMOS logic, but the output drive current is not sufficient unless a buffer stages of some sort are used.  The net result would be more expensive than the current circuit.  TTL logic would be able to drive the LEDs directly, but this has the drawback of needing a 5V supply.  A regulator IC could be used but again this adds to the cost.  On balance it was decided that a simple circuit, using two transistors costing 10p each, offers a cheap and elegant solution.

Construction

The prototype was built on a small PCB as shown.  However the circuit could easily be constructed on stripboard or some other prototyping system as the layout is not critical.

Two new LEDs should be used for D1 and D2 - so you can be sure the polarity is correct!  The PCB overlay assumes the flat on the body is the cathode.  The diodes, transistors and capacitor C3 must be inserted with the correct polarity.

None of the component values are critical so they can be varied to some extent to use what you have available.  Pairs of components that are the same value (ie R1/R4, R2/R3, C1/C2 and Q1/Q2) should remain equal to keep the mark-space ratio at about 50%.  The two LEDs can be the same colour, or they can be coloured to match the relevant test leads.

The unit may be fitted into a small plastic case if required.  Ensure there is sufficient room to house the PCB, battery and switch.  The PCB will be held sufficiently secure by two mounting clips on the LEDs.  The battery should be held in place with some foam rubber, to prevent it rattling around and touching the rear of the PCB, causing short circuits.

The power switch may be a small slide switch or a momentary normally open push button.  Note that small slide switches are not normally supplied with the fixing screws.  The switch and battery should be connected to the PCB as shown on the circuit diagram.

For the test leads, two short lengths of flex fitted with small insulated crocodile clips are ideal.  These should pass through small holes in the case, close to the relevant LED, and knotted on the inside to prevent stress on the PCB if they are pulled.

Testing and Using

When the unit is initially switched on, both LEDs should light.  If the two test leads are touched together both LEDs should extinguish.

Connect a diode between the two leads, and one of the LEDs should go out.  The LED that remains lit should be the one closest to the lead that is connected to the cathode of the test diode.  The cathode end of the diode is normally marked with a band.  Reverse the polarity of the diode and check that the other LED remains on.

Now try the same thing with an LED.  The same results should be obtained, and the test LED should light both times.  If these tests are successful the unit is working correctly.

To conserve battery life the unit should be switched off when not in use.  If one or both LEDs fail to light when the test leads are not connected the battery should be replaced.

Parts List

2   R1,R4                    820R 0.25W Resistor
2   R2,R3                    22K 0.25W Resistor
2   C1,C2                    470nF Capacitor, 7.5mm (0.3") pitch
1   C3                       10uF 25V Radial Electrolytic Capacitor
2   Q1,Q2                    BC548 Transistor
2   D1,D2                    Red 5mm LED
2   D3,D4                    1N4148 Diode
1   SW1                      Min Slide Switch
1   BATT1                    PP3 Battery
1                            PP3 Battery Clip
2                            Miniature Insulated Crocodile Clip
1                            PCB
1                            Case
2                            5mm LED Clip
As Req'd                     Flex (for test leads)