Sinumerik 840D Action Log: Configure, Locate, and View .com Files

David Krause14 min read
HMI / SCADASiemensTroubleshooting
Licensed PE Working through this on a live machine? A Maine-licensed engineer can take it from here — included with IMD hardware, by the hour for everything else. Book an engineer

Sinumerik 840D PCU 50 Action Log: Configuration, File Location, and Viewing

The Sinumerik 840D action log is the persistent, append-only audit trail recorded by the HMI (Human-Machine Interface) on the PCU (PC Unit). Unlike the alarm log buffer, the action log captures operator interventions, parameter changes, offset edits, program selections, tool commands, PLC alarms, NC alarms, and password status transitions. On a PCU 50 system, the log is written to the local hard drive as a binary stream with a .com file extension. Engineers frequently encounter two problems: the file size grows as expected, but the content appears unreadable in a standard text editor, and the configuration switches seem to have no effect. This reference consolidates the machine data, HMI menu path, file storage rules, and viewing procedure required to make the action log usable for diagnostics and FAT/SAT evidence.

Scope: Sinumerik 840D (classic) and 840D sl with PCU 50. NCU families NCU 561.x, NCU 571.x, NCU 710.x, NCU 720.x, and NCU 730.x with HMI-Advanced or HMI-Embedded are in scope. PCU 20 systems use a different storage path and are treated only as a contrast case.

1. Action Log vs. Alarm Log: Functional Split

Sinumerik distinguishes between the alarm log and the action log, and confusing the two is the most common reason operators believe the action log is empty.

Attribute Alarm Log Action Log
Triggered by NC/PLC alarm raise/clear events Operator actions, parameter edits, mode changes, password events
Stored in Alarm buffer in NCK + mirrored to alarmlog in F:\AC_LOG actionlog.com in F:\AC_LOG
Typical extension .com (binary, rename to .txt) .com (binary, rename to .txt)
Filtered by MD 9012 (alarm log display filter) MD 9012 bit field (action log enable)
User access Diagnostics > Alarm Log on HMI Startup > HMI > System Settings > Action Log
Persistence Power-fail-safe; backed by SRAM or CF card Power-fail-safe; backed by hard drive image

The action log is the only record that captures who changed what and when, including password-protected parameter writes. For machine builders and end users subject to FDA 21 CFR Part 11, ISO 13485, or IATF 16949 audit trails, the action log is the canonical source.

2. Prerequisites

Before enabling the action log, verify the following hardware and software conditions.

Item Requirement Verification
PCU type PCU 50.3 / PCU 50.5 (Intel architecture) Read from Startup > HMI > Version on HMI
NCU type NCU 561.4, 571.4, 710.3, 720.3, 730.3 or later Label on NCU housing or MD 13000 read
Software version HMI-Advanced >= 07.05, or HMI-Embedded >= 04.05 Read version.me on C:\Program Files\Siemens\MotionControl
Access level Manufacturer or Service password for MD writes Active password shown in Startup > Password
Storage media HDD with at least 200 MB free on partition F: Service menu > System > Storage
File viewer WordPad, Notepad++, or any editor supporting LF line endings External PC; do not edit in place on the PCU
NCU/PCU mismatch warning: If the HMI version is older than 04.05 SP2, the action log may exist as action.log (no .com suffix) and live on C:\AC_LOG instead of F:\AC_LOG. Confirm the path before assuming missing data.

For the underlying HMI architecture and the role of the PCU within the operator panel, refer to the Sinumerik 840D sl Operator Components and HMI Manual.

3. Enabling the Action Log with MD 9012

Display machine data MD 9012 is a bit-coded configuration word. It is loaded from the active CF card image and read at HMI boot. The action log categories are mapped to individual bits; setting the appropriate bits tells the HMI which event classes to record.

3.1 Bit Assignment of MD 9012

Bit Value (hex) Event Class Recorded
0 0x0001 Operator panel key presses (channel-select, mode change, override)
1 0x0002 PLC alarm raise/clear events
2 0x0004 NC alarm raise/clear events
3 0x0008 Parameter adjustment (R/W to MD, setting data, GUD)
4 0x0010 Offset adjustment (tool offset, work offset, frames)
5 0x0020 Program selection (NC program load, select, cancel)
6 0x0040 Tool command (T-selection, M06, magazine operations)
7 0x0080 Password status (login, logout, level change)
8-15 0xFF00 Reserved / manufacturer-specific extensions

