Digital I/O

cancel
Showing results for 
Search instead for 
Did you mean: 

Assigning ports on NI6509 (96 DIO)

I need to assign 32-bits for reading, 8-bits for writing.

For read, if I assign "Dev1/port0", create a DI channel and use DAQmxReadDigitalU32, will the state of the 32 IO lines on ports 0 - 3 be read into the return array? Will the LSB (little endian) contain the state of port0, line 0?

For write, if I assign "Dev1/port4/line0:7", create a DO channel and use DAQmxWriteDigitalU8, will the state of port 4 reflect the value specified? I'll assume the endianess also applies here.
Thanks,
Dave
0 Kudos
Message 1 of 2
(3,194 Views)
Hello Dave,

"For read, if I assign "Dev1/port0", create a DI channel and use DAQmxReadDigitalU32, will the state of the 32 IO lines on ports 0 - 3 be read into the return array? Will the LSB (little endian) contain the state of port0, line 0?"
No, you will have to read from channels "Dev1/port0:3" to read all 32 bits. The LSB is P0.0.

"For write, if I assign "Dev1/port4/line0:7", create a DO channel and use DAQmxWriteDigitalU8, will the state of port 4 reflect the value specified? I'll assume the endianess also applies here."
Port 4 should match the value you wrote. P4.0 will be the LSB.

Let me know if you have any further questions.

Regards,
Sean C.
0 Kudos
Message 2 of 2
(3,182 Views)