S5 → S7 Address Converter
Convert Siemens S5 PLC addresses to S7 equivalents with detailed explanations.
Conversion Result
Enter an S5 address to see the S7 equivalent.
Why this converter?
When migrating Siemens S5 to S7, address conversion is one of the biggest sources of errors. Inputs and outputs are simple — E 0.0 stays E 0.0. But the moment data blocks come into play, the logic flips: S5 uses word addressing (DW), S7 uses byte addressing (DBW). An S5 address like DB10 DW 5 becomes DB10.DBW 10 in S7 — the value doubles. Forget even a single address and you produce silent data corruption in a running process.
This converter translates every S5 address into its S7 equivalent — with an explanation of why the value changes, what warnings to watch for, and what the matching SCL access looks like. Supported are inputs (E/I), outputs (A/Q), memory (M/MB/MW/MD), data blocks (DB/DW/DL/DR/data bits), timers (T), counters (Z/C), and peripheral I/O (PE/PA, PI/PQ). Both German and international (English) mnemonics.
The DW × 2 rule — explained
This is the single most important rule in S5→S7 address conversion. Forget it and you produce errors that only surface during commissioning — or, in the worst case, in production.
In S5, each data word (DW) is addressed as a 16-bit unit: DW 0, DW 1, DW 2, DW 3. There are 16 bits (2 bytes) between DW 0 and DW 1. Physically, DW 0 occupies bytes 0–1, DW 1 occupies bytes 2–3, DW 2 occupies bytes 4–5 — and so on. S7 accesses the same bytes, but the address is the byte address itself. That's why you must always multiply the S5 word address by 2 to get the S7 byte address.
| S5 Address | S7 Address | Calculation |
|---|---|---|
| DB10 DW 0 | DB10.DBW 0 | 0 × 2 = 0 |
| DB10 DW 1 | DB10.DBW 2 | 1 × 2 = 2 |
| DB10 DW 5 | DB10.DBW 10 | 5 × 2 = 10 |
| DB10 DW 50 | DB10.DBW 100 | 50 × 2 = 100 |
| DB10 DW 100 | DB10.DBW 200 | 100 × 2 = 200 |
For individual data bits, an additional rule applies: bits 0–7 sit in the low byte (odd byte address = word × 2 + 1), bits 8–15 sit in the high byte (even byte address = word × 2). Example: S5 D 3.7 becomes S7 DBX 7.7 (low byte), S5 D 3.15 becomes DBX 6.7 (high byte, bit 15 − 8 = 7).
German vs. international mnemonics
Siemens PLCs support two instruction sets that differ in their address prefixes. German mnemonics are the standard in S5; S7 accepts both. When migrating, you must decide which one to use — and stay consistent within a single project.
| Category | DE | EN | Note |
|---|---|---|---|
| Input | E | I | Bit and word addresses identical in both notations |
| Output | A | Q | A was the default notation in S5 |
| Memory (Merker) | M | M | Identical in both languages |
| Timer | T | T | Identical, but IEC timers recommended |
| Counter | Z | C | Different prefix |
| Peripheral Input | PE | PI | Peripheral Input |
| Peripheral Output | PA | PQ | Peripheral Output |
| Data Block | DB | DB | Identical, but DW → DBW conversion required |
Real-world conversion examples
Typical addresses from real S5 programs and their S7 equivalents, in order from simple to complex:
1. Simple I/O assignment
U E 0.0 = A 4.0
A "Start_Button" // E 0.0 / I 0.0 = "Motor_ON" // A 4.0 / Q 4.0
I/O addresses stay numerically identical. With English mnemonics: I 0.0 / Q 4.0.
2. Copy a memory word
L MW 100 T MW 200
L MW 100 // unchanged T MW 200
Memory (M) addresses are numerically identical between S5 and S7. No conversion needed.
3. Read a data word — the classic trap
A DB 10 L DW 5
L "Recipe".DBW 10 // was DW 5 → × 2 = 10
S5 address DW 5 becomes DBW 10 in S7. This is where most migration errors happen.
4. Set an individual data bit
A DB 20 S D 3.7
S "Status".DBX 6.7 // DW 3 bit 7 → byte 6 (low), bit 7
Bits 0–7 sit in the low byte (odd byte = word×2+1). Bit 7 stays bit 7.
5. High-byte bit (bit 8–15)
A DB 20 U D 3.15
A "Status".DBX 7.7 // DW 3 bit 15 → byte 7 (high), bit 7
Bits 8–15 sit in the high byte. The S7 bit number is bit minus 8: here 15 − 8 = 7.
6. Timer in S7 SCL
U E 1.0 L KT 030.2 SD T 1
"Timer_Delay"(
IN := "StartCondition",
PT := T#30s
);Timer number stays the same, but the S5 timer instructions (SI/SE/SD/SS/SA) are replaced by IEC blocks (TP/TON/TOF). See the timer calculator for details.
Common mistakes in address migration
Five mistakes that show up over and over in S5→S7 migrations — and how to avoid them:
Mistake 1: DW addresses not doubled
The classic. DW 5 in S7 is NOT DBW 5, it's DBW 10. Forget this and S7 reads data from a completely different memory area — without any compiler warning. The plant appears to start up normally, but setpoints no longer match actual values.
Mistake 2: Byte addresses (DL/DR) mapped incorrectly
DL (data word left) is the high byte, DR (right) is the low byte. In S7 byte addressing: DL → even byte address (word × 2), DR → odd byte address (word × 2 + 1). Swap left and right and you write payload data to the wrong location.
Fix: Mnemonic: DL (left) = even byte address, DR (right) = odd byte address.
Mistake 3: Timer numbers match, but timer behavior doesn't
T 1 in S5 and T 1 in S7 share the same number, but on TIA Portal / S7-1500 the classic S5 timer instructions (SI/SE/SD/SS/SA) are no longer supported. Convert just the address and ignore the timer type, and you produce code that won't run.
Fix: Always migrate the timer type to IEC timers (TP/TON/TOF) along with the address.
Mistake 4: Forgetting BCD-vs-INT counter conversion
S5 counters store values BCD-encoded. S7 counters (including the legacy variant) use INT. During migration, counter values cached in data blocks must be reformatted — otherwise HMI/SCADA systems will display wrong values.
Fix: Use IEC counters (CTU/CTD/CTUD) — they work natively with INT.
Mistake 5: Overlooking memory-byte suffixes
S5 had the syntax FY (flag byte), FW (flag word), FD (flag double word). In S7 these become MB, MW, MD. A find-and-replace migration that ignores these suffixes will miss byte accesses entirely.
Fix: Always also search for FY/FW/FD in the source code and migrate them to MB/MW/MD.
Related tools and references
S5 Timer Calculator
Convert KT timer values to seconds and IEC format
AWL Command Lookup
All 40 S5 STL/AWL instructions with S7 equivalents
S5 STL Code Converter
Translate complete STL/AWL code lines to S7 STL and SCL automatically
S5 → S7 Address Mapping (Reference)
Complete address mapping tables for I/O, memory, DB, and peripheral
S5 Command Reference
Full technical reference for every S5 STL/AWL instruction
S5 to S7 Migration: Complete Guide
Step-by-step guide for the full S5 → S7 migration
Quick Reference
| S5 | S7 (DE) | S7 (EN) | Notes |
|---|---|---|---|
| E 0.0 | E 0.0 | I 0.0 | Identical |
| EW 0 | EW 0 | IW 0 | Identical |
| A 4.0 | A 4.0 | Q 4.0 | Identical |
| M 10.0 | M 10.0 | M 10.0 | Identical |
| F 0.0 | M 0.0 | M 0.0 | F → M |
| FY 10 | MB 10 | MB 10 | FY (byte) → MB |
| T 1 | T 1 | T 1 | Use IEC timers! |
| Z 3 | Z 3 | C 3 | Z → C (EN) |
| DB10 DW5 | DB10.DBW 10 | DB10.DBW 10 | DW × 2 = DBW |
| DB10 DL5 | DB10.DBB 10 | DB10.DBB 10 | High byte (×2) |
| DB10 DR5 | DB10.DBB 11 | DB10.DBB 11 | Low byte (×2+1) |
| DB10 D5.3 | DB10.DBX 11.3 | DB10.DBX 11.3 | Bit 0–7 → low byte |
| DB10 D5.8 | DB10.DBX 10.0 | DB10.DBX 10.0 | Bit 8–15 → high byte |
| PEW 128 | PEW 128 | PIW 128 | Identical |
Frequently Asked Questions
How do I convert S5 DB addresses to S7?
What is the difference between DW and DBW addressing?
How do S5 timers differ from S7 timers?
What happened to the F (Flag) addresses from S5?
Do I need to change I/O addresses when migrating S5 to S7?
Why does DW 5 become DBW 10 instead of DBW 5?
How do I convert individual data bits from S5 to S7?
What is the difference between DL and DR?
Do I need to convert timer and counter addresses?
What about indirect addressing like DO FW or LIR?
Is there a difference between E and I in the mnemonics?
Need to migrate an entire S5 program?
PLCcheck Pro converts complete S5 programs to S7 — all addresses, timers, counters, DB structures, and function blocks — with full documentation and I/O mapping.
Try PLCcheck Pro →Not affiliated with Siemens AG. S5, S7, STEP 5, STEP 7, and TIA Portal are trademarks of Siemens AG.