I have made a patch that will take three measurements from an ultrasonic sensor. On the first reading I set the servo angle to zero, and read the distance. I increment the COUNT node. The COUNT node feeds back to a SELECT node that then sets the servo angle to 70 degrees (approximately forward looking). I increment the COUNT and the SELECT node sets the servo angle to 120 degrees (the max for my servo).
I would like the count to go from 1 to 3. I noticed that when I initially set the output (accumulator) of the COUNT node to 1, the count does indeed start at 1. But, when I reset the COUNT node so that we can start the process all over again, then the original value of the output node (accumulator) is ignored and the count is reset to zero (which is what the help says it will do).
Is this a bug (i.e., should the COUNT node “remember” the original value that the user set for the output/accumulator of the COUNT node), or is it a feature that it will always reset to zero regardless.
It’s no big problem. Obviously I can index from 0 to 2, or test for zero and act accordingly. I am just curious if this is actually the desired behavior.
Here is the patch if anyone is interested: