I would love some opinions from the community when it comes to how faceplates link up to your control modules/ blocks / AOIs / FBs
I am currently rewriting our company's standard blocks.
When it comes to linking a control module to a faceplate I like to have a bit per button that changes the state in the block, and then the status is mapped back.
For example (thumbsuck) there would be two bits, one called OnRequest, and one called OffRequest. OnRequest would be set in the SCADA, and then the PLC would set the On bit to true and reset OnRequest. The On Status is then mapped back to the SCADA separately. This gives me definite switching, the SCADA isn't changing the internals of the block directly, and the bits can be mapped to each button. You could animate them to show that the button has indeed been pressed and as soon as the PLC handles it, it would return to its non-pressed state and the status indication would then show.
This also allows me to bit pack into two seperate words, one which the scada reads from, one which it writes to, and even if the SCADA engineer messes up nothing can be accidentally switched. Nothing of the internal block is exposed, there is an interface.
This is all fine
But, now I get to things like configuration setpoints. something like a High Alarm threshold. Now in all the code I have seen these setpoints are linked directly to the SCADA, changing it on a faceplate, changes it internally.
Is this really the way to go about it though? Is this good enough?
The other way I can see this happening is if you follow the same convention as with the above bits. you would have tags that are commands, and tags that are statuses. If you change the high limit it would be written to a register, the PLC would scan this register, if it is not zero it writes that to the internal variable, and this is then mapped back to a feedback variable which is then displayed on the SCADA
This however doubles the amount of tags used, and brings in more complexity. Hence the question, do I go down this route, is it worth it?
What would be the best practice here?
What do you do?