Introduction
In today’s world, technology is making our lives easier in many ways. One such example of technology is home automation. Automation of our homes using technology is becoming increasingly popular, and one area that has seen a lot of growth in lighting automation. Home automation lighting systems not only bring convenience but also add style to our homes. With the help of advanced controllers like the Arduino Nano, Relay Module, HC-SR04 Module, and LEDs, we can control our home lights using hand motions. In this article, we are going to showcase a Hand Motion Controlled Light system using Arduino Nano, Relay Module, HC-SR04 Module, and LEDs.
As technology advances, there has been a massive revolution in the way we control various appliances at home. Hand motion control has been an emerging technology that has greatly improved our lives. One such example of hand motion control is the hand motion-controlled light. This technology allows you to control your lights without touching any switches, making it a unique and efficient method of controlling the lights.
To make a Hand Motion Controlled Light, you need an Arduino Nano, a relay module, an HC-SR04 module, and LEDs. The Arduino Nano is a microcontroller that forms the backbone of the Hand Motion Controlled Light. The relay module allows the microcontroller to control the light circuit. On the other hand, the HC-SR04 module detects the hand motions and triggers the relay circuit via the Arduino Nano. The LEDs are the lighting elements that you control with your hand motions.
The Hand Motion Controlled Light is a great addition to any home or office. It is highly efficient and convenient, especially when you are carrying luggage or other items that could make it difficult to reach the light switch. It is also an ideal solution for people who are physically challenged and unable to reach the switches.
Overall, the Hand Motion Controlled Light is an excellent example of how technology can make our lives easier and more comfortable. It is an innovative approach to lighting control that is worth exploring, and with the help of Arduino Nano, relay module, HC-SR04 module, and LEDs, you can build your own hand motion-controlled light system, bringing efficiency and convenience to your home or office.
Project Video:
Following is the project video of this article which is already uploaded to the YouTube Channel. You can view it here or switch to YouTube Channel for more interesting videos.
Circuit Diagram
of Hand Motion Controlled Light
The Hand Motion Controlled Light Circuit Diagram using Arduino Nano, Relay Module, HC-SR04 Module, and LEDs is a simple but innovative project that allows you to control the lighting of an area without having to touch any switches. The following Circuit Diagram is made up of an Arduino Nano board, which acts as the brain of the system, a relay module which is used to switch the LEDs, an HC-SR04 module which is used to sense hand motions, and LEDs which are used as the light source.
More Circuit Layouts
Components List
of Hand Motion Controlled Light
- Arduino Nano
- Relay Module
- HC-SR04 Module
- 12V LEDs
- jumper wires
- PCB
- Power Supply
- Gerber files: https://drive.google.com/file/d/1EGhpiEN7ZfH9fLQUl4_aCnM7aJMn6m9Q/view
- code: Arduino File : https://drive.google.com/file/d/1qqrxhWFx00wDNIobqdSSN45Fk_8_howe/view
- zip File : https://drive.google.com/file/d/1NLfGe8f5v_A1DKsN0jiQ4d4dgF7nHGlh/view
- Text File : https://drive.google.com/file/d/1sHAEfZT5ctIgWUYZdukBaSFalKLIwSoq/view
Arduino Code
# define distance 8
long duration, inches, inches1;
bool a,b;
void setup() {
pinMode(2, INPUT); //echo a
pinMode(4, INPUT); //echo b
pinMode(3, OUTPUT); //trig a
pinMode(5, OUTPUT); //trig b
pinMode(13, OUTPUT); // output
}
void loop() {
// put your main code here, to run repeatedly:
digitalWrite(3, LOW);
delayMicroseconds(2);
digitalWrite(3, HIGH);
delayMicroseconds(10);
digitalWrite(3, LOW);
duration = pulseIn(2, HIGH);
inches = microsecondsToInches(duration);
if(inches<distance&!a){
a=1;
if(b){
b=0;
a=0;
digitalWrite(13, LOW);
}
delay(50);
}
digitalWrite(5, LOW);
delayMicroseconds(2);
digitalWrite(5, HIGH);
delayMicroseconds(10);
digitalWrite(5, LOW);
duration = pulseIn(4, HIGH);
inches1 = microsecondsToInches(duration);
if(inches1<distance&!b){
b=1;
if(a){
b=0;
a=0;
digitalWrite(13, HIGH);
}
delay(50);
}
Serial.print(" in1=");
Serial.print(inches);
Serial.print(" in2=");
Serial.println(inches1);
}
long microsecondsToInches(long microseconds) {
return microseconds / 74 / 2;
}
Working Explanation
of Hand Motion Controlled Light
Controlling lights with hand gestures has always been an intriguing concept, and the idea of doing it without touching any physical switch is even more fascinating. With the help of a few components, we can create an interface that detects hand motion and activates lights accordingly. In this article, we will guide you on how to build your hand motion-controlled light using an Arduino Nano, Relay Module, HC-SR04 Module, and LEDs.
Before jumping into the construction process, let’s look at the key components and how they work together.
Arduino Nano
Arduino Nano is a microcontroller board designed to work with small sensors and actuators. It is based on the ATmega328 microcontroller and has a similar architecture to the Arduino Uno. However, it is smaller in size, making it more suitable for projects with limited space. Arduino Nano has 14 digital input/output pins, six analog inputs, a reset button, and a USB interface.
Relay Module
A relay module is an electronic switch that can be used to control high voltages and currents with a low voltage signal. The module consists of a relay, a driver circuit, and a switch. When the input signal is applied, the driver circuit energizes the relay, which closes the switch and allows the current to flow through it. In our project, we will use a relay module to control the power supply of the LEDs.
HC-SR04 Module
The HC-SR04 module is an ultrasonic distance sensor that is commonly used in robotics projects. It works by emitting high-frequency sound waves and measuring the time it takes for the sound waves to bounce off an object and return to the sensor. This time can be used to calculate the distance between the sensor and the object. We will use the HC-SR04 module to detect hand motion and activate the lights.
LEDs
Light-emitting diodes (LEDs) are electronic components that emit light when current flows through them. LEDs are widely used in lighting applications because they are energy-efficient, long-lasting, and produce less heat than traditional bulbs. In our project, we will use LEDs to provide the light source.
Now we have a general understanding of the key components and their functions let’s get into the process of constructing the Hand Motion Controlled Light.
Step 1: Gathering the Materials
Before we start building our project, it’s essential to gather all the materials that we’ll need. This project requires an Arduino Nano, Relay Module, HC-SR04 Module, LEDs, breadboard, jumper wires, and a power supply. Additionally, since we are working with high voltage, we need to take some safety precautions. The following materials are required for the project:
• Arduino Nano • Relay Module • HC-SR04 Module • LEDS • Breadboard • Jumper Wires • Power Supply
Step 2: Connecting the Components
Once we have all the materials required, we need to begin connecting the components. Firstly, we connect the HC-SR04 module to the Arduino Nano. We will connect it to the digital pins 4 and 5 of the Nano. The Trigger pin of the HC-SR04 module will be connected to pin 4, while the Echo pin will be connected to pin 5. Next, we will connect the Relay module to the Arduino Nano. We will connect the Relay Module to the digital pin 6 of the Nano. We connect the Vcc pin of the Relay Module to the positive rail on the breadboard and the Gnd pin to the negative rail on the board.
Step 3: Powering the LEDs
We will use the Relay Module to control the power supply of the LEDs. We will connect the LEDs in parallel with a 330 ohms resistor to the Relay module. The positive pin of the LED will be connected to the NO (Normally Open) Pin of the Relay Module, while the negative terminal of the LEDs will be connected to the negative rail of the breadboard.
Step 4: Coding the Arduino
After connecting all the components, it’s time to write the code for the Arduino Nano. We will use the HC-SR04 sensor to detect the distance between the hand and the sensor. When a hand is detected within a certain distance, the Relay Module will turn ON, and the LEDs will light up. When the hand moves away, the Relay Module will turn OFF, and the LEDs will turn off.
Conclusion
In conclusion, the hand motion-controlled light system using Arduino Nano, Relay Module, HC-SR04 Module, and LEDs is an excellent project for anyone interested in home automation lighting systems. This project can be easily adapted to work with other components, and the program can be tweaked to suit your needs.
More projects, You may like:
- Video Transmitter DIY Homemade FM Radio Transmitter
- Adjustable Power Supply DIY Battery Charger
- 12V-220V 500 Watt inverter DIY Homemade
- 12V-220V H-Bridge Inverter DIY Homemade
- MPPT Solar Charge Controller DIY Homemade
- 18650 battery bank free charge protection module
- D718 B688 Bass Amplifier Homemade DIY
- C5200 Bass Amplifier DIY Homemade with Volume
- DIY LA4440 bass amplifier homemade
- C5200 A1943 TDA2030 Amplifier DIY Homemade