SlideShare uma empresa Scribd logo
1 de 21
Attendance System using ESP8266(Wi-Fi)
with MySQL
By Deligence Technologies
www.deligence.com
What we will Cover?
Project Description
Software Required
Hardware Required
Node MCU V3
RFID-RC522
Circuit Diagram
CODE: (Node MCU ESP8266)
CODE: (PHP)
Video Presentation
Project Description
Here We are going to connect
Node MCU ESP8266 and RFID-
RC522 with MYSQL Database. So
for that first we should connect
our Node MCU ESP8266 Board
with RFID Module. By using the
RFID Module we are going to
scan our RFID card and tag which
are allow or not. And by using
our ESP8266 we are going to
send that data to our MYSQL
Database which is connect
through a php page.
You can watch it in action in slide
20.
Software Used
 Arduino IDE
 LAMP Server for Linux or WAMP Server for Windows or MAMP Server for MAC OS
Hardware Used
 Node MCU V3
 RFID Reader with Tag
 Jumper Wire
Node MCU V3
Node MCU is an open source IOT platform. It includes
firmware which runs on the ESP8266 Wi-Fi SoC from
hardware which is based on the ESP-12 module. The term
"Node MCU" by default refers to the firmware rather than
the dev kits.
RFID-RC522
RFID RC522 is a low cost and easy to use module suitable
for equipment and advanced application development that
needs RFID applications. RFID application. RFID stands for
Radio-Frequency Identification. The acronym refers to small
electronic devices that consist of a small chip and an
antenna.
Circuit Diagram
CODE: (Node MCU ESP8266)
#include<SoftwareSerial.h>
#include <ESP8266WiFi.h>
#include <WiFiClient.h>
#include <ESP8266WebServer.h>
#include <ESP8266mDNS.h>
#include <SPI.h>
#include <MFRC522.h>
const char* ssid = "TP-LINK_28C6";
const char* password = "02105604";
//WiFiClient client;
char server[] = "192.168.0.115"; //YOUR SERVER
#define SS_PIN 2 //FOR RFID SS PIN BECASUSE WE ARE USING BOTH ETHERNET
SHIELD AND RS-522
#define RST_PIN 15
#define No_Of_Card 3
Cont…. >>>>>
CODE: (Node MCU ESP8266)
WiFiClient client;
//WiFiServer server(80);
SoftwareSerial mySerial(8,9);
MFRC522 rfid(SS_PIN,RST_PIN);
MFRC522::MIFARE_Key key;
byte id[No_Of_Card][4]={
{44,153,22,219}, //RFID NO-1
{112,224,72,84}, //RFID NO-2
{151,94,80,84} //RFID NO-3
};
byte id_temp[3][3];
byte i;
int j=0;
Cont…. >>>>>
CODE: (Node MCU ESP8266)
for(byte i=0;i<6;i++)
{
key.keyByte[i]=0xFF;
}
// Connect to WiFi network
Serial.println();
Serial.println();
Serial.print("Connecting to ");
Serial.println(ssid);
WiFi.begin(ssid, password);
while (WiFi.status() != WL_CONNECTED) {
delay(500);
Serial.print(".");
}
Serial.println("");
Serial.println("WiFi connected");
Cont…. >>>>>
CODE: (Node MCU ESP8266)
// Start the server
// server.begin();
Serial.println("Server started");
Serial.print(WiFi.localIP());
delay(1000);
Serial.println("connecting...");
}
void loop()
{ // Check if a client has connected
int m=0;
if(!rfid.PICC_IsNewCardPresent())
return;
if(!rfid.PICC_ReadCardSerial())
return;
for(i=0;i<4;i++)
{
id_temp[0][i]=rfid.uid.uidByte[i];
delay(50);
} Cont…. >>>>>
for(i=0;i<No_Of_Card;i++)
{
if(id[i][0]==id_temp[0][0])
{
if(id[i][1]==id_temp[0][1])
{
if(id[i][2]==id_temp[0][2])
{
if(id[i][3]==id_temp[0][3])
{
Serial.print("your card no :");
for(int s=0;s<4;s++)
{
Serial.print(rfid.uid.uidByte[s]);
Serial.print(" ");
}
Cont…. >>>>>
CODE: (Node MCU ESP8266)
CODE: (Node MCU ESP8266)
Serial.println("nVALID");
Sending_To_DB();
j=0;
rfid.PICC_HaltA(); rfid.PCD_StopCrypto1(); return;
}
}
}
}
else
{j++;
if(j==No_Of_Card)
{
Serial.println("inVALID");
Sending_To_DB();
j=0;
}
}
} Cont…. >>>>>
CODE: (Node MCU ESP8266)
// Halt PICC
rfid.PICC_HaltA();
// Stop encryption on PCD
rfid.PCD_StopCrypto1();
}
void Sending_To_DB() //CONNECTING WITH MYSQL
{
if (client.connect(server, 80)) {
Serial.println("connected");
// Make a HTTP request:
Serial.println("GET /rfid/rfid_read.php?allow="); //YOUR URL
/rfid/rfid_read.php?allow
client.print("GET /rfid/nodemcu_rfid/rfid_read.php?allow="); //YOUR URL
/rfid/rfid_read.php?allow /var/www/html/rfid/rfid_read.php
Cont…. >>>>>
CODE: (Node MCU ESP8266)
if(j!=No_Of_Card)
{
Serial.println('1');
client.print('1');
}
else
{
Serial.println('0');
client.print('0');
}
Serial.println("&id=");
client.print("&id=");
for(int s=0;s<4;s++)
{
Serial.println(rfid.uid.uidByte[s]);
client.print(rfid.uid.uidByte[s]);
}
Cont…. >>>>>
CODE: (Node MCU ESP8266)
client.print(" "); //SPACE BEFORE HTTP/1.1
client.print("HTTP/1.1");
client.print("Host: ");
client.println(server);
client.println("Host: 192.168.0.115");
client.println("Connection: close");
client.println();
} else {
// if you didn't get a connection to the server:
Serial.println("connection failed");
}
client.stop();
}
CODE: (PHP)
<?php
class rfid{
public $link='';
function __construct($allow, $id){
$this->connect();
$this->storeInDB($allow, $id);
}
function connect(){
$this->link = mysqli_connect('localhost','root','Deligence@1') or die('Cannot
connect to the DB');
mysqli_select_db($this->link,'rfidesp') or die('Cannot select the DB');
}
Cont…. >>>>>
CODE: (PHP)
function storeInDB($allow, $id){
$query = "insert into rfid set rfid='".$id."', allow='".$allow."'";
$result = mysqli_query($this->link,$query) or die('Errant query: '.$query);
}
}
if($_GET['allow'] != '' and $_GET['id'] != ''){
$rfid=new rfid($_GET['allow'],$_GET['id']);
}
?>
You can get it's source code at -
https://github.com/DeligenceTechnologies/
Attendance-System-using-ESP8266-Wi-Fi-
with-MySQL
In case, you need any Embedded Systems
Development or IoT work - you can send an
email to us at sales @ deligence.com
Deligence Technologies –
(your growing technology partner)
www.deligence.com/contact-us
Email : info@deligence.com
Phone : +91 9910130340
Attendance System using ESP8266(Wi-Fi) with MySQL

Mais conteúdo relacionado

Mais procurados

Smart shopping trolley using rfid and remote controlling
Smart shopping trolley using rfid and remote controllingSmart shopping trolley using rfid and remote controlling
Smart shopping trolley using rfid and remote controllingPranav Veerani
 
Rfid based smart attendance system
Rfid based smart attendance systemRfid based smart attendance system
Rfid based smart attendance systemafserfec56
 
Introduction to ESP32 Programming [Road to RIoT 2017]
Introduction to ESP32 Programming [Road to RIoT 2017]Introduction to ESP32 Programming [Road to RIoT 2017]
Introduction to ESP32 Programming [Road to RIoT 2017]Alwin Arrasyid
 
RFID (Radio Frequency Identification)
RFID (Radio Frequency Identification)RFID (Radio Frequency Identification)
RFID (Radio Frequency Identification)Amber Bhaumik
 
Rfid based attendance system using arduino (1)
Rfid based attendance system using arduino (1)Rfid based attendance system using arduino (1)
Rfid based attendance system using arduino (1)AWANISHKUMAR84
 
lesson2 - Nodemcu course - NodeMCU dev Board
 lesson2 - Nodemcu course - NodeMCU dev Board lesson2 - Nodemcu course - NodeMCU dev Board
lesson2 - Nodemcu course - NodeMCU dev BoardElaf A.Saeed
 
Rfid Attadance System ( Project PPt )
Rfid Attadance System ( Project PPt )Rfid Attadance System ( Project PPt )
Rfid Attadance System ( Project PPt )Bhautik Vaghela
 
WOMEN SAFETY DEVICE USING NFC
WOMEN SAFETY DEVICE USING NFC WOMEN SAFETY DEVICE USING NFC
WOMEN SAFETY DEVICE USING NFC venkteshb
 
Applications of RFID technology
Applications of RFID technologyApplications of RFID technology
Applications of RFID technologysweta dargad
 
“Making Edge AI Inference Programming Easier and Flexible,” a Presentation fr...
“Making Edge AI Inference Programming Easier and Flexible,” a Presentation fr...“Making Edge AI Inference Programming Easier and Flexible,” a Presentation fr...
“Making Edge AI Inference Programming Easier and Flexible,” a Presentation fr...Edge AI and Vision Alliance
 
Boards for the IoT-Prototyping
Boards for the IoT-PrototypingBoards for the IoT-Prototyping
Boards for the IoT-PrototypingLars Gregori
 
Rfid technology next generation application solutions
Rfid technology next generation application solutionsRfid technology next generation application solutions
Rfid technology next generation application solutionsashtopustech
 
Fire fighting robot using arduino
Fire fighting robot using arduinoFire fighting robot using arduino
Fire fighting robot using arduinoNiranjan Kumar
 
Home security system using iot
Home security system using iotHome security system using iot
Home security system using iotMDMarufMF
 

Mais procurados (20)

Smart shopping trolley using rfid and remote controlling
Smart shopping trolley using rfid and remote controllingSmart shopping trolley using rfid and remote controlling
Smart shopping trolley using rfid and remote controlling
 
Wi-Fi Esp8266 nodemcu
Wi-Fi Esp8266 nodemcu Wi-Fi Esp8266 nodemcu
Wi-Fi Esp8266 nodemcu
 
Rfid based smart attendance system
Rfid based smart attendance systemRfid based smart attendance system
Rfid based smart attendance system
 
Ppt on embedded systems
Ppt on embedded systemsPpt on embedded systems
Ppt on embedded systems
 
Introduction to ESP32 Programming [Road to RIoT 2017]
Introduction to ESP32 Programming [Road to RIoT 2017]Introduction to ESP32 Programming [Road to RIoT 2017]
Introduction to ESP32 Programming [Road to RIoT 2017]
 
RFID (Radio Frequency Identification)
RFID (Radio Frequency Identification)RFID (Radio Frequency Identification)
RFID (Radio Frequency Identification)
 
Rfid based attendance system using arduino (1)
Rfid based attendance system using arduino (1)Rfid based attendance system using arduino (1)
Rfid based attendance system using arduino (1)
 
lesson2 - Nodemcu course - NodeMCU dev Board
 lesson2 - Nodemcu course - NodeMCU dev Board lesson2 - Nodemcu course - NodeMCU dev Board
lesson2 - Nodemcu course - NodeMCU dev Board
 
Rfid Attadance System ( Project PPt )
Rfid Attadance System ( Project PPt )Rfid Attadance System ( Project PPt )
Rfid Attadance System ( Project PPt )
 
WOMEN SAFETY DEVICE USING NFC
WOMEN SAFETY DEVICE USING NFC WOMEN SAFETY DEVICE USING NFC
WOMEN SAFETY DEVICE USING NFC
 
Applications of RFID technology
Applications of RFID technologyApplications of RFID technology
Applications of RFID technology
 
Rfid security access control system
Rfid security access control systemRfid security access control system
Rfid security access control system
 
“Making Edge AI Inference Programming Easier and Flexible,” a Presentation fr...
“Making Edge AI Inference Programming Easier and Flexible,” a Presentation fr...“Making Edge AI Inference Programming Easier and Flexible,” a Presentation fr...
“Making Edge AI Inference Programming Easier and Flexible,” a Presentation fr...
 
RFID
RFIDRFID
RFID
 
Boards for the IoT-Prototyping
Boards for the IoT-PrototypingBoards for the IoT-Prototyping
Boards for the IoT-Prototyping
 
RFID
RFID RFID
RFID
 
Rfid technologies
Rfid technologiesRfid technologies
Rfid technologies
 
Rfid technology next generation application solutions
Rfid technology next generation application solutionsRfid technology next generation application solutions
Rfid technology next generation application solutions
 
Fire fighting robot using arduino
Fire fighting robot using arduinoFire fighting robot using arduino
Fire fighting robot using arduino
 
Home security system using iot
Home security system using iotHome security system using iot
Home security system using iot
 

Destaque

IoT(internet of thing) Based working of Smart devices
IoT(internet of thing) Based working of Smart devices IoT(internet of thing) Based working of Smart devices
IoT(internet of thing) Based working of Smart devices Ahmad Kamal
 
IOT: Home Automation using Android Application
IOT: Home Automation using Android ApplicationIOT: Home Automation using Android Application
IOT: Home Automation using Android ApplicationNikhil Jadav
 
Home automation using IoT
Home automation using IoTHome automation using IoT
Home automation using IoTAthira_1993
 
Voice Control Home Automation
Voice Control Home AutomationVoice Control Home Automation
Voice Control Home AutomationAbhishek Neb
 
Home automation using android mobiles
Home automation using android mobilesHome automation using android mobiles
Home automation using android mobilesDurairaja
 

Destaque (7)

IoT(internet of thing) Based working of Smart devices
IoT(internet of thing) Based working of Smart devices IoT(internet of thing) Based working of Smart devices
IoT(internet of thing) Based working of Smart devices
 
IOT: Home Automation using Android Application
IOT: Home Automation using Android ApplicationIOT: Home Automation using Android Application
IOT: Home Automation using Android Application
 
Home automation using IoT
Home automation using IoTHome automation using IoT
Home automation using IoT
 
Presentation on home automation
Presentation on home automationPresentation on home automation
Presentation on home automation
 
Voice controlled home appliances
Voice controlled home appliancesVoice controlled home appliances
Voice controlled home appliances
 
Voice Control Home Automation
Voice Control Home AutomationVoice Control Home Automation
Voice Control Home Automation
 
Home automation using android mobiles
Home automation using android mobilesHome automation using android mobiles
Home automation using android mobiles
 

Semelhante a Attendance System using ESP8266(Wi-Fi) with MySQL

Attendance system using MYSQL with Raspberry pi and RFID-RC522
Attendance system using MYSQL with Raspberry pi and RFID-RC522Attendance system using MYSQL with Raspberry pi and RFID-RC522
Attendance system using MYSQL with Raspberry pi and RFID-RC522Sanjay Kumar
 
Arduino Interface with MySQL for Storing RFID Access Details
Arduino Interface with MySQL for Storing RFID Access DetailsArduino Interface with MySQL for Storing RFID Access Details
Arduino Interface with MySQL for Storing RFID Access DetailsSanjay Kumar
 
Monitoring temperature rumah dengan display lcd dan recording
Monitoring temperature rumah dengan display lcd dan recordingMonitoring temperature rumah dengan display lcd dan recording
Monitoring temperature rumah dengan display lcd dan recordingMR Selamet
 
Monitoring temperature ruangan dengan display lcd
Monitoring temperature ruangan dengan display lcdMonitoring temperature ruangan dengan display lcd
Monitoring temperature ruangan dengan display lcdsiti_haryani
 
Monitoring Temperature Room With Display LCD and Data Recording
Monitoring Temperature Room With Display LCD and Data RecordingMonitoring Temperature Room With Display LCD and Data Recording
Monitoring Temperature Room With Display LCD and Data RecordingMR Selamet
 
Monitoring temperature ruangan dengan display lcd
Monitoring temperature ruangan dengan display lcdMonitoring temperature ruangan dengan display lcd
Monitoring temperature ruangan dengan display lcdmukhammadimam
 
Monitoring temperature rumah dengan display lcd dan recording
Monitoring temperature rumah dengan display lcd dan recordingMonitoring temperature rumah dengan display lcd dan recording
Monitoring temperature rumah dengan display lcd dan recordingYuda Wardiana
 
FPGA Based IP Core Initialization for Ps2-Vga Peripherals Using Microblaze Pr...
FPGA Based IP Core Initialization for Ps2-Vga Peripherals Using Microblaze Pr...FPGA Based IP Core Initialization for Ps2-Vga Peripherals Using Microblaze Pr...
FPGA Based IP Core Initialization for Ps2-Vga Peripherals Using Microblaze Pr...IJERA Editor
 
Mypptinslideshare 180508104046 (1)
Mypptinslideshare 180508104046 (1)Mypptinslideshare 180508104046 (1)
Mypptinslideshare 180508104046 (1)raviteja srinivasula
 
RFID based smart shopping cart and billing system
RFID based smart shopping cart and billing systemRFID based smart shopping cart and billing system
RFID based smart shopping cart and billing systemlaharipothula
 
Open Source Home Automation with LinkSprite.IO
Open Source Home Automation with LinkSprite.IOOpen Source Home Automation with LinkSprite.IO
Open Source Home Automation with LinkSprite.IOJingfeng Liu
 
Home Automation with LinkSprite IO
Home Automation with LinkSprite IOHome Automation with LinkSprite IO
Home Automation with LinkSprite IOJingfeng Liu
 
RAHUL NASKAR IOT.ppt
RAHUL NASKAR IOT.pptRAHUL NASKAR IOT.ppt
RAHUL NASKAR IOT.pptPrakasBhowmik
 
用Raspberry Pi 學Linux I2C Driver
用Raspberry Pi 學Linux I2C Driver用Raspberry Pi 學Linux I2C Driver
用Raspberry Pi 學Linux I2C Driver艾鍗科技
 
Implementation of secure rfid on fpga
Implementation of secure rfid on fpgaImplementation of secure rfid on fpga
Implementation of secure rfid on fpgaansh1692
 
Implementation of secure rfid on fpga
Implementation of secure rfid on fpgaImplementation of secure rfid on fpga
Implementation of secure rfid on fpgaansh1692
 
NFCRFID Ripe for Application Expansion_ElectronicDesign
NFCRFID Ripe for Application Expansion_ElectronicDesignNFCRFID Ripe for Application Expansion_ElectronicDesign
NFCRFID Ripe for Application Expansion_ElectronicDesignHamed M. Sanogo
 

Semelhante a Attendance System using ESP8266(Wi-Fi) with MySQL (20)

Attendance system using MYSQL with Raspberry pi and RFID-RC522
Attendance system using MYSQL with Raspberry pi and RFID-RC522Attendance system using MYSQL with Raspberry pi and RFID-RC522
Attendance system using MYSQL with Raspberry pi and RFID-RC522
 
Arduino Interface with MySQL for Storing RFID Access Details
Arduino Interface with MySQL for Storing RFID Access DetailsArduino Interface with MySQL for Storing RFID Access Details
Arduino Interface with MySQL for Storing RFID Access Details
 
Monitoring temperature rumah dengan display lcd dan recording
Monitoring temperature rumah dengan display lcd dan recordingMonitoring temperature rumah dengan display lcd dan recording
Monitoring temperature rumah dengan display lcd dan recording
 
Monitoring temperature ruangan dengan display lcd
Monitoring temperature ruangan dengan display lcdMonitoring temperature ruangan dengan display lcd
Monitoring temperature ruangan dengan display lcd
 
Monitoring Temperature Room With Display LCD and Data Recording
Monitoring Temperature Room With Display LCD and Data RecordingMonitoring Temperature Room With Display LCD and Data Recording
Monitoring Temperature Room With Display LCD and Data Recording
 
Monitoring temperature ruangan dengan display lcd
Monitoring temperature ruangan dengan display lcdMonitoring temperature ruangan dengan display lcd
Monitoring temperature ruangan dengan display lcd
 
Monitoring temperature rumah dengan display lcd dan recording
Monitoring temperature rumah dengan display lcd dan recordingMonitoring temperature rumah dengan display lcd dan recording
Monitoring temperature rumah dengan display lcd dan recording
 
FPGA Based IP Core Initialization for Ps2-Vga Peripherals Using Microblaze Pr...
FPGA Based IP Core Initialization for Ps2-Vga Peripherals Using Microblaze Pr...FPGA Based IP Core Initialization for Ps2-Vga Peripherals Using Microblaze Pr...
FPGA Based IP Core Initialization for Ps2-Vga Peripherals Using Microblaze Pr...
 
Mypptinslideshare 180508104046 (1)
Mypptinslideshare 180508104046 (1)Mypptinslideshare 180508104046 (1)
Mypptinslideshare 180508104046 (1)
 
RFID based smart shopping cart and billing system
RFID based smart shopping cart and billing systemRFID based smart shopping cart and billing system
RFID based smart shopping cart and billing system
 
Open Source Home Automation with LinkSprite.IO
Open Source Home Automation with LinkSprite.IOOpen Source Home Automation with LinkSprite.IO
Open Source Home Automation with LinkSprite.IO
 
Home Automation with LinkSprite IO
Home Automation with LinkSprite IOHome Automation with LinkSprite IO
Home Automation with LinkSprite IO
 
RAHUL NASKAR IOT.ppt
RAHUL NASKAR IOT.pptRAHUL NASKAR IOT.ppt
RAHUL NASKAR IOT.ppt
 
用Raspberry Pi 學Linux I2C Driver
用Raspberry Pi 學Linux I2C Driver用Raspberry Pi 學Linux I2C Driver
用Raspberry Pi 學Linux I2C Driver
 
Implementation of secure rfid on fpga
Implementation of secure rfid on fpgaImplementation of secure rfid on fpga
Implementation of secure rfid on fpga
 
Implementation of secure rfid on fpga
Implementation of secure rfid on fpgaImplementation of secure rfid on fpga
Implementation of secure rfid on fpga
 
NFCRFID Ripe for Application Expansion_ElectronicDesign
NFCRFID Ripe for Application Expansion_ElectronicDesignNFCRFID Ripe for Application Expansion_ElectronicDesign
NFCRFID Ripe for Application Expansion_ElectronicDesign
 
WiFi SoC ESP8266
WiFi SoC ESP8266WiFi SoC ESP8266
WiFi SoC ESP8266
 
ESP8266 Wifi Nodemcu
ESP8266 Wifi Nodemcu ESP8266 Wifi Nodemcu
ESP8266 Wifi Nodemcu
 
Esp8266 v12
Esp8266 v12Esp8266 v12
Esp8266 v12
 

Mais de Sanjay Kumar

Mobile app development
Mobile app developmentMobile app development
Mobile app developmentSanjay Kumar
 
Accelerated Mobile Pages (AMP)
Accelerated Mobile Pages (AMP)Accelerated Mobile Pages (AMP)
Accelerated Mobile Pages (AMP)Sanjay Kumar
 
Serial Data from Arduino to Raspberry Pi to MySQL using CoAP Protocol
Serial Data from Arduino to Raspberry Pi to MySQL using CoAP ProtocolSerial Data from Arduino to Raspberry Pi to MySQL using CoAP Protocol
Serial Data from Arduino to Raspberry Pi to MySQL using CoAP ProtocolSanjay Kumar
 
Arduino to Control Bulbs using Web App
Arduino to Control Bulbs using Web AppArduino to Control Bulbs using Web App
Arduino to Control Bulbs using Web AppSanjay Kumar
 
Bulb Control using Web App with Raspberry Pi
Bulb Control using Web App with Raspberry Pi Bulb Control using Web App with Raspberry Pi
Bulb Control using Web App with Raspberry Pi Sanjay Kumar
 
Obstacle detection Robot using Ultrasonic Sensor and Arduino UNO
Obstacle detection Robot using Ultrasonic Sensor and Arduino UNOObstacle detection Robot using Ultrasonic Sensor and Arduino UNO
Obstacle detection Robot using Ultrasonic Sensor and Arduino UNOSanjay Kumar
 
Arduino Interface LM35 MQTT Using UART
Arduino Interface LM35 MQTT Using UARTArduino Interface LM35 MQTT Using UART
Arduino Interface LM35 MQTT Using UARTSanjay Kumar
 
Rain Drop Sensor using Arduino!
Rain Drop Sensor using Arduino!Rain Drop Sensor using Arduino!
Rain Drop Sensor using Arduino!Sanjay Kumar
 
Arduino Programming Software Development
Arduino Programming Software DevelopmentArduino Programming Software Development
Arduino Programming Software DevelopmentSanjay Kumar
 
Embedded Software Development
Embedded Software DevelopmentEmbedded Software Development
Embedded Software DevelopmentSanjay Kumar
 
Ionic - Hybrid Mobile Application Framework
Ionic - Hybrid Mobile Application FrameworkIonic - Hybrid Mobile Application Framework
Ionic - Hybrid Mobile Application FrameworkSanjay Kumar
 
Internet of Things - IOT
Internet of Things - IOTInternet of Things - IOT
Internet of Things - IOTSanjay Kumar
 
Meteor Mobile App Development
Meteor Mobile App DevelopmentMeteor Mobile App Development
Meteor Mobile App DevelopmentSanjay Kumar
 
Digital Marketing Strategy
Digital Marketing StrategyDigital Marketing Strategy
Digital Marketing StrategySanjay Kumar
 
Web Application Development
Web Application DevelopmentWeb Application Development
Web Application DevelopmentSanjay Kumar
 
Joomla Website Development Company
Joomla Website Development CompanyJoomla Website Development Company
Joomla Website Development CompanySanjay Kumar
 
Meteor js App Development
Meteor js App DevelopmentMeteor js App Development
Meteor js App DevelopmentSanjay Kumar
 

Mais de Sanjay Kumar (17)

Mobile app development
Mobile app developmentMobile app development
Mobile app development
 
Accelerated Mobile Pages (AMP)
Accelerated Mobile Pages (AMP)Accelerated Mobile Pages (AMP)
Accelerated Mobile Pages (AMP)
 
Serial Data from Arduino to Raspberry Pi to MySQL using CoAP Protocol
Serial Data from Arduino to Raspberry Pi to MySQL using CoAP ProtocolSerial Data from Arduino to Raspberry Pi to MySQL using CoAP Protocol
Serial Data from Arduino to Raspberry Pi to MySQL using CoAP Protocol
 
Arduino to Control Bulbs using Web App
Arduino to Control Bulbs using Web AppArduino to Control Bulbs using Web App
Arduino to Control Bulbs using Web App
 
Bulb Control using Web App with Raspberry Pi
Bulb Control using Web App with Raspberry Pi Bulb Control using Web App with Raspberry Pi
Bulb Control using Web App with Raspberry Pi
 
Obstacle detection Robot using Ultrasonic Sensor and Arduino UNO
Obstacle detection Robot using Ultrasonic Sensor and Arduino UNOObstacle detection Robot using Ultrasonic Sensor and Arduino UNO
Obstacle detection Robot using Ultrasonic Sensor and Arduino UNO
 
Arduino Interface LM35 MQTT Using UART
Arduino Interface LM35 MQTT Using UARTArduino Interface LM35 MQTT Using UART
Arduino Interface LM35 MQTT Using UART
 
Rain Drop Sensor using Arduino!
Rain Drop Sensor using Arduino!Rain Drop Sensor using Arduino!
Rain Drop Sensor using Arduino!
 
Arduino Programming Software Development
Arduino Programming Software DevelopmentArduino Programming Software Development
Arduino Programming Software Development
 
Embedded Software Development
Embedded Software DevelopmentEmbedded Software Development
Embedded Software Development
 
Ionic - Hybrid Mobile Application Framework
Ionic - Hybrid Mobile Application FrameworkIonic - Hybrid Mobile Application Framework
Ionic - Hybrid Mobile Application Framework
 
Internet of Things - IOT
Internet of Things - IOTInternet of Things - IOT
Internet of Things - IOT
 
Meteor Mobile App Development
Meteor Mobile App DevelopmentMeteor Mobile App Development
Meteor Mobile App Development
 
Digital Marketing Strategy
Digital Marketing StrategyDigital Marketing Strategy
Digital Marketing Strategy
 
Web Application Development
Web Application DevelopmentWeb Application Development
Web Application Development
 
Joomla Website Development Company
Joomla Website Development CompanyJoomla Website Development Company
Joomla Website Development Company
 
Meteor js App Development
Meteor js App DevelopmentMeteor js App Development
Meteor js App Development
 

Último

QCon London: Mastering long-running processes in modern architectures
QCon London: Mastering long-running processes in modern architecturesQCon London: Mastering long-running processes in modern architectures
QCon London: Mastering long-running processes in modern architecturesBernd Ruecker
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxLoriGlavin3
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.Curtis Poe
 
Generative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfGenerative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfIngrid Airi González
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity PlanDatabarracks
 
2024 April Patch Tuesday
2024 April Patch Tuesday2024 April Patch Tuesday
2024 April Patch TuesdayIvanti
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxLoriGlavin3
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024Lonnie McRorey
 
Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Kaya Weers
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024BookNet Canada
 
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024BookNet Canada
 
Varsha Sewlal- Cyber Attacks on Critical Critical Infrastructure
Varsha Sewlal- Cyber Attacks on Critical Critical InfrastructureVarsha Sewlal- Cyber Attacks on Critical Critical Infrastructure
Varsha Sewlal- Cyber Attacks on Critical Critical Infrastructureitnewsafrica
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc
 
Decarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a realityDecarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a realityIES VE
 
A Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software DevelopersA Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software DevelopersNicole Novielli
 
Top 10 Hubspot Development Companies in 2024
Top 10 Hubspot Development Companies in 2024Top 10 Hubspot Development Companies in 2024
Top 10 Hubspot Development Companies in 2024TopCSSGallery
 
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxPasskey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxLoriGlavin3
 
[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality Assurance[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality AssuranceInflectra
 
Genislab builds better products and faster go-to-market with Lean project man...
Genislab builds better products and faster go-to-market with Lean project man...Genislab builds better products and faster go-to-market with Lean project man...
Genislab builds better products and faster go-to-market with Lean project man...Farhan Tariq
 
Time Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsTime Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsNathaniel Shimoni
 

Último (20)

QCon London: Mastering long-running processes in modern architectures
QCon London: Mastering long-running processes in modern architecturesQCon London: Mastering long-running processes in modern architectures
QCon London: Mastering long-running processes in modern architectures
 
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptxThe Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
The Role of FIDO in a Cyber Secure Netherlands: FIDO Paris Seminar.pptx
 
How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.How AI, OpenAI, and ChatGPT impact business and software.
How AI, OpenAI, and ChatGPT impact business and software.
 
Generative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdfGenerative Artificial Intelligence: How generative AI works.pdf
Generative Artificial Intelligence: How generative AI works.pdf
 
How to write a Business Continuity Plan
How to write a Business Continuity PlanHow to write a Business Continuity Plan
How to write a Business Continuity Plan
 
2024 April Patch Tuesday
2024 April Patch Tuesday2024 April Patch Tuesday
2024 April Patch Tuesday
 
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptxMerck Moving Beyond Passwords: FIDO Paris Seminar.pptx
Merck Moving Beyond Passwords: FIDO Paris Seminar.pptx
 
TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024TeamStation AI System Report LATAM IT Salaries 2024
TeamStation AI System Report LATAM IT Salaries 2024
 
Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)Design pattern talk by Kaya Weers - 2024 (v2)
Design pattern talk by Kaya Weers - 2024 (v2)
 
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
Transcript: New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
 
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
New from BookNet Canada for 2024: Loan Stars - Tech Forum 2024
 
Varsha Sewlal- Cyber Attacks on Critical Critical Infrastructure
Varsha Sewlal- Cyber Attacks on Critical Critical InfrastructureVarsha Sewlal- Cyber Attacks on Critical Critical Infrastructure
Varsha Sewlal- Cyber Attacks on Critical Critical Infrastructure
 
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data PrivacyTrustArc Webinar - How to Build Consumer Trust Through Data Privacy
TrustArc Webinar - How to Build Consumer Trust Through Data Privacy
 
Decarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a realityDecarbonising Buildings: Making a net-zero built environment a reality
Decarbonising Buildings: Making a net-zero built environment a reality
 
A Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software DevelopersA Journey Into the Emotions of Software Developers
A Journey Into the Emotions of Software Developers
 
Top 10 Hubspot Development Companies in 2024
Top 10 Hubspot Development Companies in 2024Top 10 Hubspot Development Companies in 2024
Top 10 Hubspot Development Companies in 2024
 
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptxPasskey Providers and Enabling Portability: FIDO Paris Seminar.pptx
Passkey Providers and Enabling Portability: FIDO Paris Seminar.pptx
 
[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality Assurance[Webinar] SpiraTest - Setting New Standards in Quality Assurance
[Webinar] SpiraTest - Setting New Standards in Quality Assurance
 
Genislab builds better products and faster go-to-market with Lean project man...
Genislab builds better products and faster go-to-market with Lean project man...Genislab builds better products and faster go-to-market with Lean project man...
Genislab builds better products and faster go-to-market with Lean project man...
 
Time Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directionsTime Series Foundation Models - current state and future directions
Time Series Foundation Models - current state and future directions
 

Attendance System using ESP8266(Wi-Fi) with MySQL

  • 1. Attendance System using ESP8266(Wi-Fi) with MySQL By Deligence Technologies www.deligence.com
  • 2. What we will Cover? Project Description Software Required Hardware Required Node MCU V3 RFID-RC522 Circuit Diagram CODE: (Node MCU ESP8266) CODE: (PHP) Video Presentation
  • 3. Project Description Here We are going to connect Node MCU ESP8266 and RFID- RC522 with MYSQL Database. So for that first we should connect our Node MCU ESP8266 Board with RFID Module. By using the RFID Module we are going to scan our RFID card and tag which are allow or not. And by using our ESP8266 we are going to send that data to our MYSQL Database which is connect through a php page. You can watch it in action in slide 20.
  • 4. Software Used  Arduino IDE  LAMP Server for Linux or WAMP Server for Windows or MAMP Server for MAC OS
  • 5. Hardware Used  Node MCU V3  RFID Reader with Tag  Jumper Wire
  • 6. Node MCU V3 Node MCU is an open source IOT platform. It includes firmware which runs on the ESP8266 Wi-Fi SoC from hardware which is based on the ESP-12 module. The term "Node MCU" by default refers to the firmware rather than the dev kits.
  • 7. RFID-RC522 RFID RC522 is a low cost and easy to use module suitable for equipment and advanced application development that needs RFID applications. RFID application. RFID stands for Radio-Frequency Identification. The acronym refers to small electronic devices that consist of a small chip and an antenna.
  • 9. CODE: (Node MCU ESP8266) #include<SoftwareSerial.h> #include <ESP8266WiFi.h> #include <WiFiClient.h> #include <ESP8266WebServer.h> #include <ESP8266mDNS.h> #include <SPI.h> #include <MFRC522.h> const char* ssid = "TP-LINK_28C6"; const char* password = "02105604"; //WiFiClient client; char server[] = "192.168.0.115"; //YOUR SERVER #define SS_PIN 2 //FOR RFID SS PIN BECASUSE WE ARE USING BOTH ETHERNET SHIELD AND RS-522 #define RST_PIN 15 #define No_Of_Card 3 Cont…. >>>>>
  • 10. CODE: (Node MCU ESP8266) WiFiClient client; //WiFiServer server(80); SoftwareSerial mySerial(8,9); MFRC522 rfid(SS_PIN,RST_PIN); MFRC522::MIFARE_Key key; byte id[No_Of_Card][4]={ {44,153,22,219}, //RFID NO-1 {112,224,72,84}, //RFID NO-2 {151,94,80,84} //RFID NO-3 }; byte id_temp[3][3]; byte i; int j=0; Cont…. >>>>>
  • 11. CODE: (Node MCU ESP8266) for(byte i=0;i<6;i++) { key.keyByte[i]=0xFF; } // Connect to WiFi network Serial.println(); Serial.println(); Serial.print("Connecting to "); Serial.println(ssid); WiFi.begin(ssid, password); while (WiFi.status() != WL_CONNECTED) { delay(500); Serial.print("."); } Serial.println(""); Serial.println("WiFi connected"); Cont…. >>>>>
  • 12. CODE: (Node MCU ESP8266) // Start the server // server.begin(); Serial.println("Server started"); Serial.print(WiFi.localIP()); delay(1000); Serial.println("connecting..."); } void loop() { // Check if a client has connected int m=0; if(!rfid.PICC_IsNewCardPresent()) return; if(!rfid.PICC_ReadCardSerial()) return; for(i=0;i<4;i++) { id_temp[0][i]=rfid.uid.uidByte[i]; delay(50); } Cont…. >>>>>
  • 13. for(i=0;i<No_Of_Card;i++) { if(id[i][0]==id_temp[0][0]) { if(id[i][1]==id_temp[0][1]) { if(id[i][2]==id_temp[0][2]) { if(id[i][3]==id_temp[0][3]) { Serial.print("your card no :"); for(int s=0;s<4;s++) { Serial.print(rfid.uid.uidByte[s]); Serial.print(" "); } Cont…. >>>>> CODE: (Node MCU ESP8266)
  • 14. CODE: (Node MCU ESP8266) Serial.println("nVALID"); Sending_To_DB(); j=0; rfid.PICC_HaltA(); rfid.PCD_StopCrypto1(); return; } } } } else {j++; if(j==No_Of_Card) { Serial.println("inVALID"); Sending_To_DB(); j=0; } } } Cont…. >>>>>
  • 15. CODE: (Node MCU ESP8266) // Halt PICC rfid.PICC_HaltA(); // Stop encryption on PCD rfid.PCD_StopCrypto1(); } void Sending_To_DB() //CONNECTING WITH MYSQL { if (client.connect(server, 80)) { Serial.println("connected"); // Make a HTTP request: Serial.println("GET /rfid/rfid_read.php?allow="); //YOUR URL /rfid/rfid_read.php?allow client.print("GET /rfid/nodemcu_rfid/rfid_read.php?allow="); //YOUR URL /rfid/rfid_read.php?allow /var/www/html/rfid/rfid_read.php Cont…. >>>>>
  • 16. CODE: (Node MCU ESP8266) if(j!=No_Of_Card) { Serial.println('1'); client.print('1'); } else { Serial.println('0'); client.print('0'); } Serial.println("&id="); client.print("&id="); for(int s=0;s<4;s++) { Serial.println(rfid.uid.uidByte[s]); client.print(rfid.uid.uidByte[s]); } Cont…. >>>>>
  • 17. CODE: (Node MCU ESP8266) client.print(" "); //SPACE BEFORE HTTP/1.1 client.print("HTTP/1.1"); client.print("Host: "); client.println(server); client.println("Host: 192.168.0.115"); client.println("Connection: close"); client.println(); } else { // if you didn't get a connection to the server: Serial.println("connection failed"); } client.stop(); }
  • 18. CODE: (PHP) <?php class rfid{ public $link=''; function __construct($allow, $id){ $this->connect(); $this->storeInDB($allow, $id); } function connect(){ $this->link = mysqli_connect('localhost','root','Deligence@1') or die('Cannot connect to the DB'); mysqli_select_db($this->link,'rfidesp') or die('Cannot select the DB'); } Cont…. >>>>>
  • 19. CODE: (PHP) function storeInDB($allow, $id){ $query = "insert into rfid set rfid='".$id."', allow='".$allow."'"; $result = mysqli_query($this->link,$query) or die('Errant query: '.$query); } } if($_GET['allow'] != '' and $_GET['id'] != ''){ $rfid=new rfid($_GET['allow'],$_GET['id']); } ?>
  • 20. You can get it's source code at - https://github.com/DeligenceTechnologies/ Attendance-System-using-ESP8266-Wi-Fi- with-MySQL In case, you need any Embedded Systems Development or IoT work - you can send an email to us at sales @ deligence.com Deligence Technologies – (your growing technology partner) www.deligence.com/contact-us Email : info@deligence.com Phone : +91 9910130340