From Friday, April 19th (11:00 PM CDT) through Saturday, April 20th (2:00 PM CDT), 2024, ni.com will undergo system upgrades that may result in temporary service interruption.

We appreciate your patience as we improve our online experience.

LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

How to deploy Shared Variables with aliases (Project Variable), when some machines are offline?

Solved!
Go to solution

Hi all,

 

I have a distributed application (PC + a few CompactRIOs). My PC contains variables that have aliasing enabled -- they are bound to variables on the cRIOs.

 

One of the cRIOs is currently offline. I'm trying to deploy some changes I've made on the PC side. Unfortunately, LabVIEW refuses to deploy my PC libraries, because it can't connect to the cRIO that the variables are bound to.

 

How can I bypass that check, and force my PC to update? (I don't see why it's compulsory for the cRIO to be online for this :-/)

 

 

Thanks in advance!

Certified LabVIEW Developer
0 Kudos
Message 1 of 6
(3,370 Views)

Hi JKSH

 

Does it generate any error message or error code? To which type of variables on the  cRIO are bound the variables of the host application?

What exactly do you mean when you said the cRIO are currently offline?

 

Regards

Esteban 

0 Kudos
Message 2 of 6
(3,294 Views)

Thanks for responding, Esteban!

 

To answer your questions:

 

  1. No error codes. The deployment dialog just says, "Failed to connect to Real-Time target". That's expected, because the cRIO is not connected to the network.
  2. I'm binding simple numeric types only.
  3. The cRIO has been taken offline for maintenance. I'd like to update my PC .lvlib files, and test some modified PC code, but I can't because LabVIEW won't let me deploy my PC libraries or run the VIs if it can't find the cRIO. (Here's another common use case: I'm developing software before I've received my hardware, and would like to test my VIs without a cRIO connected)

 

I've attached a minimal example (LV 2012 SP1). I have a VI on the PC that plots data from the cRIO, and processes local data. I'm trying to run the PC VI when the cRIO is offline.

 

Expected outcome: The VI should run, and "PC Output" should change according to "PC Input". "cRIO Output" should have a default value, and the PSP LED should be red -- mousing over the LED should say "Bad Quality".

 

Actual outcome: LabVIEW refuses to run the VI completely, saying "Failed to connect to Real-Time target".

Certified LabVIEW Developer
0 Kudos
Message 3 of 6
(3,230 Views)
Solution
Accepted by topic author JKSH

Hi JKSH

 

In order to deploy the variable there has to be communication with the bind variable, in this case as the cRIO is not connected nor presented there is not any communication and the deployment fails.

 

As a work around what we can do is move the library from the target to the PC while the RT target is not present by doing this the variable will be in the computer and you can deploy the PC library. Keep in mind that we might need to save the project in order to save the movement of the file from the RT to the PC.

 

Regards.

Esteban R.

Deployment.PNG

Message 4 of 6
(3,209 Views)

Good idea, thank you for the workaround!

Certified LabVIEW Developer
0 Kudos
Message 5 of 6
(3,198 Views)

Your welcome, I am glad that the workaround worked for you.

0 Kudos
Message 6 of 6
(3,172 Views)