Program control (output instruction)
MCR: Master Control Reset
Opens a zone whose non-retentive outputs are driven false when the zone is off.
Also called: master control relay, MCR zone, master control.
MCR()What it does
MCR instructions work in pairs. The first one opens a zone and the condition on its rung is the zone's condition; the second closes it. While the zone is off, every output inside it is scanned as though its rung had no power, so all of them de-energise together.
It saves adding the same permissive contact to twenty rungs, and it means one place to change when that condition changes. A zone belongs to the routine it is written in and does not carry over into another one.
It only de-energises the instructions that are non-retentive. An OTE inside a false zone goes off, because an OTE simply follows its rung. A latch does not: OTL and OTU hold, because holding is exactly what a latch is for, and a retentive timer keeps its accumulated time. That difference is the point of retentive instructions, and it is also the way an MCR zone surprises people.
Read the name carefully. It comes from the hardwired master control relay of a real panel, and the instruction is not that relay. It is program logic, and it is worth being clear about why that matters.
A rung you can run
One condition switching a whole block of outputs
XIC(Zone_Enable)MCR()
XIC(Lamp_1_Cmd)OTE(Zone_Lamp_1)
XIC(Lamp_2_Cmd)OTE(Zone_Lamp_2)
XIC(Latch_Cmd)OTL(Zone_Latch)
MCR()
XIC(Lamp_3_Cmd)OTE(Outside_Lamp)With Zone_Enable on, all four rungs behave normally. Latch Zone_Latch, light both zone lamps, then turn Zone_Enable off: both lamps go out at once even though their own commands are still on, the latch stays latched, and the lamp below the closing MCR carries on taking no notice. That is the whole behaviour in one program.
Run this rung in the simulatorWhat it is called on other controllers
| Platform | Equivalent |
|---|---|
| Rockwell (Studio 5000) | MCR, used as a pair of rungs around a zone |
| Siemens (TIA Portal) | MCR zone instructions |
| Mitsubishi (GX Works) | MC and MCR |
| CODESYS and IEC 61131-3 | No direct equivalent: an enclosing IF, or an enable on the block |
Common mistakes
- Treating it as a safety function. It is not one and it must never be used as one. A master control relay in a panel is a hardwired contactor that removes power from the output devices, and it keeps working when the processor faults, when the scan stops, and when an output card fails on. An MCR instruction is a line of code that only works while the program is running normally, which is precisely the condition you cannot assume during an emergency. Emergency stops belong in a hardwired safety circuit with a rated safety relay, and no instruction on this page substitutes for it.
- Forgetting the closing MCR, or nesting zones. The zone then runs to the end of the routine, taking in rungs nobody intended to put inside it, and it is invisible because the rungs still look ordinary.
- Expecting latches to drop out. OTL and RTO hold their state inside a false zone. If something latched must be cleared when the zone goes off, unlatch it explicitly on a rung outside.
Practise it
Interactive exercises that use MCR. Each one checks your ladder against a real scan.
