I am running simultaneous acquisition and generation sessions using the PCI-6541. My generation session seems to be working fine, but for some reason my acquisition session never recognizes the pattern, and the Read Waveform VI times out. When I look at my waveforms on the logic analyzer, I can see that the waveforms are as I would expect them -- the generated waveform is a clock for my device, and the device responds while the clock is running. However, the acquisition session never sees the response from my device.
I think this is a timing issue... I've tried putting the VIs in different orders, using the Fetch VI, etc., but so far I have not been able to figure out how to make the synchronization any better. Because of the way my hardware is set up, I am unable to use the PFI lines, so I don't think a hardware trigger is possible.
I would appreciate any insights you might have! I've attached a screenshot of how I've configured my generation and acquisition sessions.
Thanks for the screenshot, that helps alot. As you have it coded,
you have the ReadWaveform and the Initiate Generation execute in
parallel so you have no guarantee which happens first. It may be
the case that you are generating the pattern before you actually start
to look for the trigger. If you need your acquisition to trigger
on your generation then you need to make sure that you initiate your
acquisition before you start to generate.
You can use the exact same Initiate VI that you used in the generation
code. By explicitly calling initiate, you can use the FETCH
waveform vi rather than the READ waveform. The READ waveform
essentially combines the two operations so you do not have as fine a
control over when the session initiate relative to other VI's in your
code. There are a couple of examples that ship with LabVIEW and
CVI that better illustrate the difference between the two functions and
how they are used.
In this fashion, you can start your acquisition and have it waiting on
the pattern match trigger. You then start your generation which
will be registered by the acquisition session which will then trigger
and acquire the data into memory.
Does this help? If not, there are some other tricks we might can try that will get the two sessions to be more in synch.