To enable all seven of the standard categories required for a complete audit trail (PLC alarm, NC alarm, parameter, offset, program, tool, password), the effective MD 9012 value is the OR of bits 1-7:

MD 9012 = 0x01 + 0x02 + 0x04 + 0x08 + 0x10 + 0x20 + 0x40 + 0x80 = 0x00FF (decimal 255)

3.2 Writing MD 9012

  1. On the HMI, navigate to Startup > Machine Data > Display MD.
  2. Filter by group 9xxx and locate row 9012.
  3. Enter FF (hexadecimal entry is accepted when the input field is set to HEX; otherwise enter decimal 255).
  4. Press Input or the Enter key to commit.
  5. If a confirmation dialog appears, choose OK and acknowledge that the new value is non-volatile.

For the formal description of the display machine data concept and access control, see the Sinumerik 840D sl Base Software and HMI-Embedded Programming Manual.

Do not confuse MD 9012 with MD 13100 $MN_USER_DATA_INT or with the alarm log filter MD 9000. MD 9000 controls the alarm log retention length (default 8192 entries) and is unrelated to the action log enable mask.

4. Selecting Event Classes in HMI System Settings

MD 9012 is the global enable mask. The HMI System Settings dialog is the per-channel, per-event-class refinement layer. Both must be configured or the action log will remain empty.

  1. On the HMI, press the Startup horizontal soft key.
  2. Select HMI from the vertical soft-key bar.
  3. Open System Settings.
  4. Select the Action Log tab.
  5. Tick each event class that should be recorded. The dialog presents check boxes that map one-to-one to the bits in MD 9012.
  6. Press OK to apply.

If the HMI prompts for a password at this point, the current access level is below Service. Repeat the procedure after logging in with the appropriate Service or Manufacturer password.

5. Action Log File Storage on PCU 50

5.1 Default File Layout

Drive Path File Purpose
F: \AC_LOG\ alarmlog.com Persistent alarm log mirror
F: \AC_LOG\ actionlog.com Persistent action log
F: \AC_LOG\ actionlog.bak Rotated previous segment (when current exceeds ring size)
F: \MMC2\ action.com Legacy PCU 20/50.3 fallback on older HMI versions

The ring buffer size is fixed at the factory (typically 4 MB on PCU 50.5). When the file reaches the cap, the HMI renames the active file to .bak and starts a fresh .com. Operators who see a static file size for hours should check whether the .bak file exists; the buffer may have silently rotated.

5.2 File Format

The .com files are not strictly binary. They are plain ASCII or UTF-8 records with a fixed 64-byte header followed by newline-terminated entries. The .com extension is historical (COM = commissioning) and is preserved to prevent Windows from executing the file. The file can be opened in any text editor after renaming.

6. Viewing the Action Log Without Renaming

There are three reliable methods to read the log on the PCU itself or on an external PC.

6.1 Method A: Rename and Open in WordPad

  1. Connect a USB keyboard and mouse to the PCU 50 front panel, or use Windows CE Remote Desktop if available.
  2. Open My Computer > F: > AC_LOG.
  3. Right-click actionlog.com and choose Rename.
  4. Change the extension to .txt. Confirm the rename warning.
  5. Double-click the file. The default Windows association may open Notepad; if entry lines are not wrapped correctly, close and open with WordPad (Start > Programs > Accessories > WordPad).

WordPad is preferred over Notepad for files larger than 64 KB because Notepad has a known buffer bug that silently truncates LF-only files. Notepad++ is the most robust choice on an external PC.

6.2 Method B: Use the HMI Built-in Viewer

For live monitoring without leaving the operator panel:

  1. Navigate to Diagnostics > Logs > Action Log.
  2. The viewer shows the most recent 1000 entries with timestamps and the user account responsible.
  3. Use the Save soft key to export the visible range to F:\TEMP\action_export.txt.

