Digital I/O

cancel
Showing results for 
Search instead for 
Did you mean: 

switch between inputs and outputs of DIO 650x using DAQmx API

We need to switch 2 ports (16 lines) of our DIO 650x from input to output and vice versa.  We want to use the DAQmx C-API for that task.
What steps are needed to this ? Is
 
Stop task
Either Create DO Channel or Create DI Channel 
Start task
 
OK,  or are there additional steps necessary.
 
 
 
0 Kudos
Message 1 of 2
(3,066 Views)
Hi Markus,

you also have to create a new task for switching between read/write operation on the same port. So it's not enough to stop the task, you should clear it and reinitialize with the same channels after that.

Have a look on the DAQmx examples Read/Write from/to digital port on your local folder, that should give you more insight in DAQmx programming with the C-API:

C:\Programme\National Instruments\NI-DAQ\Examples\DAQmx ANSI C\Digital\

regards,

Nikolai


0 Kudos
Message 2 of 2
(3,047 Views)