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: 

String Indicator not updating after each cycle

Hi everyone,

 

I have a giant file containing many sub VIs. One of the VI contains a program to convert bit arrays into string characters. I placed this VI inside a while loop of the main VI. The sub VI works wonderfully well on the first while loop iteration and the string is  properly displayed on the main VI.

 

When I change the bit array for the next iteration, the string value does not get updated. I still receive the same string array I obtained in my previous iteration. I tried everything I know: like changing the properties of the string indicator to "Update value while typing" and "Wrap at work breaks" but nothing seems to change. 

stringindicator.PNG

 

What could be the issue here? The sub VI is attached.

 

PS: The main VI contain too many sub VI so it would be an inconvenience to upload all. But I derived the program from here Packet-based Digital Link - NI Community

 

Looking forward to your replies.

 

Thank you very much

0 Kudos
Message 1 of 11
(1,615 Views)

Can you "save for previous" and reattach. I currently don't have access to LabVIEW 2021. My guess is that you have a race condition.

0 Kudos
Message 2 of 11
(1,557 Views)

OK, I am able to look at your VI and the problem seems to be the way you are calling it. Can you show us the caller program? That's where the problem is.

 

I am not sure why you are playing with the string properties at all. This is an indicator, not a control, so the update mode is irrelevant. The rest are just cosmetic. How is the output of the subVI connected in the main VI? How is the subVI called? How does it get the array?

0 Kudos
Message 3 of 11
(1,543 Views)

Which version?

0 Kudos
Message 4 of 11
(1,539 Views)

Doesn't matter. I have a computer now that can open it. You need to show us the caller.

 

("Giant file" already hints at a serious problem, but we don't know how you define "giant". My guess is a dataflow problem or a race condition. Just attach the caller, we don't need all the subVIs.)

 

0 Kudos
Message 5 of 11
(1,535 Views)

So this is the file:

 

Rxfile.PNG

 

Since there are lot of dependencies, I am only attaching screenshots. I am trying to run the program in USRP which I got from example program here: Packet-based Digital Link - NI Community

 

I am using the subVI(marked yellow) here:

 

rxscreenshot.PNG

 

The previous sub VI is also attached in this reply. 

 

The output of the previous subVI is a bundle containing an array of type int and another array of type bool. The bundle is unbundled and the array of type int is fed to subVI Format Rx Data, which converts it into type string. Let me know if you need any other information

 

 

0 Kudos
Message 6 of 11
(1,503 Views)

I am not sure why you are attaching another random subVI instead of the caller?

The bug is in what you wrote, not in the VIs from the example.

 

Can you verify that the global variable connected to the case structure is guaranteed to be true when it is read?

Is "enable?" guaranteed to be true in the input stream cluster?

0 Kudos
Message 7 of 11
(1,489 Views)

Yes. I checked the global variable myself through its front panel.

0 Kudos
Message 8 of 11
(1,482 Views)

I thought about that as well. I used the example program as it is, without changing anything. I checked the example program with two different strings:  

 

HelloWorld_USRP_Output.PNG

LabView is fun.PNG

 

As you can see, the string indicator does not change. It remains same. I verified with higher power, different frequencies as well. I got same results. So the issue is actually with the example program.

0 Kudos
Message 9 of 11
(1,471 Views)

Hi @altenbach,

 

This problem existed even before I added that global variable. That global variable was added to avoid USRP leakage. The global variable is not the problem, I can vouch for that.

 

Do you think the problem could be that the example program was released in 2011 and I am running it in LV2021 which may be causing some unexpected bug?

 

Any other reason may be?

0 Kudos
Message 10 of 11
(1,367 Views)