0% found this document useful (0 votes)
34 views

Types of Sensors

Sensors are devices that can detect changes in the environment and convert that information into an electrical signal. There are different types of sensors classified by their power source, detection method, and output signal. Some common sensors include temperature, proximity, accelerometer, infrared, pressure, light, ultrasonic, gas, touch, color, humidity, tilt, and flow/level sensors. The document then provides more details on temperature, proximity, and accelerometer sensors. It also includes an example Arduino code for an ultrasonic distance sensor.

Uploaded by

Meet Kotak
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
34 views

Types of Sensors

Sensors are devices that can detect changes in the environment and convert that information into an electrical signal. There are different types of sensors classified by their power source, detection method, and output signal. Some common sensors include temperature, proximity, accelerometer, infrared, pressure, light, ultrasonic, gas, touch, color, humidity, tilt, and flow/level sensors. The document then provides more details on temperature, proximity, and accelerometer sensors. It also includes an example Arduino code for an ultrasonic distance sensor.

Uploaded by

Meet Kotak
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 5

Sensors:-

Generally speaking, a sensor is a device that is able to detect changes in an environment. By


itself, a sensor is useless, but when we use it in an electronic system, it plays a key role. A sensor
is able to measure a physical phenomenon (like temperature, pressure, and so on) and transform
it into an electric signal. These three features should be at the base of a good sensor:

● It should be sensitive to the phenomenon that it measures

● It should not be sensitive to other physical phenomena

● It should not modify the measured phenomenon during the measurement process

Sensors can be grouped using several criteria:

● Passive or Active. Passive sensors do not require an external power source to monitor an
environment, while Active sensors require such a source in order to work.

● Another classification is based on the method used to detect and measure the property
(mechanical, chemical, etc.).

● Analog and Digital. Analog sensors produce an analog, or continuous, signal while
digital sensors produce a discrete signal.

Types of sensors:-

● Temperature Sensor
● Proximity Sensor
● Accelerometer
● IR Sensor (Infrared Sensor)
● Pressure Sensor
● Light Sensor
● Ultrasonic Sensor
● Smoke, Gas and Alcohol Sensor
● Touch Sensor
● Color Sensor
● Humidity Sensor
● Tilt Sensor
● Flow and Level Sensor

1. Temperature sensors:-
A temperature sensor is a device, typically, a thermocouple or RTD, that provides for
temperature measurement through an electrical signal. A thermocouple (T/C) is made
from two dissimilar metals that generate electrical voltage in direct proportion to changes
in temperature. An RTD (Resistance Temperature Detector) is a variable resistor that will
change its electrical resistance in direct proportion to changes in temperature in a precise,
repeatable and nearly linear manner.

2) Proximity sensor:-

A proximity sensor is an electronic sensor that can detect the presence of objects within its
vicinity without any actual physical contact. In order to sense objects, the proximity sensor
radiates or emits a beam of electromagnetic radiation, usually in the form of infrared light, and
senses the reflection in order to determine the object's proximity or distance from the sensor.

Proximity sensors are commonly used in industrial applications, from manufacturing and food
production to recycling. They are also used in vehicles for detecting the proximity of other
vehicles relative to one's own car, as well as for parking-assist functions. In mobile devices,
especially phones, the proximity sensor is used to detect whether the user's face is close to the
phone during a phone call, prompting the screen to turn off to prevent false touches on the
touchscreen.
There are many types of proximity sensors and they use different methods for sensing. For
example, capacitive and photoelectric sensors are more suited to plastic and organic targets,
whereas inductive proximity sensors can only detect metal targets.
3) Accelerometer:-

An accelerometer is a device that measures changes in ​gravitational acceleration​ in a device it


may be installed in. Accelerometers are used to measure acceleration, tilt and vibration in
numerous devices.

At rest, an accelerometer measures 1g: the earth’s gravitational pull, which registers 9.81 meters
per second or 32.185 feet per second. Accelerometers that use the ​piezoelectric​ effect measure a
small voltage change. Others measure ​capactitance​ between two components.

To sense motion in multiple directions, an accelerometer must be designed with multi-axis


sensors or multiple linear axis sensors. Three linear accelerometers are adequate to measure
movement in three dimensions.

Code:-

const int trigPin = 9;

const int echoPin = 10;

const int buzzer = 11;

const int ledPin = 13;

// defines variables
long duration;

int distance;

int safetyDistance;

void setup() {

pinMode(trigPin, OUTPUT); // Sets the trigPin as an Output

pinMode(echoPin, INPUT); // Sets the echoPin as an Input

pinMode(buzzer, OUTPUT);

pinMode(ledPin, OUTPUT);

Serial.begin(9600); // Starts the serial communication

void loop() {

// Clears the trigPin

digitalWrite(trigPin, LOW);

delayMicroseconds(2);

// Sets the trigPin on HIGH state for 10 micro seconds

digitalWrite(trigPin, HIGH);

delayMicroseconds(10);

digitalWrite(trigPin, LOW);
// Reads the echoPin, returns the sound wave travel time in microseconds

duration = pulseIn(echoPin, HIGH);

// Calculating the distance

distance= duration*0.034/2;

safetyDistance = distance;

if (safetyDistance <= 10){

digitalWrite(buzzer, HIGH);

digitalWrite(ledPin, HIGH);

else{

digitalWrite(buzzer, LOW);

digitalWrite(ledPin, LOW);

// Prints the distance on the Serial Monitor

Serial.print("Distance: ");

Serial.println(distance);

You might also like