Overview
The Siemens CP 1242-7 is a communications processor (CP) that connects a SIMATIC S7-1200 station to a GSM/GPRS network. It publishes the S7-1200 as a TeleControl server or remote terminal, enabling event-driven and time-driven data exchange with a control center using the TeleControl protocol (a Siemens variant of IEC 60870-5-104 over GPRS/Internet). The module plugs onto the left side of the S7-1200 CPU and is configured as a slave on the internal communication bus; it does not occupy a slot in the signal-module (SM) row.
This reference covers three engineering concerns that field engineers repeatedly hit:
- Country-specific radio certification gating import and initial delivery of new CP variants (the issue that has historically blocked deployment of CP 1242-7 V2 modules in markets such as Chile, Argentina, and parts of South America until SUBTEL / ENACOM / similar authorities issued the corresponding type approval).
- Connection lifecycle: how the CP behaves when the GPRS partner is unreachable, including the configurable keep-alive and connection-abort behavior.
-
Programming with
TC_CONFIGin STEP 7 / TIA Portal: changing parameters at runtime, reading the current configuration, and verifying responses.
All cited part numbers, MLFB identifiers, and instruction names follow the official Siemens product documentation. Engineers should always verify against the manual bundle that ships with the firmware version loaded on their device.
Hardware Identification and Order Numbers
Two hardware generations are in active circulation. The distinction matters because the V2 device re-baselines the GPRS engine and changes the antenna connector, the SIM holder form factor, and the diagnostic LED layout.
| MLFB | Designation | Generation | Typical Use |
|---|---|---|---|
| 6GK7242-7KX30-0XE0 | CP 1242-7 (V1.0) | First generation | GPRS Class 12, single antenna SMA |
| 6GK7242-7KX31-0XE0 | CP 1242-7 (V2) | Second generation | GPRS Class 12, Quad-band GSM, redesigned SIM holder |
| 6AG1242-7KX30-4XE0 | CP 1242-7 (SIPLUS V1) | SIPLUS conformal-coated variant | Extended temperature range (-25 to +70 °C) and corrosive atmosphere |
The product catalog entry for the standard V2 device is published on the Siemens Industry Online Support portal: Communication processor CP 1242-7 - 6GK7242-7KX31-0XE0.
Country Approvals and Import Restrictions
CP 1242-7 variants integrate a certified GSM/GPRS modem. The modem component carries its own radio type approval, and Siemens cannot import a finished module into a market until that modem is approved by the local telecommunications authority. Siemens publishes the current approval matrix in the document Online Country Approvals - GSM/UMTS Products, which is referenced from the support entry Online CountryApprovals_GSM_UMTS_products.
For South America the historical sequence has been:
| Country | Regulator | Typical CP 1242-7 Approval Trigger |
|---|---|---|
| Peru | MTC | First South American approval historically granted for CP 1242-7 V1 |
| Chile | SUBTEL | Required for commercial import; field homologation process adds months |
| Argentina | ENACOM (formerly CNC/AFTIC) | Required for commercial import; CNC-IdB homologation flow |
| Brazil | Anatel | Approval tracked separately; CP variants with Anatel ID have suffix "-0XA0" or similar |
Technical Specifications
The specifications below are condensed from the CP 1242-7 operating instructions (BA_CP-1242-7_76.pdf) and the V2 manual at BA_CP-1242-7-V2_76.pdf.
| Parameter | Value |
|---|---|
| Supported CPUs | S7-1200 (all firmware versions that expose the left-side CM/CP interface) |
| Mobile network | GSM / GPRS, Quad-band 850 / 900 / 1800 / 1900 MHz |
| GPRS class | Class 12 (4+4 timeslots), mobile station class B |
| SIM interface | 1 x mini-SIM (2FF), 1.8 V and 3 V |
| Antenna connector | SMA female (50 Ω); use Siemens-approved antenna only |
| Power supply | 24 V DC from S7-1200 backplane; typical current draw 100 mA, peak 240 mA during transmit burst |
| Operating temperature | 0 °C to +55 °C horizontal, 0 °C to +45 °C vertical |
| Protocol stack | Siemens TeleControl Server (IEC 60870-5-104 profile) |
| Programming interface | STEP 7 Basic / TIA Portal, hardware catalog "Communications modules" |
| Maximum number of CPs per S7-1200 | 3 (left bus, addresses 1 to 3) |
GPRS Connection Lifecycle and Timeout Behavior
The CP maintains a permanent logical connection to the TeleControl server. When the server becomes unreachable, the CP applies the configured retry and timeout logic before it closes the socket and attempts to re-establish.
Per the V2 manual: If the module does not receive a response within the configured time, it closes the connection and tries to set it up again. The two relevant TIA Portal parameters are:
-
Connection establishment timeout- Maximum time the CP waits for the TCP handshake and TeleControl logon to complete. If the partner does not acknowledge within this window, the CP aborts the attempt. -
Message frame monitoring time- Watchdog that triggers a connection close if no application-layer frame is received within the configured window.
The CP also closes the socket if the communications partner terminated the connection or if the connection was aborted (for example by radio link loss). The module then enters the exponential back-off reconnect sequence defined by Connection establishment delay and its multiplier.
Connection establishment timeout of 60 s and a Message frame monitoring time of 3 × the partner's keep-alive interval. Lowering either parameter reduces time-to-detect-failure but increases the rate of false reconnects during transient radio fade.TC_CONFIG Programming Reference
The TC_CONFIG instruction is the runtime API for changing CP 1242-7 parameters from the S7-1200 user program. It is the supported replacement for direct SMS-based configuration that was available on legacy GPRS CPs.
Calling interface
The instruction lives in the Communication palette under Telecontrol in TIA Portal and is declared in the program as:
TC_CONFIG(
REQ : BOOL;
LADDR : HW_IO; // HW identifier of the CP (from device configuration)
CONFIG : VARIANT; // Pointer to a DB containing the parameter structure
BUSY : BOOL;
DONE : BOOL;
ERROR : BOOL;
STATUS : WORD;
ERR_LOC : WORD
);
The CONFIG variant points to a data block built from the TC_CONFIG_PARAM UDT shipped with the TIA Portal Telecontrol option. Each parameter is identified by an ID code:
| ID (hex) | Parameter | Direction | Notes |
|---|---|---|---|
| 0x0001 | APN | Read/Write | Access Point Name from the mobile operator |
| 0x0002 | APN user name | Read/Write | Optional; required by some operators |
| 0x0003 | APN password | Read/Write | Optional; required by some operators |
| 0x0004 | DNS server | Read | Assigned by network at logon |
| 0x0010 | Partner IP / DNS | Read/Write | TeleControl server address |
| 0x0011 | Partner port | Read/Write | Default 26382 |
| 0x0020 | Connection establishment timeout | Read/Write | Seconds |
| 0x0021 | Message frame monitoring time | Read/Write | Seconds |
| 0x0030 | IMEI | Read | Modem identifier |
| 0x0031 | SIM ICCID | Read | SIM serial number |
| 0x0032 | Mobile network registration status | Read | Used for diagnostics |
Example: change APN at runtime
// Data block "TC_DB" with TC_CONFIG_PARAM UDT
// Only the parameters to be changed need to be set:
TC_DB.Param[1].ID := 16#0001;
TC_DB.Param[1].Len := 16;
TC_DB.Param[1].Mode := 1; // 1 = write
TC_DB.Param[1].Data := 'wap.tigo.cl';
TC_DB.Param[1].Done := FALSE;
IF StartConfig THEN
TC_CONFIG(REQ := TRUE,
LADDR := 257, // example HW identifier
CONFIG := TC_DB,
BUSY => tcBusy,
DONE => tcDone,
ERROR => tcError,
STATUS => tcStatus,
ERR_LOC => tcErrLoc);
END_IF;
STATUS and ERR_LOC follow the standard S7-1200 error model: STATUS returns 0x0000 on success or a Siemens error code, and ERR_LOC identifies whether the error originated in the local CP (1) or the partner (2).
TIA Portal Configuration Steps
- In the device view of the S7-1200 station, drag CP 1242-7 V2 > 6GK7242-7KX31-0XE0 from the hardware catalog onto a free left-side slot.
- Open the CP properties and assign it a unique HW identifier; record this value - it is the
LADDRinput toTC_CONFIG. - Configure the Telecontrol interface: define the partner (TeleControl server) IP or DNS name, partner port (default 26382), and the local station number.
- Set the APN, APN user name, and APN password to match the SIM card provisioned by the local mobile operator.
- Define the data points: select S7-1200 tags (DBs, M bits, I/Q areas) and map them to the IEC 60870-5-104 information object addresses and types.
- Compile the project and download to the CPU. The configuration is pushed to the CP at next CP restart.
- Verify on the CP face: the LINK LED must go solid green (PDP context activated) and the SIGNAL QUALITY LED ladder must indicate a usable signal.
LED Diagnostics
| LED | State | Meaning |
|---|---|---|
| PWR (green) | On | 24 V supply OK |
| PWR (green) | Flashing | CP in startup / firmware update |
| LINK (green) | On | TCP connection to TeleControl server established |
| LINK (green) | Flashing | Establishing or re-establishing connection |
| LINK (off) | Off | No connection; check APN, signal, SIM PIN |
| SIGNAL QUALITY (3 LEDs) | 3 on | Excellent RSSI (> -75 dBm) |
| SIGNAL QUALITY (3 LEDs) | 2 on | Good (-85 to -75 dBm) |
| SIGNAL QUALITY (3 LEDs) | 1 on | Marginal (-95 to -85 dBm) - use directional or higher-gain antenna |
| SIGNAL QUALITY (3 LEDs) | All off | No signal or SIM not registered |
| FAULT (red) | On or flashing | Diagnostic event active; read buffer via TIA Portal online > Diagnostics |
Troubleshooting Matrix
| Symptom | First Check | Likely Root Cause | Corrective Action |
|---|---|---|---|
| CP not available in hardware catalog | TIA Portal version and HSP | Missing Hardware Support Package for CP 1242-7 V2 | Install latest HSP matching firmware version |
| All SIGNAL QUALITY LEDs off | Antenna, SIM card, operator coverage | SIM not seated, PIN locked, or no coverage at antenna location | Re-seat SIM, disable SIM PIN or enter it in CP config, relocate antenna or add outdoor antenna |
| LINK LED never reaches solid green | Partner reachability, APN correctness | Wrong APN, partner firewall blocks port 26382, DNS not resolvable from APN | Verify APN with operator, test partner:port with a laptop tethered to the same SIM, switch partner to IP literal to rule out DNS |
| LINK LED solid green but no application data | Data point configuration on both sides | Data point mappings do not match between CP and TeleControl server | Compare the data point export from TIA Portal with the server-side project; correct IOA addresses and types |
| Connection drops every few minutes | Signal quality, watchdog settings | Weak signal causes radio link loss; Message frame monitoring time too tight |
Improve antenna gain, raise watchdog to 3 × keep-alive, check for cell-tower load |
| TC_CONFIG returns STATUS 0x80C1 | CONFIG DB structure | Parameter length mismatch or unsupported ID | Confirm Len field matches the actual Data length; verify ID against Siemens list |
| TC_CONFIG returns STATUS 0x80B1 | CP state | CP firmware busy processing prior request | Re-call TC_CONFIG after BUSY goes FALSE |
| FAULT LED lit | Online > Diagnostics > Diagnostic buffer | Configuration error or partner-side rejection | Read the diagnostic buffer; events include "Partner terminated connection" and "Connection aborted by network" |
| Module imported but does not register on local network | Country approval status of the exact MLFB | Modem not type-approved for the destination country | Verify the modem PBA on the Siemens Online Country Approvals matrix; if not listed, the import itself is the problem |
Commissioning Checklist
- Confirm the CP MLFB is approved for the target country (cross-reference the Online Country Approvals document).
- Insert the SIM before power-up to avoid SIM hot-plug issues on V1 hardware; V2 supports hot-plug with a brief re-registration.
- Connect the antenna and verify at least two SIGNAL QUALITY LEDs are lit before attempting to bring up the partner connection.
- Disable the SIM PIN request on the SIM using a mobile phone, unless the operator requires PIN-locked SIMs.
- Configure the APN, partner address, and partner port in TIA Portal and download the project.
- After restart, verify the LINK LED transitions from flashing to solid green within the configured connection establishment timeout.
- Force a process value change in the S7-1200 and confirm it arrives at the TeleControl server; cross-check that the server-side timestamp is current.
- Capture the diagnostic buffer from the CP and store it with the SAT record for warranty reference.
Integration Notes for S7-1200
The CP occupies one of the three left-side communication addresses. The CPU firmware must support the CP's expected handshake - this is automatic for current TIA Portal versions, but legacy CPU firmware (V1.x of the S7-1200) does not recognize V2 CPs. In mixed fleets, do not assume that an S7-1200 that has run a V1 CP will accept a V2 CP after an online firmware change without a power cycle on the left bus.
Up to three CPs can be combined per S7-1200 station (for example one GPRS CP, one Ethernet CP for programming, one RS485 CM). The total left-bus current budget must be respected; the CP 1242-7 V2 draws the most of the available CPs during the transmit burst.
Replacement and Migration Considerations
For new deployments where GPRS coverage is unreliable or unavailable, evaluate the CP 1243-1 (Industrial Remote Communication, Ethernet-based) and the CP 1243-7 LTE (the LTE successor to CP 1242-7). The CP 1243-7 LTE uses the same TC_CONFIG instruction surface and the same data point model, so an upgrade is largely a hardware swap plus a TIA Portal device substitution.
Why is the CP 1242-7 V2 not deliverable in my country even though Siemens lists it globally?
The integrated GSM/GPRS modem inside the CP needs a radio type approval from the local telecommunications authority (for example SUBTEL in Chile, ENACOM in Argentina). Siemens cannot import a non-approved modem variant, so the module ships only into countries where that approval is on file. Check the Online Country Approvals document for current coverage and contact your local Siemens sales representative for the expected approval date.
How long does the country approval process typically take?
For South American markets Siemens has historically quoted 3 to 6 months from formal submission to grant, depending on the regulator backlog and any retest cycles. Lead times quoted by Siemens distributors for new CP variants into markets without existing approval therefore reflect the homologation window, not factory capacity. Pre-approved country-locked MLFBs ship immediately.
What does TC_CONFIG STATUS 0x80C1 mean?
It indicates that the CONFIG DB does not match what the CP expects, typically a Len field that does not equal the actual data length or an ID that the firmware does not recognise. Recompute Len from the data and re-verify the ID against the parameter list in the CP manual.
Can I change the partner IP address at runtime without restarting the CP?
Yes. Write the new address into a TC_CONFIG parameter record with ID 0x0010 and call TC_CONFIG with Mode = 1. The CP closes the current socket and re-establishes the link against the new partner without a full restart. Plan for a brief data gap during the reconnection.
What is the maximum number of data points the CP 1242-7 can buffer?
The CP 1242-7 buffers up to 1000 process values per partner, with a transmission window defined by the configured spontaneous and cyclic event classes. Values generated while the GPRS connection is down are queued in non-volatile memory and transmitted on the next successful handshake, subject to the buffer capacity.