S7 Hardware Configuration in TIA Portal: Complete Setup Guide
Configuring the hardware of a SIMATIC S7 controller in TIA Portal is more than just dropping a CPU and a few signal modules into a project. Every backplane-bound module — the CPU, the interface modules, the signal modules, the function modules, and the communication processors — must be represented in the device view with the exact order number (MLFB) that is installed in the cabinet. The power supply, mounting rail, and front connectors, while often physically decoupled from the backplane, still need to be selected so the bill of materials, the cabinet layout, and the spare-parts list stay consistent with what is actually wired on site.
This reference walks through the complete configuration flow: opening the device view, populating the rack with the correct PS, CPU, IM, SM, FM, and CP modules, integrating mechanical components (rails, front connectors, U-connectors), validating the configuration against the hardware catalog, and resolving the most common inconsistencies that appear at compile time.
1. S7 System Families and Their Hardware Variants
Before configuring, identify which S7 family the target installation uses. Each family has its own module series, firmware behavior, and rack rules. Mixing modules across families is not supported.
| Family | Typical CPU range | Rack concept | PS series |
|---|---|---|---|
| S7-300 | CPU 312, 314, 315-2 PN/DP, 317, 319-3 PN/DP | Mounting rail with up to 8 slots per segment; multi-rack via IM 360/361/365 | PS 305, PS 307 |
| S7-400 | CPU 412, 414, 416, 417 | Fixed racks UR1/UR2/UR2-ALU/CR2 with rigid backplane | PS 405, PS 407 |
| S7-1200 | CPU 1211C, 1212C, 1214C, 1215C, 1217C | Single integrated backplane, signal board plus signal modules left of CPU | PM 1207 (separate load supply) |
| S7-1500 | CPU 1511, 1513, 1515, 1516, 1517, 1518, 1519 | Mounting rail with system power supply (PS) slot | PS 25W/60W/100W (system PS), PM 70W/190W (load PM) |
The remainder of this guide uses the S7-300 as the primary example because it is the family that most often raises the question "why does the device view only show the CPU and not the PS or rack?" — a result of the S7-300's segmented backplane where the PS does not occupy a slot in the device view in the same way it does on the S7-1500.
2. Prerequisites
Before opening the device view, gather the following so the configuration can be done in one pass without catalog lookups for every slot.
- TIA Portal installation — V15.1, V16, V17, V18, or V19. Each major version expands the supported module catalog. Use the latest Siemens Industry Online Support HSP (Hardware Support Package) for the installed TIA Portal version so the catalog reflects the current MLFBs.
- Module list with MLFBs — every backplane-bound module that is physically installed, including the firmware version if it is non-default.
-
Mounting rail length and order number — S7-300 rails are ordered by length (e.g., 160 mm, 482 mm, 530 mm, 830 mm, 2000 mm) with the MLFB prefix
6ES7 390-1.... - Front connector type for each SM/FM — screw-type 20-pin (6ES7 392-1AJ00-0AA0), spring-type 20-pin (6ES7 392-1BJ00-0AA0), or 40-pin for S7-300 high-density modules.
- Power supply order number — PS 305/307 for S7-300; PS 405/407 for S7-400; system PS or load PM for S7-1500.
- Interface module (IM) order numbers — for multi-rack S7-300, the send IM (IM 360), the receive IM (IM 361), and the appropriate connecting cable (e.g., 6ES7 368-3BB00-0AA0 for 1 m).
3. Opening the TIA Portal Device View
The device view is the graphical representation of the rack and is the only place where the configured hardware must match the physical hardware. Open it with Project tree → Devices & networks → [PLC] → Device view.
The device view shows the rack as a horizontal strip of numbered slots. The exact slot count depends on the family:
- S7-300 — Slot 1 is reserved for the PS (or remains empty if the PS is mounted externally). Slot 2 is reserved for the CPU. Slots 3 to 8 hold signal/function/communication modules. Slot 9 is reserved for an IM 360 (send) in expansion rack 0.
- S7-400 — Slots are lettered and numbered (e.g., slot 1 power supply, slots 2-18 plug-in modules). The CR2 rack has two segments separated by a fan; each segment has its own PS slot.
- S7-1500 — Slot 0 is the system power supply; slot 1 is the CPU; slots 2-31 are I/O modules. A load PM can be added at the end.
If the device view is empty, double-click Add new device in the project tree and select the CPU from the catalog. The empty rack appears after the CPU is added.
4. Adding the Power Supply (PS) Module
For S7-300, the PS does not appear in the backplane in the same way the CPU does. It feeds the backplane via the bus connector and the wiring on the rail, but it has no logical module identity on the network. There are two consequences:
- The PS does not occupy a numbered logical slot in the device view for S7-300. It is, however, present in the catalog and can be dragged to the rack outline as a visual reference.
- The PS must be specified in the bill of materials separately. Use the TIA Selection Tool at siemens.com / tia-selection-tool to size and order the PS.
For S7-1500, the system PS is a real module in slot 0 of the device view and supplies the backplane. The load PM (PM 70W, PM 190W) is added to the right of the I/O modules and supplies the 24 V load circuit. Both are configured in the device view.
4.1 Sizing the power supply
The S7-300 PS 307 (e.g., 6ES7 307-1EA01-0AA0, 5 A) must supply both the backplane current and the 24 V sensor/actuator load. Use the formula:
I_PS >= sum(I_backplane) + sum(I_24V_load) + I_reserve
Typical S7-300 backplane currents for sizing:
| Module | Typical current draw from backplane |
|---|---|
| CPU 315-2 PN/DP | ~ 750 mA |
| CPU 319-3 PN/DP | ~ 1 000 mA |
| SM 321 DI 16×24 V | ~ 40 mA |
| SM 322 DO 16×24 V / 0.5 A | ~ 80 mA |
| SM 331 AI 8×12 bit | ~ 60 mA |
| IM 361 (receive) | ~ 350 mA per receive |
Add 20 % reserve as a field-proven sizing margin. If the calculated load exceeds the smallest PS 307 (2 A), step up to the 5 A or 10 A variant.
5. Adding the CPU
The CPU is the only module that must match the physical hardware. Selecting the wrong CPU MLFB in the device view results in compile errors and incorrect address assignment.
- In the device catalog (right-hand pane), navigate to Controllers → SIMATIC S7-300 → CPU.
- Expand the family that matches the installed CPU (e.g., CPU 315-2 PN/DP).
- Select the exact MLFB. The 6ES7 315-2EH14-0AB0 is a different firmware (V3.3) from the 6ES7 315-2EH13-0AB0 (V3.2) — confirm the label on the physical module.
- Drag the CPU to slot 2 of the rack outline.
If the catalog does not list the CPU MLFB, install the matching Hardware Support Package (HSP) from Siemens Industry Online Support and re-open the device view.
6. Adding Interface Modules (IM) for Multi-Rack S7-300
An S7-300 with more than eight signal modules requires an expansion rack. Expansion racks connect through IM modules and dedicated cables. The rules are strict:
| Mounting location | IM type | Order number example | Notes |
|---|---|---|---|
| CPU rack, slot 9 | IM 360 (send) | 6ES7 360-3AA01-0AA0 | Maximum 3 expansion racks |
| Expansion rack, slot 1 | IM 361 (receive) | 6ES7 361-3CA01-0AA0 | Maximum 3 receive IMs total |
| Expansion rack 1, slot 6 | IM 365 (1+1 segment) | 6ES7 365-0BA01-0AA0 | For a single 2-segment expansion only |
In the TIA Portal device view, drag the IM 360 to slot 9 of the central rack, then add a new Device → SIMATIC S7-300 → IM 361 device for the expansion rack. Connect them with a PROFIBUS or backplane bus link — for S7-300 IM 360/361, this is a dedicated IM connecting cable, not PROFIBUS. The cable length is selectable (1 m, 2.5 m, 5 m, 10 m).
7. Adding Signal Modules (SM)
Signal modules — digital input (DI), digital output (DO), analog input (AI), analog output (AO) — are added to the slots immediately to the right of the CPU. The order in the device view determines the I/O address assignment: slot 3 starts at byte 0 by default, slot 4 at byte 4, and so on.
- Drag each SM to the device view, slot 3 onward.
- Confirm the address assignment in Properties → I/O addresses. The default is fine for new projects; rewrite it only when aligning with an existing PLC program or HMI tag list.
- For analog modules, open the Properties → Channels tab and set the measurement type (voltage, current 4-20 mA, RTD, thermocouple) and the diagnostic enable bits. Mismatches here are the most common cause of "value = 7FFFH" (overflow) or "value = 8000H" (wire break on S7-300 AI) in the user program.
8. Adding Function Modules (FM) and Communication Processors (CP)
Function modules (FM 350-1, FM 351, FM 352, FM 353, FM 354, FM 355, FM 357-2) handle high-speed counting, positioning, and PID tasks independently of the CPU scan. Communication processors (CP 340, CP 341, CP 342-5, CP 343-1 Lean, CP 343-1, CP 443-1, CP 443-5 Extended) handle fieldbus and industrial Ethernet connections that the CPU's built-in interface does not support, or for which offloading the communication is desired.
Each FM and CP is added to a free slot, in the same way as an SM. The device configuration in TIA Portal only describes the physical presence — the FM/CP firmware parameters (e.g., measuring range for FM 350, baud rate for CP 340) are configured in a separate dialog opened from the module's properties or via the FM-specific configuration tool launched from TIA Portal.
9. Mounting Rail Selection
The mounting rail is the mechanical foundation. For S7-300, the standard rail is 530 mm (6ES7 390-1AF30-0AA0), which holds the PS, CPU, and up to six SM/FM/CP modules. A longer 830 mm rail is required when the rack contains eight modules plus the PS.
Order the rail in the same tool as the modules — typically the TIA Selection Tool or the Siemens Industry Mall. The TIA Selection Tool calculates the rail length automatically once the slot list is finalized.
| Length | MLFB | Typical slot count |
|---|---|---|
| 160 mm | 6ES7 390-1AB60-0AA0 | PS + CPU + 1 SM |
| 482.6 mm (19") | 6ES7 390-1AE80-0AA0 | PS + CPU + 5 SM |
| 530 mm | 6ES7 390-1AF30-0AA0 | PS + CPU + 6 SM |
| 830 mm | 6ES7 390-1AJ30-0AA0 | PS + CPU + 8 SM |
| 2 000 mm (cut to length) | 6ES7 390-1BC00-0AA0 | Custom |
10. Front Connector Selection
Every S7-300 SM/FM uses a 20-pin or 40-pin front connector. The connector is mechanically keyed to the module and is not part of the backplane. The three common variants are:
| Connector type | MLFB | Use case |
|---|---|---|
| Screw-type 20-pin | 6ES7 392-1AJ00-0AA0 | Standard wiring, vibration-tolerant |
| Spring-type 20-pin | 6ES7 392-1BJ00-0AA0 | Vibration, fast wiring with ferrules |
| Screw-type 40-pin | 6ES7 392-1AM00-0AA0 | High-density SMs (e.g., AH01 analog) |
Order one connector per slot occupied by an SM or FM. A spare connector for each type is a sensible spare-parts entry.
11. Using the TIA Selection Tool for a Complete Bill of Materials
The TIA Selection Tool (TST) is a browser-based configurator that produces a complete, exportable bill of materials including PS, rail, front connectors, and even labeling strips. It is the recommended way to size a cabinet before the device view is opened in TIA Portal.
- Open the TST at siemens.com / tia-selection-tool.
- Create a new project. Drag the controller, then the I/O modules, then the PS.
- When the slot list is complete, switch to the Accessories tab. The TST proposes the correct rail length, the correct number of front connectors, and any U-connectors required between physically separated slots (S7-300 rule: a maximum of one slot gap is allowed between powered modules; gaps beyond that require a U-connector or a new power segment).
- Export the bill of materials as CSV or transfer it to the Siemens Industry Mall shopping cart.
12. U-Connector and Backplane Continuity Rules (S7-300)
The S7-300 backplane is not continuous. The bus connector is built into each module, and the modules must sit on the rail in physical contact. If slots are left empty, the backplane is broken at that point. The S7-300 hardware rule is:
Slots 3 through 8 are powered by the CPU's backplane supply. If a slot is left empty, the modules to the right of the gap may not be powered. Use a dummy module (6ES7 370-0AA01-0AA0) or a U-connector to bridge the gap.
This is one of the most frequent field installation issues. A module physically mounted in slot 6, with slot 5 left empty, will not communicate — the backplane is broken at the empty slot. The TIA Portal device view does not enforce this; only the physical assembly does.
13. Verifying the Configuration
After populating the device view, run the following checks before downloading to the CPU.
- Compile the hardware — Project tree → PLC → Compile → Hardware (rebuild all). Any inconsistency appears in the Inspector window under Info → Compile.
- Compare online/offline — once the CPU is online, right-click the device and select Compare offline/online. The order number, firmware version, slot, and address of every module must match. Mismatches are highlighted in red.
- Diagnostic buffer readout — open Online & diagnostics → Diagnostic buffer. Event ID 0x1394 (module pulled/plugged) confirms the physical module identity. Event ID 0x13A1 (module parameter assignment error) indicates that the configured channel type does not match the wiring.
- I/O check — force a value at one DO and read back the corresponding input state at the cabinet terminals. This catches U-connector and addressing errors that the diagnostic buffer may not surface.
14. Troubleshooting Matrix
| Symptom | Likely root cause | Fix |
|---|---|---|
| Device view shows only CPU and SMs, no PS or rail | Expected for S7-300 — PS and rail are catalog items but are not backplane slots. Add them via the catalog as accessories or via the TIA Selection Tool. | Drag PS from Power supply catalog node for visual reference; track the PS in the BOM separately. |
| Compile error: Module X not in catalog | The MLFB is not in the installed TIA Portal version's catalog. | Install the matching HSP from Siemens Industry Online Support. |
| SM present in cabinet but not visible online | Module not seated fully, or backplane broken by an empty slot to the left. | Seat the module firmly; add a dummy module or U-connector to bridge the gap. |
| DI/DO shows input but no output (or vice versa) | Address mismatch between configured slot and wired slot. | Check Properties → I/O addresses and the wiring diagram; remap if necessary. |
| AI returns 7FFFH for all channels | Channel measurement type set to voltage, signal source is current (4-20 mA), or wire break. | Open Properties → Channels and select the correct measurement type; enable wire-break diagnostic for the channel range. |
| CPU SF LED on, diagnostic buffer shows 0x13A1 | Module parameter assignment error — typically a mismatch between configured channel type and the wiring or sensor. | Compare wiring to the channel configuration; correct the channel type or the wiring. |
| IM 361 expansion rack not online | Wrong IM pairing (IM 360 with another IM 360) or wrong cable. | Confirm central rack slot 9 = IM 360 and expansion rack slot 1 = IM 361; replace the cable with the correct MLFB 6ES7 368-3xx00-0AA0. |
| Front connector mechanically does not fit | Wrong connector family (20-pin vs 40-pin) ordered. | Check the module's connector requirement in the catalog and re-order the matching MLFB. |
15. Field-Engineering Notes
- Spare part discipline. A 10 % spare population for each SM type, one spare PS, one spare front connector per type, and a 2 000 mm raw rail are field-proven defaults for an S7-300 cabinet.
- Firmware pinning. When a CPU firmware upgrade is performed in TIA Portal, every module in the device view may need to be re-pinned to the new firmware. TIA Portal V17 and later will warn about a non-uniform firmware configuration during compile.
- Project archival. Archive the configured project with the matching HSP list noted. A new install of TIA Portal without the same HSPs will open the project but show a stripped-down catalog and may not be able to download to the physical CPU without a catalog refresh.
- Labeling. Use the TST-generated labeling strips (e.g., 6ES7 392-2XX00-0AA0) for slot numbers. This reduces commissioning time and the chance of addressing mistakes during field wiring.
FAQ
Why does the TIA Portal device view for my S7-300 only show the CPU and the I/O cards, and not the power supply or the rack?
On the S7-300, the power supply and the mounting rail are not backplane-bound modules — the PS feeds the backplane via the rail wiring rather than a logical slot. The catalog still contains the PS and rail, but they are added as accessories, not as slots in the device view. Use the TIA Selection Tool to size the PS, rail, and front connectors, and include them in the bill of materials.
How do I find the correct MLFB for a module that is not in my TIA Portal catalog?
Install the matching Hardware Support Package (HSP) for your TIA Portal version from Siemens Industry Online Support. After installing the HSP, restart TIA Portal and reopen the device view — the new MLFBs appear in the catalog under the correct family and firmware branch.
Can I leave empty slots between S7-300 modules on the rail?
No, the S7-300 backplane is broken by an empty slot. Modules to the right of the gap will not be powered or addressed. Either seat the modules in adjacent slots or insert a dummy module (6ES7 370-0AA01-0AA0) to bridge the gap.
How do I size the S7-300 power supply correctly?
Sum the backplane current of the CPU, the IM (if any), and every SM/FM/CP in the rack, add the 24 V sensor/actuator load, and add at least 20 % reserve. For example, a CPU 315-2 PN/DP (≈ 750 mA) plus eight SM 321 (8 × 40 mA = 320 mA) plus 2 A of 24 V load requires a PS 307 rated 5 A or higher.
What is the difference between the S7-300 system power supply model and the S7-1500 system power supply model?
The S7-300 PS 307/PS 305 is a load power supply that feeds the backplane as a side effect; it is not a logical module in the device view. The S7-1500 system PS (PS 25W/60W/100W) is a true backplane module in slot 0 and supplies the CPU and I/O modules; the load PM (PM 70W/190W) is a separate module that supplies the 24 V load circuit. Both are configured in the device view.