Hello @k.a.belange,
Regarding BE-A301 (NPN Output) and BE-A301P (PNP output):
The answer very much depends on the remainder of your circuit.
Industrial
From an industrial control programmable Logic Controller perspective, the PNP (sourcing) output is preferred.
Microcontroller
From a microcontroller perspective, the NPN (sinking) may be the preferred solution. We can often use NPN output transistor directly in the circuit e.g., with a load resistors connected to the 5 VDC rail.
The datasheet claims
Residual voltage: 2 V or less (sink current at 50 mA) 1 V or less (sink current at 16 mA).
Read this as a warning when for the direct to microcontroller circuits. We must ensure that the sensor’s output voltage drops below the microcontrollers, logic zero threshold.
As a sidenote, recommend optical isolation be used for nearly all industrial sensor to microcontroller interface. An exposed microcontroller pin is one accident away from burnout in an industrial setting.
Sincerely,
APDahlen