Explainer
Sending Report System Error Alarms to an OPC Data Logger
Short answer
Displaying Report System Error hardware diagnostics on the panel and exporting them to a third-party OPC logger are two separate paths. The logger reads the CPU over OPC, not the panel's alarm display, so the PLC program must call SFC51, store the returned diagnostic records in a dedicated data block, and expose that block through the CPU's OPC connection. Panel-based OPC servers are documented for Multi Panel devices, not compact operator panels.

On this page
- Do I need to do anything at the HMI end after RSE is configured?
- Can a third-party data logger read the panel's alarms over OPC?
- Can the operator panel itself act as the OPC server?
- How does the diagnostic data reach the logger?
- Which system status list does SFC51 read, and what does a record look like?
- What should the diagnostic data block contain?
- Does the OPC export reproduce exactly what the panel displays?
- How do I verify the complete alarm route before commissioning?
- Which architecture should your project use?
- Questions asked
You can display Report System Error hardware diagnostics from a CPU 317-2 PN/DP on an OP77B configured with WinCC flexible 2007, but that panel alarm display cannot be sent to a third-party OPC data logger as-is. The logger talks to the CPU over OPC, not to the panel, so the export is a PLC programming task: call SFC51 (RDSYSST), write the returned system status records into a dedicated data block, and expose that block through the CPU's OPC connection. Panel-based OPC servers are documented for Multi Panel devices, not compact operator panels. This article separates the display path from the logging path, gives the SFC51 method with a block sizing example, states what the export does and does not reproduce, and ends with the decision for each case.
Do I need to do anything at the HMI end after RSE is configured? #
Yes: finish the alarm display on the OP77B in WinCC flexible 2007 and prove it with a real fault, because arming RSE in the hardware configuration of the CPU 317-2 PN/DP alone does not demonstrate that the panel shows anything.
Report System Error is armed in the PLC hardware configuration, which ties the diagnostic reporting to the CPU. The panel side needs an alarm view configured in the WinCC flexible project, compiled and downloaded to the OP77B, before the diagnostics have somewhere to appear. A project pairing RSE with this panel and tool combination displayed process alarms, system alarms and hardware diagnostics once both ends were configured; the individual WinCC flexible settings are project-specific, so configure the alarm view and check it on the panel rather than assuming the PLC-side work carries over.
When RSE alarms never reach the display, the causes are specific and testable: the Comfort Panel case is collected in why Report System Error alarms are missing on Comfort Panels. A worked display configuration built on the same RSE and SFC51 records is documented in displaying S7-400 system errors in WinCC using RSE and SFC51.
Can a third-party data logger read the panel's alarms over OPC? #
No: the logger exchanges data with the CPU over its own OPC connection, while the alarms you see on the OP77B live in the panel's HMI runtime, so no OPC item on that connection carries the alarm display.
The two requirements, display at the panel and export to the logger, are met by two independent paths. The display path runs from the CPU's hardware configuration through RSE to the panel's alarm runtime. The logging path must run entirely through memory the OPC server can address, which on this architecture means PLC memory: a data block on the CPU. Nothing on the panel, not its alarm buffer and not its display, is an item on the logger's connection.
Can the operator panel itself act as the OPC server? #
Panel-based OPC server operation is documented for Multi Panel devices, not for compact operator panels such as the OP77B, so this architecture cannot be assumed for the project as configured and would need product documentation for the exact device before you designed on it.
Even where a panel OPC server exists, it serves the panel's own data over a second connection, while the logger already holds a working connection to the CPU. The PLC-side route adds no network node, no second server and no dependency on panel runtime: if the panel is switched off or is being re-projected, the logger keeps recording. That is why the decision table at the end of this article sends the logging path to the CPU.
How does the diagnostic data reach the logger? #
The PLC program reads the diagnostics itself: call SFC51 (RDSYSST) to read a partial system status list, write the returned records into a dedicated data block, expose the selected block fields on the CPU's existing OPC connection, and point the logger at those OPC items.
- List what the logger must record from the hardware diagnostics, for example station fault and module fault events.
- Call SFC51 (RDSYSST) in the PLC program, on a fixed cycle or from your diagnostic routine, with the list identifier and index documented for the diagnostic list you need.
- Copy the returned header and records into a dedicated data block whose layout you fixed first.
- Expose the selected data-block fields through the OPC connection the logger already uses; reading raw PLC data over OPC as diagnostics is an established pattern, shown from the client side in reading raw PLC tags as diagnostics in WinCC over OPC.
- Configure the logger's OPC items on those fields and map them with the documented block layout; if the client then fails to connect, the fault sits on the server and connection side, and why an OPC DA client fails on a third-party OPC server collects the common causes.
Which system status list does SFC51 read, and what does a record look like? #
SFC51 (RDSYSST) reads the partial system status list you select with the list identifier and index documented for that list, and each call returns a header followed by the data records, so the layout comes from the instruction documentation rather than guesswork.
RDSYSST is the read instruction behind SFC51: it reads a partial list of the system status lists or an extract of one partial list, and the manufacturer's support portal documents it for STEP 7 Professional V13.1 under entry 109011420. You supply the list identifier and the index and hand the instruction a buffer. The returned buffer begins with a header that gives the record length and the number of records returned, and your program copies the header and the records that follow into the data block.
List identifiers differ between CPU families, so use the ones tabulated for the S7-300 family the CPU 317-2 PN/DP belongs to, and take the context help in the engineering software (F1 on the instruction) as the interface reference for your version. Verify the first read on the bench by comparing the header's record count against what the CPU's online diagnostic display shows for the same event. The S7-300 walkthrough of SFC51, RSE and the error OBs that carry the hardware events is in S7-300 hardware diagnostics with SFC51, RSE and error OBs.
What should the diagnostic data block contain? #
Decide the fields from what the logger must show, and define them before writing any offsets: an update counter the logger can watch, the returned header fields, and a fixed-size record area sized for the maximum record count documented for that list.
Keep the block dedicated, so nothing else in the program writes to it. The update counter increments each time the program stores a fresh set of records; an unchanged counter means no new events, and an incremented counter tells the logger the records beside it are current. Document the byte layout beside the block declaration and name every field for what it carries, because the OPC item mapping and the logger's import template both follow that document.
Worked sizing example: if the documentation table for your selected list states a maximum of 20 records and a record length of 10 bytes, the record area is 20 × 10 = 200 bytes, plus the space the returned header needs and one word for the update counter. Take both numbers from your list's own table, because another CPU or another list changes them.
Does the OPC export reproduce exactly what the panel displays? #
No: the SFC51-to-data-block route exports the diagnostic records the CPU returns, and it does not reproduce the panel's alarm texts, incoming event timestamps or acknowledgement handling, nor does it collect process alarms and system alarms into the same block automatically.
The records carry event codes and module references, while the alarm texts the OP77B shows are configured in the HMI project: either configure matching texts in the logger or ship the text table with it. The logger time-stamps a record when its OPC item changes, because the panel's incoming times belong to the panel runtime. Acknowledging an alarm is a panel runtime action that leaves no trace in the data block, so if the logger must record acknowledged state, your program has to mirror an acknowledge bit into the block deliberately. Process alarms and system alarms reach the panel through their own alarm mechanisms, and for this configuration there is no method that places them into the SFC51 data block automatically, so program that copy explicitly and test it as its own path.
How do I verify the complete alarm route before commissioning? #
Create one known hardware diagnostic on a bench or during a planned stop and follow it through every hop: panel display, data-block change, OPC item change, logger record, in that time order.
- Pick a fault you can create and clear on demand, for example dropping the connection to one network station or removing power from one remote I/O module, and inject it on a bench setup or during a planned stop, never by interrupting a running process.
- Confirm the diagnostic appears on the OP77B alarm display.
- Confirm the data block: the update counter incremented and the record area changed.
- Confirm the OPC items changed and the logger wrote a row that matches the documented layout.
- Restore the faulted device and confirm the display and the log both capture the return to normal.
- Trigger a process alarm from the program and confirm it on the panel, and note that it will not appear in the data block, which is why the copy for process and system alarms is programmed and tested separately.
Which architecture should your project use? #
Use the RSE-plus-panel-alarm-view architecture when the operator only needs to see the diagnostics, and add the SFC51-to-data-block route when a third-party logger must record them, keeping the two feeds independent so a panel fault cannot take the logging path down.
| Case in this project | Decision |
|---|---|
| Operator only needs to see the hardware diagnostics | RSE in the hardware configuration plus the configured OP77B alarm view, proven with a real fault |
| Logger must record the hardware diagnostics | SFC51 (RDSYSST) into a dedicated data block, selected fields exposed on the CPU's OPC connection |
| Logger must also record process and system alarms | Program an explicit copy of their states into PLC memory and test it separately; no automatic route exists |
| Logging taken from the panel rather than the CPU | Not supported for this panel class; panel-based OPC servers are documented for Multi Panel devices, so design on the CPU route |
| Diagnostics from PROFINET devices as well | Configure RSE for PROFINET diagnostics as its own scope, then reuse the same SFC51-to-data-block route |
Run the two paths independently: the panel can be switched off, replaced or re-projected without touching the logging route, and the logger can be offline without the operator losing the display.
Questions asked
Can the logger read the CPU diagnostic buffer directly over OPC?
No. An OPC server publishes only the data it is configured to serve, and the CPU's diagnostic buffer is not on that list. SFC51 is the documented instruction that copies system status information into PLC memory, and the data block your program fills that way becomes the OPC-readable copy. Without that copy step the logger has nothing to subscribe to, however healthy its connection is.
How large should the record area in the data block be?
Size it from the documentation table for the list you selected: that table gives the list identifier together with the maximum number of records and the record length. Reserve room for the returned header plus that count times the record length, and let the header's record-count field tell the program how many records the current call actually returned.
Does it matter whether the third-party logger uses OPC DA or OPC UA?
The block method does not change, because both clients read the same exposed data-block items. The protocol decides the connection work: OPC DA adds server and DCOM configuration on the computer that hosts the server, while OPC UA adds endpoint and security settings. Put that connection work on the bench checklist before the diagnostic items are trusted.
What happens to the logged data when the CPU restarts?
Plan for a reset. The update counter in the data block clears when the CPU restarts unless you make the block retentive, so configure the logger to treat a counter reset as a session boundary rather than as lost data. After any restart, generate a fresh known fault and walk the whole chain again before trusting the log.
Is hardware diagnostics over PROFINET covered by the same configuration?
Not automatically. Diagnostics reported by PROFINET devices have their own RSE scope in the hardware configuration, and that configuration is a separate task from the display and logging routes described here. Once the events are present in the CPU's system status lists, the same SFC51-to-data-block route exposes them to the logger without further change.


