---
title: "S7-1500 diagnostic buffer"
---

# S7-1500 diagnostic buffer

Read the diagnostic buffer of an S7-1500 over its web API, read only, refresh it and export it as CSV or JSON.

**State:** kit shipped. The module's own HTTPS JSON-RPC client, the pinned certificate, the login with re-login and the view are tested on Linux over real HTTPS against a model of the CPU's web server. Every method, field and error code is taken from the source of Siemens' MIT-licensed web API client. Nothing has run against a real S7-1500.

## Read the buffer

1. Add and connect an S7-1500 target (see [Connect to controllers](https://neuralinverse.com/docs/modules/plc/targets/)).
2. Open the **S7-1500 Diagnostics** view (PLC container). It reads the diagnostic buffer when it is shown on a new connection. **Refresh S7-1500 Diagnostic Buffer** (title button or Command Palette) reads it again.

When the buffer holds more entries than the first answer returned, the Editor asks again for all of them. Each row shows:

- the timestamp (UTC with nanoseconds, as returned);
- incoming or outgoing;
- the event id (`16#<text list>:<text>`);
- the short text, with the long and help texts on hover.

The line above the rows names the target, the counts, the buffer's last change, the time of reading and that it was read through the web API, read only. Diagnostic texts come in the language set on the target.

## Export

**Export S7-1500 Diagnostic Buffer** (title button or Command Palette) writes:

- CSV: one line per entry, with a header;
- JSON: the entries under the web API's own field names, with the target, the time of reading and the method.

## What is sent

Reading the buffer sends only `DiagnosticBuffer.Browse`, after `Api.Login`. Nothing writes to the CPU. Every read, export and failure is in the **PLC** log, never the password or the token.

## Not verified

- Any S7-1500; which firmware versions offer the methods; the default number of entries without a count; the languages a CPU returns for a culture its project does not hold.
