Hi Andy,
Thanks for starting this excellent thread! Good questions & answers. I am adding this topic, which I’ll call: “Flowchart Flow” to my list of topics we could cover better with our various training tools.
To answer your question about the -5: yes, you would get that error coming back if you tried to start a chart that was already running. For example, if you tried to start the Powerup chart from within the Powerup chart, you’d get a -5 for the status code returned.
There’s one important point I’d like to emphasize, especially given the mention above “cyclic charts”: in these charts that loop, ALWAYS add a Delay command. We talk about this in the training classes here at Opto 22 in Temecula, and Ben always puts this in his examples and reminds people any chance he can get. It may just be the most important concept for the “novice” strategy developer.
At first, this idea of adding a delay to make your strategy run faster overall, might seem counter-intuitive. Someone else mentioned, earlier in this discussion, the concept of a “time slice” and other charts getting a chance to run. Keep in mind that there’s only one CPU in your PAC, so all these charts that run “at once” are sharing the CPU’s time.
To use an analogy of a mom driving some kids somewhere–the chart with no delay is like the kid in the back seat asking: “Are we there yet? Are we there yet?” over and over. You want him to maybe ask you every 20 minutes max. Likewise, in your strategy, if you have looping/cyclical chart that perhaps checks: “Is it too hot yet?” over and over, faster than makes sense, then the CPU doesn’t have as much time to do all the other things it should be doing and can appear slow or sluggish overall.
Meanwhile, the mom (or dad) driving has a PID running in their head to keep their speed below the limit, where the “Input” is the current speed, “Output” is foot on gas, and the PID “algorithm” might be…??? Maybe I took this analogy too far.
In any case, keep those good questions and answers coming!
Speaking of Novice Questions, and learning… I’d like to ask all of you:
[INDENT]1) What were some of the must[B] difficult concepts [/B]you came across while learning about and how to use Opto 22 products?
-
What kinds of [B]learning tools [/B]do you prefer? (Videos, animated demos, sample code, discussions like this, free Product Support, white papers, in-person classes?)
-
What [B]topics [/B]would you like to see more learning tools address (videos, etc.)?
[/INDENT]Thanks and write on!
-Mary