Rockwell Automation Publication 1756-RM003N-EN-P - October 2011 451
Program Control Instructions (JMP, LBL, JSR, RET, SBR, JXR, TND, MCR, UID, UIE, AFI, NOP, EOT, SFP, SFR, EVENT) Chapter 11
Jump to Label (JMP)
Label (LBL)
The JMP and LBL instructions skip portions of ladder logic.
Operands:
Relay Ladder
Description: When enabled, the JMP instruction skips to the referenced LBL instruction and
the controller continues executing from there. When disabled, the JMP
instruction does not affect ladder execution.
The JMP instruction can move ladder execution forward or backward. Jumping
forward to a label saves program scan time by omitting a logic segment until it’s
needed. Jumping backward lets the controller repeat iterations of logic.
Be careful not to jump backward an excessive number of times. The watchdog
timer could time out because the controller never reaches the end of the logic,
which in turn faults the controller.
The LBL instruction is the target of the JMP instruction that has the same label
name. Make sure the LBL instruction is the first instruction on its rung.
A label name must be unique within a routine. The name can include the
following:
· Have as many as 40 characters
· Contain letters, numbers, and underscores (_)
Arithmetic Status Flags: Not affected
Fault Conditions:
Operand Type Format Description
JMP instruction
Label name Label name Enter name for associated LBL instruction
LBL instruction
Label name Label name Execution jumps to LBL instruction with referenced
label name
ATTENTION: Jumped logic is not scanned. Place critical logic
outside the jumped zone.
A major fault will occur if Fault type Fault code
Label does not exist 4 42