changing device properties during single exposure

classic Classic list List threaded Threaded
4 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

changing device properties during single exposure

dmahecic
Hi all,

I am new to MM and I am trying to implement a script where the device properties or defined presets, are changed during a single exposure of the camera. The aim is to have the galvo mirror sweep through a range of angles, while the signal is integrated across the camera to produce a single frame for the whole sweep.

I am using a NI DAQ board to output an analog voltage signal that controls the position of the galvo mirror, using the NI100X device adapter. I am also using the Zyla 4.2 camera, which I plan to trigger externally using the same NI DAQ board.

I would really appreciate any help on how to achieve this...

Best,

Dora
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: changing device properties during single exposure

Nico Stuurman-2
Hi Dora,

> I am trying to implement a script where the device properties or defined presets, are changed during a single exposure of the camera. The aim is to have the galvo mirror sweep through a range of angles, while the signal is integrated across the camera to produce a single frame for the whole sweep.
>
> I am using a NI DAQ board to output an analog voltage signal that controls
> the position of the galvo mirror, using the NI100X device adapter. I am also
> using the Zyla 4.2 camera, which I plan to trigger externally using the same
> NI DAQ board.

As you may have noticed, the Core.snapImage function blocks for the
duration of the exposure.  So, to do something else during that
function, you will need to start another thread.  An example can be
found in the script "ThreadExample.bsh" (in the 1.4 source).
However, if you want to trigger the camera externally, you can start a
"burstAcquisition" (which is not-blocking), and then set properties in
the NI DAQ device to trigger exposure and to move your galvos.  I do not
know how fast those commands will execute and if your timing will be
correct.    Examples are in "burst.bsh" (1.4) or "burstAcquisition.bsh"
(2.0).


Best,

Nico

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
micro-manager-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/micro-manager-general
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: changing device properties during single exposure

dmahecic
Thank you for your reply.

I would just like to clarify something: Imagine I use the NI onboard clock to synchronise and control the times of the output voltages (galvo and camera external exposure trigger) in an external application, while configuring the camera for external exposure triggered acquisition within micromanager. Will the timing of the camera then be correct and match the NI onboard clock?

Is there a way to access the onboard clock of the NI board within micromanager?

Best,

Dora
Nico Stuurman-2 wrote
Hi Dora,

> I am trying to implement a script where the device properties or defined presets, are changed during a single exposure of the camera. The aim is to have the galvo mirror sweep through a range of angles, while the signal is integrated across the camera to produce a single frame for the whole sweep.
>
> I am using a NI DAQ board to output an analog voltage signal that controls
> the position of the galvo mirror, using the NI100X device adapter. I am also
> using the Zyla 4.2 camera, which I plan to trigger externally using the same
> NI DAQ board.

As you may have noticed, the Core.snapImage function blocks for the
duration of the exposure.  So, to do something else during that
function, you will need to start another thread.  An example can be
found in the script "ThreadExample.bsh" (in the 1.4 source).
However, if you want to trigger the camera externally, you can start a
"burstAcquisition" (which is not-blocking), and then set properties in
the NI DAQ device to trigger exposure and to move your galvos.  I do not
know how fast those commands will execute and if your timing will be
correct.    Examples are in "burst.bsh" (1.4) or "burstAcquisition.bsh"
(2.0).


Best,

Nico

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
micro-manager-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/micro-manager-general
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: changing device properties during single exposure

Maxime Woringer
In reply to this post by dmahecic
Hi Dora,

This might not exactly address your problem, but we've been using in our
lab an Arduino to modulate the laser intensity and adjust the focus
during one exposure.
We have a draft of a MicroManager plugin at this address:
https://github.com/imodpasteur/ArduinoCompressedSensing
(a little bit more context is available here:
https://www.eleves.ens.fr/home/woringer/CS/ )

So far it is pretty much undocumented, but this might change if there is
interest in the plugin.

Best,
Maxime

dmahecic <[hidden email]> writes:

> Hi all,
>
> I am new to MM and I am trying to implement a script where the device
> properties or defined presets, are changed during a single exposure of the
> camera. The aim is to have the galvo mirror sweep through a range of angles,
> while the signal is integrated across the camera to produce a single frame
> for the whole sweep.
>
> I am using a NI DAQ board to output an analog voltage signal that controls
> the position of the galvo mirror, using the NI100X device adapter. I am also
> using the Zyla 4.2 camera, which I plan to trigger externally using the same
> NI DAQ board.
>
> I would really appreciate any help on how to achieve this...
>
> Best,
>
> Dora

------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
micro-manager-general mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/micro-manager-general

signature.asc (482 bytes) Download Attachment
Loading...