NPN/PNP=What a Delima!

BDKuhns

Member
Join Date
Sep 2003
Location
KC, MO
Posts
78
OK…..just a review. I need a check on reality sometimes or more so just confirmation. My peers seem to think that I’m an IDIOT (sometimes so do my family) for even asking this question. Which sends current to the load “Sinking” or Sourcing”. They seem to think it doesn’t matter. (I KNOW BETTER)!

I also know that I should have done a search before I posted this…..If this creates as much heat here as at my job………..I’d like to see it!
 
Current flow is from the source to the sink. Think of water coming out of a faucet (source) and going down the drain (sink).

So, if you're talking about a PLC's DC output module. With a sourcing output, current flow is from the module to the load. The load is the sink. The side of the load device not connected to the PLC output is wired to DC common. With a sinking output, current flow is from the load to the module. The load is the source. The side of the load device not connected to the PLC output is wired to DC positive.

Now, if you're talking about a PLC's DC input module, the input is the load. With a sinking input, current flow is from the sensing device to the input module. With a sourcing input, current flow is from the input module to the sensing device.
 
Ha, and to cornfuse you even more, classical current flow (the standard we follow today) is from positive to negative, through the load.

However, in reality, electrons carry the charge, and they are negatively charged, so the electrons are actually moving from the negative side to the positive.

It's kind of a funny side note that classic current flow was defined before the acutal mechanism (negativly charged electrons) was discovered. I guess if it were easy anyone could do it.
 
jimbo3123 said:
Ha, and to cornfuse you even more, classical current flow (the standard we follow today) is from positive to negative, through the load.

However, in reality, electrons carry the charge, and they are negatively charged, so the electrons are actually moving from the negative side to the positive.

It's kind of a funny side note that classic current flow was defined before the acutal mechanism (negativly charged electrons) was discovered. I guess if it were easy anyone could do it.
Who is confused?...

A lot of years ago when I was at school, a classmate raised this in our physics class whereupon the prof drew a simple series circuit on the board with a battery, a semiconductor diode, and a jar of silver nitrate solution (can't remember the electrode materials) all connected with copper wire.

The charge carriers in the wire are electrons, holes in the semiconductor, and, if I recall correctly, in the solution there were charge carriers (ions) going in both directions.

We work with "conventional" current because it's a waste of time keeping track of what is carrying charge in any part of a circuit and which direction it's moving.
 
NPN or PNP

Hi there,
Very simple u need to keep this simple logic in ur mind always
a)If u have the Sink(NPN) card then u need a Source(PNP) sensors attached with it.

b)If u have Source(PNP) card then u need to attach the Sink(NPN) sensor attached to it, to complete the circuit.

You can remember NPN as-> Not Pointing iN


See u need logic to remember something!!
 
Confuse or inform???

Which sends current to the load “Sinking” or Sourcing”. They seem to think it doesn’t matter. (I KNOW BETTER)!
Technically it does not matter, more coming.

a)If u have the Sink(NPN) card then u need a Source(PNP) sensors attached with it.
b)If u have Source(PNP) card then u need to attach the Sink(NPN) sensor attached to it, to complete the circuit.
You can remember NPN as-> Not Pointing iN
Not necessarily, its relative.

I am trying to keep this simple.

03073.png


As you can see the electron flow is against the arrow. Now lets use an NPN as a switch.

03078.png


The switch could be an inductive prox etc. As you can see electron flow (actual current) will not happen until the switch is made.

Now lets change the NPN to a PNP device.

03076.png

If you look at the first picture you will see current flow is against the arrow, also note polarity is the same as it was with the NPN transistor. So what happens in this case?

I dont have the appropriate picture but what happens is when the switch is OFF the PNP transistor will allow current to flow and the light (or input) would be ON. When the switch is made the light (or input) would be OFF...a basic inverter circuit.

I am not sure who came up with the sink/source thing but I think it confused the issue in some ways. The idea is to understand when current flow occurs and a signal is present where needed.

An analogy or comparison with plcs can be made using a Normally open pushbutton. With an NO PB attached to Input 1 you can write ladder that makes it TRUE when you push the button.

Input1 Output
|---| |----------( )--|


Output only comes on when NO PB is pressed.

OR you can write code that makes the INPUT FALSE when you push the button.

Input Output
|---|/|---------( )--|


The output will be ON until the NO PB is pressed.

Its just a matter of understand "HOW" you need/want the signal to the plc to work.
 
And to make even more confusion, A/B inverts the terms sometimes and makes them relate to what the field device is doing, not what the I/O card is doing. Grrrrrrr.
 
My analogy..

Ok so youve got a bucket and a hose. Your going to place water in the bucket with the hose. So the hose is the SOURCE for the water and the bucket is the SINK that your putting the water in.

So the conventional current flow is from the source to the sink.
 
Another chance for a discourse

theDave2 said:
And to make even more confusion, A/B inverts the terms sometimes and makes them relate to what the field device is doing, not what the I/O card is doing. Grrrrrrr.

Actually they do not, they just used terms that were not intuitive...ie XIC and XIO. What does XIO mean? Examine if ON, OFF, OPEN?

