LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Distribution Kit Error

 I get the following error when trying to run a distribution kit I created. Initialization Error: A code library required by VISA could not be located or loaded. Check your connections and make sure you have the right instrument descriptor.  I have written a program that communicates to a FSH spectrum analyzer. Any ideas on what is missing from the distribution kit?

 

brenda.gillcrist@navy.mil

0 Kudos
Message 1 of 26
(5,751 Views)

Hi Brenda,

 

Do you get this error while running the distribution kit (ie, installing the CVI application), or while running the actual application (one you've installed it from the distribution kit)?

 

If it is the latter, the cause is probably that NI-VISA was not included in the distribution kit. You can add this component to your distribution kit from the  "Drivers & Components" Tab of the Edit Installer window.

 

Hope this helps! 

Jervin Justin
NI TestStand Product Manager
0 Kudos
Message 2 of 26
(5,722 Views)
I get it when I am trying to run the application after installing it. Would you be more specific on how to add the component?
0 Kudos
Message 3 of 26
(5,720 Views)

I guess a better question is how do I properly include it in the distribution kit instead of editing the installer?

 

Brenda

 

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

Hi Brenda,

 

The distribution kit is the installer. When you create an installer in CVI, you can choose to include additional components that also get installed along with your application like the CVI Runtime Engine, and any neccessary driver.

 

To create a new installer/distribution kit, open your project and click Build» Manage Distributions and create a new configuration for a distribution. This will only create the configuration for the distribution, not the actual distribution. When you are done configuring it, you can build the distribution from Build»Build Active.


When I mentioned that you could edit the distribution earlier, I meant that you could edit the configuration of your old distribution and re-build it once you added NI-VISA to it. 

 

This is a good resource on the topic:
Developer Zone Tutorial: Distributing Applications with the LabWindows/CVI 8.x Distribution Kit 

Jervin Justin
NI TestStand Product Manager
Message 5 of 26
(5,716 Views)

Jervin,

 

I have Labwindows/CVI 7.0.0  I have looked at the help documentation and it isn't clear to me how to add NI-VISA to the distribution kit. Do you have any other documentation that I can refer to?

 

thank you for your assistance

Brenda

 

0 Kudos
Message 6 of 26
(5,677 Views)

The ability to package drivers like NI-VISA into the distribution kit is available only in version 8.0 and later. Since you are using 7.0, you'll have to install NI-VISA to your target machine separately from your distribution kit, in the same manner you installed it to your development machine.

 

Mert A.

National Instruments 

Message 7 of 26
(5,665 Views)

I developed some NI Labwindows/CVI software to communicate to a Rhode Schwarz spectrum analyzer. The spectrum analyzer cable is an optical to rs232 cable. I serial to usb cable is used to connect the spectrum analyzer cable to a laptop. I inherited this code and have made modifications to it. When I try to install the software via a distribution kit I get errors that NI-VISA has not been installed. Is there any reason why NI_VISA is required for what I am trying to do? I have purchased labwindows cvi, and the drivers from Rhode Schwarz. Drivers are installed for the serial to usb cable as well.

 

Brenda

 

0 Kudos
Message 8 of 26
(5,602 Views)

It depends how which libraries/functions you are using to do the serial communication with the instrument. If the code you inherited/modified makes any calls to NI-VISA functions (e.g. viRead, viWrite, etc.), then you will need to install NI-VISA to the target computer. If your program instead calls the RS-232 library (i.e functions like OpenCom, ComRd, ComWrt, etc.), then you should not need VISA. Can you confirm that your program makes no VISA calls?

 

Mert A.

National Instruments

0 Kudos
Message 9 of 26
(5,596 Views)

If you decide to use NI-VISA, you would be for sure better off from my point of view.

 

1) There is an application note available how to remote control R&S spectrum analyzers via plain SCPI commands: http://www2.rohde-schwarz.com/en/service_and_support/Downloads/Drivers/?rckb=1&type=25&downid=2567

 

2) even more convenient is to get rid of all the SCPI command and use the R&S instrument drivers for LabWindows/CVI: http://www.rohde-schwarz.com/driver/FSHLabWindows.html (includes an application example) Also an update for this instrument driver for the new FSH4/8 generation on the roadmap

 

regards juergen

0 Kudos
Message 10 of 26
(5,584 Views)