Zbotic Logo Zbotic Logo
  • Home
  • Shop
  • Sale
  • 3D Print Service
  • PCB Service
  • B2B
  • Blogs
  • Contact Us
0 0

View Wishlist Add all to cart

0 0
0 Shopping Cart
Shopping cart (0)
Subtotal: ₹0.00

View cartCheckout

  • Shop
  • About Us
  • Contact Us
  • Reseller
  • Blogs
020 69134444
1800 209 0998
[email protected]
Help Desk
Facebook Twitter Instagram Linkedin YouTube
Zbotic Logo Zbotic Logo
0 0

View Wishlist Add all to cart

0 0
0 Shopping Cart
Shopping cart (0)
Subtotal: ₹0.00

View cartCheckout

All departments
  • 3D Print Service
  • 3D Printer
  • Batteries & Chargers
  • Development Boards
  • Drone Parts
  • EBike parts
  • Sensor Modules
  • Electronic Components
  • Electronic Modules
  • IoT and Wireless
  • Mechanical Parts and Workbench Tools
  • Motors & Drivers & Pumps & Actuators
  • DIY and Robot Kits
  • Show more
  • Home
  • Shop
  • Sale
  • 3D Print Service
  • PCB Service
  • B2B
  • Blogs
  • Contact Us
Return to previous page
Home Communication & Wireless Modules

HC-SR501 PIR Wireless Alert: NRF24L01 Security System Project

HC-SR501 PIR Wireless Alert: NRF24L01 Security System Project

March 11, 2026 /Posted byJayesh Jain / 0

HC-SR501 PIR Wireless Alert: NRF24L01 Security System Project

If you are looking to build a PIR NRF24L01 wireless security Arduino system at home without spending thousands of rupees on commercial alarm systems, this project is exactly what you need. Using the affordable HC-SR501 passive infrared sensor and the NRF24L01 2.4 GHz radio module, you can create a reliable multi-zone wireless intruder alert system that covers your entire home — all for under ₹500 in components. Indian hobbyists and makers have been building such systems for years, and in 2026, the parts are cheaper and better documented than ever.

Table of Contents

  1. How the PIR + NRF24L01 System Works
  2. Components You Need
  3. Circuit and Wiring Guide
  4. Arduino Transmitter Code (Sensor Node)
  5. Arduino Receiver Code (Base Station)
  6. Expanding to Multi-Zone Coverage
  7. Power Supply and Battery Tips for Indian Conditions
  8. Frequently Asked Questions

How the PIR + NRF24L01 System Works

The HC-SR501 PIR sensor detects infrared radiation emitted by warm bodies — humans, animals, or even a hot chai cup moving across the room. When motion is detected, the sensor outputs a HIGH signal on its output pin. In this project, an Arduino Nano (or Uno) reads this signal and immediately transmits a radio packet using the NRF24L01 module operating at 2.4 GHz.

At the receiving end — perhaps your bedroom or a central hub — another Arduino with an NRF24L01 listens for incoming packets. When it receives an alert, it can trigger a buzzer, light an LED, send an SMS via a GSM module, or activate a relay to switch on lights. The beauty of this architecture is that you can place multiple sensor nodes throughout your house — entrance, garage, terrace — and all of them report to a single base station.

The NRF24L01 operates at 2.4 GHz with a range of up to 100 metres in open space (about 20–30 metres through walls, which is sufficient for most Indian homes). It uses SPI communication and the popular RF24 library, making coding straightforward even for beginners.

Components You Need

Here is everything required for a single-zone system. Multiply the sensor-side components for multi-zone setups.

  • 2× Arduino Nano (one transmitter, one receiver)
  • 2× NRF24L01 2.4 GHz wireless module
  • 1× HC-SR501 PIR motion sensor
  • 1× Active buzzer (5V)
  • 1× 0.96-inch OLED display (optional, for status readout at base)
  • 100µF capacitor across NRF24L01 VCC-GND (critical — reduces noise)
  • Jumper wires, breadboard
  • 5V USB power bank or 3× AA battery pack
