angelmcdoggie
2008-05-23 10:10:07 UTC
Hello All,
I want to start trigger a digital output (NI 9401) module to generate data. I read some info but I am having problems with my timing.
m_DITask->DIChannels. CreateChannel( risingEdgeLine1, _T( ""), DAQmxOneChannelForEachLine);
m_DOTask->DIChannels. CreateChannel( commandLine1, _T( ""), DAQmxOneChannelForEachLine);
m_DOTask->Timing. ConfigureSampleClock( "/cDAQ1Mod5/ai/SampleClock", rate, DAQmxSampleClockActiveEdgeRising, DAQmxSampleQuantityModeContinuousSamples, samples);
m_DOTask->Triggers. StartTrigger. ConfigureDigitalEdgeTrigger( "/cDAQ1/ai/StartTrigger", DAQmxDigitalEdgeStartTriggerEdgeRising);
Related to trigger, this is the workaround that I am trying to achieve.
Source: <a href="http://digital.ni.com/public.nsf/websearch/67E849D5A5715BB486256F7A0064D85B?OpenDocument" target="_blank"> http://digital.ni.com/public.nsf/websearch/67E849D5A5715BB486256F7A0064D85B?OpenDocument</a>
Triggering:To trigger the waveform acquisition or generation, the source of the DIO sample clock (i.e. the analog sample cock) must be set up for the trigger and the DIO operation should just be configured to receive that clock. For example, if you were going to use the analog input sample clock to clock your digital measurements, you would configure your AI subsystem to receive a start trigger and to use an internal clock. Once the trigger arrives, the AI Sample clock is generated and passed to the DIO subsystem
My program generates the status error in the attachment. Another question, Is the link also applies to C - series DAQ? I'd like to do some post processing of samples. By the way, I am using a cDAQ-9172, NI-9401 for my DIO; Visual C++. Thanks for any enlightenment.
Please advice,
A
twoedge_meas.ppt:
http://forums.ni.com/attachments/ni/70/8906/1/twoedge_meas.ppt
I want to start trigger a digital output (NI 9401) module to generate data. I read some info but I am having problems with my timing.
m_DITask->DIChannels. CreateChannel( risingEdgeLine1, _T( ""), DAQmxOneChannelForEachLine);
m_DOTask->DIChannels. CreateChannel( commandLine1, _T( ""), DAQmxOneChannelForEachLine);
m_DOTask->Timing. ConfigureSampleClock( "/cDAQ1Mod5/ai/SampleClock", rate, DAQmxSampleClockActiveEdgeRising, DAQmxSampleQuantityModeContinuousSamples, samples);
m_DOTask->Triggers. StartTrigger. ConfigureDigitalEdgeTrigger( "/cDAQ1/ai/StartTrigger", DAQmxDigitalEdgeStartTriggerEdgeRising);
Related to trigger, this is the workaround that I am trying to achieve.
Source: <a href="http://digital.ni.com/public.nsf/websearch/67E849D5A5715BB486256F7A0064D85B?OpenDocument" target="_blank"> http://digital.ni.com/public.nsf/websearch/67E849D5A5715BB486256F7A0064D85B?OpenDocument</a>
Triggering:To trigger the waveform acquisition or generation, the source of the DIO sample clock (i.e. the analog sample cock) must be set up for the trigger and the DIO operation should just be configured to receive that clock. For example, if you were going to use the analog input sample clock to clock your digital measurements, you would configure your AI subsystem to receive a start trigger and to use an internal clock. Once the trigger arrives, the AI Sample clock is generated and passed to the DIO subsystem
My program generates the status error in the attachment. Another question, Is the link also applies to C - series DAQ? I'd like to do some post processing of samples. By the way, I am using a cDAQ-9172, NI-9401 for my DIO; Visual C++. Thanks for any enlightenment.
Please advice,
A
twoedge_meas.ppt:
http://forums.ni.com/attachments/ni/70/8906/1/twoedge_meas.ppt