LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

viWrite sends incorrect data

I have a test set application written using LabWindows 2013 SP1 that sends data over a USB connection to a radar system.  The application sends data using viWrite to a serial port connection on a radar system.  This application worked fine on three of our old test set systems. 

 

We recently bought new computers to develop more test sets.  When I try running our program on the new systems, I'm finding that the data transmitted in the USB message send is being garbled.  Random sections of the message are being overwritten with garbage. 

 

The new systems have a different BIOS, but all the computers are running Windows 7 Ultimate or Enterprise service pack 1 (64-bit), all are Intel I7s, and all have the same LabWindows version.

 

Attached are lists of the software installed on one of the original systems (PLATE 3) and one of the new ones (PLATE 5).  Is there anything installed that might be interfering with the USB message send?  Or anything else that might cause this problem?

Download All
0 Kudos
Message 1 of 4
(3,705 Views)

Hi richferrara,

 

The viWrite function simply calls the Windows SDK for serial communications. Could you try calling the Windows SDK through a different application (e.g. Visual Studio, Python, etc.) to see if the same behavior still occurs?

 

Otherwise what Operating System did you have on your old computers? Also, what kind of a message are you sending to the radar?

0 Kudos
Message 2 of 4
(3,674 Views)
Have you captured the data being sent with I/O Trace?

Also, the screen shots don't help much since they don't list the specifics of the NI software. Use MAX to list those.
0 Kudos
Message 3 of 4
(3,666 Views)

I appear to have found a fix for the problem.  I changed the code to move the problematic USB message send to its own thread.  Our test crew hasn't seen the errors appear since then.

 

We still don't know why this issue was only happening when running with the newer PCs.

0 Kudos
Message 4 of 4
(3,643 Views)