Digital I/O

cancel
Showing results for 
Search instead for 
Did you mean: 

what is "line mask" of "DIO PORT WRITE.VI"?? I CANNOT Understand the Help file.

In a example , i see "x*2n" for it. why !
0 Kudos
Message 1 of 2
(3,581 Views)
Hey gpibssx,

The line mask is used to mask off the bits you are not interested in or you do not want to change. It is normally applicable when writing to a port.

For example if the existing port value was 0b00001111 and you are writing the value 0b10101010 to a port. If the line mask was 0b00000001 the new value written to the port would be 0b00001110. If the line mask was 0b00001111 the new value would be 0b00001010. If the line mask was the default 0b11111111 the new value of the port would be 0b10101010.

Basically the mask lets you know what values to change. I hope this helps out and let us know if this is still confusing.

Joshua P.
Application Engineering
National Instruments
0 Kudos
Message 2 of 2
(3,581 Views)