Digital I/O

cancel
Showing results for 
Search instead for 
Did you mean: 

Specifying MSB and LSB for 16-bit reads

I am doing a two byte read on the NI-6534 DIO card. I want to specify that port 1 (B) be the most significant byte, and port 0 (A) be the least significant. However, the port list input will only accept the value 0:1, which has the byte order reversed. Is there a way to specify 1:0 for the order?
0 Kudos
Message 1 of 2
(3,126 Views)
Hello jbrandon,
I am attaching a sample program that demonstrates how the byte reversal can be done in LabVIEW. There are definitely more than one ways (and there might be a simpler way too, this vi demonstrates only one of them).
The reason why LabVIEW won't accept the input "1:0" for port list is because some devices have port list restrictions. Valid port lists for 653x devices are:
0
2
0:1
2:3
0:3
and thus the input has to abide these restrictions. So if you use 0:1 as input for port list and then do byte reversal in LabVIEW, that should solve your problem.
I hope this answers your question. Again, thank you for choosing National Instruments. Good luck with your project and have a great day !

Swapnil P.
National Instrument
s Engineer
0 Kudos
Message 2 of 2
(3,126 Views)