Error on a Read and No Data is Returned

NI-488.2

Error on a Read and No Data is Returned

If you wrote to your instrument without the write returning an error, you can reasonably assume your written message was properly sent to the instrument. If you wrote a command that the instrument responds to, you should perform a read (ibrd function call). If you receive an error on a read, it most likely is an EABO (abort) due to a TIMO (timeout) condition. This indicates the GPIB controller board was waiting for a response from the instrument, but the response never came.

To correct this error, check the following items:

  • The command you previously wrote to your instrument may not be valid. If you wrote an invalid command, the instrument may not respond with anything at all. Refer to your instrument user manual or contact the manufacturer for a simple command the instrument will respond to. Many instruments respond to *IDN? or ID, but others do not support these basic identification commands.
  • The termination method used on your write string may be incorrect. There are two main ways to terminate data messages sent to instruments: assert the EOI (End or Identify) line on the GPIB with the last byte of the transmission, or send an EOS (End of String) character at the end. The default termination for the National Instruments GPIB driver software is to assert the EOI line with the last character sent on GPIB writes. If your device requires a termination character, add it to the end of the string you write to the instrument. You can change the EOI setting with the ibconfig call, or in Measurement & Automation Explorer on Windows or GPIB Explorer on other operating systems.

Refer to Iberr Error Codes and Solutions for a complete list of GPIB error codes and their common causes. If you continue to have difficulty communicating with your instrument, contact National Instruments technical support.