Maker Pro
Maker Pro

Problem reading frequency using arduino on pin f5

I tried measuring the frequency using the output generated by LM 311 ic but arduino couldn't do so. Can any one please help me figuring out flaws at my circuits. The circuit looks kinda like this :)
 

Attachments

  • LC meter new.zip
    62.3 KB · Views: 120
I tried measuring the frequency using the output generated by LM 311 ic but arduino couldn't do so. Can any one please help me figuring out flaws at my circuits. The circuit looks kinda like this :)
I couldn't open your files because I don't have the appropriate sw for them. Try posting a pdf or jpg image
 
are you using the coil to magnetically pickup a signal? Are you able to verify there is a valid output at the comparator? If so, then the problem is in the firmware. Did you write it yourself or did you load an example code?
Your comparator circuit is overly complicated, but first let's at least see if you have any useful output
 
are you using the coil to magnetically pickup a signal? Are you able to verify there is a valid output at the comparator? If so, then the problem is in the firmware. Did you write it yourself or did you load an example code?
Your comparator circuit is overly complicated, but first let's at least see if you have any useful output

I checked the output in Oscilloscope and the time period turn out to be fine :)
I guess there's some problem with the Arduino program...
can you help me writing the code :)
 
Maybe. What frequency range do you expect to measure? Can you post the code you have so far
 

hevans1944

Hop - AC8NS
This is a popular inductor and capacitor measuring circuit. It is based on measuring the frequency change that occurs in an LC oscillator when the unknown inductor or the unknown capacitor is placed in parallel (capacitor) or in series (inductor) with the built-in L and C oscillator components. There are many variations on the microprocessor used to measure frequency, but the oscillator circuit stays pretty much the same. Look at the schematic images here for some idea of the variations. Compare with the PIC implementation in the image below:

lc_meter_pic16f84a.jpg


Or this one, based on the popular ATMega:

LCF%20meter.GIF


The problem with the novice trying to duplicate any of these is usually the microprocessor code. The easiest solution is probably to measure the period of the LM311 oscillator output and use floating-point math functions to calculate the inductance or capacitance that caused the change in frequency. Or you could just buy one that works without any additional coding required, but where is the fun in that?.
 
This is a popular inductor and capacitor measuring circuit. It is based on measuring the frequency change that occurs in an LC oscillator when the unknown inductor or the unknown capacitor is placed in parallel (capacitor) or in series (inductor) with the built-in L and C oscillator components. There are many variations on the microprocessor used to measure frequency, but the oscillator circuit stays pretty much the same. Look at the schematic images here for some idea of the variations. Compare with the PIC implementation in the image below:

lc_meter_pic16f84a.jpg


Or this one, based on the popular ATMega:

LCF%20meter.GIF


The problem with the novice trying to duplicate any of these is usually the microprocessor code. The easiest solution is probably to measure the period of the LM311 oscillator output and use floating-point math functions to calculate the inductance or capacitance that caused the change in frequency. Or you could just buy one that works without any additional coding required, but where is the fun in that?.

Let me try this one!
When worked I can tell ya! :)
 
Top