Problem Statement
When configuring multiple Pulse Train Output (PTO) axes on a Siemens SIMATIC S7-1214C DC/DC/DC CPU (order number 6ES7214-1AG40-0XB0), engineers frequently encounter a runtime fault when attempting to enable a second PTO axis while the first is already in operation. The control system reports that "only one axis can be enabled at one time", even though the CPU physically supports four hardware PTO channels. This article documents the root cause—collision of motion control instance data blocks—and the corrected engineering practice that enables true simultaneous multi-axis motion on the S7-1200 platform.
The error manifests at the MC_Power function block. After creating two technology objects (e.g., Axis_1 and Axis_2) in TIA Portal, both axes operate correctly when commanded individually. The moment the engineer calls MC_Power for the second axis, the axis enable bit fails to latch, the Status output of the second MC_Power returns an error word (typically 16#8001 "Axis not enabled" or 16#8011 "Axis disabled, error in axis configuration"), and the axis-state flag for the first axis may also toggle. The technology object alarm window typically reads "Axis cannot be enabled; an internal conflict exists between two MC_Power instances".
The diagnosis and resolution steps below apply to:
- SIMATIC S7-1200 CPUs with firmware V4.0 through V4.7 (G1 generation)
- TIA Portal V15.0 through V18 (with installed HSP for newer firmware)
- All STEP and DIRECTION-controlled stepper or servo systems
For the newer S7-1200 G2 generation, the architecture differs; refer to the dedicated section at the end of this document.
Hardware Identification
The CPU referenced in the original case is the S7-1214C DC/DC/DC, order number 6ES7214-1AG40-0XB0. This is a critical detail because only the DC/DC/DC variant—with bipolar transistor (source-type) outputs—can generate PTO signals. The relay-output variants (6ES7214-1BG40-0XB0) cannot produce high-speed pulse trains and will display a configuration error in the Technology Object properties the moment PTO is selected.
| Parameter | Value |
|---|---|
| Order Number (MLFB) | 6ES7214-1AG40-0XB0 |
| Product Family | SIMATIC S7-1200 (G1) |
| Firmware Range | V4.0 – V4.7 |
| Digital Outputs (Transistor, Source) | 10 (Q0.0 – Q1.1) |
| PTO Hardware Channels | 4 (configurable up to 100 kHz each) |
| Max PTO Pulse Frequency | 100 kHz (Q0.0–Q0.3 high-speed pairs) |
| Recommended PTO Output Pairs | Q0.0/Q0.4, Q0.1/Q0.5, Q0.2/Q0.6, Q0.3/Q0.7 |
| Max Configured Axes (PTO) | 4 (CPU hardware limit) |
| Work Memory (Program / Data) | 100 KB / 4 MB |
| Bit Memory (M) | 8192 bytes |
| Max Number of Technology Objects | 128 (depends on memory budget) |
Confirm the exact variant by reading the order number on the front of the module and verifying it matches 6ES7214-1AG40-0XB0. The third letter group "AG" identifies the DC/DC/DC variant; "BG" identifies the DC/DC/Relay variant; "HG" identifies the AC/DC/Relay variant. The fourth numeric group "40" identifies firmware generation 4 (V4.x).
S7-1200 Family PTO Comparison
The following table compares PTO capabilities across the S7-1200 G1 and G2 product lines. Use it to select the appropriate CPU for the application:
| CPU Model | Order Number | Generation | PTO Channels | Max Frequency | Min Cycle Time |
|---|---|---|---|---|---|
| CPU 1211C DC/DC/DC | 6ES7211-1AE40-0XB0 | G1 | 2 | 100 kHz | 10 µs |
| CPU 1212C DC/DC/DC | 6ES7212-1AE40-0XB0 | G1 | 2 | 100 kHz | 10 µs |
| CPU 1214C DC/DC/DC | 6ES7214-1AG40-0XB0 | G1 | 4 | 100 kHz | 10 µs |
| CPU 1215C DC/DC/DC | 6ES7215-1AG40-0XB0 | G1 | 4 | 100 kHz | 10 µs |
| CPU 1217C DC/DC/DC | 6ES7217-1AG40-0XB0 | G1 | 4 | 100 kHz | 10 µs |
| CPU 1215G2 DC/DC/DC | 6ES7215-1BG40-0XB0 | G2 | 8 | 200 kHz | 5 µs |
| CPU 1217G2 DC/DC/DC | 6ES7217-1BG40-0XB0 | G2 | 8 | 200 kHz | 5 µs |
The minimum cycle time is the reciprocal of the maximum frequency. The S7-1200 G1 FPGA divides the system clock by N to generate the pulse train; for 100 kHz output the divisor is 10 µs. The S7-1200 G2 doubles the system clock, enabling 200 kHz output and 5 µs minimum pulse width.
S7-1200 PTO Architecture and STEP/DIRECTION Mode
Each PTO channel in the S7-1200 is implemented as a hardware-accelerated pulse generator routed to a specific digital output pin. The pulse train is generated entirely in the CPU's onboard FPGA, independent of the OB1 scan time. This means the achievable pulse rate is not limited by user program cycle time, only by the hardware maximum frequency (100 kHz on the high-speed output pairs of the S7-1214C).
The STEP/DIRECTION mode (also called "pulse + direction" or P/D) is one of two signal modes supported by the technology object. The alternative is CW/CCW (count-up/count-down) where the S7-1200 toggles between two outputs. STEP/DIRECTION is the most common mode for stepper drives and most digital servo drives. In STEP/DIRECTION mode:
- The pulse output (PULSE / STEP) emits one pulse per step commanded. A 1000-step move at 100 kHz output frequency completes in 10 ms.
- The direction output (DIR) is held low for negative direction and high for positive direction. Level changes occur only when the axis reverses between motions.
The mapping between the technology object's "Signal selection" and the physical output pin is configured in the Technology Object > Configuration > Hardware Output panel of TIA Portal. Recommended mapping for a 4-axis S7-1214C system:
| Technology Object | Pulse Output | Direction Output | Drive Signal Mode |
|---|---|---|---|
| Axis_1 (PTO1) | Q0.0 | Q0.4 | STEP + DIR |
| Axis_2 (PTO2) | Q0.1 | Q0.5 | STEP + DIR |
| Axis_3 (PTO3) | Q0.2 | Q0.6 | STEP + DIR |
| Axis_4 (PTO4) | Q0.3 | Q0.7 | STEP + DIR |
If the stepper drive optically isolates the inputs and uses 24 V signal levels, connect the S7-1200 source-type output to the drive's optocoupler anode. For source-type outputs of the DC/DC/DC variant, verify the drive's input polarity. Most modern stepper drives (Leadshine DM series, Schneider Lexium MDrive, Applied Motion ST series) accept 5–24 V inputs and have configurable sink/source input type.
PLCopen Motion Control Function Block Set
The S7-1200 motion control library implements the PLCopen Motion Control standard. Each FB requires a unique instance DB to store its internal state machine, edge-detection flags, error latches, and per-axis handshake variables. The standard block set for a positioning application is:
| Function Block | Function | Recommended Instance DB Name Pattern |
|---|---|---|
| MC_Power | Enables/disables axis; must be called every scan | MC_Power_Axis1, MC_Power_Axis2 |
| MC_Reset | Acknowledges latched errors and re-enables the axis | MC_Reset_Axis1, MC_Reset_Axis2 |
| MC_Home | Defines the reference (zero) position of the axis | MC_Home_Axis1, MC_Home_Axis2 |
| MC_Stop | Emergency stop; cancels all active motions | MC_Stop_Axis1, MC_Stop_Axis2 |
| MC_Halt | Controlled halt with configured deceleration | MC_Halt_Axis1, MC_Halt_Axis2 |
| MC_MoveAbsolute | Moves to an absolute position | MC_MoveAbsolute_Axis1, MC_MoveAbsolute_Axis2 |
| MC_MoveRelative | Moves a relative distance from current position | MC_MoveRelative_Axis1, MC_MoveRelative_Axis2 |
| MC_MoveVelocity | Velocity mode (no position target) | MC_MoveVelocity_Axis1, MC_MoveVelocity_Axis2 |
| MC_MoveJog | Manual jog mode at low velocity | MC_MoveJog_Axis1, MC_MoveJog_Axis2 |
| MC_ReadParameter | Reads a technology object parameter at runtime | MC_ReadParameter_Axis1, MC_ReadParameter_Axis2 |
| MC_WriteParameter | Writes a technology object parameter at runtime | MC_WriteParameter_Axis1, MC_WriteParameter_Axis2 |
A 2-axis positioning system therefore requires 16–22 instance DBs. A 4-axis system requires 32–44 instance DBs. TIA Portal's automatic block call checker will display a compile-time warning if a shared instance is detected: "Instance DB for MC_Power is used multiple times — possible conflict". This warning is the surest indicator that the configuration is wrong before runtime.
Root Cause: Shared Instance Data Blocks
The single most common cause of the "only one axis can be enabled at a time" error is the use of a shared instance data block for multiple MC_Power calls. Every PLCopen motion control FB requires a unique instance DB to store its internal state machine. When the engineer drags the MC_Power block from the TIA Portal library into a second network and leaves the default "Multi-instance" or "Single instance with same name" option active, TIA Portal may either:
- Generate a multi-instance DB inside the parent FB (and the parent FB is itself a single instance, so the multi-instance is shared by both calls), or
- Reuse the same
MC_Power_DBinstance for both axis calls, causing the second invocation to overwrite the first.
In both cases, the MC_Power block is being executed twice on the same data area. The S7-1200 motion control firmware sees two MC_Power.Enable = TRUE requests with conflicting axis references and rejects the second enable to protect the FPGA PTO engine from bus contention. The technology object alarm window displays "Axis cannot be enabled because another instance of MC_Power is already active".
Secondary, less common root causes for the same error include:
- One technology object is configured with "Pulse and direction" mode and the other is configured with "PTO (Pulse A / Pulse B / Direction)" — the FPGA cannot mix modes in the same output bank.
- Two technology objects are assigned to the same pulse output pin (Q0.0 used by both Axis_1 and Axis_2) — the technology object refuses to compile and reports the conflict in the IO assignment field of the device configuration.
- The axis is already in an error state (a previous
MC_MoveAbsoluteaborted due to a hardware limit switch event) and the engineer has not calledMC_Resetto clear the latched error. TheMC_Powerblock returnsStatus = 16#8001. - The drive enable output (e.g.,
Q1.0) is wired but the drive has not powered up; the technology object detects the missing drive enable feedback and refuses to enable.
Solution: Unique Instance DBs per Motion Block
Every PLCopen motion control function block must have its own dedicated instance DB. The fix is to:
- Open the block call interface of every
MC_Power,MC_Home,MC_MoveAbsolute,MC_MoveRelative,MC_MoveVelocity,MC_MoveJog,MC_Halt,MC_Stop, andMC_Resetin the user program. - For each call, click the small dropdown at the bottom-left of the block and select "Single instance" with a unique DB name. The default naming convention is
<FBName>_DB<n>(e.g.,MC_Power_DB_1,MC_Power_DB_2). - Repeat for every motion FB in the program. A complete multi-axis application with 2 axes and the standard FB set will create approximately 16–20 instance DBs.
- Compile the program. Verify the information window shows no instance-DB conflict warnings.
The correct naming convention for a two-axis system is:
-
MC_Power_Axis1(instance DB for the MC_Power call driving Axis_1) -
MC_Power_Axis2(instance DB for the MC_Power call driving Axis_2) -
MC_Home_Axis1,MC_Home_Axis2 -
MC_MoveAbsolute_Axis1,MC_MoveAbsolute_Axis2 -
MC_MoveRelative_Axis1,MC_MoveRelative_Axis2 -
MC_MoveJog_Axis1,MC_MoveJog_Axis2 -
MC_Stop_Axis1,MC_Stop_Axis2 -
MC_Reset_Axis1,MC_Reset_Axis2
This naming style also makes program review, online monitoring, and cross-reference analysis far more efficient. Avoid the auto-generated DB1234 names — they are functionally correct but operationally painful.
Step-by-Step TIA Portal Configuration
The complete engineering procedure for a 2-axis S7-1214C stepper system follows. The TIA Portal screen navigation paths reflect TIA V17; equivalent paths for V15, V16, and V18 are functionally identical.
Step 1 — Add the CPU and verify firmware
Open the project, insert a new SIMATIC S7-1200 device of order number 6ES7214-1AG40-0XB0. Open Device View > CPU > Properties > System and Clock Memory and verify the firmware version. For multi-axis motion, use firmware V4.4 or higher. Earlier V4.0–V4.3 supports PTO but with reduced performance in the S7-1200 motion control firmware.
Step 2 — Configure the pulse outputs
Open Device View > CPU > Properties > Pulse generators (PTO/PWM). Enable four pulse generators:
- PTO1: Signal type = PTO, Output = Q0.0, Direction output = Q0.4, Maximum frequency = 100000 Hz
- PTO2: Signal type = PTO, Output = Q0.1, Direction output = Q0.5, Maximum frequency = 100000 Hz
- PTO3: Signal type = PTO, Output = Q0.2, Direction output = Q0.6, Maximum frequency = 100000 Hz
- PTO4: Signal type = PTO, Output = Q0.3, Direction output = Q0.7, Maximum frequency = 100000 Hz
Disable PWM mode for these outputs. Click Apply. The digital output properties for Q0.0, Q0.1, Q0.2, Q0.3, Q0.4, Q0.5, Q0.6, and Q0.7 are now grayed out under "Standard output" — they are reserved for the motion control engine.
Step 3 — Add the technology objects
Navigate to Project tree > Technology objects > Add new object. Add two objects of type PositioningAxis (or "TO_Axis" in older TIA Portal versions):
- Name:
Axis_1 - Name:
Axis_2
For each axis, complete the configuration wizard:
| Configuration Section | Parameter | Recommended Value |
|---|---|---|
| Drive | Signal type | PTO (Pulse and direction) |
| Drive | Reference speed / max speed | 1000 pulse/s (adjust to stepper) |
| Drive | Acceleration/deceleration | 100 pulse/s² |
| Mechanics | Load revolutions per motor revolution | 1 (direct drive) |
| Position limits | Software limit switch | Enable, range = application |
| Homing | Active homing mode | Use zero mark or hardware limit |
| IO assignment | Pulse output | Axis_1 → PTO1, Axis_2 → PTO2 |
| IO assignment | Drive enable | Optional Qx.y |
Step 4 — Declare the FB instance with separate motion blocks
Open an existing FB or create a new FB named Motion_Control. Declare the following static tags in the VAR section:
VAR
EnableAxis1 : Bool;
EnableAxis2 : Bool;
PosTarget_Axis1 : Real;
PosTarget_Axis2 : Real;
Axis1_Homed : Bool;
Axis2_Homed : Bool;
JogForward_Axis1 : Bool;
JogForward_Axis2 : Bool;
JogBackward_Axis1 : Bool;
JogBackward_Axis2 : Bool;
Axis1_Error : Bool;
Axis2_Error : Bool;
END_VAR
Insert motion control blocks. For each block call, click the small arrow at the bottom-left, choose "Single instance", and assign a unique DB name per the convention above. The ladder / FBD / SCL network structure should be:
- Network 1:
MC_Power_Axis1with Axis =Axis_1, Enable =EnableAxis1 - Network 2:
MC_Power_Axis2with Axis =Axis_2, Enable =EnableAxis2 - Network 3:
MC_Home_Axis1with Axis =Axis_1, Execute =Tag_HomeAxis1 - Network 4:
MC_Home_Axis2with Axis =Axis_2, Execute =Tag_HomeAxis2 - Network 5:
MC_MoveAbsolute_Axis1with Axis =Axis_1, Position =PosTarget_Axis1 - Network 6:
MC_MoveAbsolute_Axis2with Axis =Axis_2, Position =PosTarget_Axis2
Call the FB in OB1. Compile and download. The information window must show no instance-DB conflict warnings.
Sample SCL Program: Simultaneous Two-Axis Motion
The following SCL example demonstrates a parallel motion sequence: Axis_1 moves to position 10000 pulses, Axis_2 simultaneously moves to position -5000 pulses, both at 5000 pulse/s. The unique instance DBs are created at the call sites automatically by TIA Portal when each block is dragged from the library.
// Network 1: Power both axes
"MC_Power_Axis1"(Axis := "Axis_1", Enable := TRUE, StartMode := 1);
"MC_Power_Axis2"(Axis := "Axis_2", Enable := TRUE, StartMode := 1);
// Network 2: Homing sequence
IF "First_Scan" THEN
"MC_Home_Axis1"(Axis := "Axis_1", Execute := TRUE, Position := 0.0, Mode := 0);
"MC_Home_Axis2"(Axis := "Axis_2", Execute := TRUE, Position := 0.0, Mode := 0);
END_IF;
// Network 3: Coordinated motion
IF "Start_Motion" AND "Axis1_Homed" AND "Axis2_Homed" THEN
"MC_MoveAbsolute_Axis1"(
Axis := "Axis_1",
Execute := TRUE,
Position := 10000.0,
Velocity := 5000.0,
Acceleration := 1000.0,
Deceleration := 1000.0
);
"MC_MoveAbsolute_Axis2"(
Axis := "Axis_2",
Execute := TRUE,
Position := -5000.0,
Velocity := 5000.0,
Acceleration := 1000.0,
Deceleration := 1000.0
);
END_IF;
// Network 4: Error handling
IF "MC_Power_Axis1".Status <> 16#7000 THEN
"Axis1_Error" := TRUE;
END_IF;
IF "MC_Power_Axis2".Status <> 16#7000 THEN
"Axis2_Error" := TRUE;
END_IF;
The motion control engine executes both moves concurrently. The axis-state flags "MC_MoveAbsolute_Axis1".Done and "MC_MoveAbsolute_Axis2".Done become TRUE independently as each axis reaches its target. No interaction between the two axes exists at the application level; they are fully decoupled.
Sample Ladder Logic: Two-Axis Enable and Jog
The equivalent ladder (LAD) network for axis enable and jog commands uses contacts to drive the MC_Power and MC_MoveJog FBs:
Network 1: Axis 1 Power and Jog
| EnableAxis1 MC_Power_Axis1.DB
|------| |---------| Enable Axis |
| | |
| JogFwdAxis1 MC_MoveJog_Axis1.DB
|------| |---------| JogForward Axis |
| | JogVelocity: 500 |
| JogRevAxis1 MC_MoveJog_Axis1.DB
|------| |---------| JogBackward Axis |
Network 2: Axis 2 Power and Jog
| EnableAxis2 MC_Power_Axis2.DB
|------| |---------| Enable Axis |
| | |
| JogFwdAxis2 MC_MoveJog_Axis2.DB
|------| |---------| JogForward Axis |
| JogRevAxis2 MC_MoveJog_Axis2.DB
|------| |---------| JogBackward Axis |
The two networks are scanned in every OB1 cycle. With unique instance DBs, both MC_Power blocks latch their enable state and both axes are simultaneously active. The MC_MoveJog calls per axis use their own instance DBs and operate independently.
Homing Mode Reference
Every positioning axis must be homed before absolute moves can be issued. The S7-1200 technology object supports the following homing modes (configured in Axis configuration > Homing):
| Mode | Type | Description | Hardware Required |
|---|---|---|---|
| 0 | Active homing | Axis moves to a homing switch (digital input) and uses the input's edge as the reference | Home switch on DI |
| 1 | Active homing | Axis moves to a positive hardware limit switch and reverses to a home switch | Home switch + limit |
| 2 | Active homing | Axis moves to a negative hardware limit switch and reverses to a home switch | Home switch + limit |
| 3 | Active homing | Axis moves to the motor's zero pulse (encoder Z signal) | Encoder Z on DI |
| 5 | Active homing | Axis moves to a homing switch, then to the next encoder zero pulse | Home switch + encoder |
| 7 | Passive homing | Axis position is set by external command during motion (e.g., from a sensor edge) | Home switch on DI |
| 8 | Passive homing | Axis position is set to the value of the position parameter at the encoder Z pulse | Encoder Z on DI |
| 9 | Direct homing | No motion; current position is set to the value of the position parameter | None (software only) |
For stepper systems without an encoder (the typical S7-1214C PTO application), only modes 0, 1, 2, and 9 are practical. Mode 9 (direct homing) is the most common for open-loop stepper applications: it sets the current position to the specified value without requiring a home switch or motor motion.
Drive Enable Signal Handling
The S7-1200 technology object has an optional drive enable output. When configured, the technology object asserts this output as part of the axis enable sequence. The drive enable signal is typically wired to the stepper drive's "Enable" or "ENA" input, which gates the drive's power stage. Without drive enable, the drive's motor terminals remain in a high-impedance state, preventing current flow and torque production.
For a 2-axis S7-1214C system, the drive enable outputs can be assigned to:
- Axis_1 drive enable: Q1.0 (or any unused standard output)
- Axis_2 drive enable: Q1.1 (or any unused standard output)
The drive enable output goes high when MC_Power.Enable is TRUE and the axis is in a healthy state. The output goes low on MC_Power.Enable = FALSE, on MC_Stop.Execute, or on a fatal axis error. Configure the drive enable in the technology object under Hardware Output > Drive enable. If the drive enable is wired but the drive's response is not monitored, set the technology object to "Drive enable without feedback" mode. If the drive's enable response is monitored (e.g., a contactor auxiliary contact), use "Drive enable with feedback" and assign the feedback to a digital input.
Profile Mode: Trapezoidal vs S-Curve
The S7-1200 motion control technology object supports two velocity profile modes. The profile is selected in the technology object configuration under Drive > Profile mode:
- Trapezoidal profile (default): Constant acceleration, constant velocity, constant deceleration. The velocity-time graph is a trapezoid. Simple, predictable, but the velocity change at the start and end of motion is instantaneous, which can excite mechanical resonances at high speeds.
- S-curve profile (firmware V4.2+): Acceleration ramps up from zero to a maximum value over the jerk time, then remains at the maximum acceleration, then ramps down to zero. The velocity curve is a smooth S-shape. Reduces mechanical shock and improves positioning time for high-inertia loads. Increases position-tracking delay by approximately one-half of the jerk time.
For S-curve profiles, configure the jerk in the technology object (Drive > S-curve > Jerk). Typical jerk values are 1000–10000 pulse/s³. Higher jerk reduces motion time but increases mechanical stress; lower jerk is smoother but slower. Profile mode is selected per axis and is independent across axes; one axis may use trapezoidal while another uses S-curve.
Wiring and Signal Conditioning
The S7-1200 DC/DC/DC outputs are 24 V PNP (source) outputs rated at 0.5 A continuous. They are ESD-sensitive and require proper handling. Observe the following wiring practices:
- Use shielded, twisted-pair cable for the pulse and direction signals. Ground the shield at the cabinet entry panel only — do not ground at both ends.
- Power down the CPU and the drive before connecting or disconnecting the PTO wiring. Hot-plugging can damage the S7-1200's output driver or the drive's optocoupler input.
- Install a flyback diode on inductive loads (e.g., a 24 V relay coil connected in parallel to a CPU output). The S7-1200's output transistor does not include internal flyback protection.
- Verify the drive's input voltage range. Most stepper drives accept 5–24 V single-ended inputs. If the drive requires 5 V differential signals (RS-422), use an external line driver (AM26LS31, SN75174) to convert the S7-1200's 24 V single-ended signal to 5 V differential.
For long cable runs (>10 m), use a line driver at the S7-1200 end to boost the signal, or use a differential signal converter at the drive end. The high-speed pulse edges of a 100 kHz signal have a rise time of approximately 1 µs; a 10 m cable with 50 pF/m capacitance creates a 500 pF load, which the S7-1200 output can drive but with degraded edge quality. For 20 m and longer, always use a differential interface.
S7-1200 G2 Multi-Axis Capabilities
The S7-1200 G2 generation (introduced 2024, firmware V21 and later) substantially extends the PTO capabilities. The relevant G2 CPUs include 6ES7215-1BG40-0XB0 (CPU 1215G2) and higher models. Per the official TIA Portal V21 documentation, a single G2 CPU supports up to 8 PTO channels and up to 8 drives simultaneously controlled.
The G2 technology object structure differs: rather than the G1-style PositioningAxis with a hardware-output mapping, G2 uses a "Drive" technology object that abstracts the axis control logic and links to a PTO channel via a software connection. The user may add drives, configure motion profiles, and assign PTO channels from the central PTO resource pool. The S7-1200 G2 reference manual states: "You can control a maximum of 8 drives simultaneously via the eight PTOs of the CPU."
The multi-axis instance-DB requirement also applies to G2. While the G2 drive pool abstracts the PTO channel assignment, every PLCopen motion control FB call must still have a unique instance DB. The error symptom on G2 is identical if instance DBs are shared: the drive refuses to enable, and the online alarm window displays "Drive is locked by another MC_Power instance".
For S7-1200 G2 systems with more than 4 axes, refer to the official Introduction to Motion Control PTO S7-1200 G2 documentation. This is the authoritative source for G2 multi-axis configuration, axis parameter limits, and S-curve profile support.
Commissioning and Verification
After configuration and download, perform the following verification steps to confirm simultaneous multi-axis operation:
- Online > Axis Control Panel: Open the TIA Portal axis control panel for Axis_1. Issue a manual jog command. Verify Q0.0 emits the STEP pulses (use a logic analyzer or oscilloscope on the drive terminal). Issue a manual jog for Axis_2. Verify Q0.1 emits the STEP pulses independently. Confirm both axes can be jogged concurrently without errors.
-
Online > Monitoring: Set a watch table on
"MC_Power_Axis1".Statusand"MC_Power_Axis2".Status. Both must read16#7000("Axis is enabled and ready") when bothEnableinputs are TRUE. Any value other than16#7000indicates a fault. - Online > Diagnostics > Technology Objects: Verify no active alarms on either technology object. The alarm buffer should be empty for a healthy system.
- Hardware verification: Use a digital oscilloscope or frequency counter on Q0.0 and Q0.1. With the axis moving at 5000 pulse/s, the scope should show 5 kHz with a 50% duty cycle. Confirm the two outputs run at independent frequencies and that no crosstalk exists.
- Direction verification: Issue a positive and a negative move on each axis. The DIR output (Q0.4 for Axis_1, Q0.5 for Axis_2) must transition between 0 V and 24 V as commanded. A stuck DIR output indicates a technology object misconfiguration.
- Synchronization test: Trigger both MC_MoveAbsolute blocks simultaneously via a common start input. Verify both axes start motion within 1 scan cycle of each other. Use the on-board trace (TIA V16+) to capture the actual position curves of both axes overlaid for visual inspection.
Troubleshooting Matrix
| Symptom | MC_Power.Status | Root Cause | Resolution |
|---|---|---|---|
| Second axis does not enable; first axis continues to operate | 16#8001 (Axis not enabled) | Shared instance DB between two MC_Power calls | Create a unique instance DB per MC_Power call |
| Both axes enable, but second move command aborts immediately | 16#8401 (Axis disabled during motion) | MC_MoveAbsolute or MC_MoveRelative shares instance DB with another motion FB | Create unique instance DBs for all motion FBs |
| Axis enables but does not move when MC_MoveAbsolute.Execute is pulsed | 16#8001 (Axis not enabled) | Axis is not homed; absolute move is rejected | Call MC_Home and wait for Done before MC_MoveAbsolute |
| Axis moves only at maximum frequency, ignoring velocity parameter | 16#7000 (Enabled) | Velocity exceeds configured maximum | Verify velocity parameter is in pulse/s and below axis max |
| Q0.0 toggles but drive does not move | 16#7000 (Enabled) | Wiring polarity reversed on drive optocoupler; DIR signal stuck at 24V or 0V | Verify drive signal common and pulse polarity per drive manual |
| Axis jogs in only one direction; reverse command is ignored | 16#7000 (Enabled) | DIR output not assigned or assigned to an already-used pin | Reconfigure direction output in the Technology Object's Hardware Output panel |
| Technology object will not compile; "Output already in use" error | N/A (compile-time) | Two axes assigned to the same Q0.x pulse output | Reassign each axis to a unique pulse output pin |
| Axis enables, motion starts, drive fault input trips | 16#8022 (Axis error — drive signal lost) | Drive enable output not wired or drive enable signal polarity reversed | Check Drive enable output wiring and level (active high/low) |
| Position drift over time; axis loses commanded position | 16#7000 (Enabled) | Open-loop stepper system losing steps due to high acceleration or load shock | Reduce acceleration; verify stepper motor sizing vs load inertia |
| MC_Power.Status toggles between 16#7000 and 16#8001 | 16#7000 / 16#8001 alternating | MC_Power instance DB is being overwritten by another scan or FB call | Check for multi-instance DB collisions and parent FB call frequency |
Memory and Performance Considerations
Each instance DB consumes work memory (data area). The S7-1214C has 4 MB of data work memory, of which the user data is shared with all DBs, M memory, and the I/O image. A typical MC_Power instance DB is 80 bytes; MC_MoveAbsolute is 120 bytes; MC_Home is 96 bytes. For a 2-axis system with the full PLCopen FB set, expect approximately 1.5–2 KB of instance DB data. This is trivial for the S7-1214C's 4 MB budget.
For a 4-axis system, double the instance DB count to 30–40. The total instance DB memory rises to 3–4 KB. The technology object configuration data (stored in the CPU's system area) consumes an additional 8–12 KB per axis. The S7-1214C can comfortably support 4 axes at full performance with margin to spare.
CPU scan time impact is minimal: the PTO pulse generation is performed in the FPGA, and the PLCopen FBs execute in the user's OB1. Each MC_Power call requires approximately 50 µs of CPU time. A 2-axis application adds 100 µs per scan. At a typical OB1 cycle of 5 ms, this is 2% additional load — well within budget.
Migration Path to S7-1500 or S7-1200 G2
If the application grows beyond 4 axes, requires higher pulse rates, or needs closed-loop control with encoder feedback, the migration path is:
- S7-1200 G2 (recommended for 5–8 axes, open-loop): The technology object structure and PLCopen FB set are similar to G1, requiring minimal code changes. The instance DB convention remains identical. The CPU 1215G2 (6ES7215-1BG40-0XB0) and CPU 1217G2 (6ES7217-1BG40-0XB0) support 8 PTOs. The motion control firmware is the V21+ generation.
- S7-1500 (recommended for 9+ axes, closed-loop, or high-speed): The S7-1511T, S7-1515T, S7-1516T, and S7-1517T CPUs support 10–40 axes with PROFINET-based drives (SINAMICS V90, S210, S120) or analog/pulse interfaces. The migration from S7-1200 to S7-1500 requires re-creating the technology objects in the new CPU's project and adapting the PLCopen FB call signatures. The basic blocks are identical; the advanced blocks (MC_CamIn, MC_GearIn) are added.
When migrating, re-create the technology objects in the new project — do not copy the G1 technology objects to a G2 or S7-1500 project. The configuration data structures differ, and the cross-project copy may corrupt the axis configuration.
Open-Loop vs Closed-Loop Operation
The S7-1200 G1 PTO is an open-loop pulse generator. The CPU emits the commanded pulse count and assumes the motor reached the commanded position. No feedback path is provided in the S7-1200 G1 architecture. Open-loop operation is acceptable for stepper systems with low-to-moderate load inertia and applications where small position errors (caused by lost steps) are tolerable.
For closed-loop control on a budget, the S7-1200 G2 introduces "drive-internal closed loop" — the technology object connects to a digital drive (e.g., SINAMICS V90 PN) over PROFINET, and the drive handles the closed-loop control internally. The S7-1200 G2 sends a position setpoint and the drive replies with the actual position. This is not available on G1 CPUs.
For full PLC-based closed-loop control with encoder feedback, the S7-1500T CPUs (technology variant) are required. The S7-1500T supports S-curve profiles with jerk limiting, cam profiles, gear synchronization, and advanced motion control features beyond the S7-1200's positioning-only capability.
Frequently Asked Questions
Why does my S7-1214C show "only one axis can be enabled at a time" when I have two PTO channels?
This is a software error, not a hardware limitation. The S7-1214C has four independent PTO hardware channels. The error occurs when two MC_Power function blocks share the same instance data block. Create a unique instance DB for each MC_Power call (e.g., "MC_Power_Axis1" and "MC_Power_Axis2") and re-download the program. The error will clear and both axes will enable simultaneously.
Which S7-1214C variants support PTO pulse train output?
Only the DC/DC/DC variant (order number 6ES7214-1AG40-0XB0) with transistor (source-type) outputs supports PTO. The DC/DC/Relay (6ES7214-1BG40-0XB0) and AC/DC/Relay (6ES7214-1HG40-0XB0) variants have relay outputs that physically cannot generate the high-speed pulse train required for stepper and servo control. The order number's third letter group identifies the output type: "A" for DC/DC/DC, "B" for DC/DC/Relay, "H" for AC/DC/Relay.
What is the maximum number of PTO axes on an S7-1214C?
The S7-1214C (G1 generation) supports up to 4 PTO axes at 100 kHz maximum pulse frequency on the high-speed output pairs Q0.0–Q0.3. The S7-1200 G2 generation (e.g., 6ES7215-1BG40-0XB0, 6ES7217-1BG40-0XB0) supports up to 8 PTO axes with firmware V21 and TIA Portal V18+. The hardware limit on pulse frequency is 100 kHz on S7-1214C and 200 kHz on S7-1200 G2.
Do I need separate instance DBs for every PLCopen motion control block?
Yes. Every call to MC_Power, MC_Home, MC_MoveAbsolute, MC_MoveRelative, MC_MoveVelocity, MC_MoveJog, MC_Halt, MC_Stop, MC_Reset, MC_ReadParameter, and MC_WriteParameter requires a unique instance DB. A 2-axis application typically requires 16–20 instance DBs. TIA Portal will display a compile-time warning if a shared instance is detected: "Instance DB for MC_Power is used multiple times — possible conflict".
Can I run axis 1 at 100 kHz and axis 2 at 20 kHz on the same S7-1214C?
Yes, the PTO channels are independent and each can be configured for any frequency up to its individual maximum. The S7-1214C's Q0.0/Q0.4 pair (PTO1) and Q0.1/Q0.5 pair (PTO2) support up to 100 kHz; the Q0.2/Q0.6 pair (PTO3) and Q0.3/Q0.7 pair (PTO4) also support up to 100 kHz. Configure the maximum frequency per axis in the Technology Object's Drive configuration panel. Each axis has its own runtime velocity parameter, so Axis_1 can run at 80 kHz and Axis_2 at 20 kHz concurrently with no interference.
How do I move two axes simultaneously and trigger them from the same start signal?
Set the Execute input of both MC_MoveAbsolute blocks to the same Boolean tag. With unique instance DBs, both motion commands will be accepted by the technology objects in the same OB1 scan, and both axes will begin accelerating within one scan cycle of each other. The actual motion-start timing depends on the FPGA's PTO scheduling but is typically within 1 ms for two axes on the S7-1214C. Use the TIA Portal trace (V16+) to capture the actual position curves and verify synchronization.