User | Kudos |
---|---|
4 | |
3 | |
3 | |
2 | |
2 |
There are times when I don't really like the way feedback nodes make my diagrams appear:
I don't like the wires going back and overlapping things. This usually happens when there are a number of FNs in a single piece of code.
One way to work around this issue is to do something like this:
This splits the wire into two nodes and is essentially the "text based" approach - create a named variable and use it as a buffer. The fact that it's a local doesn't really bother me that much, even though that might raise the local police on me, but it does have some actual disadvantages - memory allocation (not usually a real consideration, but still), difficulty in setting an initial value, a technical possibility of creating race conditions if the user doesn't know what they're doing, it's harder to see that the two nodes are connected, etc.
So what I want is something which would combine the two - allow us to right click a feedback node and select Split, which would split it into two:
which results in this:
This is essentially like having a shift register without the loop. It ties the two parts of the node together and it should allow having an init terminal on the read node. In theory, it could also have a label. Also, note that in this case I didn't limit the vertical positioning of the nodes. This should be useful in cases where nodes are connected through elements which change the height of the wire, like Build Array or Select.
If you want to see some more opinions on this, we discussed it here a few years ago - http://labviewartisan.blogspot.com/2009/03/why-are-you-still-using-loops-in-your.html
Also, here are a couple of alternate visuals, just for completeness, although I don't really like them:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.