AJW

Papilio lock-in amplifier?

Recommended Posts

I'm relatively new to both electronics in general and FPGA's in particular. I was wondering if anyone knows whether any of the Papilio range could be used to make a basic lock-in amplifier? I'm trying to detect a very small phase sensitive oscillating signal against a very large background noise. Many thanks for your help.

Share this post


Link to post
Share on other sites

Yeah, sorry for the lack of detail. I'm trying to recreate the classic lock-in experiment where you can detect the light of an LED, the brightness of which is oscillating a particular frequency (say 500 Hz, but I'd like to go up to several KHz) across a room using a photo-diode with significant background noise by using phase sensitive detection. Essentially the FPGA would have to take the analogue input from the photodiode, multiply it by a reference signal (in this case the sine wave voltage driving the LED) and then average over time. Because any noise multiplied by a sine wave will average to zero over time, but an in-phase signal will average to a DC offset, this technique is very powerful for separating an oscillating signal of a known frequency from the background noise.

 

I'm roughly following http://bret.io/media/seniorLabs/lockinlab.pdf

 

This is more an exercise to learn about lock-in amplifiers by building one than anything else.

 

Thanks for your help.

Share this post


Link to post
Share on other sites

Heh, this may help me with my low-power proximity detector :)

 

Ok, let me read this carefully. But I will assume you will need a proper ADC (which Papilio itself does not have, but there are some ADC wings available). With the ADC, you can do everything in the digital domain.

 

500Hz or up to 1MHz should be very easy.

Share this post


Link to post
Share on other sites

Once you get it gojng, rather than using a sine wave, why not try a GPS gold code?

( or something similar to one)

It is a pseudo random bit stream that is quite long. When you correlate with an external signal you can get a really precise phase lock.

This time to phase lock is what gives the long time to first fix of a GPS as it trys all the different alignments, but once locked it is very solid, even though the power levels of the signal is well below the noise floor and mixed up with all the other GPS birds.

By having g a real time clock on the GPS the time to first fix is improved as the GPS knows where to start hunting.

Also, I believe that most GPS units have a one bit DAC, so maybe a bandpass filter and to compare against the long term average is all you need?

  • Like 2

Share this post


Link to post
Share on other sites

Once you get it gojng, rather than using a sine wave, why not try a GPS gold code?

( or something similar to one)

It is a pseudo random bit stream that is quite long. When you correlate with an external signal you can get a really precise phase lock.

This time to phase lock is what gives the long time to first fix of a GPS as it trys all the different alignments, but once locked it is very solid, even though the power levels of the signal is well below the noise floor and mixed up with all the other GPS birds.

Actually the GPS signal includes ephemeris data. Cold starts have to download a new copy of the ephemeris after locking on to the signal. Warm starts just need to lock to the signal, hence the reduced time. Locking on to the gold code only takes a second or two.

Share this post


Link to post
Share on other sites

Doesn't ephemeris data change at each message ? It should contain time and location of the GPS satellite, and this needs to be decoded in order to properly decode your posiiton using trilateration, so I don't quite understand "have to download a new copy of the ephemeris after locking on to the signal". It needs to decode that data constantly, not exactly "downloading it".

Still, I don't know much about GPS anyway, so I may be mistaken.

Share this post


Link to post
Share on other sites

Ephemeris data is considered valid for 4 hours and changes every 2 hours. Data is broadcast at 50 bits/second and a complete frame is 1500 bits, so from cold it needs about 30 seconds per satellite to get a full set of data. Since they run in parallel then a cold start takes between 18 and 36 seconds.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now