09-16-2017 03:58 AM
dear all
i have project reading shared variable from PLC.
i am using table control and i have put different shared variable on each pages of tab according to function and given tab name accordingly.
now if i want to use while loop and put each shared variable of tab pages in each while loop.
which will be best practice and will run fast because some time lab view showing slow reading variable from PLC.
Please see attached vi.
Thanks,
Asif
09-17-2017 04:00 PM
I'm not quite sure what you mean, so i'll state some general tips. Don't use several copies of the Shared variables, drop 1 on the block diagram and split the wire as needed. Else there's a chance the program reads several times for less efficiency. Also, the top loop has no wait, making it a cpu hog, add a wait of 40(?) ms.
The LED-level can preferrably be replaced by a an array of LEDs with a Level Quotient 16 (or however big your steps are) to determine how many leds are to be lit. See attachment.