simple logic question

Skidood

Member
Join Date
Oct 2016
Location
Ontario
Posts
215
Hello again..trying something on an existing poorly written program and just wanted to double check something
system is an A-B MicroLogix 1200
In the ladder below, if Input B is not ON, and Input A is ON, will the coil still energize?

20240422_162311.jpg
 
no, the coil value is upated for each rung. the 2nd rung sets the coil to false.

the 1200 updates outputs at the end of scan, so it will never energize, even momentarily
 
as stated above.


just try to imagine, or even toggle offline in any program that does updates, and becomes the logic yourself. Scan top to bottom, left to right.

Input A is false -> Coil A = Low
Input B is False -> Coil A= Low
Send data to keep coil A low


next scan

Input A is true -> Coil A = high
Input B is false -> Coil A = Low
Send data to keep Coil A low as the last received information was Coil A = Low


Next scan

Input A is false -> Coil A = low
Input B is True -> Coil A = High
Send data to put Coil A High as the last received information was Coil A = High



when read top to bottom, left to right the last read state of the logic for that coil will be what is done. There are instances where a (L) can be in multiple places, and that's where you can fall into some intermittent output issues, but an OTE is a one time use, any instance of the coil before the last one scanned mean nothing in the final decision.
 
The OTE coil instruction is fairly unique in that it does something when it is true, AND does something when it is false. Most output instructions take an action when they are true and then do nothing when they are false. As Cheeseface mentions, the physical outputs update at the end of the scan so if you have two rungs attempting to control the same output using OTE instructions, the "last one wins"

Because of this, Input_B will always control the physical output Coil_A. The first rung might as well be deleted as it will never affect the physical output. If Input_B is open, the output is turned off. If Input_B is closed, then the output energizes. The first rung never controls the physical output.

This isn't "illegal" in the code, so the software will not prevent it. It just won't work as you expect it to.

OG
 
Ron Beaufort had the easiest explanation for an OTE. It simply writes a 1 to the tag when the preceding rung is true, and writes a 0 to the tag when the rung is false. Has nothing to do with physically turning an output on. Only when the tag is evaluated during the IO update will it actually do anything to the physical output. At that point the value in tag is written to the physical output.

Note, the IO update in the micro logix is at the end of the ladder scan. However there are instances like immediate IO, or in a Control Logix where the IO is updated asynchronous to the scan. For that reason, if you want to enforce the sequential IO update, map in logic real world IO to intermediate tags, and use the intermediate tags in all your logic. This also aids in using repetitive code from PLC to PLC where the logic may be the same, but the physical IO configuration is different.
 

Similar Topics

Could someone explain why on the first screen the highlighted Output_1 is not energized while on the other it is? My understanding would be that...
Replies
21
Views
5,980
I am new to PLC programming and recently purchased a demo unit for a WAGO 750-881. I am trying to do a simple test in ladder logic that does the...
Replies
1
Views
2,300
RUNG 1 : [A]-----(B) RUNG 2 : [B\]----[A\]-----(C) RUNG 3: [C]-----(DLatch) RUNG 4...
Replies
35
Views
15,211
Hi all, I'm new to the forum and novice at ladder logic programming so bare with me. Quite simply, I need help converting a normally closed...
Replies
12
Views
9,965
Hello, I´m having a problem trying to program in Ladder. An output should be trigged by two possible contacts. Take a look on the printscreen...
Replies
5
Views
165
Back
Top Bottom