XIO and XIC... and variations thereof...

Terry Woods

Member
Join Date
Apr 2002
Posts
3,170
This is a long, double-post explanation of XIO and XIC. It goes through the full derivation of the concept and ultimately ends with a "cut-to-the-chase" short cut. So, if you don't have the patience, go to the end of Post #2. Otherwise, it would be worthwhile to find out what "they" were thinking and how it all came to be as it is.

XIO... XIC... What an incredibly dumb idea that was!

XIO...
When viewed by itself, this acronym is ambiguous...

"Examine If ON"?
"Examine If OFF"?
"Examine if OPEN"?

Only when both of the complimentary acronyms are known, does the meaning become apparent... sort of...

XIC can only mean "Examine If Closed"

Since XIO and XIC are supposed to be opposites...
if XIC means "Examine If Closed" then...
XIO, the opposite of XIC, must mean "Examine If Open".

OK... so the literal meanings of the acronyms, XIO and XIC, are understood.

Now... what is the practical meaning of those acronyms, or, for that matter, what is the practical meaning of the literal translations?

I won't even go into what symbols represent XIO and XIC; it only causes confusion.

Let's just jump into the concept. The concept involves the state of a particular, "imaginary", double-throw relay.

In their infinite wisdom, the originators of the XIO/XIC scheme envisioned the acronyms being applied to the state of a pair of contacts in an imaginary, single-pole, double-throw relay. In this kind of relay, there are two outputs. One output comes from the normally closed contact (--|/|--), the other from the normally open contact (--| |--).

If we assume that the common terminal is always Hot (ON), then, when the relay is OFF, the output from the normally closed contact (--|/|--) is Hot (ON). The output from the normally open contact (--| |--) is Not-Hot (OFF).

When the relay is ON, the ouput from the normally closed contact (--|/|--) is Not-Hot (OFF) and the output from the normally open contact (--| |--) is Hot (ON).

Now... looking at it a bit backwards, it can be seen that, if the normally closed contact (--|/|--) is Hot, then the relay must be OFF. If the normally open contact (--| |--) is Hot, then the relay must be ON.

Ultimately, the purpose in this madness is to determine the state of the signal that controls the relay. That is...
Is the signal to the relay ON, or...
Is the signal to the relay OFF.

So now... how is the state of that signal ascertained?

The scheme says that you can determine the state of the signal to the relay by "examining" the state of the output signals from the contacts.

Now remember,...

...if the relay is OFF...
the normally closed contact (--|/|--) is Hot (ON), and the normally open contact (--| |--) is Not-Hot (OFF).

...if the relay is ON...
the normally closed contact (--|/|--) is Not-Hot (OFF), and the normally open contact (--| |--) is Hot (ON).

It should be immediately apparent that the state of the relay signal can be determined by "seeing" the ON/OFF state of either contact... as long as you know which contact you are looking at.

That is...
...if the normally open contact (--| |--) is Not-Hot (OFF) then the relay signal is OFF.
...if the normally open contact (--| |--) is Hot (ON) then the relay signal is ON.

On the other hand...
...if the normally closed contact (--|/|--) is Hot (ON) then the relay signal is OFF.
...if the normally closed contact (--|/|--) is Not-Hot (OFF) then the relay signal is ON.

Basic Electrical Wiring, using normal relay logic, requires a "hot path" from the left rail (HOT) to the output in order to turn on the output.

Relay
N.C. <-- "Normally Closed"
Contact
--|/|-------( ) Indicator Light #1 (Relay is OFF)


.
In the example above, if the relay is OFF then the output from the normally closed contact is Hot (ON); the output will turn ON.

Relay
N.O. <-- "Normally Open"
Contact
--| |-------( ) Indicator Light #2 (Relay is ON)


.
In this example, if the relay is ON then the output from the normally open contact is Hot (ON); the output will turn ON.

