|
KiCADKicad
|
Automatic Residential Lighting System Board Based on AT89C51
In our day-to-day activities, we often don't remember to switch off or on the lights in our rooms. This system comes in to help us solve this problem whereby you don't need a physical switch but your movement does the job. The system will take care of everything automatically.
Modern-day technology has come to automatically take care of so many things ending up minimizing human involvement, saving time, and hence improving the standards of living.
The project we are implementing here does the automatic control of the light in the room.
Requirements;
- 5V Relay Module
- AT89C51 Microcontroller
- 16 x 2 LCD Display
- 2 x Infrared Sensors
- Power Supply
- Lamp
- 8051 Development Board
- Connecting Wires
The Circuit and Description
The circuit is designed in KiCAD. The circuit shows all the connections that are needed with consideration of the microcontroller. if you decided to do the same system using the microcontroller development board then some of the components connected in the schematic are not relevant.
On the circuit, we have to connect the LCD to the microcontroller pins P1.0 to Pin1.7. They connect the two IR sensors to the microcontroller too. The relay module is connected to pin P0.0. Through the schematic above, make sure you do all the connections as shown.
Components and description
5V relay module; It is used to help the 8051 microcontrollers to be able to control the high voltage gadgets like the lights. The detailed 5V relay connection is shown in the schematic listed below. The circuit is made up of an optocoupler, two resisters, a transistor, and two diodes.
The IR sensor Module; is a simple infrared sensor that serves the purpose of detecting objects by either proximity sensing or distance measuring. it is made up of the receiver, the transmitter, and the signal processing unit.
The project when ordered for manufacturing expects to see a gadget that looks like the attached image. The design was done in KiCAD where the circuit was converted into 3D design output before being forwarded to PCBway for manufacturing.
How the System works
The most important component of this system is the IR sensor and they have to be placed strategically for them to sense the movement. Their placement determines the functioning of the system. The sensor has to be placed on both sides of the door. The sensor placed inside the room is labeled sensor 2 and the one placed outside the door is called sensor1. When a person wants to access the room, sensor one will be the first to sense then sensor 2 which will notify the microcontroller that a person wants to access the room. The microcontroller will put on the light and increment the counter to 1 and if we have more people entering the room, the microcontroller will keep the light on and keep incrementing the counter accordingly.
On the other hand, when the person tries to leave the room, sensor 2 will detect that and the microcontroller will take note of that. The lights will not go off until the last person gets out of the room as per the counter.
How to implement such a project.
Visit PCBway and directly go to the instant quote page to order for the manufacturing of the circuit above into the board which will make the project implementation easy.
From KiCAD download all the design files such as the Gerber files, the pick and place files, the BOM, the drill files, etc which you shall upload to the PCBway instant quote website.
On the instant quote page, enter all your project specifications which include the color, the number of the boards, the size of your board, the material to be used, and the quality required then click on calculate to get the appropriate quote.
Hit add to cart then submit your Gerber files in the next window that pops up. The resultant outcome is that a team of experts will receive your final submission, correct the errors and give you the final quote.
Finally submit your payments using various payment methods available on the PCBway and seat back as you wait for your final product to be delivered within seven working days.
#include<reg51.h>
#define lcd P1
sbit rs=P3^6;
sbit e=P3^7;
sbit relay=P0^0;
sbit s1=P2^0;
sbit s2=P2^1;
void delay (int);
void cmd (char);
void display (char);
void init (void);
void string (char *);
void view (int);
int count=0;
int no[10]={48,49,50,51,52,53,54,55,56,57};
void delay (int d)
{
unsigned char i=0;
for(;d>0;d--)
{
for(i=250;i>0;i--);
for(i=248;i>0;i--);
}
}
void cmd (char c)
{
lcd=c;
rs=0;
e=1;
delay(5);
e=0;
}
void display (char c)
{
lcd=c;
rs=1;
e=1;
delay(5);
e=0;
}
void string (char *p)
{
while(*p)
{
display(*p++);
}
}
void view (int n)
{
cmd(0xc0);
display(no[(n/10)%10]);
display(no[n%10]);
}
void init (void)
{
cmd(0x38);
cmd(0x0c);
cmd(0x01);
cmd(0x80);
}
void main()
{
init();
string("counter........");
cmd(0xc0);
view(count);
while(1)
{
if(s1==1)
{
while(s2==0);
if(count!=99)
count=count+1;
while(s2==1);
view(count);
}
else if(s2==1)
{
while(s1==0);
if(count!=0)
count=count-1;
while(s1==1);
view(count);
}
else if(count==1)
relay=0;
else if(count==0)
relay=1;
}
}
Automatic Residential Lighting System Board Based on AT89C51
*PCBWay community is a sharing platform. We are not responsible for any design issues and parameter issues (board thickness, surface finish, etc.) you choose.
- Comments(0)
- Likes(1)
- Engineer Sep 23,2022
- 1 USER VOTES
- YOUR VOTE 0.00 0.00
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
-
7design
-
7usability
-
7creativity
-
7content
More by Simon Mugo
- High Power Three Channel LED Driver IntroductionI have been thinking about how to drive RGB LED patterns most simply. In my day-to-day r...
- 433 MHz Radio Frequency Transmitter Module IntroductionTwo devices can communicate with each other using radio frequencies and using an RF tran...
- Customized Servo Motor Driver Board IntroductionServo motors, also called rotary or linear actuators, are designed for minimal control o...
- Arduino Customized L298M Dual Motor Driver Module IntroductionThe Arduino Customized L298M Dual Motor Driver Module is designed to handle high-power D...
- Overvoltage Protection Board PrecautionBefore making use of the circuit in this design project, ensure that you first set the var...
- Automatic Residential Lighting System Board Based on AT89C51 In our day-to-day activities, we often don't remember to switch off or on the lights in our rooms. T...
- The Energy Saving Bulb Board The traditional incandescent bulb is an energy waster and it should be removed off shelves. My new t...
- ESP8266 MINI TEST BOARD Design Of The SchematicThe schematic design is done in KiCAD. The process starts with finding the da...
- POWER SUPPLY FOR THE ESP8266 ESP8266 is a microchip of low cost that is produced by a company by the name of ESPPRESSIF stems. It...
- 1N4148 INCOPORATING 741 IC TEMEPERATURE SENSOR Creating a simple temperature sensor using a diode (1N4148) and an operational amplifier (741 IC) is...
- TSL25911 Light Sensor IntroductionWe interact with different intensities and strengths of light in our daily activities. T...
- SIM800 GPS module ElevatorThis project demonstrates how you can develop various GPS/ GPRS and SMS capability developme...
- nRF51822 Mini Evaluation Board IntroductionDemand for development and evaluation boards the world over has increased. Due to such d...
- Customized LM393D Soil Moisture Sensor Board ElevatorThe project is good at converting analog signals from the soil to digital signals for soil m...
- PAM8403 Amplifier Module IntroductionThis is a simple project for improving your musical or audio entertainment by powering y...
- 741 IC Bass Booster IntroductionIn this project, we are going to design a bass booster circuit using the 741 IC. This is...
- LM317 AND LM337 ADJUSTABLE POWER SUPPLY CIRCUIT BOARD IntroductionThe LM317/LM337 symmetrical power supply circuit is an electronic setup for meeting the ...
- 230V AC to 1.5V DC PCB for Your Application IntroductionA power management integrated circuit (PMIC) is utilized to supply the necessary power t...
-
-
-
-
-
-
3D printed Enclosure Backplate for Riden RD60xx power supplies
153 1 1 -
-