From 04:00 PM CDT – 08:00 PM CDT (09:00 PM UTC – 01:00 AM UTC) Tuesday, April 16, 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: 

synchronization for intensity image via gated buffered counting

I am currently designing a high-speed imaging system using labview.  Thus far it requires 1 internal gate signal, 1 buffer counter, and 2 analog outputs.  These signals must all start at the same time in order to properly generate my images.  The analog signals control mirrors which allows for my laser to scan across the sample.  The gate and buffer are used to determine the intensity for each pixel via photon counting.  I am using a PCI-6259 to generate the mirror signals and a PCI-6602 for the photon counting.  I have attached the vi of what I have so far.  My problem is that the collagen that I attempted to image does not stay fixed on the intensity graph, but would appear to slowly slide across and wrap around the image.  Of course the collagen is actually fixed on the microscope stage and should not be moving.  My only guess for the cause of this would be that the mirror signals and the counter signals do not start simultaneously.  By observing the order using the "Highlight Execution" button, it appears that the buffer counter activates first, followed by the gate, and then finally the mirror signals.  Is there a way to make it such that all three signals begin execution simultaneously?
 
Thanks,
Anthony
0 Kudos
Message 1 of 7
(2,551 Views)
Sorry I cant open this because I am still using LV 7.0 but are you using a hardware trigger to synchronize your DAQ?
Paul Falkenstein
Coleman Technologies Inc.
CLA, CPI, AIA-Vision
Labview 4.0- 2013, RT, Vision, FPGA
0 Kudos
Message 2 of 7
(2,539 Views)
Attached is a screenshot of the portion of my vi where the signals are initialized.  The top portion uses an internal counter to generate the gate for my buffered counting.  The middle portion initializes the buffer.  The bottom portion generates the analog signal outputs to control mirrors used in my imaging system.  Essentially, I need the analog signals to be triggered off the internal gate in order to acquire the image properly.  So for example when I press Run, the gate activates.  When the first rising edge of the gate is reached, the analog signal generation begins.  Additionally, the buffer will accumulate on every rising edge of the gate.  The frequency of the analog signal is divisible by the frequency of the internal gate, therefore I believe everything should be synchronized.  However, I don't think my vi currently performs what I desire because the DAQmx start task functions don't execute simultaneously when I run it through "Highlight Execution" mode.  Any ideas?  If this isn't the right way to go about it, then please let me know.  I'm not too experienced with this type of labview programming.
 
Thanks.
0 Kudos
Message 3 of 7
(2,530 Views)

Hi,

Thanks for posting the screenshot. I recommend implementing a start trigger in your program. This way, you can be sure that all of your tasks start simultaneously. Here is the link to a tutorial with more information on triggering: Advanced Data Acquisition Techniques with Intelligent DAQ. I hope that you find this information helpful.

Regards,
Hal L.

0 Kudos
Message 4 of 7
(2,518 Views)

I agree, A hardware trigger is where I was going with my question.  When you want to do a repetitive measurment on multiple channels it is always best to lock the DAQ loops to a single hardware pulse.  This will give you the best synchronization.

 

Paul

Paul Falkenstein
Coleman Technologies Inc.
CLA, CPI, AIA-Vision
Labview 4.0- 2013, RT, Vision, FPGA
0 Kudos
Message 5 of 7
(2,500 Views)
Our imaging system is currently being used for the next week so I'm unable to test the changes I've made to the vi.  Does it look like my vi is now triggered and synchronized accordingly?  That website was somewhat limited as to explaining the procedure for triggering tasks so I did the best I could with it.
Download All
0 Kudos
Message 6 of 7
(2,484 Views)

Hi,

I took a quick look at your code and you are getting a lot closer to having your final application. I found a better tutorial for you about triggering and synchronization: Timing and Synchronization Features of NI-DAQmx. I recommend checking this tutorial out in the meantime.

Regards,
Hal L.

0 Kudos
Message 7 of 7
(2,461 Views)