VI_ATTR_ASRL_END_IN

NI-VISA 15.0 Help

Edition Date: June 2015

Part Number: 370131S-01

»View Product Info

Resource Classes

Serial INSTR

Attribute Information

Access Privilege Data Type Range Default

Read/Write
Local

ViUInt16

VI_ASRL_END_NONE (0)
VI_ASRL_END_LAST_BIT (1)
VI_ASRL_END_TERMCHAR (2)

VI_ASRL_END_TERMCHAR

Description

VI_ATTR_ASRL_END_IN indicates the method used to terminate read operations.

  • If it is set to VI_ASRL_END_NONE, the read will not terminate until all of the requested data is received (or an error occurs).
  • If it is set to VI_ASRL_END_LAST_BIT, the read will terminate as soon as a character arrives with its last bit set. For example, if VI_ATTR_ASRL_DATA_BITS is set to 8, the read will terminate when a character arrives with the 8th bit set.
  • If it is set to VI_ASRL_END_TERMCHAR, the read will terminate as soon as the character in VI_ATTR_TERMCHAR is received. In this case, VI_ATTR_TERMCHAR_EN is ignored.

Because the default value of VI_ATTR_TERMCHAR is 0Ah (linefeed), read operations on serial ports will stop reading whenever a linefeed is encountered. To change this behavior, you must change the value of one of these attributes—VI_ATTR_ASRL_END_IN or VI_ATTR_TERMCHAR.


Related Topics

INSTR Resource

VI_ATTR_ASRL_END_OUT

VI_ATTR_TERMCHAR

WAS THIS ARTICLE HELPFUL?

Not Helpful