Jump to content

DVR's not working across vi's when built into exe


Recommended Posts

Hi All

I have a program written in LabVIEW 2015 that works well enough in the dev environment but I'm having an issue when it is built into an application and i can't see why.

I use 3 different DVRs in order to ensure that the data I capture over a CAN bus in my main application is available and correct for use in a sub vi launched in one of the panes of my main Vi. This is with a view to having different sub vi's for different applications.

The DVR's are registered and created in the main vi and I have tried initially using run VI methods and Ctrl Val.Set properties to send the reference value to the vi in question, then i tried using the reference and storing it in a global for the vi to see and in a test case I've tried to pass it directly to a test vi via a connector/control on in  the vi but in all instances, it works in the dev environment but not when in an application.

Does anyone have any advice on whether i have some bad build settings or whether these references cannot be passed between vi's (which i thought was their purpose).

Either way, i've been scratching my head for a while and haven't got anywhere

Link to comment

Hi

The code that creates the DVR is always running. The main portion creates the DVR's, reads in data from CAN bus and other sources, places them into the DVR controlled memory and repeats.

The other code in a separate vi then looks at the stored data by taking the DVR reference and finding the appropriate data and then displaying it or whatever it needs to do. Problem is this works fine in the dev environment but the reference or some other cause stops the other vi from accessing the data using an in-place structure when it is part of an application.

Link to comment

Here is a screenshot of the basic test i am doing.

When running in the dev environment i can see all the data in this DVR that has been set up in the main application, but when i run it as an exe, it is blank and no errors are generated.

Is there a way to prove that a reference has been successfully established, can i view it? I can then see if it is being transferred to this vi or not.

lv1.png

Edited by BBL
Link to comment
21 minutes ago, BBL said:

but when i run it as an exe, it is blank and no errors are generated

This is strange. If the DVR is invalid there will definitely be errors.

Based on what you've told us and the code above. I'd say that there simply is no data in the DVR. Is it being written to the DVR correctly? The above code shown is not good for debugging. You need to put the IPE structure in some kind of loop. It only executes once as shown, right?

Link to comment

Thanks for your reply. It triggered me to search further into my code and I did discover that the path to a configuration file was not correctly being modified to suit an exe rather than dev environment and therefore, as you correctly said, did not populate the DVR data as required.

 

It easy to get convinced it is one thing only to discover it is something completely different.

 

Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use.