OkiePC said:
...I must have missed that one...
Paul,
You most certainly did not...
In the thread I was referring to, you were actually defending the use of multiple output instructions on the same rung. So you certainly do like to stir things up. You just reverse the direction of stirring!
OTE in middle of rung
However, you're right in both cases I feel. That's the beauty with this feature, and something I think most were/are overlooking. You have a choice...
If you want to structure the logic in a more classical way, then for multiple output instructions with the same logical preconditions, use branching, or use separate rungs.
If you want to consolidate multiple output instructions that are preconditioned by the same logic, then series them on the same rung.
For both these methods, I would only advise using them within reason, or else it can become excessively long winded looking.
If you have an exceptionally large amount of output instructions to execute from the same logical pre-condition, then I would advise looking at using other methods besides individual output instructions.
Example:
You have a DINT array mapped to 32 physical outputs. Under certain preconditions, let's say an initialization, you want to reset the 32 physical output addresses to 0, or OFF.
You could, for instance here, use a CLR instruction to write zero's to all of the DINT's bit addresses. One logical instruction replaces many Boolean instructions.
Using the multiple OTU on one rung method here could, to some, look cumbersome or messy with several rung wraps. This is what can, for some, give this method a bad name. Overuse of Boolean instructions, whether input or output, on one rung can, for some, look ill thought out when there are simpler ways to handle relatively large amounts of contiguous data. Of course, the trick is to make the data contiguous in the first place. That's where the real planning comes in.
This also demonstrates another good reason to buffer, or map your I/O, as you can arrange blocks of scattered, but related I/O, contiguously buffer tag-wise, for reasons such as the above. It's not always possible, and some rungs will have scattered tag references which cannot always avoid multiple Boolean instructions. But where you can, I feel it's a good practice to get in to.
Regards,
George