LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Setting scanning parameters for subsequent scans

Hi LabVIEW experts,

 

This program (Line Scanning.VI) is a state machine which contains several functionalities for confocal microscopy based research. I was hoping to further improve the workflow of experiments by implementing some more "ergonomic" features. However, I'm not sure if such features are capable with LabVIEW.

 

A cursory bit of context: In the imaging tab, the " get image" button initiates a set of DAQmx tasks. the USB 6361 outputs voltage to a set of scanning galvanometer mirrors, which sweep through an array of pixels. At each pixel, a photo detector turns photons into TTL pulses which are counted. Finally, the 2D array of number of counts at each pixel is plotted in "intensity graph". These are the elements I'd like to add/change

 

1. I'd like to be able to select an area on the plot "intensity" and from that selected area, define the area of the next scan. In other words, the four corners of the selected area would be inputted as the min and max parameters of the following scan. This is a common attribute of any scanning system user interface. Have any of you come across something like this in LabVIEW?

 

2. Also, I'd like to know how to overwrite the bounds of the plot (number of pixels) and replace them with the x min - x max, and y min - y max values. 

 

I've left off the subVIs because I don't think they will help. 

 

Thanks very much for any feedback.

 

Adam

 

0 Kudos
Message 1 of 2
(1,877 Views)

I can't open your VI as I'm in 2018, but can help..

 

For your first question, you can either use cursors or the zoom tools. Cursors will let you snap to specific points. I'd probably try using the MouseDown event to position your first cursor, then position your second cursor on MouseMove (so it draws a box- also, make sure to only do this IF the mouse is down on the control, you don't want it if the user is just positioning the mouse), then "process" both of them on MouseUp. If you use the Zoom tools you can use the "ScaleRangeChange" event to process the zoom.

 

The first case will draw a box within your window, not changing the scale. The second case will actually zoom in your image, and you can use the X and Y axis min and max scale values as your new XY location. Either method will work, it's just a matter of if you want to zoom in on the new area to scan or just mark it with a square.

 

For your second question, use the properties X Scale.Offset and Multiplier (same for Y scale) to convert pixels into points.

0 Kudos
Message 2 of 2
(1,840 Views)