Filter löschen
Filter löschen

Why am I unable to trigger my data acquisition device when I set the "TriggerType" property to "HwDigital"?

2 Ansichten (letzte 30 Tage)
I am using a NI-DAQ device with the Data Acquisition Toolbox. I have set the "TriggerType" property of my ANALOGINPUT object “ai” to "HwDigital" :
ai = analoginput('nidaq','Dev1');
addchannel(ai,0);
set(ai,'TriggerType','HwDigital')
However, the acquisition starts immediately. I am unable to trigger the device.

Akzeptierte Antwort

MathWorks Support Team
MathWorks Support Team am 14 Jan. 2010
This change has been incorporated into the documentation in Data Acquisition Toolbox 2.15 (R2009b). For previous releases, read below for any additional information:
For data acquisition objects created using NI-DAQ, there is an additional device specific property called as "HwDigitalTriggerSource" which has to be set when the "TriggerType" property is set to "HwDigital".
"HwDigitalTriggerSource" defines which pin is used to initiate a data acquisition when the "TriggerType" property is set to "HwDigital".
ai = analoginput('nidaq','Dev1');
addchannel(ai,0);
set(ai,'TriggerType','HwDigital')
set(ai,'HWDigitalTriggerSource','PFI0');
"HwDigitalTriggerSource" can take values from PFI0 to PFI9 or RTSI0 to RTSI6.
(Consult the manual for the specific pin of the board being used)
Please note that the "HWDigitalTriggerSource" property is only implemented for the Analog Input object and not for the Analog Output object.

Weitere Antworten (0)

Kategorien

Mehr zu Simultaneous and Synchronized Operations finden Sie in Help Center und File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by