Codey OnlineBiblioteca de componentes Arduino y ESP32 › Motion sensor with microwave radar RCWL-051
Motion sensor with microwave radar RCWL-051
Sensores

Motion sensor with microwave radar RCWL-051

El RCWL-051 es un módulo sensor de movimiento por radar de microondas que detecta movimiento emitiendo señales de microondas de baja potencia y buscando cambios en la señal reflejada. Normalmente funciona con una alimentación de 3,3–5 V y ofrece una salida TTL digital (OUT) que puedes leer con un Arduino o un ESP32 para la detección de movimiento y presencia.

Ancho: 36.3 mm

Pinout — Motion sensor with microwave radar RCWL-051

Pin Señal Descripción
3V3 power Regulated 3.3V output from the module for small external loads or reference.
GND ground Common ground return for power supply and logic signal reference.
OUT digital Digital motion output; goes high when the radar sensor detects movement.
VIN power Main supply input for powering the RCWL-051 module.
CDS analog Light-sensor control input; connect an LDR network to inhibit motion output in daylight.

Esquema de cableado de ejemplo — Motion sensor with microwave radar RCWL-051

Desde Hasta Cable
board:5V x1:VIN red
board:GND x1:GND black
board:D2 x1:OUT green

Código Arduino de ejemplo — Motion sensor with microwave radar RCWL-051

Este ejemplo se escribió y verificó por compilación para arduino-uno. Codey Online lo adapta a cualquier otra placa compatible.

// RCWL-051 microwave radar motion sensor example
// Wiring:
// - RCWL-051 VIN  -> Arduino 5V
// - RCWL-051 GND  -> Arduino GND
// - RCWL-051 OUT  -> Arduino D2

const int motionPin = 2;

void setup() {
  pinMode(motionPin, INPUT);
  Serial.begin(9600);
  while (!Serial) {
    ;
  }
  Serial.println("RCWL-051 motion sensor example");
  Serial.println("Move in front of the sensor to see OUTPUT change.");
}

void loop() {
  int motionState = digitalRead(motionPin);

  if (motionState == HIGH) {
    Serial.println("Motion detected");
  } else {
    Serial.println("No motion");
  }

  delay(250);
}

Componentes relacionados

18650 Battery Shield with USB-C Charger and 5V Boost Converter

18650 Battery Shield with USB-C Charger and 5V Boost Converter

2.4 inch OLED Display I2C 3.3V

2.4 inch OLED Display I2C 3.3V

3.5 inch TFT LCD Shield

3.5 inch TFT LCD Shield

50kg Load Cell Weight Sensor

50kg Load Cell Weight Sensor

Crea tu proyecto de Arduino o ESP32 con IA

Describe lo que quieres construir. Codey Online escribe el codigo, dibuja el esquema de conexiones, lo compila y graba tu placa directamente desde el navegador.

Empieza gratis