Best Way to Handle Setpoints from Different Sources

zeroion

Lifetime Supporting Member
Join Date
Aug 2020
Location
California
Posts
1
I am working on a project using AB PLCs and PanelView HMIs.

There is a desire to allow control loop setpoints to be provided through the HMI or remotely from the plant PLC (via produced/consumed tags).

The challenge is how to handle the situation where the HMI and plant PLC provide different setpoints.

I have come up with some ideas, but none of them sound all that great:
  • Have the HMI setpoint always win. I would probably have to retransmit the current setpoint as a produced tag for the plant PLC so they would know that they are being overridden by the HMI value.
  • Track changes in both setpoints by time, using the latest value as the setpoint.

Has anybody come up with some good solutions for this problem?
 
Create a remote mode and a local mode. Primary HMI will have a button to select this mode. In remote mode move remote setpoint into "remote tag". In local mode move local setpoint into "local tag"..... hopefully that helps
 
Maybe not what you want, but how about check set points against last change so that if one of them change you post that one into the variable for the set-point & update the check.
for example you have compares for not equal, if one of them changes then update the setpoint & update the check variable.
CMP <> HMI_SP, Req_SP---- MOV HMI_SP, Req_SP, Other_SP
CMP <> OTHER_SP, Req_SP---- MOV OTHER_SP, Req_SP, HMI_SP
If it is not desirable to update say HMI on the other SP change then you would need a couple of spare variables to use as the last SP
CMP <> HMI_SP, HMI_Last ---- MOVE HMI_SP, Req_SP MOV HMI_SP,HMI_Last
Do the same for the other SP.
 
Perhaps this may help, do not know what hirachy you require but the code below just assumes that if either the HMI or scada (in this case) a setpoint is changed then it changes the required SP, there is also a button on each to override the setpoint from either device, the idea is that if the current SP has been selected from the Scada, the HMI SP has not changed so to implement the HMI SP just press the update button & vice versa.
Either that button but if no button then the operator just changes the SP by a small amount then back to the one they want.

SP Update.png
 
Maybe not what you want, but how about check set points against last change so that if one of them change you post that one into the variable for the set-point & update the check.
for example you have compares for not equal, if one of them changes then update the setpoint & update the check variable.
CMP <> HMI_SP, Req_SP---- MOV HMI_SP, Req_SP, Other_SP
CMP <> OTHER_SP, Req_SP---- MOV OTHER_SP, Req_SP, HMI_SP
If it is not desirable to update say HMI on the other SP change then you would need a couple of spare variables to use as the last SP
CMP <> HMI_SP, HMI_Last ---- MOVE HMI_SP, Req_SP MOV HMI_SP,HMI_Last
Do the same for the other SP.

This is what I was going to recommend as well.
 
You can imagine a scenario where either of the setpoints should have priority. Is the plant PLC generating its setpoint from a recipe or from conditions upstream of the process controlled by the local PLC? In other words, is the plant PLC trying to change the setpoint based on what it anticipates is going be happening?
If the plant PLC setpoint is generated from a recipe, my inclination would be to favor the HMI setpoint on the assumption that it comes from a person with eyes on the process. But that assumes the person at the HMI is at least as competent as the plant PLC.
On the other hand, if the plant PLC is changing the setpoint because of something the local operator isn't aware of, the plant PLC setpoint might be the better choice.
You might want to include logic to limit the allowable discrepancy between the two setpoints.
 
Yes Steve is right, there are a lot of if's.
The way I posted assumes the following:
It can be altered without pre-conditions
The operator input perhaps should have some sort of level entry to stop un-authourised use.
The set points are limited by either limits within the HMI/Scada.
Or maybe set so a change on the HMI has to be within a certain +/- percent of the Scada setting.
 
Does 1 system have priority over the other?

If not just have both writing to the same tag.

If so then have a local / remote switch on the highest priority.
 
I do this all the time. Primary HMI selects local or remote control. Remote setpoint is controlled by Primary HMI (Plant SCADA). Local Setpoint is ignored unless primary HMI sets local control tag to allow setpoint change.
As janner_10 said.
 
to avoid choosing from local remote, i make both device write into the same tag with a temporary bit. During the rising edge of that bit, the side that want setpoint to be change can change it and once it is done, the data can be accessed by both side again.
One can just make a stored data entry to be moved into the setpoint tag and have a ''enter'' button just beside reffered to the temporary bit that will allow writting.
 
This is called the 2 Generals problem in CS classes. I've not come up with a solution that works easily and transparently. this is especially bad when long delay telemetry is involved.

The one way I made it work was to use an additional write bit from the side that changes the value but read it back every scan to update the other side on what was changed.

Clunky but it did work.
 
Go directly to the PlantPAX CmdSrc documentation and AOI for a guide on this control strategy. Do not pass Go. Send me $200.

It permits command and setpoint selection among different possible command sources, with varying degrees of precedence:
- Program (local, automatic)
- Operator (local, manual)
- External (remote, automatic or manual)
- Maintenance (local, but overrides the others)

There's others, but this would be a good starting point. You can even disable a subset of those provided.
 
Last edited:

Similar Topics

Hi; We have below mentioned softwares for PLCs, PVs drives etc. I want to ask what is the best practice to handle these softwares, should we...
Replies
9
Views
2,929
Hi there. I need to do a really small update to a program in a s7-314 cpu and wonder what's the best way to do it? The machine is located...
Replies
3
Views
4,001
Compactlogix controller, program has 28 conveyors that use TON's to start the conveyors. The TT sounds a warning horn during start and the DN...
Replies
5
Views
59
I have S7 1512C controler for controlling 48 PID temperature loop, the output is PWM. Please I need the best, most efficient way to write the...
Replies
5
Views
213
I am going to need to use HART multi-drop in order to handle a series of Vega Radar units. There are a lot of options and I'm wondering what...
Replies
3
Views
218
Back
Top Bottom