IMDHMIControls LibraryShop main store

Troubleshooting

Why an HMI cannot write a PLC PID setpoint directly

PLC programming Published 7 min read By IMDHMI controls team

Short answer

The panel driver for a Do-more PLC exposes flat memory types only, so it cannot address the loop's .SP structure member, and the tag export does not carry loop internals. Write the setpoint into a plain staging register, gate a MOVE into .SP on a real value change or an accept bit, and echo the live setpoint back to a separate read register. Cast a real staging element on an even element number, for example DLV0:R; DLV1:R is rejected.

On this page
  1. Why the write never reaches the setpoint
  2. Stage the setpoint and move it in the ladder
  3. Gate the move and keep each element one-way
  4. Worked example: a 123.4 C setpoint through R0 into Loop1.SP
  5. Casting a DLV element to REAL when word memory is all you have
  6. Mirror the loop data the panel still needs
  7. Questions asked

The operator changes the setpoint on the panel, the number sticks on the screen, and the loop keeps running to the old target. Nothing faults, because the write landed somewhere valid - just not in the loop. A Do-more PLC holds every PID loop as a structure, and only a client that speaks the controller's full addressing syntax can reach inside it; a panel driver built on flat memory types has no syntax for a member such as .SP. The fix lives in the ladder, not in the panel: give the numeric entry a plain staging register it can address, gate a MOVE into the loop's .SP member on a real value change or an accept bit, and echo the live setpoint back to a separate read register the panel displays. Tag exports, memory-type drop-downs and re-downloads cannot bridge that gap.

Why the write never reaches the setpoint #

A Do-more CPU is strongly typed. A PID loop is not a block of registers with published offsets; it is a structure whose members carry their own data types and whose internal layout belongs to the firmware. Do-more Designer reaches those members because it speaks the controller's full addressing syntax. A panel driver built on a flat address model - bit, word, double word, real - stops there, so it has no way to ask for a member such as .SP even though the controller would serve it.

These five attempts get tried before the shift is over, and none of them can work:

  • Type the member path into the tag address field. The driver's parser has no member syntax, so it rejects the string or quietly resolves it to a base memory type.
  • Hunt through the memory-type drop-down. It lists flat blocks only; structured elements are not exposed as a selectable type.
  • Import the PLC tag database into the panel. The element-documentation export carries flat elements and their nicknames; the loop internals do not come out as addressable tags.
  • Put a nickname on .SP and export again. Quick to try and still blocked, because the limitation sits in the driver, not in the PLC.
  • Reboot the panel or re-download the program. The write path is intact and there is no communication fault to clear.

A write that reports success while the target value never moves is the same failure shape as why a SCADA write to a PLC real address fails silently, and the cure has the same shape: move the write to a location the client can genuinely reach. Decision: no panel-side setting opens the structure, so the rung belongs in the PLC.

Stage the setpoint and move it in the ladder #

Give the panel one plain element it can address and let the ladder be the only writer of the loop structure. The pattern survives driver and firmware updates because nothing depends on the structure's internal layout.

  1. Pick a staging element whose type matches the setpoint: a real element such as R0 for a floating-point target, or one 16-bit word for an integer-scaled loop.
  2. Nickname it for the panel side, SP_Cmd in this example, so the exported documentation reads cleanly at the screen.
  3. Point the numeric-entry object at that nickname; the driver handles a bare element address without trouble.
  4. Add a rung that executes every scan and moves the staging element into the loop's .SP member only while the two differ, or while a momentary accept bit from the panel is on.
  5. Add a second rung that moves the live .SP member back into a separate echo element every scan, and point the display at the echo, never at the entry element.
// Rung 1: accept a setpoint from the panel
// SP_Cmd = staging element (example: R0)   SP_Echo = echo element (example: R1)
// the compare contact passes only while SP_Cmd differs from Loop1.SP
if SP_Cmd not equal to Loop1.SP then MOVE SP_Cmd into Loop1.SP

// Rung 2: echo the live setpoint for display, every scan
MOVE Loop1.SP into SP_Echo

Decision: the panel writes one element, the ladder writes the structure, and neither side depends on the other's internals.

Gate the move and keep each element one-way #

An unconditional move every scan hands the loop to the panel: any setpoint that a recipe routine, a ramp block or a supervisory program places on .SP is stomped within one scan, and the loop appears to ignore its own logic. Gate the move on a real difference, or on the accept bit, and the sources coexist.

Blame the configuration before the ladder: when the loop is set so the setpoint tracks the process variable while the loop is in manual, an external write during manual is overwritten at the next loop update, and the symptom looks exactly like the original driver gap.

Treat the staging write as a command, not an override: the loop's limits and the machine's interlocks stay owned by the PLC program, and the panel path must never be able to force a value past them.

Keep one writer per element. Commands get their own element and status gets its own; the entry and echo split above already follows that rule. Decision: a gated move with separated directions keeps the handshake predictable for every writer on the machine.

Worked example: a 123.4 C setpoint through R0 into Loop1.SP #

The case: a temperature loop nicknamed Loop1, an example nickname, holding 120.0 C, with the operator raising the target to 123.4 C, an example value, from the panel. Staging is R0, nicknamed SP_Cmd, a real element the panel driver addresses natively; the echo is R1 in this example, nicknamed SP_Echo, beside it. The panel writes only SP_Cmd and displays only SP_Echo.

