LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

Dynamic call data log issue

Hi team ,

 

I call a program by dynamic method . So i tried with 2 methods of calling a file path .

1st method : by static reference call

2nd method : Relative path

 

Please find attachment of subvi . Described in image

 

 

 

From the main vi , i get a data  output  ( log data - control name  )

 

after getting this data  i wrote this data in text file from main vi .

 

Issue was totally weird and ridiculous. 

 

Issue :

From running the main vi , data was not written on text file .

 

But i opened this vi ( Attached - subvi file )  and put a probe , after that checking the log was captured and logging everytime , but not normally run from main vi  . Totally mysterious .

 

please advice .

 

0 Kudos
Message 1 of 5
(1,124 Views)

Could you please attach your main vi? Your probe seems to only prove you can obtain the data from the log data control, but as you haven't attached how you're writing this data to your text file, there is no way to determine what the issue is.

 

 

Using Labview 2022, Windows 10
0 Kudos
Message 2 of 5
(1,091 Views)

Hi allison ,

 

These are the subvi's i used for logging .

please find attachment

Shell uut COM read is a vi which receives a log from UUT  .

Dynamic log run is vi , which gets data dynamically calling inside the main VI

0 Kudos
Message 3 of 5
(1,055 Views)

Hi willcan,

 


@willcan wrote:

Issue :

From running the main vi , data was not written on text file .

 

But i opened this vi ( Attached - subvi file )  and put a probe , after that checking the log was captured and logging everytime , but not normally run from main vi  . Totally mysterious .


Why do you need to read control values by method node?

Why don't you read the SharedVariable?

Why don't you call this VI as a standard subVI and get the desired value by wire?

 

There might be a race condition in your mainVI: you start the "Shell-UUT" VI and immediatly after you read the "Log data" indicator: are you sure this subVI was already able to do its job and provide a new value for "Log data"?

 

When "Shell-UUT" should run in parallel to your mainVI you might also use a queue/notifier to transfer data to your mainVI (among other techniques)!

Best regards,
GerdW


using LV2016/2019/2021 on Win10/11+cRIO, TestStand2016/2019
0 Kudos
Message 4 of 5
(1,050 Views)

@willcan wrote:

Hi allison ,

 

These are the subvi's i used for logging .

please find attachment

Shell uut COM read is a vi which receives a log from UUT  .

Dynamic log run is vi , which gets data dynamically calling inside the main VI


Hello Willcan,

 

Unfortunately, your attached code doesn't show the whole picture.

 

1. Please attach all code necessary to review your issue. You've attached your write vi, but not the vi that calls it. The Bobcat_process Raw Data vi is missing, and so is the Shell class.

2. As GerdW points out, you're calling the Shell-UUT COM Read vi and then immediately reading the LogData control, without knowing if the control has yet to receive new data.

3. You're clearing out errors in your Write Text File.vi and Shell-UUT COM Read.vi, thus ignoring possible issues in your code that may help answer your questions.

Using Labview 2022, Windows 10
0 Kudos
Message 5 of 5
(1,040 Views)