All of the above
A sensor is a device that detects the change in the environment and responds to some output on the other system. A sensor converts a physical phenomenon into a measurable analog voltage (or sometimes a digital signal) converted into a human-readable display or transmitted for reading or further processing.