18 essential sensors every maker needs to know — from beginner to advanced
✅ Measure temperature & humidity
💡 Better accuracy → DHT22
✅ Accurate analog temperature measurement
✅ Detect light intensity
✅ Accurate lux measurement
✅ Measure distance using sound waves
✅ Object detection
✅ Detect human motion
✅ Detect movement & tilt
✅ Detect LPG, smoke, methane
✅ Measure atmospheric pressure & altitude
✅ Measure heart rate
✅ Heart rate + SpO2 measurement
✅ Detect water presence or level
✅ Measure soil water content
✅ Detect sound intensity
✅ Detect magnetic field
✅ Detect human touch
✅ Measure pressure
| Sensor | Best Use Case |
|---|---|
| DHT22 | Weather Station |
| LDR | Smart Lighting |
| PIR | Home Security |
| Ultrasonic (HC-SR04) | Robotics |
| Soil Moisture | Agriculture |
| MAX30102 | Health Monitoring |
| MQ-2 | Safety Systems |
The DHT11 is a low-cost digital sensor used to measure temperature and relative humidity. It is commonly used in beginner electronics and IoT projects with microcontrollers like Arduino Uno, ESP8266, and Raspberry Pi.
| Feature | Description |
|---|---|
| Sensor Type | Digital Temperature & Humidity Sensor |
| Output | Digital signal (Single-wire protocol) |
| Operating Voltage | 3.3V – 5V |
| Temperature Range | 0°C to 50°C |
| Humidity Range | 20% to 90% RH |
| Accuracy | ±2°C (Temp), ±5% RH |
| Sampling Rate | 1 reading per second |
| Cost | Very low (₹50–₹150 approx.) |
DHT11 has 4 pins (when looking at the front grill side):
| Pin | Name | Description |
|---|---|---|
| 1 | VCC | 3.3V or 5V supply |
| 2 | DATA | Serial Data output |
| 3 | NC | Not Connected |
| 4 | GND | Ground |
⚠️ Important: If using the bare sensor (not module), you need a 10kΩ pull-up resistor between VCC and DATA.
The DHT11 contains:
Uses a capacitive humidity sensing element.
Changes in humidity → change in capacitance → converted to digital signal.
Uses an NTC thermistor.
Temperature change → resistance change → converted to digital signal.
The internal microcontroller processes both values and sends 40-bit digital data.
| DHT11 Pin | Arduino Pin |
|---|---|
| VCC | 5V |
| GND | GND |
| DATA | Digital Pin 2 |
#include <DHT.h> #define DHTPIN 2 #define DHTTYPE DHT11 DHT dht(DHTPIN, DHTTYPE); void setup() { Serial.begin(9600); dht.begin(); } void loop() { float h = dht.readHumidity(); float t = dht.readTemperature(); Serial.print("Humidity: "); Serial.print(h); Serial.print(" % Temperature: "); Serial.print(t); Serial.println(" °C"); delay(2000); }
📦 You must install DHT sensor library from Arduino Library Manager.
| Feature | DHT11 | DHT22 |
|---|---|---|
| Temp Range | 0–50°C | -40–80°C |
| Humidity Range | 20–90% | 0–100% |
| Accuracy | ±2°C | ±0.5°C |
| Cost | Cheap | Slightly expensive |
💡 If you need better accuracy → choose DHT22.