LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

VISA error code: -1073807339

Hi there,
Sometimes I get error code -1073807339 when i click on Stop button.
Why is that error?
Do i really need delay of 50ms?

Please, help!

Kind regards,
Balázs

Download All
0 Kudos
Message 1 of 15
(3,869 Views)

That is a timeout error.  You get it when you are not getting data back from your instrument.  A few possible causes:

1. Wrong port settings

2. Instrument is not connected

3. You failed to send a proper command to tell the instrument to send data back

 

What are you trying to communicate with?  What is the message protocol?



There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
0 Kudos
Message 2 of 15
(3,844 Views)

No.  You should not need the delay assuming your device uses a termination character like your VISA Configure is set up for.

 

For the command you are sending, do you need to include a termination character such as a line feed at the end of the command?  Right now your entire command is a question mark and there are no other characters after it.

 

You should swap the local variable and the terminal for "Read Buffer".  Terminals are faster so that should be in the loop.  Use the local variable for the initialization when the VI starts.

 

If you set your Send Cmd button to Latch when Pressed rather than Switch when Pressed, you don't need to set it back to false.

0 Kudos
Message 3 of 15
(3,834 Views)

Also you do know that even when Send CMD is false you are sending an empty string along with the default Termination Character (Line Feed) every 50mS that your loop is running

 

Maybe sending this empty command every 50mS when it should be sitting idle is confusing your instrument or overflowing an internal buffer?

========================
=== Engineer Ambiguously ===
========================
0 Kudos
Message 4 of 15
(3,823 Views)

@RTSLVU wrote:

Also you do know that even when Send CMD is false you are sending an empty string along with the default Termination Character (Line Feed) every 50mS that your loop is running

 

Maybe sending this empty command every 50mS when it should be sitting idle is confusing your instrument or overflowing an internal buffer?


Actually there is nothing there that indicates a termination character is being sent.

 

It is a completely different property node that must be enabled in order to send termination characters on Write.  This VI doesn't have that.  So sending an empty string actually sends nothing.

 

But RTSLVU is correct in that for good programming practice the VISA Write should be in the case structure as well.

0 Kudos
Message 5 of 15
(3,815 Views)

@RavensFan wrote:

@RTSLVU wrote:

Also you do know that even when Send CMD is false you are sending an empty string along with the default Termination Character (Line Feed) every 50mS that your loop is running

 

Maybe sending this empty command every 50mS when it should be sitting idle is confusing your instrument or overflowing an internal buffer?


Actually there is nothing there that indicates a termination character is being sent.

 

It is a completely different property node that must be enabled in order to send termination characters on Write.  This VI doesn't have that.  So sending an empty string actually sends nothing.

 

But RTSLVU is correct in that for good programming practice the VISA Write should be in the case structure as well.


The VISA Configure Serial Port termination character terminal defaults to "termination char (0xA = '\n' = LF) "

 

The VISA Configure Serial Port Enable Termination Char terminal defaults to "True"

 

The OP had neither one of those terminals wired in the code he posted so the termination character is enabled by default and would be sending the default value (LF).

 

TermCapture.PNGterm2Capture.PNG

========================
=== Engineer Ambiguously ===
========================
0 Kudos
Message 6 of 15
(3,806 Views)

Enable termination character only applies to Reads.

 

There is a separate property node that is not a part of the VISA configure if you want it to apply to Write.

 

See https://forums.ni.com/t5/LabVIEW/Visa-serial-don-t-work-sometimes/m-p/3888496#M1102863

Message 7 of 15
(3,794 Views)

@RavensFan wrote:

Enable termination character only applies to Reads.

 

There is a separate property node that is not a part of the VISA configure if you want it to apply to Write.

 

See https://forums.ni.com/t5/LabVIEW/Visa-serial-don-t-work-sometimes/m-p/3888496#M1102863


I didn't know that... Makes me wonder how all those programs I have written all these years manage to work now....?

========================
=== Engineer Ambiguously ===
========================
0 Kudos
Message 8 of 15
(3,792 Views)

Either it did send the termination character because it was set somewhere else, or maybe the devices just timed out and took the command as it was, which was complete, just lacking the termination character.

0 Kudos
Message 9 of 15
(3,787 Views)

Hi there,
Thanks to everyone for the quick reply.
The instrument is a BMT932-6 (6 means 6 channels)
BMT932-6 Datasheet


It has two types of operating modes:
1)User mode that can be timed and polled. Default mode is timed, when instrument is sending measurement data in following format every timed interval.:
06.02.19,05:56:30,000.0 ppm,000.0 ppm,000.0 ppm,000.1 ppm,000.0 ppm,000.0 ppm,0000
In polled mode i have to send ? questionmark to get the measurement data. I need to configure it manually.

2)Link mode: in link mode i should be able to configure the instrument remotely. It has its commands. To start link mode i have to send *0#DK0NHF and instrument should response with *0#DL7ZN which means remote mode is activated.
I have tried many times but 'Read Buffer' shows me no response.

Should 'Read Buffer' be able to receive response?

Kind Regards,

Balázs

0 Kudos
Message 10 of 15
(3,766 Views)