Saturday, 13 April 2013

Very accurate LC meter by RONY


DESCRIPTION: Well this is a Very Accurate LC Meter based on PIC 16F628A .Having inspired from surprisingly accurate LC Meter. This is my attempt to build an accurate L/C meter. This design is little different from other designs found on the internet. The goal of my hard work is to people get success in a single try. Cz Most of the design doesn’t work as described in the documentation or lack of information’s.  The most challenging part of the project was to program the entire floating point math in 2k code memory of 16F628A.
  
 Basically LC meter is a kind of frequency meter, there is an LC Tank oscillator that oscillates with measured L or C and result is being calculated. The precision of frequency is up to 1Hz. For more details of measuring frequency with timers, see my article frequency counter..
Theory of operation: Look at the schematic carefully; I didn’t use any reed relay, which is the burden for most of hobbyist, because of unavailability in local market. In my country (Bangladesh) it is also not available.  So first I decided to use a Mosfet instead of Reed Relay. But I found better result in normal NPN transistor like BC547. If you don’t trust transistors, you can add Reed Relay yourself. I have used Pic’s internal comparator for oscillator and fed it to Timer1 External clock source to calculate frequency. So it eliminates the external Lm311 Op amp .The relay RL1 used for selecting L and C mode. The meter works on four basic equations. This are
For both unknown L and C, Equation 1 and 2 are Common. Means we get F1 with internal LC tank circuit then connect Ccal Parallel with tank circuit and take the value of F2.
Afterwards,
  1. For  Capacitor it takes F3(Eq3) keeping the Cx Parallel with tank circuit then Calculates Cx from Equation 4
  2. For inductor it takes F3 (Eq7) keeping Lx series with internal inductor of tank circuit and calculates Lx from Equation 8   
So, For Both Inductor and capacitor equation 1, 2, and equation 5, 6 are same.
After getting the raw value of inductance or capacitance, program automatically scales the value to engineering unites. Then shows it to 16x2 LCD with unites. 
If it is hard to understand all the maths better leave for a while and try to make the hardware first and go through the calibration process I referred in next section.
Construction:
Precision depends on the status of your components. The two 33pf capacitors in the oscillator should be tantalum (for low series resistance/inductance). Use C4, C5 (Ccal) Polystyrene type. Because Green caps tend to drift in value too much. Avoid ceramic capacitors. Some of these can have high losses (and it is hard to tell).  
  1. First check all parts according to the schematic placed perfectly.
  2. Program the chip (16F628A) with the Hex file given below the Page. If you don’t have a programmer / loader check my PicKit-2 clone. It’s easy to make
  3. Connect power to the circuit without the chip first, then check the IC Base pin no 5, 14 with a volt meter. You will find 5v if everything ok.
  4. Put the Chip on Ic Base and connect the power, If you find LCD is much contrast, increase the value of R11 to several kilo ohms.  
Calibration:
  1. Keep short two test leds and switch on the circuit. It will then auto calibrate. And default mode is inductance. Allow several minutes "warm-up", then press the "zero" button to force a re-calibration. The display should now show ind = 0.00 uH
  2. Now Open two test leds and connect a well known value of inductor like 10uH or 100uH. The LC meter should read somewhere near its value (with up to +/- 10% error).
  3. Now you need to tune the meter to show the result near +/- 1% . To do so check the schematic there is 4 jumpers Jp1 ~ Jp4.  Jp1 and Jp2 are delivered to + and – the value. To increase the value first join Jp1 and run the process 1,2. And to decrease the value Join Jp2 and run the process 1,2.
  4. Once it shows the desired value, remove the jumpers. Now the chip will remember the calibration until you change it again.
  5. If you still not get the perfect value, join the Jp3 to see the Value of F1. It will show near about 503292 with 100uH L and 1nF capacitor. Or join Jp4 to see F2. If doesn’t shows anything that means your oscillator is not working perfectly. Check your PCB again.


Practical Image Of LC Meter

Find the Artwork and Hex here.