The rule: rung 1 moves SP_Cmd into Loop1.SP only while the values differ; rung 2 moves Loop1.SP into SP_Echo every scan.

Scan 1: the compare checks SP_Cmd against Loop1.SP, 123.4 C - 120.0 C = 3.4 C, a nonzero difference, so the contact passes and the move fires, and Loop1.SP becomes 123.4 C. Scan 2: the compare repeats, 123.4 C - 123.4 C = 0.0 C, the contact is false and the move does not fire, so a supervisory write to .SP survives. The echo move copies the accepted value into SP_Echo every scan, so the display follows the loop rather than the keypad.

Result: one scan after the entry, Loop1.SP holds the entered value, and the number on the screen is the number the loop is using.

Decision: the threshold is simply nonzero, because any real difference fires the move and equality leaves the rung false, so the handshake needs no tuning. If the loop still holds 120.0 C after a move that fired, the rung is not executing or the loop is in manual with the setpoint tracking the process variable; correct that in the PID configuration, not in the ladder.

Casting a DLV element to REAL when word memory is all you have #

When a fixed map or leftover addressing parks the staging value in DLV memory, cast it. Appending :R to a data-block element tells the instruction, or the Data View, to treat that element as a REAL instead of its native unsigned 16-bit word type. A REAL occupies two consecutive words, so the element must sit DWORD-aligned and only even element numbers qualify.

Cast reference Result
DLV0:R, DLV2:R, DLV4:R Legal: DWORD-aligned, gives access to a 32-bit REAL
DLV1:R, DLV3:R Rejected: odd element, not DWORD-aligned

When a map that cannot be renumbered forces a misaligned pair, PUBLISH and SUBSCRIB copy between the misaligned memory and properly typed elements in both directions. When the Data View format drop-down offers no REAL choice for a word element, type the address with the cast suffix instead of fighting the selector. The full casting rules sit in Do-more Designer help topic DMD0309. The even-element requirement is not unique to this controller: the same two-word arithmetic decides why a BRX PLC needs an even first word to read a Modbus Float32.

Decision: an even element with the :R cast when word memory is forced on you, a native real element such as R0 when it is not, and PUBLISH with SUBSCRIB when a fixed map hands you an odd element.

Mirror the loop data the panel still needs #

The same gap runs in the read direction. The process variable, the control output, the mode status and the alarm flags all live inside the structure, and a flat driver cannot reach any of them. Build one contiguous mirror block per loop and move those values into it once per scan, with the layout fixed and documented: the panel tag list is built on those offsets, and shifting them later means re-editing every object on every screen. Group the mirrors for all loops into one continuous range so a driver that supports block reads pulls the whole set in one transaction, the same idea as reading PLC tag arrays in one block request.

Decision: writes travel from the panel into a staging element and through a gated move, and reads travel from the loop members into a mirror block and back to the panel. Nothing touches the structure from the panel side on a driver whose address model is flat; the ladder owns the structure on both paths.

Questions asked

How do I prove the handshake works before operators use it?

Enter a test value at the panel, then watch three things in the PLC software: the staging element takes the value, the loop's setpoint member changes on the next scan, and the echo element matches the member. If the staging element updates but the member does not, the gated rung is not executing or the loop is in manual with the setpoint tracking the process variable. Hand the screen over only once all three agree.

Does an integer-scaled setpoint need the same alignment care?

No. The cast suffix and the even-element rule exist only when a word element must be treated as a 32-bit REAL. An integer setpoint fits a single 16-bit word, so one word of staging memory works and any element number is legal. The gated move and the echo rung stay exactly the same; only the data type of the staging and echo elements changes.

Can two panels write the same loop's setpoint this way?

Yes, if both panels write the same staging element and read the same echo element. The gated rung becomes the single point where the two entries are resolved, and each screen shows the accepted value rather than the last number typed. Give every panel the same numeric-entry limits, because the staging element itself carries no per-panel protection.

Keep reading

  • How-to

    Cascaded PID loops on a Do-more without a Cascade mode

    The Do-more PID has no Cascade mode and no setpoint pointer: cascade is built in ladder by moving the outer loop's Output into the inner loop's SP every scan while cascade is selected, writing the local setpoint only on change, interlocking the two loops' Auto/Manual states, and preloading the outer manual output before each transfer. The C-more reaches the values through native R memory, not the PID structure.

    PLC programming

  • How-to

    Scaling a PLC-5 FLEX analog output from PID 0-4095 to 0-30840

    A PLC-5 PID drives its control variable from 0 to 4095, while a FLEX analog output channel configured for the current loop expects output data from 0 to 30840, so a raw CV gives 6.125 mA at 100 percent. Leave the PID limits at 0 and 100 percent, scale the control variable times 30840 divided by 4095 into a separate integer word, and point the BTW at that word. The CV word and the BTW data word must be different addresses.

    PLC programming

  • How-to

    Structure dock door conveyor interlocks in Studio 5000

    Run the conveyor on three explicit states — Ready, Running and Restart-required — with door-open, truck-present and curtain-clear as permissives. Truck departure mid-cycle stops the conveyor and latches a manual restart; the light curtain's protective stop stays in safety-rated equipment. Fix the door sensor before debouncing, then size the timer to the measured flicker — 600 ms against a 240 ms example.

    PLC programming

Write HMI device data into an S7-400 DB with an external tag