In the first example, if Indicator Light #1 goes ON then it can do so only because the normally closed contact is Hot (ON). If the normally closed contact is Hot (ON) then that can only be because the relay is OFF.

In the second example, if Indicator Light #2 goes ON then it can do so only because the normally open contact is Hot (ON). If the normally open contact is Hot (ON) then that can only be because the relay is ON.

Indicator Light #1 will go ON only if the relay is OFF. Indicator Light #2 will go ON only if the relay is ON.

That is...
If the relay is OFF, then Indicator Light #1 will be ON and Indicator Light #2 will be OFF.
If the relay is ON, then Indicator Light #1 will be OFF and Indicator Light #2 will be ON.

Now here are a couple of interesting things to notice...

First, in the examples above, the contacts controlling the lights have two different names...
The first is called "Relay N.O. Contact" and the second is called "Relay N.C. Contact".

It should be clear to see that power to the lights is being controlled by two separate entities, namely, a normally open contact and a normally closed contact. Even though these two contacts are within the same relay, they are in fact, two separate signals. Each signal is used to drive a particular output. Each signal "asserts" a particular status. That is, when the signal from the normally closed contact is Hot (ON) then the signal causes Indicator Light #1 to turn ON thus asserting that the relay is OFF. When the signal from the normally open contact is Hot (ON) then the signal causes Indicator Light #2 to turn ON thus asserting that the relay is ON.

Second, since the ultimate aim of the scheme is to determine the state of the relay, is it not apparent that the state of the relay can be determined by monitoring the status of only one of the contacts?

That is, because the results are mutually exclusive... both signals can not be Hot (ON) at the same time.
...if the normally open contact is Hot (ON) then the relay must be ON.
...if the normally open contact is Not-Hot (OFF) then the relay must be OFF.

...if the normally closed contact is Hot (ON) then the relay must be OFF.
...if the normally closed contact is Not-Hot (OFF) then the relay must be ON.

Notice that the state of the relay can be determined by examining the status of only one of the contacts.

If we choose to use the contact that provides the "positive" indication then we would choose the normally open contact. If the normally open contact is Not-Hot (OFF) then the relay is OFF. If the normally open contact is Hot (ON) then the relay is ON. The state of the contact signal corresponds directly to the state of the relay.

We can determine the state of the relay simply by examining the state of the normally open contact.

So, in general terms, we can say if the state of the normally open contact is Hot (ON) then the state of the relay is ON and thus we turn ON the output that indicates that the relay is ON. This is a "positive" assertion; that is, the signal to the relay is ON.

On the other hand, if the state of the normally open contact is Not-Hot (OFF) then the state of the relay is OFF and thus DO NOT turn ON the output that indicates that the relay is ON. This too is a "positive" assertion; except, in this case, the assertion is that the relay is NOT ON, i.e, the relay is OFF.

So....

Let's say that you need to know the state of the relay in order to control something... a motor, a valve, whatever.

If the relay is ON, then turn ON a valve. If the relay is OFF, then turn ON a Light.

In terms of the valve, it is simple to examine the state of the normally open contact.

Relay
N.O. <-- "Normally Open"
Contact
--| |-------( ) Push Valve


.
If the normally open contact is Hot (ON), then the relay is ON and so turn ON the Push Valve, otherwise, DO NOT turn ON the Push Valve.

Now... let's say we have a Light that indictaes that the relay is OFF. How do we control the light?

CONTINUED in Post #2
 
XIO and XIC...

CONTINUED from Post #1

The intent is...
If the normally open contact is Not-Hot (OFF), then turn ON the light, otherwise, DO NOT turn ON the light.

How do we construct that control? We have already decided that we are only going to monitor the status of the normally open contact to make our determinations. So how can we use the normally open contact to ascertain that the contact is Not-Hot (OFF)?

