Showing results for 
Search instead for 
Did you mean: 

COM ports not showing up in distributed EXE

My serial VI's always work fine on my own development computer. I created an EXE for one of our suppliers and although the device shows up in windows as a COM port, my VI doesn't see it, so it generates the -1073807202 error. He's tried unplugging/plugging, restarting, etc. It's the FTDI adapter cable, which I've always had very good luck with, brand new, so it's got the latest driver.


When I search the forums, I see references to MAX. Is it possible that my supplier will need to install MAX, in addition to the LVRTE? It seems preposterous, but, then, it's labview.


Any help is appreciated.

0 Kudos
Message 1 of 10

In your program, how are you setting the COM ports?


If you're opening "COM1" or whatever, that is actually an alias set up by MAX.  You might need to set it up to look for "ASRL1::INSTR" instead (changing the "1" out for the appropriate COM port number).

Message 2 of 10

Did you create just an exe, or an installer?


I assume you are using VISA functions to communicate with the instrument, thus, a VISA runtime would need to be installed.



0 Kudos
Message 3 of 10

Another advice is to use a state machine in your code with an option to reinitialize the serial communication. Imagine, what happens if they accidentally unplug the cable?

Usually what I do with built executables, is that, the application checks the connected device via COM1 (or whatever was the default port when the app was tested on the dev PC). The application tells the connected hardware to identify itself. If this is successful, the state machine gets into a state where the serial unit is used.

If there is timeout error or no proper ID coming back, I clear the error, and at the same time I report this problem to the operator.

At this point I use two different approaches.

One is that, when the state machine scans through all available COM ports and requests the unit for ID.

The other option I use, is that the state machine gets into an Idle state, and the user needs to browse and select the proper COM port for reinit. If this is successful, the application saves the working COM port into a configuration file. So the next time the user launches the executable, it searches for existing config file, and loads the last time working COM port info before ID request.

0 Kudos
Message 4 of 10

NI-MAX should have been installed by the NI-VISA runtime, you did install the NI-VISA runtime, right?

=== Engineer Ambiguously ===
0 Kudos
Message 5 of 10

Except VISA run-time you also need NI Serial run-time to work with com-ports

0 Kudos
Message 6 of 10

@Alexander_Sobolev wrote:

Except VISA run-time you also need NI Serial run-time to work with com-ports

Depends on what hardware he has.


NI-Serial provides support for customers using NI Serial cards and NI embedded controllers with serial ports.



0 Kudos
Message 7 of 10

Your're not alone.  I'm working on the same problem.

0 Kudos
Message 8 of 10
0 Kudos
Message 9 of 10

@Jim12345678 wrote:

Your're not alone.  I'm working on the same problem.

Since you hi-jacked the thread,  Could you give a bit more information about your installer settings and what problems you see on the target machine?  (And what is the target OS?)

"Should be" isn't "Is" -Jay
0 Kudos
Message 10 of 10