What we can deduce is that XIC means Examine if CLOSED and XIO should be the opposite so it should mean Examine if OPEN. These are just "inverted" representations of the same thing.

It all depends on what you need and where you need it.

If a Normally Open PB is used at input 1 with an XIC then the XIC will be true when the PB is pressed and allow rung continuity. An example is a Start Pushbutton.

A normally closed device, like a STOP button, will provide a signal when the pushbutton is NOT pressed and the use of an XIC will provide continuity in the rung UNTIL the PB is pressed.

Why would you need XIO? In the STOP PB situation you needed the ALWAYS ON condition to provide continuity to the rungs involved. Lets say you have a prox sensor with a normally closed output...ie with nothing in front of the prox it is ALWAYS ON. This prox could be used for counting product etc etc, now you need to KNOW when the INPUT signal is OFF...ie the prox senses product and the output turns off...NOW you need the rung to have continuity when the prox input is OFF (0) so would use an XIO.

NC prox
|----|/|------------|counter|--|


In this case when the prox senses a product the Normally closed contact will open and NO signal will be present at the PLC input..ie a 0 will be present in the input table. This in turn will make the XIO instruction be ON (True) which allows continuity in the rung...ie the counter will count.

With the STOP PB you needed to disallow rung continuity when it was OFF. With the prox you needed to allow continuity when it was OFF.

In either case of buttons, sensors, switches and using NPN/PNP devices the "logic" can be inverted and make the code work...the issue is that doing so can make it confusing for others to understand.

Its natural for us to think...the input comes ON then the instruction comes ON and action occurs..WHY? Because we do this everyday, flip a light switch and the light comes ON..ie flip switch, power (signal) goes to bulb and it turns ON. Its not intuitive to think in another fashion so inverted logic can make things confusing.

In general what matters is understanding what you need and how to use it...there have many situations where the wrong device was put on a machine...operator/mechanic error, correct device not available etc where I have just inverted the logic in the PLC.

I will not go into the relay analogy but you can read it here:
http://www.patchn.com/xio_xic_explained.htm
 
rsdoran said:
Actually they do not, they just used terms that were not intuitive...ie XIC and XIO. What does XIO mean? Examine if ON, OFF, OPEN?

How did we get into contacts from I/O sourcing / sinking ??? :)

Actually, I think someone at AB said "All Elements shall have 3 words", then then next guy writting the tech. manual asked about what the plc did, and the other non-tech guy said something like "Well, the plc looks at the bit and see's if it's on or off", so the other guy didn't like using SBO as that could be See Bit On or See Bit Off, so some more back and forth came about, then they didn't like EIO & EIC 'cause some manager said that sounded like the Old MacDonald Farm song.

That's my story and I'm sticking to it.
 
How did we get into contacts from I/O sourcing / sinking ??? :)
Because thats what they are whether they are mechanical or solid state.

It all boils down to is it ON or is it OFF and what do I do with that information.

Personal opinion;
The hard part of this to understand is all the terminology that is used, in general I think it confuses the issue so much that for some, me included, it takes years to fully comprehend even though we still apply it.

Lets take SINK and SOURCE inputs as an example, these are solid state devices that can be normally open or normally closed "contacts" BUT the plc may see them "inverted" depending on wiring and/or the instruction being used. Overall I know of no explanation that could be given that would allow every individual to "automatically" understand what is happening.
 
sonsors to plc configuration

Hi Mr Doran

I just want to ask simple question .
1)Is it possible to connect NPN CARD with a NPN type Inductive sensor or vice-versa of this?
You said its "relative" please elaborate.
regards
Manmeet
 
I am not sure how to explain it properly at this time. I do not have any npn/pnp sensors on hand but will see if I can obtain something and provide pictures.

As an example and to keep it simple lets say you have 3 wire DC sensors (prox) these will be labeled NPN and PNP but the NPN is actually a normally opened switch and the PNP is a normally closed switch.

Take the NPN sensor and connect the NO lead to the PLC NPN input and connect the other 2 leads to power. At this point the plc input will be OFF but activate the sensor and the input comes ON.

Take the PNP sensor and connect the NC lead to the PLC NPN input and connect the other 2 leads to power. The PLC input will be ON, activate the sensor and the PLC input will go OFF.

The action is inverted.
Here is another example, note the plc input is NPN. The first device has an open collector NPN output, the second is a PNP open emitter.

sinkinggoutplcin.jpg


sourceoutplcin.jpg


Sink/Source was created (I think) to simplify explaining current flow...IF you understand how current will flow you can use either an NPN or PNP device interchangeably BUT the action of the device may be inverted....it depends.

Maybe I can offer better details later, basically this is correct but I am not sure I have detailed it correctly.
 
Last edited:

Similar Topics

I like PNP (source) way better. It just seems more natural and correct to be controlling the +DC voltage than the -DC. It is a real pain when...
Replies
13
Views
1,236
Has any one ever tried to do NPN with a 1734-IK counter card? Common hot? switch the return? we have these dumb NPN sensors that we always use...
Replies
0
Views
1,570
Hi to All, How I can change NPN to PNP solid state switch? Exapmle1: D-M9N Solid state switch with D-M9P Exapmle2: or allen bradley p.e.c. type...
Replies
3
Views
1,435
Back
Top Bottom