Home
About Us
Achievement
Home
Raspberry-Pi Projects
_Raspberry Pi 4 Complete Guide
Arduino Project
_All Projects
Esp8266 Project
_All Projects
Esp32 Project
_Automation-with-feedback
RFID Light Controlling System | Arduino Uno Interfacing With RFID | Arduino Projects
Just Do Electronics
December 03, 2019
RFID Light Controlling System
CIRCUIT DIAGRAM
CODE
/* Arduino Simple RFID Access Control Using EM-18 RFID Reader Module Prateek singh https://www.prateeks.in */ #define RELAYPIN 3 #define WARNLEDPIN 5 char tag[] ="400035056818"; // Replace with your own Tag ID char input[12]; // A variable to store the Tag ID being presented int count = 0; // A counter variable to navigate through the input[] character array boolean flag = 0; // A variable to store the Tag match status void setup() { Serial.begin(9600); // Initialise Serial Communication with the Serial Monitor pinMode(RELAYPIN,OUTPUT); // RELAY OUTPUT pinMode(WARNLEDPIN,OUTPUT); //WRONG TAG INDICATOR } void loop() { if(Serial.available())// Check if there is incoming data in the RFID Reader Serial Buffer. { count = 0; // Reset the counter to zero while(Serial.available() && count < 12) { input[count] = Serial.read(); // Read 1 Byte of data and store it in the input[] variable count++; // increment counter delay(5); } if(count == 12) // { count =0; // reset counter varibale to 0 flag = 1; while(count<12 && flag !=0) { if(input[count]==tag[count]) flag = 1; // everytime the values match, we set the flag variable to 1 else flag= 0; count++; // increment i } } if(flag == 1) // If flag variable is 1, then it means the tags match { Serial.println("Access Allowed!"); digitalWrite(RELAYPIN,HIGH); delay (5000); digitalWrite (RELAYPIN,LOW); } else { Serial.println("Access Denied"); // Incorrect Tag Message digitalWrite(WARNLEDPIN,HIGH); delay(5000); digitalWrite(WARNLEDPIN,LOW); } for(count=0; count<12; count++) { input[count]= 'F'; } count = 0; // Reset counter variable } }
0 Comments
Newer
Older
Build Your Own Gps Tracking System using Arduino
How To Make RFID & Keypad Based Door Lock
IoT Based Fingerprint Biometric Attendance System Using NodeMCU (Esp8266)
ESP32 Interfacing With LDR Sensor
Ultrasonic Sensor as a Counter with Arduino
IoT Based Patient Health Monitoring System Using Blynk App
Nodemcu Interfacing With Em-18
OTP Based Door Lock Using Arduino And SIM800L
Esp32 Cam Based Face Unlock
MLX90614 Non-Contact Infrared Thermometer With Arduino
YouTube
Like on Facebook
Follow on Twitter
Follow on Google+
Follow on Instagram
Subscribe on Youtube
Hi WelCome To My Website If you have a creative mind and want to learn Electronics even without studying it then FRIENDS this Website And Youtube Channel is for you, I am crazy creators who love making Electronics things. I have a bunch of more than 130 Tutorial Videos on My YouTube Channel and I upload a new Tutorial every Sunday.
Tags
Arduino Project
Esp32 Project
Esp8266 Project
0 Comments