Resolving the Suffix on Siemens 840D MSG Output
On SINUMERIK 840D / 840D sl controls, the high-level language command MSG("text") is used inside an NC part program to display a user-defined string in the operator message line of the HMI. A recurring field symptom is that every programmed message is rendered with the suffix <no text available> appended to the end of the operator text, for example:
Hello <no text available>
The behavior persists regardless of message length, does not affect program execution, and is reproducible on every line that uses MSG(...). The phenomenon is not a syntax error and is not caused by missing HMI text files. It is a message-bar rendering condition that the NCK and the HMI resolve by falling back to a default placeholder when the message slot cannot be unambiguously identified at display time.
This article documents the diagnostic path, the documented SINUMERIK behavior that produces the suffix, and the corrective actions that are field-proven on 840D sl controllers with HMI Operate (Operate V4.x and the newer Operate V5.x) running NCU firmware 4.5 / 4.7 / 4.8.
1. Background: How the MSG Command Works on 840D sl
The NC language element MSG(string) writes a text into a modal message buffer inside the NCK. The buffer is then read by the HMI's message line widget and rendered in the top status bar. The complementary form MSG("") clears the buffer, and a leading semicolon — ;MSG("text") — demotes the statement to a comment that the interpreter discards.
| Syntax | Behavior | Result on HMI message line |
|---|---|---|
MSG("Hello") |
Active message statement; loads the string into the modal message slot. | Displays Hello
|
MSG("") |
Clears the modal message slot. | Clears the message bar |
;MSG("Hello") |
Comment — interpreter discards it. | No effect |
MSG(" ") |
Loads a single space. | Empty bar / fallback <no text available> |
MSG without parentheses (legacy 840D) |
Operator message referencing an alarm/text number; requires configured text in the alarm database. | Configured alarm text, or <no text available> if the number is undefined |
The HMI message widget assumes that whatever text is in the slot at the moment of refresh is the text to display. The widget is not syntax-aware: it cannot tell the difference between an empty slot, a slot whose value the operator message line cannot map, or a slot whose key was set to a numeric alarm number that the HMI's alarm text resolution path cannot resolve. In all three of those cases the HMI renders the literal placeholder <no text available> so the operator still sees a non-empty, easily-recognizable token rather than a blank field.
2. Symptom Description
The reported symptom is consistent across the affected machine:
- Every
MSG("text")line displays the user string followed by<no text available>in the HMI message line. - Program execution is not affected; the part is machined as intended.
- The behavior is identical whether the program is loaded from a network share, a CF card, or DNC mode.
- The behavior is identical in MDA, AUTO, and JOG modes.
- The behavior persists after NCK reset, cold restart, and after deleting
NCK.SYSon the CF card.
The fact that the user text is displayed correctly proves the parser interpreted the string. The fact that the placeholder is appended proves the HMI is the component that has lost the second token it normally expects. That distinction is what drives the entire diagnostic path described in Section 4.
3. Root Cause Analysis
There are four documented conditions that cause the HMI to render <no text available> as a suffix to operator text. They are presented in the order in which they should be ruled out during commissioning.
3.1 Mismatched message scope and modal lifetime
On 840D sl, the message slot is a single-slot modal register. The text in it survives until one of three things happens:
- An explicit
MSG("")clears it. - A new
MSG("text")overwrites it. - Reset / M30 / program end clears it.
If the HMI refreshes the message line at a moment when the slot has been cleared but the widget still expects to display the previous message, the widget substitutes <no text available> for the missing token. Long CAM-generated programs with frequent tool changes frequently trip this condition because the post-processor emits MSG("") in the tool-change macro.
3.2 Operator message line written as MSG without parentheses (legacy 840D)
On legacy 840D (pre-sl, NCU 561.x), the statement MSG written without parentheses is treated as a reference to a configured operator message number. The HMI looks up the number in the alarm/text database and displays the resolved string. If the referenced number is not defined in the active language set, the HMI displays the placeholder <no text available> rather than a blank field. This is the most common root cause on machines whose part programs were originally written for an older controller and then re-run on an 840D sl that was not configured to publish the same alarm text database.
3.3 PLC operator message collision
The PLC has its own channel for pushing operator messages (DB19 / DB2x.DBX depending on the PLC library version). If a PLC message with the same priority class is in the queue at the same time as the NC's modal message, the HMI concatenates the PLC payload after the NC text. When the PLC payload is a clearing message (no text), the HMI appends <no text available> instead of a blank.
Verify by reading the diagnostic buffer DB19.DBX8.x (or the equivalent symbolic tag in the project) while the symptom is visible. If the buffer is non-zero, this is the active cause.
3.4 HMI display setting messageline.mode
On HMI Operate V4.7 SP3 and later, the message line widget supports a configuration switch in /user/system/configuration/configuration.xml and in the sl-specific file slconfig.ini that controls how the widget reconciles concurrent messages. The relevant key is messageline.mode. Default is 0 (concatenate). A non-default value of 1 or 2 (replace on conflict) forces the widget to clear the slot rather than concatenate, which then produces the placeholder suffix during the refresh window.
4. Step-by-Step Diagnostic Procedure
Use the following checklist in order. Each step is non-destructive and can be performed in production.
Step 1 — Confirm the parser interprets the string
From the part program header, write a single, isolated test block and run it in MDA:
MSG("TEST_MESSAGE")
G04 F2
M30
Observe the message line. If you see TEST_MESSAGE <no text available>, the parser is interpreting the statement correctly; the HMI rendering layer is the issue. Continue to Step 2.
Step 2 — Verify the slot lifetime
Run the same block with a delay between the MSG and the program end:
MSG("LIFETIME_TEST")
G04 F30
M30
If the placeholder only appears in the last 250 ms before M30 clears the slot, the cause is Section 3.1 (modal lifetime). Continue to Step 3.
Step 3 — Check for MSG written without parentheses
Open the source file in a text editor and search the file (case-insensitive) for the literal token MSG. Each match must be one of:
MSG("...") ; valid active message
MSG("") ; valid clear statement
;MSG(...) ; comment, ignored
Any line containing bare MSG followed by whitespace and a number (no parentheses) is a legacy 840D reference. Either convert it to the modern form, or add the missing text to the alarm database.
Step 4 — Rule out PLC message collision
With the program halted, monitor the PLC tags for the message channel:
| Library version | Tag to monitor | Interpretation |
|---|---|---|
| PLC 840D sl < V2.6 | DB19.DBX8.0 - DBX8.7 | Bit = 1 ⇒ a PLC operator message is pending |
| PLC 840D sl >= V2.6 | DB19.DBX9.0 - DB19.DBX9.7 | Bit = 1 ⇒ a PLC operator message is pending |
| PLC 840D sl NCU 7x0 | DB19.DBW100 onwards (array) | Non-zero word ⇒ payload index, indicates source of operator text |
Disable the PLC message source temporarily by forcing the relevant bit to 0 from the PLC programmer. Reload the part program. If the suffix disappears, the cause is Section 3.3. The fix is to either (a) move the PLC message to a different priority, or (b) clear the bit at the end of the cycle so it does not collide.
Step 5 — Inspect the HMI configuration
On the TCU / PCU hosting the HMI, open:
/user/system/configuration/slconfig.ini
Locate the section [MESSAGELINE]. Confirm:
[MESSAGELINE]
mode = 0
fallback = "<no text available>"
Anything other than mode = 0 should be reverted. Restart the HMI after the change:
ssh operator@<hmi-ip> "sudo /etc/init.d/hmi restart"
Step 6 — Inspect NCK machine data
From the SINUMERIK Operate startup area, navigate to:
Startup → Machine Data → NCK → General → Messages
Verify the values shown in the table below. Out-of-range or zeroed values will cause the HMI to fall back to the placeholder.
| Machine data | Description | Recommended value | Symptom when wrong |
|---|---|---|---|
| MD51074 $MNS_NUM_MESSAGES | Number of available operator-message slots in the NCK. | 5 (default for 840D sl) | Fallback to placeholder when 0 or 1. |
| MD51075 $MMS_NUM_MSG_CHARS | Maximum message length in characters. | 128 | Truncation; placeholder when over-run. |
| MD51199 $MNS_ACCESS_MESSAGES | Access level required to edit messages. | Manufacturer (3) for service | No effect on display, but may block fix. |
| MD13100 $MN_DIAMETER_AX_DEF | Default diameter axis (impacts axis-label rendering on the same line). | Per machine kinematics | Axis-label collisions producing fallback. |
5. Resolution
The corrective action depends on the root cause identified in Section 4. Each subsection is independent; apply the one that matches your diagnostic outcome.
5.1 Fix for modal-lifetime cause (Section 3.1)
Add an explicit MSG("") before M30 to force the slot to be cleared at the right moment, and avoid emitting MSG("") in tool-change macros that fire faster than the HMI refresh interval:
; Original (problematic)
MSG(" HELLO")
G01 X10 Y10 F500
M30
; Corrected
MSG(" HELLO")
G01 X10 Y10 F500
MSG("")
M30
5.2 Fix for legacy MSG reference cause (Section 3.2)
Convert legacy statements to the modern form. For each line that uses MSG as a number reference, replace it with the equivalent modern form or configure the alarm text:
; Legacy (840D pre-sl)
MSG 4711
; Modern equivalent
MSG("TOOL CHANGE REQUEST")
If the original number must be preserved (e.g., for alarm-log compatibility), add the missing text to the alarm database via:
Startup → Alarm Texts → Operator Messages → New
Set the alarm number to 4711, choose the language set, and enter the operator text. Save and reload the active language set.
5.3 Fix for PLC collision cause (Section 3.3)
In the PLC program, locate the FC / FB that writes to the operator message channel and either:
- Add a reset of the message bit at the end of the OB1 cycle, or
- Change the priority class of the PLC message so it does not preempt the NC message.
The recommended pattern in the Siemens PLC library is to use the block FC 10 (alarm/error messaging) with a clear-then-set sequence. The clear pulse is one OB1 cycle wide, so it does not produce the placeholder on the HMI.
5.4 Fix for HMI configuration cause (Section 3.4)
Edit slconfig.ini and set the message-line mode to 0 (concatenate), then restart the HMI. The fallback string should be left at its default value unless the operator requires a localized token.
6. CAM and Post-Processor Considerations
Programs generated by CAM systems (Mastercam, Fusion 360, CAMWorks, Siemens NX) frequently contain MSG statements in the post-processor's header, footer, and tool-change sections. A misconfigured post can introduce one of the four conditions above.
| CAM artifact | Typical cause of the suffix | Post-processor fix |
|---|---|---|
Empty MSG("") in tool-change macro |
Section 3.1 (modal lifetime) | Remove the empty clear; rely on slot overwrite |
Short G01 segments preceded by MSG
|
HMI refresh race during high block-rate sections | Reduce block rate or insert a dwell |
Comment written as MSG (no parentheses) |
Section 3.2 (legacy reference) | Prefix with ; in the post template |
Post emits both MSG and DELDTG
|
Collision with distance-to-go display | Suppress one of the two during heavy cutting |
For Siemens NX post-builders, the relevant post.tcl macro to inspect is PDEF MSG. Confirm that every emission of the MSG keyword is wrapped in parentheses, and that no MSG emission passes a numeric literal as the sole argument.
7. Verification
After applying the fix, perform the following verification on the affected machine before returning it to production.
- Reload the part program and run it in AUTO mode with the door interlock open and the spindle disabled.
- From the HMI message line, confirm that the user text is displayed without the
<no text available>suffix for the entire program duration. - Stop the program partway through. Confirm that the last
MSGtext remains visible and clean in the message line. - Run a second part. Confirm that the slot is correctly overwritten by the next
MSGcall. - Run a third part with the PLC message channel deliberately triggered (e.g., from the PLC programmer). Confirm that PLC and NC messages coexist without the placeholder.
- Run the original South-African part program in its entirety. Confirm the symptom is gone for every
MSGline.
8. Field Notes and Edge Cases
On controls running Operate V4.5 SP2 and earlier, the message line widget uses a different refresh mechanism and the symptom may not be the placeholder suffix but rather a truncated string. In that case, the fix is to upgrade to V4.7 SP3 HF4 or later and to apply the same slconfig.ini change.
On NCU 710.3 and 720.3 (early 840D sl hardware) the PLC library version must be at least V2.6 SP1 for the modern operator-message interface. Earlier libraries use a different DB layout and the monitoring addresses in Step 4 of Section 4 do not apply. Cross-check the version with PLCVLIB in the PLC project header.
If the suffix appears only on a subset of programs — for example, only on programs that were generated by a particular CAM package — the issue is almost always Section 3.2 (legacy MSG reference) introduced by the post-processor. The fix is in the post, not in the controller.
Finally, be aware that the HMI message line and the alarm bar share the same physical widget on 840D sl Operate. A high-priority operator message (priority 1) will overwrite the modal MSG text on the same line. If the suffix appears only briefly between two operator messages of different priority, this is normal and is not the condition described in this article.
9. Summary of Settings
| Item | Default / recommended | Where |
|---|---|---|
MD51074 $MNS_NUM_MESSAGES |
5 | NCK machine data |
MD51075 $MMS_NUM_MSG_CHARS |
128 | NCK machine data |
[MESSAGELINE] mode |
0 | slconfig.ini |
[MESSAGELINE] fallback |
<no text available> |
slconfig.ini |
| PLC message reset at cycle end | Required | OB1 / FC10 |
Post-processor MSG emission |
Always parenthesized | CAM post template |
Why does my Siemens 840D sl show <no text available> after every MSG() line?
The HMI message widget is appending its default placeholder because the NCK message slot is being cleared or overwritten faster than the widget can refresh. Check whether your part program contains a legacy MSG reference (no parentheses), whether a PLC operator message is colliding with the NC message, and whether the slconfig.ini [MESSAGELINE] mode is set to anything other than 0.
What is the difference between MSG(...) and ;MSG(...) on 840D sl?
MSG("text") is an active message statement that loads the string into the NCK's modal message slot. ;MSG("text") is a comment — the semicolon demotes the statement so the interpreter discards it and no text is loaded.
Which machine data controls the number of operator messages on 840D sl?
MD51074 $MNS_NUM_MESSAGES controls the number of operator message slots. The default is 5. Setting it to 0 or 1 will force the HMI to fall back to the placeholder suffix. MD51075 $MMS_NUM_MSG_CHARS controls the maximum length per message; the default is 128 characters.
How do I monitor PLC operator messages on 840D sl?
On PLC library versions below V2.6, monitor DB19.DBX8.0 through DB19.DBX8.7. On V2.6 and later, monitor DB19.DBX9.0 through DB19.DBX9.7. A set bit indicates a pending PLC operator message that may be colliding with the NC's MSG payload.
Can a CAM post-processor cause the <no text available> suffix on 840D?
Yes. A post-processor that emits the legacy MSG keyword without parentheses, or that emits an empty MSG("") inside a fast tool-change macro, will trigger the HMI fallback. The fix is in the post template: ensure every MSG emission is parenthesized and that the modal slot is not cleared mid-block.