close
ARDUINO

SMALL DIGITAL LOCKER FOR MOBILE AND WALLET IN OFFICE

Problem:

In corporate offices there is restriction of use of mobile for employees and visitors. Because of this the employee or visitor switches mobile in silent mode or switch off it. In silent mode the employee may use the mobile while working time. And most of employees do not want to switch off their mobiles while working ours. So the authority has to keep all the mobile in locker at time of joining the office and return back at the time of leaving office. Also in break time (lunch) the employees may ask the mobile for personal. So also the authorized person will give it back and keep once again after break period.

So in whole process the authorized person will keep the mobile in locker with identification of employee and return it with identification. The authority has to do this process minimum one time to maximum 2 or 4 times in a day. Keeping in a locker with identification and returning it back with identification in a day for more than one time is very difficult for a large number of employees.

Solution:

The simple solution of this problem is a SMALL DIGITAL LOCKER. In this model we have developed a small digital locker in which the employee has to keep a RF TAG in a form of small key chain. This key chain can be inserted with the key chain of vehicle key. So it is very easy to keep it in a pocket. In this model, the small locker will occupy 6″ x 9″ space per mobile in this model. But in a form of product the space may be reduced.

How to operate the locker?

The employee will come in the office with RF TAG key chain. Before joining the office work the employee will show the RF TAG in front of RF TAG READER module. The door of locker will open and he / she will put his / her mobile in it and once again shows the RF TAG in front if RF TAG READER so the door of locker will close. After keeping all mobiles in the different locker, the authorized person will switch off the power of this module so the locker will not operate. Now at the break time of or the office leaving time, the authorized person will switch on the power of locker. And once again the employee has to place the RF TAG in front of RF TAG Reader. So the gate of locker will open and the employee will take back his / her mobile. In case of large size of locker the employee can put their wallets in it.

Components:

  • Arduino Uno
  • RF Tag
  • RF Tag Reader
  • DVD writer door mechanism
  • Jumpers
  • RED LED 1
  • Green LED 1
  • 10K Resistor 2
  • 330 Ohms Resistor 2
  • acrylic or pvc sheet pieces for body
  • Wonder Tape
<pre data-mode="python" data-theme="xcode" data-fontsize="16" data-lines="Infinity" class="wp-block-simple-code-block-ace">/*
 * This coding simple digital locker.
 * please check the circuit diagram before 
 * uploading the program 
 */
 
#include &lt;SPI.h&gt;
#include &lt;MFRC522.h&gt;
#include &lt;Servo.h&gt;
Servo myservo;  // create servo object to control a servo
// twelve servo objects can be created on most boards
int pos = 0;    // variable to store the servo position
const int red = A3; //define red led
const int grn = A2; //define green led
const int m1p = A0; //define dc motor1 + terminal
const int m1n = A1; //define dc motor1 - terminal
const int upper = A5; //upper limit switch is sonnected at pin A4
const int lower = A4; //lower limit switch is sonnected at pin A5
 
#define SS_PIN 10
#define RST_PIN 9
MFRC522 mfrc522(SS_PIN, RST_PIN);   // Create MFRC522 instance.
int up = 0;         // variable to store the upper limit switch value
int lo = 0;         // variable to store the lower limit switch value
 
void setup() 
{
  Serial.begin(9600);   // Initiate a serial communication
  SPI.begin();      // Initiate  SPI bus
  mfrc522.PCD_Init();   // Initiate MFRC522
  Serial.println("Approximate your card to the reader...");
  Serial.println();
  pinMode(red, OUTPUT); 
  pinMode(grn, OUTPUT);
  pinMode(m1p, OUTPUT); 
  pinMode(m1n, OUTPUT); 
  digitalWrite(red, HIGH); // turn the LED on 
  digitalWrite(grn, LOW); // turn the LED off 
  
  gate_close();
  
}
void loop() 
{
  
  // Look for new cards
  if ( ! mfrc522.PICC_IsNewCardPresent()) 
  {
    return;
  }
  // Select one of the cards
  if ( ! mfrc522.PICC_ReadCardSerial()) 
  {
    return;
  }
  //Show UID on serial monitor
  Serial.print("UID tag :");
  String content= "";
  byte letter;
  for (byte i = 0; i &lt; mfrc522.uid.size; i++) 
  {
     Serial.print(mfrc522.uid.uidByte[i] &lt; 0x10 ? " 0" : " ");
     Serial.print(mfrc522.uid.uidByte[i], HEX);
     content.concat(String(mfrc522.uid.uidByte[i] &lt; 0x10 ? " 0" : " "));
     content.concat(String(mfrc522.uid.uidByte[i], HEX));
  }
  Serial.println();
  Serial.print("Message : ");
  content.toUpperCase();
  if (content.substring(1) == "7B 08 EA 1A") //change here the UID of the card/cards that you want to give access
  {
    
    gate_open();
    
    digitalWrite(red, LOW); // turn the LED on 
    digitalWrite(grn, HIGH); // turn the LED off 
    
    Serial.println("Authorized access");
    Serial.println();
    
  }
  else
  {
    Serial.println(" Access denied");
    delay(3000);
  }
  
  // Look for new cards
  if ( ! mfrc522.PICC_IsNewCardPresent()) 
  {
    return;
  }
  // Select one of the cards
  if ( ! mfrc522.PICC_ReadCardSerial()) 
  {
    return;
  }
  //Show UID on serial monitor
  Serial.print("UID tag :");
  //String content= "";
  //byte letter;
  for (byte i = 0; i &lt; mfrc522.uid.size; i++) 
  {
     Serial.print(mfrc522.uid.uidByte[i] &lt; 0x10 ? " 0" : " ");
     Serial.print(mfrc522.uid.uidByte[i], HEX);
     content.concat(String(mfrc522.uid.uidByte[i] &lt; 0x10 ? " 0" : " "));
     content.concat(String(mfrc522.uid.uidByte[i], HEX));
  }
  Serial.println();
  Serial.print("Message : ");
  content.toUpperCase();
  if (content.substring(1) == "7B 08 EA 1A") //change here the UID of the card/cards that you want to give access
  {
    
    gate_close();
    
    digitalWrite(red, HIGH); // turn the LED on 
    digitalWrite(grn, LOW); // turn the LED off 
    
    Serial.println("Authorized access");
    Serial.println();
  }
  else
  {
    Serial.println(" Access denied");
    delay(3000);
  }
} 
void gate_open()
{
    do
    {
      up = digitalRead(upper);   // read lower switch value
      
      digitalWrite(m1p, HIGH); // turn the MOTOR + high 
      digitalWrite(m1n, LOW); // turn the MOTOR - low
    
    }while(up == 1);
    
    motor_stop();
}
void gate_close()
{
    do
    {
      up = digitalRead(upper);   // read lower switch value
      
      digitalWrite(m1p, LOW); // turn the MOTOR + high 
      digitalWrite(m1n, HIGH); // turn the MOTOR - low
    
    }while(lo == 1);
    
    motor_stop();
}
void motor_stop()
{
    digitalWrite(m1p, LOW); // turn the MOTOR + low
    digitalWrite(m1n, LOW); // turn the MOTOR - low
  
}</pre>
admin

The author admin

Leave a Response