Measurement Studio for .NET Languages

cancel
Showing results for 
Search instead for 
Did you mean: 

DAQmxCfgDigEdgeAdvTrig

Solved!
Go to solution

My ultimate goal is to create a stepping function (for example: 0v, 1v, 2v, 3v, 0v, 1v, 2v, 3v, 0v, 1v,...) where the transisition from one voltage to the next is triggered by a digital input signal.

 

The only way I see to do this is to use the  DAQmxCfgDigEdgeAdvTrig function, but I'm unclear on how to setup the task before using it.

 

 

DAQmxCfgDigEdgeAdvTrig

  Purpose

    Configures a switch task to advance to the next entry in a scan list on a rising or falling edge of a digital signal.

 

 

 

I understand it advances to the next entry, but how do I populate the task with all entries, and is it possible to create a loop of events so that I can create the stepping function I desire?

0 Kudos
Message 1 of 4
(3,841 Views)

Hi elleryjh-

 

     The DaqmxCfgDigEdgeAdvTrig function is only used for controlling a switch to move through a scan list of configuration settings.  It is not the correct way to move through a set of voltages.

 

     You might look at this forum post to get some more ideas on staircase/step functions.

 

     You will probably end up setting up some logic to increase the voltage of an analog output task based on a digital input.

 

Best of luck with your application!

Gary P.
Applications Engineer
National Instruments
0 Kudos
Message 2 of 4
(3,810 Views)
Solution
Accepted by topic author elleryjh

Hi elleryjh-

 

     I just wrote a piece of sample code in LabVIEW that does exactly what you need it to do.  It might help to see it in LabVIEW then implement it in a text-based environment.

 

     It can be found here.

 

Regards,

Gary P.
Applications Engineer
National Instruments
Message 3 of 4
(3,789 Views)
Wow that looks great - thank you so much for your help, Gary!!
0 Kudos
Message 4 of 4
(3,784 Views)