When using VISA Serial Read and requesting 227 bytes, only ~30 are read, which is reported by the vi. Why doesn't the vi read all the bytes at the port? I made sure all the bytes were transmitted by my modbus device via a datascope so I know its not on my end. Is there a property to set? The old Initialize Port vi had a buffer size that could be set, which seems to be my problem here. I don't see this in the VISA properties. Is there one that is just worded differently? Thanks in advance for any help? I am new to VISA.
Most likely you have termination char at your data sequence. So you need to set property of Message based settings->Termination char and Termination char enabled. This hopefully should switch VISA to read the whole data string up to termination char. If this is not so, do VISA read sequentially in a loop until get the all desired data or reach timeout. See online help for VISA functions and VISA manuals for details.
There are 2 things to try here: 1) Set the serial input end mode attribute to 0. The attribute/property name is either "ASRL End In" or "Serial End Mode for Reads". 2) Use the "VISA Set I/O Buffer Size" function in the VISA Interface Specific subpalette. This will let you set the receive and/or transmit buffer size.
Dan Mondrik Senior Software Engineer, VISA National Instruments