6.3 Method C: Network Transfer to Engineering PC

  1. On the engineering PC, open Windows Explorer and enter \\<PCU50_IP>\AC_LOG$ in the address bar.
  2. Authenticate with the Service Windows account.
  3. Copy actionlog.com to a local folder.
  4. Rename locally to actionlog.txt and open in Notepad++ or Excel (use the Import > From Text wizard with the pipe character as delimiter if the entries are pipe-separated).
Do not edit the file on the PCU while the HMI is running. WordPad locks the file with a read-only share mode, but other editors can corrupt the buffer. Always copy first, then view.

7. Decoding the Log Content

Each record in the action log is structured as a single line. A typical entry for a parameter change on a Sinumerik 840D with HMI-Advanced 07.06 looks like the example below (values redacted):

2024-03-14 09:21:07 | USER=Service  | ACT=PAR_WRITE | CH=1 | MD=20150[0] | OLD=2 | NEW=3 | RESULT=OK

Field meanings:

Field Description
Timestamp Local HMI time, ISO 8601
USER Active access level (Operator, Setup, Service, Manufacturer)
ACT Action class: PAR_WRITE, OFFS_WRITE, PROG_SEL, TOOL_CMD, PWD_LOGIN, PWD_LOGOUT, ALARM_RAISE, ALARM_CLEAR
CH Channel number (1-6 on 840D)
MD Machine data number and optional array index
OLD / NEW Value before and after the change
RESULT OK, REJECT (insufficient access), ABORT (NC not ready)

For PLC alarms the ACT field becomes ALARM_RAISE and the MD field is replaced by the alarm number, e.g. ALARM=700001. For password events, ACT=PWD_LOGIN and the USER field shows the level that was unlocked.

8. Troubleshooting Matrix

Use this matrix to triage the most common field complaints about the action log on a PCU 50 system.

Symptom Likely Root Cause Corrective Action
File does not exist on F:\AC_LOG HMI version < 04.05 or wrong partition Search C:\AC_LOG and D:\MMC2; upgrade HMI to current SP
File exists but size never grows No event class selected in HMI System Settings Re-check check boxes; verify with a deliberate parameter write
File grows but content is unreadable Editor is not handling LF line endings Use WordPad or Notepad++ with "Show All Characters" enabled
Cannot rename to .txt on the PCU File is locked by HMI process Stop the HMI service from Service Center > HMI > Stop, then rename
Only PLC alarm events are missing MD 9012 bit 1 not set, or PLC alarm handler not configured Set MD 9012 = 0xFF and verify DB10.DBB0 is wired to the alarm interface
Only password events are missing Password log is controlled by a separate mask, MD 9013 on 840D sl Set MD 9013 = 0x01 in addition to MD 9012
File size grew then froze Ring buffer rotated; .bak file is the new active Inspect actionlog.bak; consider extending the ring size in service mode
Network share returns "Access Denied" Windows CE local account policy blocks UNC writes Map the share on a service laptop instead, or use the built-in FTP server (port 21)

9. Backup, Archival, and Long-Term Storage

The action log on a single PCU 50 typically holds 30-90 days of data before ring rotation. For audit purposes, configure a scheduled transfer to the network.

  1. Create a Windows scheduled task on a domain controller that runs daily at 02:00.
  2. Use robocopy \\PCU50\AC_LOG$\actionlog.com \\ARCHIVE\SINUMERIK\%COMPUTERNAME%\actionlog_%date%.com with the /COPY:DAT switch.
  3. After successful copy, append a SHA-256 hash to a sidecar file (actionlog_YYYYMMDD.com.sha256) for tamper evidence.
  4. Retain archives for the regulatory minimum (typically 7 years for medical devices, 15 years for energy).

For plants subject to FDA 21 CFR Part 11, the action log archive must be on a WORM (write once, read many) storage tier and must be cryptographically signed at archive time. The hash sidecar satisfies the integrity requirement; the WORM tier satisfies the immutability requirement.

10. Safety and Data Integrity Considerations

Do not delete actionlog.com during machine operation. The HMI holds an open file handle. Deleting the file from Windows Explorer removes the directory entry but leaves the handle active, which leads to phantom growth on next reboot and a corrupted ring index.
  • Never edit the action log on the PCU; an editor that adds a CR character invalidates the entry CRC.
  • Never copy the log via an FTP client configured for ASCII mode; always use binary transfer, then rename locally.
  • Never clock the HMI backward. The action log is time-ordered; a backward clock step creates out-of-order entries that auditors will treat as evidence tampering.
  • When replacing a CF card, image the old card with dd or a Windows sector tool before formatting; the log persists on the card, not in the NCK SRAM.

