A sensor is a device that detects and responds to some type of input from the physical environment. It is a device, module, machine, or subsystem that detects events or changes in its environment and sends the output signal for the purpose of sensing a physical phenomenon. Sensors can detect a wide range of physical phenomena, including light, heat, motion, moisture, pressure, and many others. They are used in everyday objects such as touch-sensitive elevator buttons and lamps which dim or brighten by touching the base, and in innumerable applications of which most people are never aware. With advances in technology, the uses of sensors have expanded beyond the traditional fields of temperature, pressure, and flow measurement, for example into MARG sensors. Sensors play a pivotal role in the internet of things (IoT) and are used in homes, automobiles, on airplanes, in industrial settings, and in other environments. There are two types of electronic sensors: analog and digital. Analog sensors convert physical data into an analog signal, while digital sensors are limited to a finite set of possible values.