Think "International Symbols". International symbols are designed to impart the concept pictorially. That is, in those areas where farting is not allowed, there are signs that show a butt with a plume of gas expelling from the brown-eye. There is a circle (usually red) around the whole image. Then there is a diagonal slash through the circle from upper-right to lower-left. The slash indicates "NOT" as in, Not Allowed or Not Permitted.

Let's apply that model to the logic.

Relay
N.O. <-- "Normally Open"
Contact
--|/|-------( ) Light


.
This says... if the normally open contact is NOT ON, then turn ON the light!

Hmmm... that was simple... wasn't it? But hang on... there's more...

Since we are only examining the state of the normally open contact to determine the state of the relay we can dispel with the "N.O." in the name of the contact. We can simply say, if the "Relay Contact is ON" (--| |--), or if the "Relay Contact is OFF" (--|/|--), then do such-n-such.

Relay
Contact
--| |-------( ) Push Valve

While the N.O. Relay Contact IS ON, turn ON the Push Valve.

Relay
Contact
--|/|-------( ) Light

While the N.O. Relay Contact is NOT ON, turn ON the Light. This means, "Part is NOT present".


.
Hang on... there's still more...

Since the relay is controlled by something... a switch, a limit switch, a photo-eye... whatever, we can eliminate all references to that damned, convoluted imaginary relay, and go "straight to the horse's mouth"... that is, since the state of the relay indicates the state of L.S. #1...

L.S.#1
--| |-------( ) Push Valve

While L.S. #1 IS ON, then turn ON the Push Valve. This means, Part is present, so "Push the Part".

L.S.#1
--|/|-------( ) Light

While L.S. #1 is NOTON, then turn ON the Light. This means, "Part is NOT present"!


.
Yeah... hang on... there's even more...

Since the state of L.S. #1 indicates something, the name of the bit that represents the state of L.S. #1 should indicate what that "something" is... for example, if L.S. #1 indicates the presence of a part at a particular location then the name of the bit should indicate so, as in...

