In developmentNot released yet — features and data may change without notice.

Catalog

Sensor

HC-SR04 ultrasonic ranging module (4-pin header)

hc_sr04GPIO5 V logic

Datasheet · reference circuit

Why this support circuit is added

5 V module. ECHO is a 5 V output, so a 3.3 V MCU needs a divider.

Grounded in the catalog and golden patterns (real open-source circuits). Every auto-inserted part comes with a reason.

Support circuit added automatically0

No extra support circuit for this part — only the board rail and the connector are wired.

InterfaceGPIO
Catalog id
hc_sr04
Category
Sensor
Protocol
GPIO
Logic level
5 V
Firmware detection3

Any of these #includes identifies this part

#include <NewPing.h>
#include <HCSR04.h>
#include <Ultrasonic.h>

Examples using this part

Run them in the browser, no login needed.

Arduino Uno R30 libraries38 lines

Parking sensor

An ultrasonic range finder beeps at shorter intervals as something gets closer, and lights an LED inside 30 cm.

buzzerhc_sr04led
Arduino Uno R35 libraries48 lines

A greenhouse controller

The relay closes when the DS18B20 passes 28 °C; an ultrasonic sensor measures distance too.

buttonds18b20hc_sr04ledrelay_1chssd1306_i2c
HC-SR04 ultrasonic ranging module (4-pin header) · ibouPCB