The device is an ultrasonic sensor for detecting the position of an object within the operating range. The sensor has an optically isolated transistor output with a PNP or NPN connection, with overload protection and back-up protection. The output NO / NC function is determined by the connection of the power terminals. Two limit positions (from the operating range) and the output mode can be set by a button on the housing.