Handling Aborted and Stopped SFC Phases in SIMATIC BATCH Without Recipe Blocking
In SIMATIC BATCH, when an active SFC phase is aborted or stopped via LOCKABORT or LOCKSTOP, the recipe operation (ROP) halts execution because the batch engine treats the abnormal phase termination as a blocking condition to prevent hazardous out-of-sequence processing. To allow the recipe to automatically advance to subsequent steps without requiring manual operator intervention in BatchCC: 1. Use LOCKCOMPLETE instead of LOCKABORT during controlled abort sequences, signaling successful phase termination while setting an internal fault flag; 2. Configure alternative transition branches in the recipe that evaluate the phase completion status; or 3. Utilize an automated AS command block or SIMATIC BATCH API routine to automatically acknowledge and reset the aborted phase step.
Table of Contents
- Executive Summary
- Architecture and Fundamental Mechanics
- Step-by-Step Implementation Procedure
- Verification
- Limitations and Operational Precautions
- Engineer FAQ
- Technical References
- Related Articles
- Related Tags
Executive Summary
In complex batch process plants running SIMATIC BATCH V8.2 or V9.0, automated equipment phases governed by SFC Types frequently encounter operational interruptions such as interlock trips, operator aborts, or vessel drainage holds. When an engineer asserts LOCKABORT or LOCKSTOP at the SFC-type interface in CFC, the phase transitions immediately to the Aborted or Stopped state. However, from the perspective of the SIMATIC BATCH recipe execution engine, this abnormal termination causes the parent Recipe Operation (ROP) to halt with the diagnostic message 'a sub-object is blocking'. The recipe freezes, requiring manual operator intervention in BatchCC to reset the step. This article analyzes the ISA-88 state machine within SIMATIC BATCH, explains why abnormal phase termination blocks recipe execution, and provides three proven engineering designs to achieve automated error recovery and continuous recipe progression.
Architecture and Fundamental Mechanics
SIMATIC BATCH State Machine, SFC Type Interface Pins, and Recipe Progression Mechanics:
- ISA-88 / NAMUR NE 33 State Architecture in SIMATIC BATCH:
- SIMATIC BATCH coordinates recipe execution through sequential function charts according to ISA-88 state models.
- In a normal recipe lifecycle, a recipe phase step (RPH) transitions:
Ready -> Starting -> Running -> Completing -> Completed. - When a phase reaches the
Completedstate, the BATCH engine satisfies the step condition and evaluates the downstream transition. -
However, if the phase terminates abnormally via
Aborting -> AbortedorStopping -> Stopped, the BATCH engine treats this as an unhandled fault. To protect plant safety and batch integrity, the recipe engine enters a blocked state (Sub-object blocking) and refuses to advance automatically. -
SFC Interface Control Inputs (
LOCKABORT,LOCKSTOP,LOCKCOMPLETE): LOCKABORT: Forces the SFC phase directly into theAbortingsequence, culminating inAborted. This signals a severe fault and locks the BATCH recipe step.LOCKSTOP: Drives the phase intoStopping->Stopped.LOCKCOMPLETE: Instructs the SFC phase to execute its normalCompletinglogic and enterCompleted.-
The Held State Dilemma: If an SFC phase is currently in the
Heldstate due to an interlock or pause command, assertingLOCKCOMPLETEdirectly is ignored by standard SFC runtime logic because an SFC cannot jump directly fromHeldtoCompletingwithout first passing throughResuming. -
Design Pattern 1: Controlled Abort Sequence via
LOCKCOMPLETEwith Status Flag: - Instead of abruptly pulsing
LOCKABORT, the AS control logic triggers a controlled cleanup sequence in the SFC abort logic. - If the phase is in
Held, the logic assertsRESUMEfollowed by a transition to a dedicated 'Fault Completed' branch. - The SFC asserts an output parameter
FaultStatus = TRUEand pulsesLOCKCOMPLETE. -
Because the phase finishes in
Completed, SIMATIC BATCH does NOT block the recipe. The recipe transition evaluatesFaultStatusand branches cleanly to an emergency drainage or cleanup ROP. -
Design Pattern 2: AS Command Block / Batch API Auto-Reset:
- If
LOCKABORTmust be retained for safety compliance, an automated supervisory block in CFC detectsQSTATE = Aborted. - The supervisory block issues an automated step reset command via the SIMATIC BATCH communication interface, clearing the sub-object blocking condition in BatchCC and permitting recipe branch evaluation.
Step-by-Step Implementation Procedure
-
Implement Controlled Fault Handling in the SFC Type:
* In SIMATIC Manager, open the Master Data Library and open the target SFC Type.
* Add an output parameter:PhaseFaulted(BOOL).
* In theAbortingorStoppingsequence of the SFC Type, insert logic to de-energize actuators (close valves, stop agitator).
* In the final step of the abort logic, setPhaseFaulted = TRUE.
* If transitioning via controlled completion, configure the transition out of the abort handler to triggerLOCKCOMPLETEso the phase finishes with stateCompleted. -
Handle the 'Held' State Transition Logic:
* In the CFC chart hosting the SFC instance, inspect the hold condition logic.
* Ensure that an abort request while inHeldtriggers an automatic pulse onRESUME_Iprior to commanding the termination sequence, allowing the state machine to transition throughResuming. -
Configure Alternative Branches in SIMATIC BATCH Recipe Editor:
* Open the master recipe in SIMATIC BATCH Recipe Editor.
* Immediately following the Recipe Operation (ROP) containing the phase, create an Alternative Branch.
* Branch A (Normal Path): Configure transition conditionPhaseFaulted = FALSE.
* Branch B (Fault Recovery Path): Configure transition conditionPhaseFaulted = TRUE.
* In Branch B, place the appropriate recovery operations (e.g. Vessel Flush, Material Reject, or Safe Park).
* Validate the recipe and release it for production in BatchCC. -
Deploy Automated Step Reset Logic (Alternative for True LOCKABORT):
* If pureLOCKABORTmust be retained, instantiate an SFC Command block or Industry Library coordination block in CFC.
* Monitor the phase state parameterBA_STATE.
* WhenBA_STATE = 7(Aborted), assert a timed one-shot reset command to the BATCH communication channel to clear the block.
Verification
- In SIMATIC BATCH, create and start a test batch using the updated master recipe.
- In CFC test mode, simulate a fault condition that triggers the abort sequence on the active SFC phase.
- Verify that the SFC executes its abort logic, sets
PhaseFaulted = TRUE, and cleanly transitions toCompleted. - Verify in the BatchCC Control Recipe View that the recipe does NOT enter the 'Sub-object blocking' state.
- Verify that SIMATIC BATCH automatically selects Branch B (Fault Recovery) and begins executing the recovery operation.
Limitations and Operational Precautions
Transitioning an SFC phase to Completed via LOCKCOMPLETE following an abnormal termination must be carefully documented in validated pharmaceutical and chemical processes (GMP/FDA CFR 21 Part 11). The batch electronic record will list the phase as completed, so the output parameter PhaseFaulted and audit trail comments must clearly record that an abort condition occurred. Direct API manipulation requires appropriate SIMATIC BATCH API licensing.
Engineer FAQ
Why does SIMATIC BATCH say 'a sub-object is blocking' when an SFC aborts?
Because the recipe engine expects the phase to reach the Completed state. An abnormal end (Aborted or Stopped) is treated as a safety fault that halts automated recipe progression.
Can LOCKCOMPLETE be triggered directly while an SFC is Held?
No. The standard SFC state machine requires an SFC in Held to transition through Resuming before it can enter Completing.
What is the cleanest way to automate recovery after an abort?
Execute safe shutdown actions within the SFC abort sequence, assert an output flag PhaseFaulted = TRUE, complete the phase via LOCKCOMPLETE, and use alternative transition branching in the recipe.
Does an aborted phase automatically release allocated equipment?
No, allocated equipment remains locked to the active batch until the recipe operation finishes or an explicit deallocation occurs.
Can recipe transitions read SFC output parameters?
Yes, any output parameter defined on an SFC Type and configured as an OCM/Batch attribute can be evaluated in recipe transitions.
Technical References
- SIMATIC BATCH V8.2 Operating Manual
- SIMATIC PCS 7 SFC for SIMATIC S7 V8.2 Function Manual
- NAMUR NE 33 / ISA-88 Batch Control Standards Guide
Related Articles
- Terminating and Deleting Blocked Control Recipes in SIMATIC BATCH when SFC Phases Hang
- Controlling BatchCC Recipe Start Execution and Verifying SFC Preconditions in SIMATIC BATCH
- Configuring Operator Step Transitions and Step Control Modes in PCS 7 SFC Types (Auto vs Manual Constraints)
- Transmitting Batch Recipe Start and Complete Status Bits Between SIMATIC BATCH and PCS 7 Controllers
Related Tags
- SIMATIC BATCH
- SFC Type
- LOCKABORT
- LOCKSTOP
- LOCKCOMPLETE
- Recipe Blocking
- BatchCC
- ISA-88