0.96 Inch I2C OLED LCD Module White SSD1306

0.96 Inch I2C IIC OLED LCD Module 4pin White SSD1306 Chip

Display real-time zone alerts and timestamps at your base station with this crisp white OLED. Works with SSD1306 library and Arduino Nano over just 2 wires.

View on Zbotic

Ai Thinker ESP32 CAM Development Board

Ai Thinker ESP32 CAM Development Board WiFi+Bluetooth

Upgrade your base station by replacing the Arduino receiver with an ESP32-CAM — capture a photo on motion detection and send it via WhatsApp or Telegram instantly.

View on Zbotic

1 Channel 12V 30A Relay Module

1 Channel 12V 30A Relay Module with Optocoupler and Guide Rail

Trigger a 12V siren, floodlight, or door lock when the base station receives a motion alert. Optocoupler isolation protects your Arduino from voltage spikes.

View on Zbotic

Circuit and Wiring Guide

The NRF24L01 requires 3.3V power — not 5V. Powering it at 5V will permanently damage the module. Always use the Arduino’s 3.3V pin and add a 100µF capacitor between VCC and GND as close to the module as possible. This single capacitor eliminates 80% of NRF24L01 connection problems that beginners face.

NRF24L01 to Arduino Nano Pinout

NRF24L01 Pin Arduino Nano Pin
VCC 3.3V
GND GND
CE D9
CSN D10
SCK D13
MOSI D11
MISO D12

Connect the HC-SR501 OUT pin to Arduino D2 (interrupt-capable), VCC to 5V, and GND to GND. Adjust the PIR’s two potentiometers — sensitivity (right, clockwise for higher sensitivity) and time delay (left, counter-clockwise for minimum 3-second delay). Set the jumper to single-trigger mode (H position) for security applications.

Arduino Transmitter Code (Sensor Node)

Install the RF24 library by TMRh20 from the Arduino Library Manager before uploading this sketch.

#include <SPI.h>
#include <RF24.h>

RF24 radio(9, 10); // CE, CSN
const byte address[6] = "00001";
const int PIR_PIN = 2;

void setup() {
  pinMode(PIR_PIN, INPUT);
  radio.begin();
  radio.openWritingPipe(address);
  radio.setPALevel(RF24_PA_LOW); // Use HIGH for longer range
  radio.stopListening();
  delay(2000); // PIR warm-up
}

void loop() {
  if (digitalRead(PIR_PIN) == HIGH) {
    const char msg[] = "MOTION ZONE1";
    radio.write(&msg, sizeof(msg));
    delay(500); // Debounce
  }
}

For multi-zone systems, change "ZONE1" to "ZONE2", "ZONE3" etc. on each node, and use different pipe addresses to avoid packet collisions.

Arduino Receiver Code (Base Station)

#include <SPI.h>
#include <RF24.h>
#include <Wire.h>
#include <Adafruit_SSD1306.h>

RF24 radio(9, 10);
const byte address[6] = "00001";
Adafruit_SSD1306 display(128, 64, &Wire, -1);
const int BUZZER_PIN = 6;

void setup() {
  Serial.begin(9600);
  pinMode(BUZZER_PIN, OUTPUT);
  radio.begin();
  radio.openReadingPipe(0, address);
  radio.setPALevel(RF24_PA_LOW);
  radio.startListening();
  display.begin(SSD1306_SWITCHCAPVCC, 0x3C);
  display.clearDisplay();
  display.setTextColor(WHITE);
  display.setCursor(0, 0);
  display.println("Security Active");
  display.display();
}

