marceluda / rp_lock-in_pid

Lock-in and PID application for RedPitaya enviroment
https://marceluda.github.io/rp_lock-in_pid/
GNU General Public License v3.0
41 stars 22 forks source link

Role of Phase for square oscillator #8

Closed DanHickstein closed 2 years ago

DanHickstein commented 2 years ago

Thank you for providing this useful piece of software! We are trying to use it to set up a PDH lock to an optical cavity.

I'm stuck trying to get the lock-in signal to have the correct "dispersive lineshape" that you show in your example video. In the image below, the input is Channel 1 and sqYo is channel 2. I would think that changing the phase would change that I see on sqYo, but it does not. Am I thinking about this correctly?

image

marceluda commented 2 years ago

El mar, 26 oct 2021 a las 22:15, Danhickstein @.***>) escribió:

Thank you for providing this useful piece of software! We are trying to use it to set up a PDH lock to an optical cavity.

You are welcome

I'm stuck trying to get the lock-in signal to have the correct "dispersive lineshape" that you show in your example video. In the image below, the input is Channel 1 and sqYo is channel 2. I would think that changing the phase would change that I see on sqYo, but it does not. Am I thinking about this correctly?

If you want to use the phase shift you have to choose the sqF signal ( https://marceluda.github.io/rp_lock-in_pid/TheApp/instruments/instruments_04_lock-in/ ). If you only want a 90 degree shift you can switch from sqY to sqX .

[image: image] https://user-images.githubusercontent.com/1107796/138983214-55e82cd0-3bbd-4228-a338-3be295c52503.png

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/marceluda/rp_lock-in_pid/issues/8, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACALCQEZVCBPV24AAW6NGETUI5HDDANCNFSM5GZDTTRA . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

DanHickstein commented 2 years ago

Thanks for the information! This helps a lot.

When using the full 30 MHz modulation, the phase shift options are very limited. I guess this limitation comes from the Red Pitaya itself.

But, when I use the Red Pitaya in "Oscilloscope and Function Generator" mode, I can make two sine waves at 50 MHz and can control the phase between them. I checked on a real oscilloscope, and the two outputs look pretty good. So, it's interesting the we can't get better control over the phase for the lock-in function.

marceluda commented 2 years ago

Yes... that's right. The 30 MHz phase shift is limited by the Red Pitaya itself. The internal FPGA clock is 125 MHz ( 8 ns period), so I can move with integer multiples of that period.

I don't know what the "Oscilloscope and Function Generator" does. It's closed software and I cannot access the code. My code is based on https://github.com/RedPitaya/RedPitaya/tree/master/apps-free/scope+gen , which hasn't got any phase control. The only way I can imagine to surpass the 8ns limit is to change the DAC comunicacion interfase... but I didn't worked on that.

El jue, 4 nov 2021 a las 19:50, Danhickstein @.***>) escribió:

Thanks for the information! This helps a lot.

When using the full 30 MHz modulation, the phase shift options are very limited. I guess this limitation comes from the Red Pitaya itself.

But, when I use the Red Pitaya in "Oscilloscope and Function Generator" mode, I can make two sine waves at 50 MHz and can control the phase between them. I checked on a real oscilloscope, and the two outputs look pretty good. So, it's interesting the we can't get better control over the phase for the lock-in function.

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/marceluda/rp_lock-in_pid/issues/8#issuecomment-961490943, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACALCQHJW6HJMTI5KHAZOZDUKML2TANCNFSM5GZDTTRA . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

DanHickstein commented 2 years ago

Hi Marcelo, thanks for your reply!

I am referring to this App that came with my Red Pitaya. Actually called "Oscilloscope and Signal Generator". image

Is this the same as the "scope+gen" app that you linked to?

marceluda commented 2 years ago

No, it is not.

the one you say is closed... and you cannot access the source code

El vie, 5 nov 2021 a las 13:07, Danhickstein @.***>) escribió:

Hi Marcelo, thanks for your reply!

I am referring to this App that came with my Red Pitaya. Actually called "Oscilloscope and Signal Generator". [image: image] https://user-images.githubusercontent.com/1107796/140541200-152f8a97-2857-4783-88ea-e656490cefd3.png

Is this the same as the "scope+gen https://github.com/RedPitaya/RedPitaya/tree/master/apps-free/scope%2Bgen" app that you linked to?

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/marceluda/rp_lock-in_pid/issues/8#issuecomment-962021256, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACALCQFF3N64NTLW4ENWGKLUKQFL3ANCNFSM5GZDTTRA . Triage notifications on the go with GitHub Mobile for iOS https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675 or Android https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub.

DanHickstein commented 2 years ago

Thanks for answering my questions!