Introduction: Simplest Object Counter & Room Electricity Controller Using Arduino and IR Sensors
It is quite simplest and C00L...Object_Counter, which counts objects. which are coming inside from door into the room and going outside from the door. This is a multi-purpose project this works as a object counter as well as room electricity controller which will be use for saving electricity automatically.
Apparatus required in that project-
2- 2x Infrared Sensors(IR sensors)
3- 6x Jumpers
Step-1 SENSOR CONNECTION
Firstly we'll connect the 2x IR senors with arduino uno board as shown in the ISIS professional snap in which the 1st IR sensor is connected to the A1 Analog pin of arduino uno and the second one is connected through A2 pin of arduino uno board.
Step-2 LED for indication
In the second step you have to connect a led for indication, if any one enter in the room the LED glows until every one getting out from the room. so you can connect the led across 11th digital pin of arduino and GND pin.
Step-3 Coding of arduino
#define sensor1 A1//IR SENSOR -1
#define sensor2 A2//IR SENSOR -2
pinMode(11,OUTPUT);// connect LED
const int s2=analogRead(sensor1);//TAKE INPUT FROM THE ANALOG PIN WHICH IS CONNECTED TO //SENSOR-1
const int s3=analogRead(sensor2);// " TAKE INPUT FROM THE ANALOG PIN WHICH IS CONNECTED TO //SENSORS-2
if(s2<200)// Adjust MIN Value of sensor-1 value according to your sensors
delay(700); // Remain same
if(s3<200)// " Adjust MIN Value of sensor-2 value according to your sensors
We have a be nice policy.
Please be positive and constructive.