Lt is an industrial automation sensor used for object detection.
The text on the device indicates connections for 24V power supply (BN) and an output (BK).
It typically operates using a red LED light source.
The device shown has a white connector plug attached to the wiring harness.