Construction of an LC meter device to measure inductor (inductance meter) and capacitor meter (capacimeter), better known as LC meter, using PIC (16f84 or 16f628) and LCD display.
Is 0 to 800nF for capacitance and 0 to 10mH for inductance.
Accuracy: is ± 1%.
Reading: 0 to 1000pF (1nF) in pF 1nF to 800nF in nF auto-range (automatic scaling)
Resolution: from ± 0.1 pF and ± 10nH.
Follow us on social media
Project: LC METER operation with PIC 16f84 or 16f628
Good to have on the bench. The oscillator design came from AADE’s LC meter page. It uses an LM311 comparator with positive feedback, working as a parallel LC oscillator with digital output. L is the 82 µH shock and C is the 1000 pF capacitor. The frequency, therefore, is f1 = 550 kHz. A capacitor of precise value, (CCal) 1000 pF ±1%, is connected in parallel to C via a relay. The new total capacitance is 1000 + 1000(Ccal) = 2000 pF, and the new frequency is f2 = 394 kHz. It is not important that these frequencies are exact, what matters is the ratio between them, which is derived from the precision capacitor of 1000 pF. Both frequencies are measured by the PIC, during self-calibration. The important thing is that if the 1000 pF capacitor (Ccal) is accurate, then there is only one value of L (the 82 µH shock) and one value of C (the 1000 pF capacitor) that can determine these two frequencies, no matter exactly their absolute values. In this way, the PIC “discovers” the true and correct value of the shock and the 1000 pF capacitor, and having that it can measure a capacitor or an external inductor. The inductor under test is placed in series with the shock. The capacitor under test is placed in parallel to the 1000 pF capacitor.
When performing self-calibration, the parasitic inductances and capacitances of the wiring are absorbed in the calculation performed by the PIC. The CH3 switch “zeroes” the value indicated in the display. Thus, only the capacitance or additional inductance of the component to be measured is shown in the display. When measuring, an unknown inductor is placed in series with L, or an unknown capacitor is placed in parallel with C. The new frequency is measured by the PIC and its value transformed into the only capacitance or inductance value that can cause that new frequency.
Assembly of the digital inductance capacitor circuit
The tolerance of the device depends on the 1000pF Ccal capacitor, which must be made of polystyrene (“styroflex”) with a tolerance of at least 1%. Then you ask where can I get a capacitor with this tolerance, easy, make an association of capacitors until you get the desired capacity, use a commercial capacimeter borrowed from a friend, select the capacitors to be used in the circuit? In my prototype I used a 1% tolerance capacitor found in junk shops, a rare thing. C2 (Cmed) doesn’t need to be precise, only thermal stability is required. So use a polystyrene one, if you are going to use ceramic, use an NPO.
For the inductor I initially used an 82µH RF shock, but the measurements were not firm, so I used a toroidal coil with 85 coils of 30 AWG wire wound on an iron powder core.
Displays that can be used in the LC meter circuit
The display can be any standard Hitachi 16×1, 16×2 or 8×2, if you use one that has a backlight, you should pay attention to the power consumption. That will be much higher, and it is recommended to use a 7805 to-220.
In my prototype, I used a PiIC16f627 and a Hitachi 16×2 display. All from scrap. The pic I found in an abandoned telephone jammer and the display in a broken fax machine. Viva la junk.
The resistors of the circuit can be 5% tolerance, some more demanding use 1% tolerance.
How to program the PIC to be used in the lc meter circuit
To write a PIC is easy, you need the writer and a program. The program is USBPICprog.
How to test the operation of the lc meter circuit
Solder all the components on the board, without the Pic, measure the voltage of the regulator to see 5 volts ± 25%. All right, ground pin 18 of the pic socket and check the relay’s operation (you should hear the relay being triggered). Put the Display on and adjust the potentiometer for the best contrast. Put the pic already with the program and if everything is right you have a digital Lc meter. If not, inspect the whole circuit, display, pic, switches, wiring, etc.
How to use the LC meter
For initial setup the pic software includes a test mode, for this close J1 and press zero. The Pic will count the oscillator cycles for 0.1 seconds and display the result. With the 82µH inductor and 1000pF capacitor in the circuit (no external component, no calibration capacitor) the oscillator will run at about 550KHz, and the display will show about 55000.
If the frequency is too high (above 655.350KHz) the display will show out of range. If the oscillator is not working, 0 will be shown on the display.
For best accuracy the frequency should be 10 to 15% below 655KHz. You can adjust the coil to achieve this.
A second jumper connects the Ccal calibration capacitor, the frequency will now be 394KHz.
A third jumper on pin 10 of the PIC, allows you to select an 8 × 2 display, the result will be shown on two lines.
How to measure Inductor using this lc meter
Select L on the function switch and the display will show “out of range” because no inductor is connected. Short the measurement terminals and press zero. Now just put the inductor in and read the result.
How to measure capacitor using LC meter
Select C on the function switch and the display will show a few pF, this is the residual (parasitic) capacitance of the wiring. Press the “zero” switch briefly. The display now indicates 0 pF. Now just put the capacitor to be measured into the terminals and read the result in the display.
Another function for this microcontrolled lc meter circuit
The instrument can be zeroed with components at the measurement terminals. And the components that are tested afterwards will be shown the difference ± from the original component value.
Accuracy of lc meter with pic 16f84 or 16f628
It depends on the components used by the assembler, during the calibration of the device, errors depend on the components used in the tank(LC) of the oscillator circuit and the standard 1000pF Ccal capacitor that should be at least 1% tolerance, if possible smaller. I got one with a tolerance of 0.625%.
The ferrite coil is not suitable for the tank circuit, the ideal is to use an iron powder core. And a good candidate for this is the Micrometals T50-1 toroidal core (marketed by Amidon, Palomar, Toroid King, etc…) and the Micrometals T50-2 iron powder core. Anyway, use an RF shock to test the circuit, then try to find a suitable coil by measuring and removing coils from some inductor found in the junk (TV, VCR, etc.).
Conclusion of the LC meter
You can have your inductor and capacitor meter that is accurate, digital, and easy to operate. With the worst possible set of components you will achieve a tolerance of at least 3%, and if you are lucky and do a little fancy, you can build your equipment with a tolerance of less than ‘1%’.
- The original design from https://sites.google.com/site/vk3bhr/home/lcm1
- The original idea and the oscillator came from https://web.archive.org/web/20160124195829/http://www.aade.com/lcmeter.htm
- The Frequency measurement code came from http://homepage.tinet.ie/~ei9gq/stab.html
Update version 2, no need LM311
Buy LC Meter Diy kits in Aliexpress with worldwide free shipping