Instrument Control (GPIB, Serial, VISA, IVI)

cancel
Showing results for 
Search instead for 
Did you mean: 

Error -1073807339 during VISA Write with RS232

Hello,

 

First: I'm using LabView 8.6 and currently trying to control a WEISS Umwelttechnik temperatur-shock-chamber TS130. So i started a small Test-VI, that works through the following steps:

Open VISA->Configuring Serial Port->Writing Command->Wait some Time->Read all the avaiable Bytes at the Port (the reaction of the TS130)

That works fine for an amount of time. I send a command. The TS130 follows them. But after a few orders I get the Error -1073807339  (Timeout during Write) for any new command. The smallest command i tried was about 6 characters long.

I already tried the following:

a) Wait for 5s or more between two commands as mentioned in the TS130 manual -> no change

b) insert an the VISA-VI to clear the send-puffer before writing the command-> no change

c) raising the timeout to 5s-> no change

d) turning the TS130 off and on again -> no change

e) rebooting windows -> it works fine for a few commands and then I'm getting the same error.

in my eyes, it is a softwareproblem (through the reboot made an effect, but not the restart of the TS130)

Can anyone please help me? Ideas?

 

 

0 Kudos
Message 1 of 7
(4,875 Views)

Hve you checked to see if the same thing happens when you use HyperTerminal?

 

How are you running the VI? Do you have a loop around the write/read pair, or is the whole VI a single-shot, and each time you run it it goes through the VISA Open? Which timeout are you changing?

 

Can you post your VI?

0 Kudos
Message 2 of 7
(4,843 Views)

today I made some research on the problem to get some additional information.
So I tried the things in Hyperterminal. Again it was possible to send a few commands and they ware executed properly. But there was a point (and I couldn't find a constant time or command that leads to the problem) when it seems no further commands could be transfered. Hyperterminal then suddenly echod the command character by character with a break of 1 second between each character and not in one piece like before (not depending on the length of the command). Further there didn't came an answer back from the machine (not after 10 Minutes). Closing the connection and building up a new one didn't solve the problem, even not after waiting for several minutes before rebuilding. Only rebooting the system made it work properly again (for the next few commands).

 

No, there are no loops etc. in the VI, it's a straight single-shot. It starts with the VISA-Open and ends with the VISA-Close. I was changing the timeout in the general settings of the connection through the according property node (see the attached VI).

 

I also made some tests to get the influence of the used Serial2USB-Converter (because the programming-notebook doesn't have any COM). I connected the TS130 directly to a COM of a pc. Now in Hyperterminal I couldn't find a point the transfer slow down. But coworkers mentioned problem after working with the TS130 through that pc for hours (thats why I have to replace the original software by a LabView). So I won't exclude problem with the Converter as reason, although I wouldn't be able to explain where to find them exactly.

0 Kudos
Message 3 of 7
(4,817 Views)
Based on the fact that you had a similar effect when using HyperTerminal, this tells me the problem isn't with LabVIEW. If you have some other instrument that can talk via serial that would be a good way to determine if the problem is with the converter. You can try to use the Portmon utility while running HyperTerminal to see if something obvious shows up. Or, you may need to resort to using a serial port sniffer (or simply a scope) to see what's happening on the serial port lines.
0 Kudos
Message 4 of 7
(4,814 Views)

I was using the Converter in similar Situations with other instruments without any problems.

But I'll try that with Portmon today and then report. Thanks.

0 Kudos
Message 5 of 7
(4,794 Views)

Hello,

 

I have the same error for my application could you please let me know if you manage to any response to this problem.

Thanks

 

0 Kudos
Message 6 of 7
(4,603 Views)

It might be a hardware handshaking issue or problem. To see what's going on with the serial port with the VISA driver, try using NI Spy (it's in your Start menu folder: Programs -> National Instruments).

 

Also, you could use the 'Free Serial Port Monitor' program. Get it here: http://www.serial-port-monitor.com/index.html

 

Good luck.

0 Kudos
Message 7 of 7
(4,599 Views)