void loop() {
  if (radio.available()) {
    char msg[32] = "";
    radio.read(&msg, sizeof(msg));
    Serial.println(msg);
    // Sound buzzer
    for (int i = 0; i < 3; i++) {
      digitalWrite(BUZZER_PIN, HIGH);
      delay(200);
      digitalWrite(BUZZER_PIN, LOW);
      delay(100);
    }
    // Update OLED
    display.clearDisplay();
    display.setCursor(0, 0);
    display.println("!! ALERT !!");
    display.setCursor(0, 20);
    display.println(msg);
    display.display();
    delay(5000);
    display.clearDisplay();
    display.setCursor(0, 0);
    display.println("Security Active");
    display.display();
  }
}

Expanding to Multi-Zone Coverage

The NRF24L01 supports up to 6 pipes simultaneously on a single receiver. This means you can monitor 6 zones with one base station. Assign each transmitter a unique pipe address and open all pipes on the receiver:

const byte addresses[][6] = {"Zone1","Zone2","Zone3"};
// Receiver:
radio.openReadingPipe(1, addresses[0]);
radio.openReadingPipe(2, addresses[1]);
radio.openReadingPipe(3, addresses[2]);

For larger homes in India with thick RCC walls, use the NRF24L01+PA+LNA variant with an external antenna, which extends range to 500+ metres in open space. Place the base station centrally and orient antennas vertically for best penetration through walls. Alternatively, you can daisy-chain nodes as repeaters using the RF24Network library.

Power Supply and Battery Tips for Indian Conditions

Power cuts are common in India, so designing your sensor nodes to run on batteries is essential. A single 18650 Li-ion cell (3.7V, 2000mAh) with a TP4056 charging module and a 5V boost converter can power a node for 3–6 months using sleep mode. Add this to the transmitter loop:

#include <avr/sleep.h>
#include <avr/interrupt.h>

ISR(INT0_vect) { /* PIR interrupt wakes MCU */ }

void deepSleep() {
  set_sleep_mode(SLEEP_MODE_PWR_DOWN);
  sleep_enable();
  attachInterrupt(0, [](){}, RISING); // D2 = INT0
  sleep_mode();
  sleep_disable();
}

In sleep mode, the Arduino Nano draws only ~0.1µA (with power LED removed). The NRF24L01 in power-down mode draws 900nA. This combination extends battery life dramatically compared to polling loops. For solar-powered outdoor nodes, pair a 5V/1W solar panel with a 1000mAh LiPo and a solar charge controller module.

0.96 Inch SPI OLED LCD Module 7pin

0.96 Inch SPI OLED LCD Module + CSpin 7pin White SSD1306 Chip

High-contrast SPI OLED for fast base station display updates. SPI interface frees up I2C for other sensors like temperature or humidity monitoring.

View on Zbotic

ESP32-CAM-MB MICRO USB Download Module

ESP32-CAM-MB MICRO USB Download Module for ESP32 CAM

Program your ESP32-CAM base station without a separate USB-TTL adapter. The MB board adds a convenient Micro-USB port and reset button for hassle-free flashing.

View on Zbotic

Frequently Asked Questions

Does the NRF24L01 need a license to operate in India?

No. The 2.4 GHz ISM band used by the NRF24L01 is license-exempt in India under WPC (Wireless Planning and Coordination) regulations, just like Wi-Fi and Bluetooth. You can freely use it for hobby and personal projects without any permits.

My NRF24L01 is not communicating — what should I check first?

The most common cause is insufficient power. Add a 100µF electrolytic capacitor across VCC and GND on the NRF24L01 module. Also verify you are powering it from 3.3V (not 5V) and that both modules use the same channel and address bytes. Use radio.printDetails() on Serial Monitor to check configuration.

Can I use this system with an ESP8266 instead of Arduino?

Yes. The ESP8266 supports SPI and works with the RF24 library. The advantage is that the ESP8266’s Wi-Fi lets you send Telegram or WhatsApp alerts. Note that the ESP8266 GPIO runs at 3.3V logic, which is compatible with the NRF24L01. Use a logic level shifter only if connecting to Arduino Uno’s 5V pins.

