BillRobinson
Member
I'm looking through a piece of ladder code put out by Allen Bradley and it's got NOP's all over the place. Is this just left over code from debugging or does is actually do anything in a ladder code?
The NOP is also handy when you want to pass parameters into a subroutine but don't want to have to hang output logic on the end of the first rung after the SBR instruction.
If I'm planning a big change that must be done online, I will use NOPs as place markers. Otherwise passing parameters to subroutines is the only real use I can think of
Why use NOPs as place markers ?
Why not create a BOOL tag called TWControls or your name, put a rung at the bebinning of the code to OTU that tag, and use it as a AFI (use XIC) or AFT (use XIO). You can always cross-reference them instead of having to search for NOPs. And what if someone else puts a NOP in the code ???
...what if someone deleted the OTU rung......