lockin amplifier

i want to measure the accurate voltage reading. The output is keep on fluctuating is there anyway to make DC or stable output

input given to irled is 100hz 10% duty cycle

Voltage received from Sensor is: 2.4497
Voltage received from Sensor is: 2.5670
Voltage received from Sensor is: 2.6696
Voltage received from Sensor is: 2.7674
Voltage received from Sensor is: 2.8065
Voltage received from Sensor is: 2.8504
Voltage received from Sensor is: 2.8016
Voltage received from Sensor is: 2.7674
Voltage received from Sensor is: 2.6843

The oscilloscope yellow curve shows Photodarlington output and blue curve shows the lockin amplifier output

Untitled.png

The blue line on your 'scope is varying. Are the Arduino values accurately reflecting that variation - or is there some other problem?

If the Arduino is accurately capturing the voltage maybe you could average the value over several readings.

If the Arduino is NOT accurately capturing the voltage I reckon you need to post the schematic showing how everything is connected. A photo of a pencil drawing will be fine. A photo of your hardware is not suitable for showing wiring connections.

...R

http://forum.arduino.cc/index.php?topic=348309.0

Hi,
The yellow is the signal to the "photodarlington", its 100Hz but 50% duty cycle.

Can you please post a copy of your circuit, in CAD or a picture of a hand drawn circuit in jpg, png?

Can you please post a copy of your sketch, using code tags?
They are made with the </> icon in the reply Menu.
See section 7 http://forum.arduino.cc/index.php/topic,148850.0.html

A picture of your project would also help.

Thanks..Tom..... :slight_smile:

sorry i used 50% duty cycle

So for what i did is shown in page 1. i am planning to do lockin amplifier circuit is in page 2.

please correct my mistakes regarding resistor and capacitor values

any other suggestions are welcome and appreciated:

#include <PWM.h>

//variables
int32_t frequency = 100;
float val = 0.0;// variable to store the value coming
// from the sensor
float Bit = 1023.0; //set value for amount of bits
float volt = 0.0; //set value to store calculated voltage
float SensorData;
float RI=0;

// Sensor pin config
//const int Sensor1Pin = A0;
//PWM pin config
#define PIN 3

void setup() {
  pinMode(PIN, OUTPUT);
  int DUTY = 50;
  InitTimersSafe();                    // won't touch timer0
  SetPinFrequencySafe(PIN, frequency); // again, not timer0
  pwmWrite(PIN, DUTY * 256 / 100);
  // Sensor(s)
  pinMode(A0, INPUT);
  // for debugging
  Serial.begin(9600);
}


void loop()
{

//  // Read and store Sensor 1 data
//  val = analogRead(A0);
//  volt = val * (5.0 / 1023.0); //equation to convert incoming value to voltage
//  SensorData = volt;
//
//
//  Serial.print("Voltage received from Sensor is:\n");
//  Serial.println(SensorData, 4);
//  delay(500);

  val = analogRead(A0);
  volt= val*(5.0/1023.0); //equation to convert incoming value to voltage
  RI=volt*1.33;
  SensorData=RI;
  
     
  Serial.print("Refractive index:\n");
  Serial.println(Sensor1Data, 4);
  delay(500);


} // END void loop...

codes i used, IRL81A IRLED and OP560a Photodarlington datasheet also attached, am i going in a correct way

your comments are valuable to improve myself.

http://forum.arduino.cc/index.php?topic=348309.msg2405017#msg2405017
i also asked many silly questions and all the answers are helped me

New Doc 1.pdf (917 KB)

IRL 81A, Lead (Pb) Free Product - RoHS Compliant.pdf (179 KB)

op560a.pdf (336 KB)

Hi,

Don't forget you have a 180Deg phase shift across the opto link, a HIGH in results in a LOW out.

Also where is the current coming from to bias your photo-darlington receiver?

You are assuming that the IR darlington produces a voltage, it doesn't, it is a current device, have a good read of the spec sheet and look at the small example circuit they use for the switching time test circuit.

Can you please post a copy of your complete circuit including the "locked in" amp schematic , in CAD or a picture of a hand drawn circuit in jpg, png?

Tom... :slight_smile:
Sorry isn't the "locked in" amplifier a form of synchronous detector?
"locked in" stupid name.

Thanks to Grumpy mike and tom sir for Valuable comments, i feel like i am improving a lot form you

I made many changes in circuits of your guidance. still need your help :slight_smile: sir

i am using +15 and -15 V to bias opamp shows good results. But i have to make a device to work on 5volt

i have attached so for i did and spec sheet of IR and Photo detector.

am i going is correct direction?.

i am waiting for your valuable comments

Regards
Tuty

1st schematic.pdf (1.2 MB)

IRL 81A, Lead (Pb) Free Product - RoHS Compliant.pdf (179 KB)

op560a.pdf (336 KB)

Sorry buy I have no idea what you are trying to do. The big picture, that is what you hope that this system will achieve.

akmsr:
...
i am using +15 and -15 V to bias opamp shows good results. But i have to make a device to work on 5volt
...

Use Dual Output SM DC/DC Converters.

muRata NTA Series

input :+5V
output:+/- 15V


$7.95, Mouser

http://www.mouser.com/ds/2/281/kdc_nta-50920.pdf

Or better DIY friendly Murata Power Solutions NMA0515SC

$8.76, Mouser

any other alternative to ad630 modulator that work at 5volt?

Not without saying what the chuff you are trying to do.

Hi,
He's trying to do this?

http://forum.arduino.cc/index.php?topic=348309.msg2402360#msg2402360

and

http://forum.arduino.cc/index.php?topic=347785.msg2398763#msg2398763

Tom..... :slight_smile:

None of those links work for me.

Hi,
hmmmm, did when I posted them.

http://forum.arduino.cc/index.php?topic=348309.0

http://forum.arduino.cc/index.php?topic=347871.msg2399016#msg2399016

Try these..

Tom.. :slight_smile:

Ok Tom thanks, those work. However he don't say what he wants to do only how he thinks he wants to implement it. Classic X-Y problem in my book.

I have used lock in amplifiers at the University and they were very expensive and used for measuring very small voltages in the presence of much larger voltages. I don't see the relevance here. He is modulating the IR signal and then trying to remove the modulation. If the modulation is for immunity from ambient light then I would have thought that a simple tuned amplifier followed by a good filter would have fitted the bill without trying to make a lock in amplifier.
That is why I want to know what he is trying to achieve with his project not how he is struggling to implement some process that is beyond him.