Achieving tight trigger timing in DAQ session under Win 7 64-bit
Mostrar comentarios más antiguos
I'm attempting to port legacy code written using the old 32-bit DAQ toolbox, into 64-bit under the new DAQ 'Session' mentality. My old code allows me to send manual triggers with minimum delay between issuing the command and the signal being generated.
The old code:
ao = analoginput('nidaq','Dev1');
chanHandle = addchannel(ao,0);
set(ao,'TriggerType','manual')
start(ao)
... (do some other things, then decide I need to send a signal with minimum delay i.e. RIGHT NOW)
trigger(ao)
Under the 64-bit system, I'm not sure how to achieve the desired minimum delay. Actually I'm not sure how to issue a software trigger at all, or whether they even exist. The documentation is awful :(
I imagine I will have to do something along the lines of:
ao = daq.createSession('ni');
chanHandle = ao.addAnalogOutputChannel('Dev1',1,'Voltage');
ao.queueOutputData(data);
L_handle = ao.addlistener( ???, @(src,event))
ao.startBackground
Can anyone point me on the right path?
Respuestas (1)
Phillip
el 1 de Nov. de 2012
0 votos
Categorías
Más información sobre Data Acquisition Toolbox Supported Hardware en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!