09-28-2018 11:48 AM
When run, time elapsed is not displayed. also, the while loop's end condition is in a true state by default. Is this right?
09-29-2018 01:23 PM - edited 09-29-2018 01:25 PM
Hi Boyemkak,
Have you taken core 2 classes ? Maybe you should review how a Functional Global Variable (FGV) is made and how it works. That will answer your question 😉
09-30-2018 06:17 PM
@boyemkak wrote:
When run, time elapsed is not displayed. also, the while loop's end condition is in a true state by default. Is this right?
When you run it, the time elapsed is only displayed if the Timer mode of the caller is NOT "RESET", i.e. one of the other two option. ("Reset" should probably not be the default value here). It seems obvious that if you constantly reset the timer you'll never see a value. Note that there should also be a "First call?" functionality, because if it is not called with "reset" at the first call, the time tareget will remain zero and the control in the caller is ignored.
Also, the "Auto reset" control of the caller should not be TRUE by default unless the label is changed to "Auto Reset (T)". Mixed messages.
Still, the answer to your other questions about the loop condition shows that you don't understand FGV's yet. Start reading here. Note that you could change the various shift registers to feedback nodes, eliminating the while loop and thus making your question irrelevant because there is not even a stop condition present. Try it! 😄 (If you succeed, you probably understand FGVs, or "action engines")
There are probably better ways to do all that.