Overview
Most industrial proximity sensors (inductive, capacitive, ultrasonic, and photoelectric) use solid-state components. Solid-state refers to the type of components used inside the sensor. Solid-state electronic components such as transistors switch the sensor output when an object is detected.
PNP and NPN Types
There are two specific types of three-wire sensors: PNP and NPN. This distinction results from the combination of the internal circuit design and the type of transistor used. A simple explanation of the two types is provided in the attached diagrams.
One key point is that PNP and NPN relate to the transistor polarity and are independent of whether the sensor is normally open (N/O) or normally closed (N/C). A PNP sensor can be N/O or N/C, and an NPN sensor can also be N/O or N/C.
This FAQ focuses specifically on the PNP/NPN output wiring of sensors rather than in-depth transistor theory. For clarity, see the attached excerpt from a practical handbook, which shows transistor terminology and circuit diagrams. Further learning materials on PNP and NPN transistors are available online from multiple sources.
Why Two Types?
The choice between a PNP sensor and an NPN sensor depends on the nature of the equipment circuits in use. For traditional relay-based control circuits, either PNP or NPN sensors can usually be used. PNP sensors tend to be more common in those applications.
Use with Programmable Logic Controllers (PLC)
When choosing sensors to use with a PLC, it is important that the sensor type matches the type of PLC input module used.
There are two types of input modules: sink current and source current. Although the terms sink/source are well known in some industries, they are not always used consistently. Therefore, determine the sensor type required by the PLC module from the PLC manufacturer's documentation or wiring diagrams.
Sink inputs are common in Europe and will work with PNP sensors. Source inputs, which are more common in some Asian markets, require NPN sensors to operate correctly. Many modern PLC input modules can be configured as sink or source, but typically that configuration applies to all inputs on a given module.
Note that dashed lines in the diagrams are optional and may or may not be required depending on your hardware and setup. The key wires to note are the solid red, black, and blue wires shown in the diagrams.