LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Visa Write in Error: -1073807339

I'm receiving this error whenever I try to run my function.

 

The idea behind the function is to allow the user to input an 8 number string which is characterized as follows: channel (0-16), high value (0-255), low value (0-255).

 

This program uses serial communications (serial.read, serial.available, etc.), and it runs via USB (Com3).

 

However, I'm getting the error code -1073807339, "VISA Write in 'program.vi'" whenever I try to run my program.

 

The labview code is attached to this post.

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

this error means that the data could not be sent before the timeout was exceeded.  What hardware are you using?

 

Youre using the initialize daq function improperly though.  If you are doing a serial operation you should replace the initialize daq function with the visa configure serial port.



-Matt
0 Kudos
Message 2 of 7
(4,817 Views)

A few questions need clarification for us to help best

 

What is the device mgf/model?  Can you link to or attach the manual?  Is COM3 showing any warnings in MAX or Windows Device manager?  How is the port configured?  Can you attach the code where you configure the port settings?

 

A timeout from a VISA write is really rare.  Something basic is miss-configured.

 


"Should be" isn't "Is" -Jay
0 Kudos
Message 3 of 7
(4,795 Views)

 What is the device mgf/model?  Can you link to or attach the manual?  

I'm using a LTC2668 for my Vout channels, along with a Teensy 3.2.

The manual is here: http://cds.linear.com/docs/en/datasheet/2668fa.pdf

 

Is COM3 showing any warnings in MAX or Windows Device manager?  

Here is the strange part. Most of the time, I will continue to get this error. However, if I unplug my Teensy, make sure that NIMax doesn't recognize it anymore (I have to quit the program, rather than just "refresh"), and then reupload the Arduino code. Once I have done all of that, it will work 1 time, give me a VISA warning of 1073676294 and then breakdown every time after the first.

 

How is the port configured?  

I have a Teensy 3.2 driver installed, so that my computer recognizes it.

 

Can you attach the code where you configure the port settings?

 I attached my complete Arduino code, you are able to manually change the voltage values in the serial terminal. In labview, as you can see, I'm just trying to write the highest value to channel 00.

Besides this, I don't have any more code for configuration.

 

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

Usually serial communication uses ascii values. In the first VISA Write you are trying to send 00000000 which in ascii is 8 consecutive NULL characters. This is probably why you are getting the timeout. Try converting your string to its ascii equivalent before sending it to VISA Write. See this post. You can probably find other posts on the subject.

 

Ben64

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

@ben64 wrote:

Usually serial communication uses ascii values. In the first VISA Write you are trying to send 00000000 which in ascii is 8 consecutive NULL characters. This is probably why you are getting the timeout. Try converting your string to its ascii equivalent before sending it to VISA Write. See this post. You can probably find other posts on the subject.

 

Ben64


None of that is true.  That first VISA Write is sending eight zeroes, decimal 48, hex 30 on an ASCII table.  If he was sending 8 bytes that were the null character, that string constant, which is in normal display, would appear empty since the null character is a non-printable character.

 

Even if he was sending 8 null characters, that would not cause a VISA Write to timeout.

Message 6 of 7
(4,703 Views)


None of that is true.  That first VISA Write is sending eight zeroes, decimal 48, hex 30 on an ASCII table.  If he was sending 8 bytes that were the null character, that string constant, which is in normal display, would appear empty since the null character is a non-printable character.

 

 

Even if he was sending 8 null characters, that would not cause a VISA Write to timeout.


I haven't use serial communication in a long time, thanks for pointing this out. Sorry if I mislead anybody.

 

Ben64

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