external triggers missed on PCIe-6321
1 次查看(过去 30 天)
显示 更早的评论
Hi
What I would like to do is to trigger output of an analogue waveform when an external trigger is received using a PCIe-6321. If further triggers are received while the waveform is being output I want these to be ignored. Once the waveform output is complete I want the trigger to be 'rearmed' and when received to play the analogue output again. This is the code:
daqSessionZ = daq.createSession('ni'); daqSessionZ.Rate = 10000;
daqSessionZ.IsContinuous = false; daqSessionZ.addTriggerConnection('External','Dev2/PFI12','StartTrigger'); daqSessionZ.ExternalTriggerTimeout = Inf;
daqSessionZ.TriggersPerRun = Inf;
waveform = linspace(0,5,10000)'; queueOutputData(daqSessionZ,waveform);
daqSessionZ.startBackground();
This does trigger in response to 5v pulses on Dev2/PFI12 but often misses triggers because it seems to take ~300ms to 'rearm' after the waveform has finished playing. Am I not doing this in the right way?
Thanks
Adam
0 个评论
回答(0 个)
另请参阅
类别
在 Help Center 和 File Exchange 中查找有关 Signal Integrity Kits for Industry Standards 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!