Overview
The CP 1242-7 GPRS V2 (Siemens article number 6GK7242-7KX31-0XE0) is a communications processor that connects a SIMATIC S7-1200 PLC to a GSM/GPRS mobile wireless network. It is installed on the left side of the S7-1200 CPU, is supplied from the backplane bus, and performs all wireless link management independently of the CPU cycle. A typical architecture pairs the CP with a TeleControl Server Basic (TCSB) running on a host PC, which acts as the OPC/Modbus gateway between the S7-1200 and the SCADA layer (WinCC, WinCC Flexible, or a third-party HMI).
This reference consolidates the field-experience commissioning flow into a single document. It covers LED-state interpretation, APN configuration, TCSB project setup, teleservice activation, WinCC Flexible tag exchange over GPRS, and the recurring "NETWORK LED on for 10 seconds, then off" failure mode after a STEP 7 project download.
CP 1242-7 GPRS V2 Hardware Facts
| Parameter | Value |
|---|---|
| Article number | 6GK7242-7KX31-0XE0 |
| Mobile radio bands | GSM 850 / 900 / 1800 / 1900 MHz; GPRS multi-slot class 10 |
| Antenna connector | SMA female, 50 Ω, ANT 8xx antenna family |
| SIM interface | 1 × Mini-SIM (not Micro/Nano), 3 V/1.8 V |
| Power supply | 24 V DC from S7-1200 backplane; current consumption approx. 100 mA |
| IP assignment | Dynamic (private APN) or static (public APN) via TCSB |
| Protocols to TCSB | Siemens TeleControl protocol over TCP/UDP, port 26862 (default) |
| Ambient temperature | 0 °C to 55 °C horizontal mounting, 0 °C to 45 °C vertical |
| Status LEDs | DIAG, SIGNAL QUALITY, NETWORK, CONNECT, Teleservice |
LED State Matrix and Meaning
Every commissioning hour spent on the CP 1242-7 starts at the LED panel. The five LEDs each have a precise, deterministic state, and the combination tells you exactly where in the connection stack the link has stopped.
| DIAG | SIGNAL QUALITY | NETWORK | CONNECT | Meaning | Action |
|---|---|---|---|---|---|
| Off | Off | Off | Off | No 24 V supply or module not recognised by CPU | Check backplane seating and STEP 7 hardware catalog (V2.x must be selected) |
| Blink green (2 Hz) | Off | Off | Off | Boot phase, no SIM detected or SIM PIN locked | Insert SIM, disable PIN, or replace card |
| Green | Off | Off | Off | Logged in GSM, signal too weak or APN not provisioned | Check antenna; verify APN string with operator |
| Blink green | Green steady | Off | Off | Logged into GSM with usable signal, GPRS PDP context not activated | APN/user/password wrong; PDP context rejected |
| Green | Green steady | Off | Off | PDP context active but no tunnel to TCSB | TCSB unreachable (firewall, wrong partner address, DNS) |
| Green | Green | Green | Off | Link to TCSB established, OPC/S7 connection not yet opened | Verify connection configuration in TCSB and STEP 7 |
| Green | Green | Green | Green | All layers up; data frames flowing | Proceed to tag test |
| Red flash | any | any | any | Configuration error / firmware fault | Read diagnostic buffer via STEP 7 / Web diagnostics |
The "DIAG blinks green, SIGNAL QUALITY green, NETWORK off" pattern that triggers this article is the canonical "logged into GSM but stuck before GPRS attach" state. The CP is physically on the cellular network but the SIM's GPRS data subscription has not been negotiated, almost always because of an APN mistake.
APN Configuration in STEP 7 (TIA Portal)
- Open the TIA Portal project that contains the S7-1200 station.
- In the project tree, double-click Devices & networks > CP 1242-7 V2.
- Switch to Properties > Mobile wireless interface.
- Enter the four APN fields exactly as the MNO (mobile network operator) published them:
-
APN name — for example
internet,web.vodafone.de, or a private M2M APN. - APN user name — frequently empty for consumer APNs.
- APN password — frequently empty for consumer APNs.
-
Dial-up number —
*99***1#for GPRS,*99#for many European MNOs.
-
APN name — for example
- Tick Use permanent connection only if a static IP is allocated by the APN; otherwise leave unchecked so the CP can re-establish after dropout.
- Compile and download the device configuration to the S7-1200.
m2m.provider.de) require a username/password pair even if the operator sheet does not advertise it.Commissioning the TeleControl Server Basic (TCSB)
TCSB is the application that terminates the GPRS tunnel, holds the S7-1200 partner definition, and exposes the S7 tags as OPC DA / Modbus TCP items. The configuration step-by-step in the official Siemens application example (entry ID 39863979) is the reference workflow. The condensed form:
- Install TeleControl Server Basic on the host PC. The install adds a Windows service
Siemens.Tcsb.Serverand the configuration tool TCSB Config. - Add a new project in TCSB Config. Define a partner for each S7-1200 station. The partner entry maps the CP's IMSI/MSISDN to an internal partner number.
- Create a connection from the SCADA layer to TCSB (OPC DA on
localhost:48020, or Modbus TCP on port 502). TCSB acts as the data concentrator; no S7-1200 IP address needs to be reachable from the SCADA network. - Bind the STEP 7 project to the TCSB partner by uploading the partner's TeleControl DB generated by STEP 7 (DB "TC_DB" by default) into TCSB Config under Import S7 configuration.
- Activate the project. The TCSB service writes
Startedinto its log; from this moment the CP is expected to dial in.
Teleservice Activation
The teleservice channel allows STEP 7 (TIA Portal) to perform an online download or online diagnostics on the S7-1200 over the same GPRS link. To enable it:
- In TIA Portal, mark the CP 1242-7 V2 and open Properties > Teleservice.
- Set Active = true and assign a PG/PC router (the TCSB host, reachable as the CP's telecontrol partner).
- Choose the same TCSB partner as for runtime data.
- In the PG/PC, configure an S7-Online route: Type = Teleservice, Partner number = CP's MSISDN.
- From TIA Portal, choose Online > Accessible nodes; the S7-1200 should appear behind the TCSB route.
If only the runtime data path (SCADA tags) works but teleservice fails, the most common cause is the teleservice partner not being linked to the same TCSB project; verify the project name in TIA Portal matches the active project on the TCSB host.
WinCC Flexible SP3 Integration over GPRS
To make a WinCC Flexible runtime exchange tags with the S7-1200 across the GPRS link, point the HMI project at TCSB as if it were a normal S7-1200 partner:
- In WinCC Flexible, add a new connection in the HMI tags editor.
- Select SIMATIC S7 1200 as the PLC type, and TCP/IP as the protocol (used for OPC bridging through TCSB).
- Set the HMI's PG/PC interface to S7ONLINE > TeleService or to an OPC DA bridge that reads from TCSB. In practice, point the connection at the TCSB host IP and use the OPC DA connection type with the local OPC server on the HMI PC.
- Create HMI tags bound to the OPC items that TCSB exposes from the S7-1200 (e.g.
S7:[TCSB_Partner1]DB100.DBW0). - Run WinCC Flexible Runtime with the project. Tags update at the polling interval configured in TCSB (default 1 s, but rate-limited by GPRS latency).
Root Cause of "NETWORK LED On 10 s, Then Off After Download"
Several engineers report that after a STEP 7 project download, the NETWORK LED of the CP 1242-7 turns on for roughly ten seconds, then switches off permanently even though APN, IMSI, and signal are correct. The mechanism is the following:
- The download pushes a new configuration into the CP, which restarts its internal GSM stack.
- The CP negotiates a PDP context, and a transient NETWORK LED on confirms the GPRS attach is successful.
- The CP attempts the first TeleControl handshake with TCSB. If TCSB rejects the partner (wrong partner number, mismatch in the TC_DB import, or the TCSB service is stopped), the CP tears down the PDP context and switches NETWORK off.
- The CP then waits for the next keepalive/cyclic dial retry (default 60 s) before trying again. If the partner mismatch persists, the same 10-second pattern repeats indefinitely.
Diagnostic verification: open Web diagnostics of the CP (browser on the S7-1200's engineering IP) and look for Telecontrol > Connection state > Reason for last disconnect. A 0x8000 0000-class error means authentication rejected by TCSB; a 0x80xx xxxx partner-not-found error means the partner number imported into TCSB does not match the one configured in TIA Portal.
Troubleshooting Matrix
| Observed symptom | Likely root cause | Fix |
|---|---|---|
| All LEDs off | No backplane power, CP seated incorrectly, or HW catalog mismatch | Reseat CP, select the V2 module in HW catalog, recompile all |
| DIAG blinks, no SIGNAL QUALITY | No SIM, SIM PIN active, or damaged SIM | Insert valid SIM, disable PIN with a mobile phone first |
| DIAG green, SIGNAL QUALITY red flash | Very poor field strength (< -102 dBm) | Use external antenna, relocate the cabinet, add lightning arrestor |
| DIAG blinks, SIGNAL QUALITY green, NETWORK off | APN/user/password rejected by MNO | Verify APN data with operator, copy exact case, strip whitespace |
| DIAG green, NETWORK green, CONNECT off | TCSB partner mismatch or TCSB service stopped | Restart TCSB, re-import TC_DB, confirm partner number |
| NETWORK on 10 s then off after download | TCSB rejects the first handshake (auth/partner) | Check TCSB event log, compare partner number with TIA Portal |
| CONNECT green, WinCC tags stay "Connection error" | Wrong OPC item path or HMI connected to wrong host | Validate OPC item in TCSB OPC test client, then in WinCC tag browser |
| Periodic reconnect every few minutes | Signal fluctuation or GPRS cell reselection | Increase keepalive, install higher-gain antenna, fix SIM into permanent context |
| CP drops offline 30 s after power-up, never reconnects | TCSB not started or firewall blocks TCP/26862 | Verify outbound 26862 with telnet from the TCSB host's perspective |
Verification Procedure After Configuration
- LED walk: Confirm DIAG steady green, SIGNAL QUALITY steady green, NETWORK steady green, CONNECT steady green.
-
Web diagnostics: Open
http://<S7-1200 IP>/<port>and verify Connection state = Connected and Bytes sent/received > 0. - TCSB event log: Confirm the partner appears as Online and the timestamp of last frame is current.
- Tag roundtrip: Force a value from STEP 7 (VAT table) and read it back in TCSB OPC test client; then flip the same tag from WinCC Flexible and confirm the value in the S7-1200's VAT.
-
24-hour burn-in: Monitor the Last disconnect reason counter; it must stay at
0x0000 0000for the run-in period.
Common Field-Proven Caveats
- Some MNOs (notably in North America) deactivate dormant GPRS sessions after a few minutes of zero traffic. Configure an empty send frame keepalive in the TIA Portal connection settings to prevent the radio from parking.
- If the S7-1200 CPU is replaced, the CP keeps its old IMSI binding in TCSB; you must delete and re-add the partner in TCSB Config or import the new TC_DB.
- Always verify the SIM card in a regular smartphone first to confirm APN, username, password, and that data is provisioned on the subscription.
- The CP 1242-7 V2 is not hot-swappable on the S7-1200. Power down before inserting/removing.
- Behind a private APN with a corporate firewall, the TCSB host may be on a different subnet; do not rely on link-local discovery — hard-code the TCSB partner IP in the TIA Portal configuration.
FAQ
What does it mean if the CP 1242-7 DIAG LED blinks green and SIGNAL QUALITY is on but NETWORK is off?
The CP is registered on the GSM network with sufficient signal, but the GPRS PDP context cannot be activated. In more than 90 % of field cases the APN name, user, or password configured in TIA Portal is wrong or not provisioned by the MNO for that SIM. Verify the APN data with the operator and re-download the project.
Why does the NETWORK LED on the CP 1242-7 turn on for about ten seconds and then switch off after a project download?
The GPRS attach succeeds, but the first TeleControl handshake with TCSB is rejected. Compare the partner number configured in TIA Portal with the partner entry in TCSB Config, re-import the TC_DB, and verify the TCSB Windows service is running and the outbound TCP/26862 firewall rule is open.
How do I read the CP 1242-7 error code from a STEP 7 project?
Open the CP's Web diagnostics in a browser pointed at the S7-1200 engineering IP, or evaluate the diagnostic buffer in TIA Portal under Online & Diagnostics > Diagnostics buffer. The last disconnect reason is shown as a Siemens diagnostic block; codes starting with 0x80xx indicate partner/authentication problems with TCSB, while 0x8F-class codes indicate radio-link failures.
Can I run WinCC Flexible SP3 directly against the S7-1200 over GPRS?
No. WinCC Flexible cannot traverse the GPRS tunnel directly to the S7-1200. The supported topology is S7-1200 → GPRS → TCSB → OPC DA → WinCC Flexible Runtime on the HMI/PC. TCSB acts as the data concentrator and protocol bridge.
Does the CP 1242-7 GPRS V2 support firmware updates over the air?
No. Firmware updates for the CP 1242-7 V2 must be applied via TIA Portal (online > accessible nodes > right-click > firmware update) over the S7-1200 backplane, either locally or through the teleservice channel once it is operational. Plan a maintenance window before applying firmware.