Hi everybody, My code is in Vb .Net and i use VISA COM Lib 3.0 to communicate with GPIB instruments. But sometimes when i write some string on gpib, i've got the VI_ERROR_TMO error, whereas before the write operation was successfull !
I am by no means an expert, but since no one else has responded, I'll share my experience with you.
I use VISA to communicate serially in LabView. I've seen lots of VI_ERROR_TMOs that appear to be normal time-out events on the port. When I've seen them, I am reading from the port, and this tells me that there is no data to be read.
When you are writing to the port, Perhaps it means that the port is still busy with a previous command, or busy receiving. Does this port have a write buffer? Try increasing the buffer size.
I have a few thoughts on why this might be happening. If you changed to a different computer it might take longer to get the information or if there is additional traffic. I would suggest changing the VISA timeout to a larger value to see if that fixes the problem.
As a side note, I would not recommend using VISA COM with .NET. NI has a native .NET class for VISA that doesn't use COM. The .NET assemblies for VISA are much better and faster in .NET then using COM.
The VISA for .NET is included with Measurement Studio 7.0 or on the recent Driver CD.