Part is at
Push Location
(L.S.#1)
--| |-------( ) Push Valve

While a part IS present at the Part Push Location (L.S. #1 IS ON, turn ON the Push Valve.

Part is at
Push Location
(L.S.#1)
--|/|-------( ) Light

While a part is NOT present (L.S. #1 is NOT ON) at the Part Push Location, turn ON the Light... this means, the "Push Location is Empy".


.
Now we come full circle....

Part is in
Push Location
(L.S.#1)
--| |-------( ) Push Valve

If a part IS present at the Part Push Location, then turn ON the Push Valve.
If a part is NOT present at the Push Location, then DO NOT turn ON the Push Valve (turn Push Valve OFF).

Part is in
Push Location
(L.S.#1)
--|/|-------( ) Light

If a part is NOT present at the Part Push Location, turn ON the Light.
If a part IS present at the Push Location, then DO NOT turn ON the Light.


.
If the particular Input is ON then turn ON the Output.
If the particular Input is OFF then turn OFF the Output.


So... Bottom Line....

(--| |--) asks... is the "appropriately" named condition TRUE?

(--|/|--) asks... is the "appropriately" named condition FALSE?

If the answer is "YES", then power flow proceeds through that portion of the rung.

If the answer is "NO", then power flow stops through that portion of the rung.
 
Nice in depth post Terry.

I think most of the confusion arises because electrical people arriving at ladder LOGIC tend to make the mistake that the rung statement correlates directly with the flow of ELECTRICTY in a hard-wired circuit.

In fact a ladder statement correlates with:

"The flow of LOGICAL truth".

Electrical logic has the limitation that only a closed contact can convey electricity. By contrast PLC logic works in the abstract and does not have this physical limitation. This means that either the "0" OR the "1" condition can be considered to convey logical truth. This just falls out of fundamental Boolean logic.

In a nutshell I used to teach my PLC classes that ladder rungs were all about the flow of logical truth. I would discourage them very much from thinking in electrical analogs. Once they got this and Boolean basics, they immediately became more confident and creative programmers.
 
PhilipW said:
Nice in depth post Terry.

I think most of the confusion arises because electrical people arriving at ladder LOGIC tend to make the mistake that the rung statement correlates directly with the flow of ELECTRICTY in a hard-wired circuit.

I don't understand.
Why is the flow of electricity not a logical analogy for how a ladder rung functions?


Pardon my ignorance, but I'm an EE, with a computer engineering background, so this is all second nature to me. I have a hard time seeing where people get mixed up.
 
Because this ---|/|--- used with a N.C. switch will be true when the switch is open. In hardwiring any contact would have to be made for power to flow.

Programming can use a physical switch/contacts on or off...ie there doesnt have to be elctron flow thru the device for the condition to be true/on.

First time I saw a N.O pushbutton used for a STOP button drove me nuts, I thought someone had installed the wrong contacts. The system was designed that way using a plc. Everyone I come across nowadays I change the programming and the switch, just too confusing for alot of people.

There is a classic example...using a N.C. pushbutton as a STOP would use ---| |--- that in the ladder...ie examine if ON, the STOP button should always be on just like in a hardwired circuit.

Hardwired contacts and plc contacts are 2 different animals.

Terry's eloquent post explained all that in detail.
Terry,
You told me once I could use anything you wrote as long as I didnt "sell it", hopefully that still stands and I can use this at the other place.
 
Last edited:
XIO XIC - CONFUSION - CLARIFY - THANKS

MANY THANKS to Terry Woods for explaining history of XIC and XIO.

I am just learning PLCs and I have
1. Found this very confusing
2. STILL confusing
3. Can be dangerous if wrong instruction is used.
4. Will always test to ensure I got it right.
5. After I do this a couple hundred times maybe I will get lucky and it will be second nature.

I am trying to restrict it to something simple - starting with is there voltage on the input? Gonna take time and experience.

Dan Bentler
 
Ron,

Of course you can.

BTW, I didn't say you can't sell what I post... I said you can't sell it unless I get my cut... that is, after you started making some money at your site (gee, that was a couple of years ago... are we making any money yet?).

Hmmm, yeah, well... I guess that means you can't sell it. (Hmmm, is there a Catch-22 in there somewhere?)

Before you grab it though... I need to rework the second post.
 
Last edited:
CONTINUED from Post #1

The intent is...
If the normally open contact is Not-Hot (OFF), then turn ON the light, otherwise, DO NOT turn ON the light.

How do we construct that control? We have already decided that we are only going to monitor the status of the normally open contact to make our determinations. So how can we use the normally open contact to ascertain that the contact is Not-Hot (OFF)?

Think "International Symbols". International symbols are designed to impart the concept pictorially. That is, in those areas where farting is not allowed, there are signs that show a butt with a plume of gas expelling from the brown-eye. There is a circle (usually red) around the whole image. Then there is a diagonal slash through the circle from upper-right to lower-left. The slash indicates "NOT" as in, Not Allowed or Not Permitted.

Let's apply that model to the logic.

Relay
N.O. <-- "Normally Open"
Contact
--|/|-------( ) Light


.
This says... if the normally open contact is NOT ON, then turn ON the light!

Hmmm... that was simple... wasn't it? But hang on... there's more...

Since we are only examining the state of the normally open contact to determine the state of the relay we can dispel with the "N.O." in the name of the contact. We can simply say, if the "Relay Contact is ON" (--| |--), or if the "Relay Contact is OFF" (--|/|--), then do such-n-such.

Relay
Contact
--| |-------( ) Push Valve


.
While the N.O. Relay Contact IS ON, turn ON the Push Valve.

Relay
Contact
--|/|-------( ) Light


.
While the N.O. Relay Contact is NOT ON, turn ON the Light. This means, "Part is NOT present".

Hang on... there's still more...

Since the relay is controlled by something... a switch, a limit switch, a photo-eye... whatever, we can eliminate all references to that damned, convoluted imaginary relay, and go "straight to the horse's mouth"... that is, since the state of the relay indicates the state of L.S. #1...

L.S.#1
--| |-------( ) Push Valve


.
While L.S. #1 IS ON, then turn ON the Push Valve.

L.S.#1
--|/|-------( ) Light


.
While L.S. #1 is NOTON, then turn ON the Light.

Yeah... hang on... there's even more...

Since the state of L.S. #1 indicates something, the name of the bit that represents the state of L.S. #1 should indicate what that "something" is... for example, if L.S. #1 indicates the presence of a part at a particular location then the name of the bit should indicate so, as in...

Part is at
Push Location
(L.S.#1)
--| |-------( ) Push Valve


.
While a part IS present at the Part Push Location (L.S. #1 IS ON), turn ON the Push Valve.

Part is at
Push Location
(L.S.#1)
--|/|-------( ) Light


.
While a part is NOT present at the Part Push Location (L.S. #1 is NOT ON), turn ON the Light... this means, the "Push Location is Empy".

Now we come full circle....

Part is in
Push Location
(L.S.#1)
--| |-------( ) Push Valve


.
If a part IS present at the Part Push Location, then turn ON the Push Valve.
If a part is NOT present at the Push Location, then DO NOT turn ON the Push Valve (turn the Push Valve OFF).

Part is in
Push Location
(L.S.#1)
--|/|-------( ) Light


.
If a part is NOT present at the Part Push Location, turn ON the Light.
If a part IS present at the Push Location, then DO NOT turn ON the Light (turn the Light OFF).


So... Bottom Line....

--| |-- asks... is the "appropriately" named condition TRUE?

--|/|-- asks... is the "appropriately" named condition FALSE?

If the answer, to either question, is "YES", then power flow proceeds through that portion of the rung.

If the answer, to either question, is "NO", then power flow stops through that portion of the rung.



Positive logic asserts a named condition with the presence of a "1". That is, if the named condition is True then the signal is ON, or "1". If the named condition is NOT True then the signal is OFF, or "0".

So... Bottom, Bottom Line....

--| |-- asks... is the value of the named condition "1"?

--|/|-- asks... is the value of the named condition "0"?

Again, if the answer, to either question, is "YES", then power flow proceeds through that portion of the rung.

And again, if the answer, to either question, is "NO", then power flow stops through that portion of the rung.


If the value of the bit named "Part is in Push Location (L.S. #1)" is "1" then a part is indeed at the push location. Since a part is at the push location, turn ON the Push Valve (and leave the Light OFF).

If the value of the bit named "Part is in Push Location (L.S. #1)" is "0" then a part is NOT at the push location. Since a part is NOT at the push location, turn ON the Light (and leave the Push Valve OFF).
 
Thanks Philip,

You are quite correct in saying "...most of the confusion arises because electrical people arriving at ladder LOGIC tend to make the mistake that the rung statement correlates directly with the flow of ELECTRICTY in a hard-wired circuit."

I had a go-around a few years ago with some folks that thought that anyone that could read an electrical schematic could create logic in a PLC.

The key, of course, as Ron explained, is that "signal is not present" is as valid a reason for passing power as "signal is present". Some would say, well, that is the purpose of the imaginary relay! But then, it seems, you are looking at the state of two separate... thingees. And then things really get crazy when you throw in a real limit switch that is wired through both the normally open and the normally closed contacts.

Dan...
I can appreciate your pain.

This might help...

Use Positive Logic whenever possible and reasonable to do so.
The name of an input should indicate the condition that exists when the input signal is present.


LS1 LS2
[ ] [ ]
/+-----+ |
|Table|
+-----+


.
This figure shows the Table at the fully retracted position. Using positive logic, LS1 is wired through the normally open contacts. Again using positive logic, when the Table is at LS1, the output from the switch is ON. This means that the input to the PLC is ON. If the LS1 input is ON, the Table is retracted.

Renaming the Limit Switch inputs to indicate the particular conditions...

Table is Table is
Retracted Extended
(LS1) (LS2)
[ ] [ ]
/+-----+ |
|Table|
+-----+

Table is
Retracted
(LS1)
---| |----------( ) Indicator Light, Table is Retracted
THIS INDICATOR IS ON!!!
Table is
Extended
(LS2)
---| |----------( ) Indicator Light, Table is Extended
THIS INDICATOR IS OFF!!!


.
Now, the Table is sent to the other extreme (extended). Before it arrives at LS2, the Table must first leave LS1.

Table is Table is
Retracted Extended
(LS1) (LS2)
[ ] [ ]
| +-----+ |
|Table|-->
+-----+

Table is
Retracted
(LS1)
---| |----------( ) Indicator Light, Table is Retracted
THIS INDICATOR IS OFF!!!
Table is
Extended
(LS2)
---| |----------( ) Indicator Light, Table is Extended
THIS INDICATOR IS OFF!!!


.
The Table now finishes the move to LS2.

Table is Table is
Retracted Extended
(LS1) (LS2)
[ ] [ ]
| +-----+\
|Table|
+-----+


.
This figure shows the Table at the fully extended position. Using positive logic, LS2 is wired through the normally open contacts. Again using positive logic, when the Table is at LS2, the output from the switch is ON. This means that the input to the PLC is ON. If the LS2 input is ON, the Table is extended.

Table is
Retracted
(LS1)
---| |----------( ) Indicator Light, Table is Retracted
THIS INDICATOR IS OFF!!!
Table is
Extended
(LS2)
---| |----------( ) Indicator Light, Table is Extended
THIS INDICATOR IS ON!!!


.
The Indicator rungs shown above use positive logic to determine the state of the indicator lights. That is, if the particular input signal is on then the corresponding indicator light is on.

Let's put a little twist into this...

Table is
Retracted
(LS1)
---|/|----------( ) Indicator Light, Table is NOT Retracted
This indicator light will be ON if the
Table is anywhere except fully retracted.
Table is
Extended
(LS2)
---|/|----------( ) Indicator Light, Table is NOT Extended
This indicator light will be ON if the
Table is anywhere except fully extended.




I'm tired... G'night.
 
Terry Woods said:

I had a go-around a few years ago with some folks that thought that anyone that could read an electrical schematic could create logic in a PLC.


Your memory serves you well Terry, but not that well, that was not the phrase I used, I never used the word 'create', I believe I used the word 'read' or it might have been 'understand'.

But we won't go down that road again...

Paul
 
Terry,

I just want to personally thank you for the time and effort that you put into these two posts. As a PLC beginner, I was always reading the XIO and XIC as actual normally-open and normally-closed relay contacts, and confusing the heck out of myself. Now that you have shown that if you just refer to the CONDITION of the incoming signal, it is much easier to understand.

With your permission, I am going to print out both posts #1 and #2, and add them to my reference notebook, for the next Senior moment that occurs !!!

Thanks again..

Jim
 

Similar Topics

I am a beginner at RSLogix 5000 and in ladder logic in general. I am tasked with making sense of an existing program and reprogramming it to make...
Replies
8
Views
6,029
Hi, I am using an AB PLC5. I have a rung with three branches on the right, so that it has three connections to the right (output) rail...
Replies
10
Views
7,150
Ok, I know in my own words the differences between XIO/XIC and NO/NC. The problem comes up when I try to convey to someone in a good way so it...
Replies
55
Views
50,270
Hi, I am new to plc and i was reading the contensts in plcs.net. I have a doubt. i am not able to understand when we should go for normally...
Replies
4
Views
5,907
I'm new to the TotalFLow XIO and it has an attached TFIO DI/DO combo module. All I'm trying to do is close an output on the TFIO module. I'm...
Replies
3
Views
609
Back
Top Bottom