Skip to Content

Ultrasonic Sensor HC‑SR04

📏 Ultrasonic Sensor HC-SR04 – Distance Measurement Module

Measure distances accurately using sound waves

The HC-SR04 Ultrasonic Sensor is a widely used, low-cost module for measuring distances between 2 cm and 400 cm with high accuracy. It works by emitting ultrasonic pulses and measuring the time taken for the echo to return. Perfect for robotics, obstacle avoidance, level sensing, and automation projects.

⚙️ Technical Specifications

ParameterSpecification
Operating Voltage5V DC
Operating Current~15 mA
Measuring Range2 cm – 400 cm
Accuracy±3 mm
Measuring Angle≤15°
Trigger Input Signal10 µs TTL pulse
Echo Output SignalTTL pulse (width proportional to distance)
Module Size45 mm x 20 mm x 15 mm

✅ Features

  • 📏 Accurate distance measurement from 2 cm to 4 m

  • 🚗 Perfect for obstacle detection in robots

  • Fast response time for real-time applications

  • 🔌 Simple 4-pin interface: VCC, Trig, Echo, GND

  • 🧠 Compatible with Arduino, ESP8266, ESP32, Raspberry Pi, STM32

🧪 Typical Arduino Connection

Module PinArduino Pin
VCC5V
TrigD9
EchoD10
GNDGND

Simple Arduino Code Example:

cpp
CopyEdit
#define trigPin 9 #define echoPin 10 void setup() { pinMode(trigPin, OUTPUT); pinMode(echoPin, INPUT); Serial.begin(9600); } void


50.00 LE 50.00 LE

This combination does not exist.

Sensor Ultrasonic