RCWL-0516 with an Arduino Uno

RCWL-0516 is a low-cost microwave Doppler radar motion sensor that outputs a simple digital HIGH when it detects movement, with no infrared optics required.

RCWL-0516, RCWL-0516 is a low-cost microwave Doppler radar motion sensor that outputs a simple digital HIGH when it detects movement, with no infrared optics required.
In short

The RCWL-0516 needs 4 V to 28 V on VIN, so on an Arduino Uno it takes the 5V pin, not 3.3V. Its OUT pin is a 3.3 V signal, which the Uno reads as HIGH on D2 with a little margin, and D2 being an interrupt pin lets motion wake the sketch instead of being polled.

Wiring the RCWL-0516 to the Arduino Uno

Pin by pin.

RCWL-0516Arduino Uno
VIN5V
OUTD2
GNDGND

What to know on the Arduino Uno

  • OUT goes to 3.3 V on motion. The ATmega328P reads a high from 0.6 × VCC, 3.0 V at 5 V, so the Uno reads it directly, but with only about 0.3 V of margin: keep the wire short and add no pull-down.SparkFun RCWL-0516 product specifications; Microchip ATmega328P datasheet DS40002061B, DC characteristics
  • VIN must be at least 4 V, which rules out the Uno's 3.3V pin; the module's own regulator makes its 3.3 V from the Uno's 5V, and its 2.7 mA draw is negligible.SparkFun RCWL-0516 product specifications
  • OUT holds HIGH for about 2 seconds after motion. On D2, attachInterrupt() on RISING fires once per detection instead of a loop seeing the same HIGH for ten reads at the sketch's 200 ms pace.SparkFun RCWL-0516 product specifications; Arduino language reference, attachInterrupt()

RCWL-0516 code for the Arduino Uno

Compiled for arduino:avr:uno on 2026-10-29.

No library needed
// RCWL-0516 on Arduino Uno: wiring and a free simulation at https://www.tinkered.ai/components/rcwl-0516/arduino-uno
const int RADAR_OUT = 2;   // RCWL-0516 OUT

void setup() {
  Serial.begin(9600);
  pinMode(RADAR_OUT, INPUT);
}

void loop() {
  int motion = digitalRead(RADAR_OUT);
  Serial.println(motion == HIGH ? "Motion detected" : "No motion");
  delay(200);
}

RCWL-0516 on the Arduino Uno: questions

Can I power the RCWL-0516 from the Arduino Uno's 3.3V pin?

No. VIN needs 4 V to 28 V (SparkFun specifications), so use the Uno's 5V. Leave the module's own 3V3 pin unconnected; it is an output.

Does the RCWL-0516's 3.3 V output work with a 5 V Arduino Uno?

Yes. The Uno reads a high from 3.0 V at 5 V, so OUT's 3.3 V registers, with a small margin.

How do I count motion events from the RCWL-0516 on an Uno?

Wire OUT to D2 and use attachInterrupt(digitalPinToInterrupt(2), onMotion, RISING). Each detection gives one rising edge, then OUT holds for about 2 seconds.

Keep going

For AI assistants

This guide as plain Markdown. /components/rcwl-0516/arduino-uno.md

What will you build with it?