How far can the NRF24L01 transmit through concrete walls?

Standard NRF24L01: 20–30 metres through 2–3 walls. NRF24L01+PA+LNA with external antenna: 50–80 metres through walls. For Indian RCC construction (thick walls + steel reinforcement), the PA+LNA variant is highly recommended. Reduce data rate to 250 kbps for better wall penetration.

Is HC-SR501 affected by Indian summer heat above 40°C?

The HC-SR501 is rated for –20°C to +80°C operation, so Indian summer temperatures pose no issue. However, when ambient temperature approaches body temperature (36–37°C), detection sensitivity reduces. Adjust the sensitivity potentiometer clockwise to compensate. For outdoor installations, shield the sensor from direct sunlight to avoid false triggers from rapid temperature changes.

Build Your Wireless Security System Today

Get all the components — NRF24L01 modules, OLEDs, relay modules, and ESP32 boards — delivered fast across India from Zbotic. Free shipping on orders above ₹999.

Shop Wireless Modules

Tags: Arduino security system, HC-SR501, nRF24L01, PIR sensor, wireless alert
Share Post
  • Facebook
  • Linkedin
  • Whatsapp
SIM800L vs SIM7600: GSM vs 4G ...
blog sim800l vs sim7600 gsm vs 4g lte module comparison india 596586
blog drv8833 motor driver dual dc motor control for esp32 596588
DRV8833 Motor Driver: Dual DC ...

Related posts

Svg%3E
Read more

ESP-NOW: Direct ESP32-to-ESP32 Communication Without WiFi

April 1, 2026 0
ESP-NOW ESP32 communication is a game-changing protocol developed by Espressif that enables direct peer-to-peer wireless communication between ESP32 boards without... Continue reading
Svg%3E
Read more

SDR Getting Started: HackRF and RTL-SDR Projects India

April 1, 2026 0
Software Defined Radio (SDR) lets you explore the electromagnetic spectrum using your computer, replacing expensive hardware radios with affordable USB... Continue reading
Svg%3E
Read more

Zigbee vs WiFi vs BLE: Choosing the Right Wireless Protocol for IoT

April 1, 2026 0
Choosing between Zigbee vs WiFi vs BLE for your IoT project is one of the most important design decisions you... Continue reading
Svg%3E
Read more

RFID Module Guide: RC522, PN532, and Long-Range UHF Options

April 1, 2026 0
The RFID module RC522 Arduino combination is the starting point for thousands of access control, attendance, and inventory tracking projects... Continue reading
Svg%3E
Read more

RS485 Modbus Communication: Industrial Sensors with Arduino

April 1, 2026 0
RS485 Modbus Arduino interfacing opens the door to industrial-grade sensor communication. Unlike hobbyist I2C or SPI sensors, RS485 Modbus sensors... Continue reading

Add comment Cancel reply

Your email address will not be published. Required fields are marked

Facebook Twitter Instagram Pinterest Linkedin Youtube

Get the latest deals and more.

Download on Google Play Download on the App Store

Call us: 020 69134444 / 1800 209 0998

Monday - Saturday 09:30 AM - 06:00 PM
For Technical Supports Email: [email protected]
For Sales / Enquiries Email: [email protected]

  • My Account

    • Cart

    • Wishlist

    • Checkout

    • My Orders

    • Track Order

    • My Account

  • Information

    • FAQs

    • Blogs

    • Career

    • About Us

    • Contact Us

    • Payment Options

  • Policies

    • Privacy Policy

    • Terms & Conditions

    • GST Input Tax Credit

    • Shipping Return Policy

    • E-Waste Collection Points

    • Our Sitemap

© Zbotic.in is registered trademark of Moxie Supply Pvt Ltd – All Rights Reserved
Login
Use Phone Number
Use Email Address
Not a member yet? Register Now
Reset Password
Use Phone Number
Use Email Address
Register
Already a member? Login Now