From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Building a diffraction grating array for SLM

Hello,

I need to control a spatial light modulator to steer a laser beam.  To steer the beam a hologram of a diffraction grating is used (with the period and rotation determining the distance and angle the laser is moved from it's original path).  I would like to use labview to generate these holograms for me but I'm not sure how to do it exactly.  A grating hologram would look like a greyscale image of a step function (see attached) and I need to be able to generate these with two inputs (period and angle) to a size of 1920x1200 pixels.
Any help would be greatly appreciated, thanks.

Regards
D.J.C.
0 Kudos
Message 1 of 11
(5,274 Views)
Hi DJC
 
This looks like a really interesting project that you are working on though can I ask you some more questions on what result you are actually wanting out of labview. You state that you are trying to create holograms of a diffraction grating, what form do these take, are you trying to create a 3D image within labview, a bitmap-like image but with inputs for the width of the "stripes"  on the grating?
 
Not being an expert in holography I am then slightly confused on how you will use this to steer a laser beem but if you could define more accurately what it is you need out of LabVIEW then I will advise best I can on how to achieve this.
 
best regards
Graham Green

Sr. Product Marketing Manager

National instruments
0 Kudos
Message 2 of 11
(5,238 Views)
Hi Graham,

Thanks for responding.  These holograms basically take the form of an 8-bit greyscale image.  This image is then sent to the SLM which converts the greyscale values of 0-255 into phase changes on the SLM from 0-2pi.  The hologram must also be the fourier transform of the beam pattern one wishes to create

So there are two ways to do what I need
1. Use labview to generate the FFT of the desired pattern and normalise this so that 0-255 corresponds to 0-2pi.
2. Knowing that a blazed grating is the FFT of a deflected spot we can compute the pattern we need using only two parameters (angle and period).

The image I attached above shows a blazed grating in greyscale.  It is essentially a repeating step function from 0-255.  So can we use labview to generate this pattern with control on period and angle?  I've been playing about using the step function vi from the signals category and then using this to build an array but the computation time takes too long and this still leaves me unable to control period or angle.

Thanks again.
DJC
0 Kudos
Message 3 of 11
(5,232 Views)
Hi DJC
 
Sorry to be so long getting back to you. I'm afraid to say that this kind of image is not going to be the easiest thing to generate in LabVIEW. To create the repeating pattern you would need to produce an array of numbers to fit your 0-255 greyscale using the mathematical format that you desire and the n append your arrays together. I think that this is the way that you have been approaching this anyway. The problem as you have found is that when producing and appending such large arrays together your program operation time will increase thus slowing the thing down. This isn't easily avoidable as I cannot find anything in labview that will simply programaticaly controll bitmap creation. Especially if you would like to be able to change the variables of the gradient of the grating on the fly.
 
If you want to maximize speed I would recommend importing the gratings into labview from a saved location on disk. You could programatical control which grating you opened and used and this kind of file opening would be much faster than creating a grating from fresh on each itteration.
 
I'm sorry I cant give you a more complete response as this is not an area I have much experience in but I hope that your application is successful.
 
best regards
Graham Green

Sr. Product Marketing Manager

National instruments
0 Kudos
Message 4 of 11
(5,152 Views)

Hi DJC,

 

    Can i generate a good Gaussian beam using SLM ? I have a 633 nm laser but it is not GB.

 

   I am very new in Labview code.

 

Thanks

Nirmal

0 Kudos
Message 5 of 11
(4,103 Views)

I have done something similar using a TI DLP kit maybe 8 years ago using LabVIEW. I used a lens to image the DLP so that I didn't have to work in the Fourier space. I don't know how much you know about your project but one concern is the discrete nature of the micro-mirrors will create a diffraction pattern of several orders. You will have to pick one of the orders.

 

As far as I can tell, there is no issue with LabVIEW. It is more the optical configuration of your setup that will be an issue.

Marc Dubois
0 Kudos
Message 6 of 11
(4,091 Views)

Thanks Marc.

 

I create a phase mask of gaussian beam and send it to SLM. But in this case i consider that our laser is flat. i am using GS algorithm.

 

can i create blazed gratting pattern and send it to SLM for generating GB ?

 

Nirmal

0 Kudos
Message 7 of 11
(4,083 Views)

Sorry, it is definitely not a LabVIEW issue here. I don't know much about what you are trying to do. I suppose that it all depend on how much gaussian you want your beam to be. It will not be perfectly gaussian because you have to take into account the pattern created by the discrete micro-mirrors.

Marc Dubois
0 Kudos
Message 8 of 11
(4,074 Views)

Hello DJC11

Did you get it? I have the same situation.

 

Best regards.

 

Fano

0 Kudos
Message 9 of 11
(3,732 Views)

DJC last logged into the Forum in 2008.  You may get more useful information by starting a new thread and being as specific as possible about what you want to do, what you have tried, and what did or did not work.

 

Lynn

0 Kudos
Message 10 of 11
(3,727 Views)