01-19-2018 06:33 AM
Hello
Please find the enclosed VIs.
Last iteration value of subVI is only updating in MainVI. But i need to update the previous iteration Case values also into mainVI.
Regards,
S Nagaraju
01-19-2018 08:11 AM
The sub VI sets the value, then returns to the main where the exact value is written again. There are no iterations in the sub VI. The references are redundant...
Not sure what you want exactly. You might try putting a wait in the main VI's loop. Or try highlight execution to see for yourself what your program is doing in slow motion.
If you want to show all values when done, let the loop build an array (auto indexing).
If you want to show new values while looping, add the elements to an array that's in a shift register.
01-19-2018 10:44 AM
Note: You misspelled "Separation" in your main vi.
01-19-2018 11:50 AM - edited 01-19-2018 11:51 AM
Even what you call "MainVI.vi" is a subVI, so for us to understand your problem, it would help to attach also the caller, i.e. the real main vi.
A lot of the code seems a bit convoluted. You know that you can wire strings to case structures, so why are you sometimes doing equal comparisons instead? When you call your main.VI, there is possibly ancient data stuck in the "remaining string" which gets never cleared, but read via local with every call. Why do you use local variables for "status" instead of placing the indicator terminal after the case structure?
Some of the code is just plain silly, e.g. the following basically checks if the string contains "07".
First you find the match, then concatenate it with the string after the match, then you take the first two letters, basically undoing the concatenation and see if it matched the original search term. Determining if "07" either exists at all or is at the start of the string does not need all that. If needed later, you can do the concatenation inside the following case structure. Can you guarantee that the string never contains more than one "07"?
In summary, take all your VIs. (real mainVI, subVI, subsubVI) and put them in a zip file. Include some simulated typcail data that shows the behavior. Tell us how you operate it, what you see, and what you like to see instead. Be as detailed as possible.
01-19-2018 11:28 PM
Dear sir,
In MainVI Response data control having three valid packets. Those are 070480000000000000000105000C0000AA439672BE42B1A85EAA000807048000000000000000010600080000AA0001AA0000000807048000000000000000010400080000AA010101AA000008.
In MainVI I'm separating the first valid packet and sending to subVI and it is giving the Az and El values and updating into MainVI.
In second iteration of MainVI is separating the second valid packet and sending to subVI. SubVI gives the antenna selected value and the same is updated into mainVI. But the Previous Az & El values are resetting to default. This is same for third valid packet also.
In MainVI, recent packet value only updating and rest of the values are setting to default. But i want to display the all the values in MainVI.
Kindly help me.
Regards,
S Nagaraju.
01-20-2018 07:53 AM
@Sonti_11532 wrote:
In MainVI, recent packet value only updating and rest of the values are setting to default. But i want to display the all the values in MainVI.
You could use a FOR loop and autoindex the output values and then you can display the array.