11. Verification Checklist

After completing the configuration, run the following verification steps in order. Each must pass before the action log is considered commissioned.

  1. On the HMI, confirm MD 9012 reads back FF (or the chosen bit mask) after an HMI restart.
  2. Trigger a deliberate PLC alarm from the PLC program (e.g. set DB10.DBX0.0 = TRUE with a configured alarm number). The alarm log on the HMI must display the alarm.
  3. Open the HMI System Settings and confirm every required event class is ticked.
  4. On the HMI, change any setting data, e.g. zero offset G54, by 0.001 mm.
  5. On the HMI, log in with a Service password, perform an action, then log out.
  6. Reboot the HMI. Verify that F:\AC_LOG\actionlog.com exists and is non-zero in size.
  7. Stop the HMI service, copy the file to a USB stick, rename to .txt, and open in WordPad. Confirm the five test events from steps 2-5 are present in chronological order.
  8. Re-start the HMI service. Confirm a new entry ("HMI started") is appended.

If step 7 returns a file that opens but is empty, the HMI is writing to a different path. Repeat step 6 with a directory search across all visible drives (C:, D:, F:, G:).

12. Field-Proven Caveats

Several behaviors observed in production cells are worth recording for future troubleshooting.

  • NCU 710.x with HMI-Embedded: The action log is stored in a SQLite database on /var/log/sinumerik/actionlog.db, not as a .com file. The MD 9012 enable still applies, but the viewing method is via the embedded diagnostics web UI on port 8443.
  • PCU 50.3 vs. PCU 50.5: The 50.3 uses a 2 GB CF card; the 50.5 uses a 4 GB or larger SSD. Ring buffer size scales with available free space, so log retention on a 50.5 is roughly 2x that of a 50.3 with identical configuration.
  • Language switching: If the HMI language is changed after the log is written, older entries continue to display in the original language. New entries use the new language. This is by design and is the correct behavior for audit.
  • Power loss during write: A power loss within the same AC cycle as a log write can truncate the most recent entry. The HMI detects the truncated tail on next boot and pads with a marker --- TRUNCATED ---. This is a known limitation, not a defect.

For the formal description of the HMI-Advanced action log subsystem and its API, consult the Sinumerik 840D sl HMI-Advanced Programming Manual and the related KB article How do you display the action log on Sinumerik 840D sl?

Why is the action log file growing but I cannot open it in Notepad?

The file has a .com extension and uses LF line endings, which Notepad handles poorly above 64 KB. Rename the file to .txt and open it in WordPad or Notepad++ instead. Always copy the file to an external PC first; do not edit it in place on the PCU 50.

What value should I write to MD 9012 to record all action log categories?

Set MD 9012 to FF (hex) or 255 (decimal) to enable bits 0-7, which covers PLC alarms, NC alarms, parameter adjustments, offset adjustments, program selection, tool commands, and password status. The change is non-volatile but requires an HMI restart to take effect.

Where is the action log file located on a PCU 50?

The default path on PCU 50.3 and 50.5 is F:\AC_LOG\actionlog.com. On older HMI versions (below 04.05) the path may be C:\AC_LOG or D:\MMC2. On NCU 710.x with HMI-Embedded, the log is stored in a SQLite database instead of a flat file.

Can the action log be deleted or cleared by the operator?

No. The file is a ring buffer owned by the HMI service and is not exposed in the operator menu. Deleting it from Windows Explorer will leave a phantom handle open and corrupt the ring index on the next boot. To archive, copy the file; never delete it during operation.

How do I distinguish a PLC alarm entry from an NC alarm entry in the log?

PLC alarm entries show ACT=ALARM_RAISE with an alarm number in the 400000-499999 range and a SOURCE=PLC tag. NC alarm entries show ACT=ALARM_RAISE with numbers in the 1000-299999 range and a SOURCE=NCK tag. Both are visible in the same log file and are filtered by bits 1 and 2 of MD 9012 respectively.

Back to blog