What you'll learn
Industrial 3-wire proximity sensors use a standard colour code across almost every manufacturer:
Lab time: ~12 minutes.
Lesson briefing
NPN / PNP Sensors — Sinking & Sourcing
Industrial 3-wire proximity sensors use a standard colour code across almost every manufacturer:
- Brown (BN) — 24 VDC supply positive.
- Blue (BU) — 0 V / DC common.
- Black (BK) — signal output to the PLC input.
The supply wiring (BN and BU) is identical for both NPN and PNP sensors. The only difference is what the black wire does when the sensor detects a target.
NPN — sinking output
An NPN sensor contains an NPN transistor whose collector drives the signal output. When the sensor is active, it connects the black wire to 0 V (it "sinks" current from the PLC input to common). The PLC input sees a LOW signal when the sensor fires.
PNP — sourcing output
A PNP sensor's internal transistor sources current from the +24 V rail onto the black wire when active. The PLC input sees a HIGH (+24 V) signal when the sensor fires. PNP is more common on modern European- style PLCs because the sourcing convention matches positive-logic inputs directly.
Wiring both onto the same PLC
Both sensors share the same +24 V and 0 V distribution bus. Their black wires connect to separate PLC input terminals (X0 for the NPN sensor, X1 for the PNP sensor). At the wiring level the connections look the same; the PLC's input circuit handles the polarity internally.
Practical tip: always read the sensor nameplate before wiring. Getting NPN vs PNP backwards is the single most common reason a perfectly-installed sensor appears to "not work" — the sensor fires, but the PLC input level is inverted relative to what the program expects.
Hints
Brown wire (+V terminal) always connects to the +24 V supply bus — this is true for both NPN and PNP sensors.
Sign up to unlock the full hint sequence.
Sign up to unlock the full hint sequence.
Sign up to unlock the full hint sequence.
Sign up to unlock the full hint sequence.
This lesson uses 8 placed components on the lab canvas. Components are vendor-neutral (no proprietary trademarks); the wiring rules apply to any equivalent industrial part.
Sign up free to start
This foundation lab is included on Free — sign up takes a minute.
Sign up free to start →