Common Functions

This guide describes the functions commonly used in AB PLC ladder diagrams, as shown in the following table.

Ladder diagram Function Description
basic command 1

Latch (OTL)

When the rung condition is True, the OTL function sets data_bit to True. data_bit remains true until it is cleared, typically by an Output Unlatch (OTU) function.

When the rung condition is changed to False, the OTL function does not change the status of data_bit.

basic command 2

Unlatch (OTU)

When the rung condition is True, the OTU function sets data_bit to False.

When the rung condition is changed to False, the OTU function does not change the status of data_bit.

basic command 3

Examine On (XIC)

If data_bit is set to True, the rung output condition is set to True.

If data_bit is set to False, the rung output condition is set to False.

basic command 4

Examine Off (XIO)

If data_bit is set to True, the rung output condition is set to False.

If data_bit is set to False, the rung output condition is set to True.

basic command 5

One Shot (ONS)

Make the remainder of the rung True each time the rung input condition transitions from False to True.

basic command 6

Move (MOV)

Move the copy of the source to the destination. The source remains unchanged.

basic command 7

Equal to (EQU)

If Source A and Source B are numbers, and Source A equals Source B, set the rung output condition to True; otherwise, set the rung output condition to False.

basic command 8

Not Equal to (NEQ)

If Source A or Source B is not a number (NAN), or Source A does not equal Source B, set the rung output condition to True; otherwise, set the rung output condition to False.

basic command 9

Greater than or Equal to (GEQ)

If Source A and Source B are numbers, and Source A is greater than or equal to Source B, set the rung output condition to True; otherwise, set the rung output condition to False.

basic command 10

Less than or Equal to (LEQ)

If Source A and Source B are numbers, and Source A is less than or equal to Source B, set the rung output condition to True; otherwise, set the rung output condition to False.

basic command 11

Timer On Delay (TON)

Start accumulating time when it is enabled, until the timer is disabled or the timer completes.
The time base is always 1 millisecond. For example, for a 2-second timer, the Preset value should be 2000.
When the timer completes, the DN bit is set to True.
Once the timer is enabled, setting the DN bit to True pauses the timer; setting the DN bit to False resumes the timer.

basic command 12

Addition (ADD)

If the rung input condition is True, the destination equals Source A plus Source B.

We Value Your Privacy

We use cookies to provide you with the best possible experience on our website. By continuing to use the site, you acknowledge that you agree to the use of cookies. If you decline, a single cookie will be used to ensure you're not tracked or remembered when you visit this website.