This content is not available in your preferred language.

The content is shown in another available language. Your browser may include features that can help translate the text.

Error -1073807339 VISA Read or Write Timeout

Updated Aug 28, 2019

Reported In


  • LabVIEW
  • LabWindows/CVI


  • NI-Serial
  • NI-488.2

Issue Details

  • I was able to communicate with my instrument with a VISA Test Panel, but when I perform a VISA Write or VISA Read operation in LabVIEW, I get the following error message:

Error -1073807339 occurred at VISA Read or VISA Write.

Possible reason(s):

VISA:  (Hex 0xBFFF0015) Timeout expired before operation completed.

The error message is also shown in the image below:


There are several reasons why you might receive this error message, the most common of which are detailed below:

A) You may not have the correct driver installed. Ensure you have the right driver for your hardware. Some common ones are:

  • NI-VISA  (for instruments using serial or GPIB communications)
  • NI-Serial  (for instruments using serial communication as RS232, RS422, RS485, etc)
  • NI-488.2  (for instruments using GPIB communications)
Note: You must install NI-488.2 driver software before installing any new NI GPIB hardware devices so Windows can detect them.

Also ensure that you have the installed most recent compatible version of your driver. Compatibility information can be found in the readme file for your driver which is listed on the corresponding download page (which are listed above).

B) Ensure the connection to the instrument is secure. Some potential issues are that the port isn’t properly connected, the wrong port is selected, or the port is not being able to send/receive data. Check the instrument is properly plugged in to the port you're using. Check that the cabling for the instrument is the correct cable (RS 232/422/485 or GPIB).

C) Try a different system with the same drivers. The COM ports could be corrupted or not working in the original machine.

D) A timeout error could also result from the wrong command strings written to the drivers. Check the command strings sent to the VISA Read and VISA Write calls and ensure that they are written in the proper syntax for your instrument.

Note: A new line or carriage return is often required at the end of a command.  A good way to test this in LabVIEW is to right-click the command string control on the front panel and change the display to '\' Codes Display mode. In this mode, a carriage return is \r, a line feed is \n, and an end of line is \r\n. Consult your product's manual to learn which is expected, and be sure to consistently use the appropriate option.

E) The port's communication settings may not be configured correctly. Verify that the Baud Rate, Data Bits, Parity, Stop Bits, and Flow Control are set correctly to correspond with your hardware requirements. You can change these settings programmatically during run-time with VISA VIs, or in NI-MAX.

Note: This error could be caused by attempting to use a 2-wire device with an RS-485 serial port. You will need to properly configure your 2-Wire device to work with an RS-485 serial port. 

F) This error may be induced by attempting to read more bits than are available at the serial port.

F.1) The VISA Property Node for Bytes At Port should be implemented to ensure that the data read by VISA is limited to exactly the amount of data available.

F.2) Additionally, you can verify that you are not trying to read too many bytes by reading only 1 byte at a time. If you do not get the error when doing so, increment the number of bytes you read until you get the timeout error again. This tells you how many bytes that command sends back.

Note: If you still receive the error while reading only 1 byte, verify the command to make sure it has been written correctly and that you have also terminated the command string correctly (as brought up in solution C).

G) Older instrumentation may not respond rapidly to commands written to the port, causing a large delay between VISA Write and VISA Read commands. Applications designed to interface with this type of instrumentation should anticipate this delay, and implement a Wait function between VISA Write and Read to effectively avoid a potential timeout error.

H) Timeouts can also occur when you read or write large amounts of data, since large data sets often take longer than the default timeout period of 2000 ms to transfer across the serial port. You can manually designate the VISA Session Timeout in different ways, depending on your development system. Please see below for instruction on setting the VISA Timeout:

LabVIEW: You can use VISA Set Timeout located in the Functions palette under Instrument I/O » VISA » VISA Advanced. Refer to Configuring Timeout for VISA Sessions.

LabWindows/CVI: You can use the viSetAttribute function with its Attribute_Name parameter is set to VI_ATTR_TMO_VALUE.

Note: Changing the Timeout value for your VISA session will affect all VISA Writes and Reads in your session. However, you are able to set this property/attribute at any point during the session, allowing you to configure it as needed.

I) Timeout also can occur if in the VISA communication the write function has to be feed with a string, with such property BackSlash (\) Code otherwise if for instance I give to my device this command *IDN?\r\nthe timeout comes out. The property can be set by right click on string>>properties>>Display Style

Additional Information

For more information about the software required, as well as techniques to troubleshoot common errors or obstacles in get an instrument up and running in your system, visit the Troubleshooting NI VISA, 488.2, Serial, and Modular Instrument Drivers document.


Not Helpful