Frequency measurement of a low voltage AC sine wave

I need to measure the frequency of a low voltage AC sine wave:

the voltage varies from ~ 50mv to a couple volts (magnet spinning in a coil)

the maximum frequency is only a few hundred Hz

microcontroller input pins only change states at 1/2 of VCC and won't sense any waves under 1.65v

(if VCC is 3.3v)

thanks

rh

Was there a question in here?

Maybe something like: feed it to a low voltage rail to tail op amp to amplify/clip the signal at the rail voltage (preferably something like 3-5 VDC), then peak it with a diode to ground, feed that to a comparator and count the comparator's transistions with your arduino?

Was there a question, or an answer, in there somewhere?

Sounds like your input is configured as a Digin, suggest you set input status to analogue then look for time intervals between maximum and minimum to calculate frequency

Bear in mind that input resolution is 1024 so at best your minimum signal resolution will be 5mV

Jackie, me boy, you make life too simple......

My compliments on an elegant reduction of the solution.

thanks

I'll try the ADC

rh

You will have a much better chance of success if you wire the sensor output to a op-amp type comparator circuit and then wire to a arduino as a digital input signal. You can then use standard frequency measuring software methods of which there are several avalible depending on the maximum frequency and your resolution requirements. Trying to measure the frequency using the analogRead() function is fraught with peril.

Lefty

lefty,

could you point me to a suitable circuit or a specific op amp ?

can I use a 741 ?

if so, how do I set the low(<50mv) reference voltage for the comparator ?

can I use a pull down resistor to ground ?

the programming aspect I can handle, but I'm a noob at the electronics

thanks

rh

rhahm:
lefty,

could you point me to a suitable circuit or a specific op amp ?

can I use a 741 ?

No, that's a hopelessly outdate general purpose op-amp. A popular comparitor is a LM339 chip.

if so, how do I set the low(<50mv) reference voltage for the comparator ?

No need for a reference really, just wire it as a zero crossing detector with the - input grounded and the + input wired to one side of your magnetic pickup and ground the other side of the pick-up

can I use a pull down resistor to ground ?

Not needed, but sometimes comparitors have a high resistance feedback from output to input to add a little hystrisis to the circuit to deal when there is a zero rpm condition and you don't want false pules due to circuit or wiring noise. Best to read the datasheet and get ideas for best solutions and methods.
http://www.ti.com/lit/ds/symlink/lm339-n.pdf
Lefty

the programming aspect I can handle, but I'm a noob at the electronics

thanks

rh

Just to re-iterate the comment on the 741. This was state of the art in 1967 or so. It wants a supply of +/-10V or more to perform, and it performs poorly by today's standards. It is only sold as replacement parts for existing circuits, it is not the right choice for new designs!

For low voltage circuits a "single supply rail", "rail to rail" op amp is the requirement.

Here a comparator is appropriate because we are detecting one voltage passing another. An opamp normally has both its inputs at the same voltage in a negative feedback configuration. A comparator has its input voltages different (most of the time!) and uses positive feedback to provide some hysteresis. Its output is a logic signal, not a linear voltage.