To control the operation of the gate, raspberry pi 4 model/ 8GB is used.7-inch LCD Capacitive Touch Screen compatible with the Raspberry Pi is used to show the employee face and QR code. The target of the proposed structure is to register employee attendance for any building by using a camera and QR code. The face, recognition step recognizes all faces that cross near the camera module and gives feedback to the system. This feedback includes the name of the employee and the arrival time. Figure 8. Illustrates the face recognition process.
The steps for face recognition can be summarized as follows:
• Insert two folders on raspberry pi, these folder includes all images for employees in one folder and the blocked peoples in another one, each image has the name of the employee.
• Read images from employees and blocked folders that have been added before on raspberry pi.
• Save the names of all images in two arrays, one of them for the employees, and the other one for blocked persons.
• Get the face locations for all the images like figure 9, and crop the face, then after that encode the face to get the dimensions and the outlines of each person’s nose, mouth, eyes, and chin like figure 10. Then save the encoding of the image in an array.
• Repeat step 4 again but now for the current frame only, if the current frame does not have any faces the code goes to the next frame until finding the face.
• Compare the dimensions of the face by all dimensions in the dimensions array of all images saved in step 3.
• Get the face distance between the face and all saved faces, the minimum distance is the correct face from faces.
• Get the name of the image that has the minimum distance and this name is the name of the person.
• Repeat the last 3 steps if any more faces in the current frame.
• After we have the names of the person or more, we go now to check if the person is in the blocked array or not, if the person in the employees array the system detect his face with a green box and write his name on the box if the person in the blocked list the system detects his face by a red box and write blocked on it. Figure 11 shows the output of the system.
This process has some lag, to solve this problem camera with 5MP is used.
After confirming the identity of the person, another means of verification was added via the QR code. Figure 12 shows the final result of the last two steps.
As soon as the person is allowed to enter, the internal gate is opened. The cost has been taken into account and depends on only one motor. Figure 13 shows the design of the internal gate.
And finally, the sterilization process. The chemical sanitizing method is used because it is available, cheap, and effective in sanitizing gates. The proposed sanitizing system consists of a spray nozzle, diaphragm water pump, Plastic hoses, T and L connectors, and solution tank as shown in Figure 14.
7 spray nozzles made from stainless steel as shown in figure 15 because it bears the presumed rust due to sanitizing solution.
A Water Pump machine that is shown in figure 16 is placed on the tip of every gate
that picks the 70% of alcohol solution from the tank. Because the system is automatic it senses if anybody is entering the gate. When anybody enters the gate, the Water Pump becomes started for 4 seconds. So that the person can go through that gate, and if there is no person pass through the gate, the pump will be off to conserve the water and electricity. The foggy sanitizing spray preserves citizens from taking bacteria along a time of at least 60 minutes. Besides, it sanitizes the air, exposed skin, and human clothing.
By comparing the practical results with the ideal results, we find a great convergence. For the ideal case, the Spray coverage (C) is 29.9 inches, the Flow rate (Q) is 0.2 LPM (For 7 nozzles), the Flow velocity immediately after nozzle (V) is 14.47 m/s. For practical case, the Flow rate (Q) is 0.5 LPM (For 7 nozzles), the tank volume is 25 Liters, Time to use all solution in the tank is 3000 secs, one person can take 4 seconds to achieve all body sanitizing, Number of persons per tank is 750 persons.
ISSG aims to implement a security gate equipped with a sanitizing system that can overcome the problems in the gates shown in Table 1 with the suitable cost as shown in table 3.
TABLE 3 THE TOTAL COST OF THE PROPOSED GATE
Components
|
Quantities
|
Cost
|
Total cost
|
Raspberry pi 4B - 4GB RAM
|
1
|
1825
|
117
|
Raspberry pi camera wire
|
1
|
35
|
35
|
Relay
|
1
|
40
|
40
|
Raspberry pi camera case
|
1
|
48
|
48
|
BPI4 BOX FAN (Raspberry pi case)
|
1
|
175
|
175
|
RPI4 Adaptor ON OFF
|
1
|
90
|
90
|
HS. P4 (Heat sink)
|
1
|
25
|
25
|
Micro HDMI to HDMI
|
1
|
40
|
40
|
SD card 32 GB
|
1
|
195
|
195
|
KIT MLX90614 with pins
|
1
|
427
|
427
|
HC-SR04 Ultrasonic Sensor
|
3
|
38
|
114
|
Raspberry pi camera
|
1
|
375
|
375
|
HDMI LCD 7'' 1.24*60
|
1
|
1250
|
1250
|
Pump & Adaptor
|
1
|
450
|
450
|
Sprinkles
|
7
|
50
|
350
|
Hoes
|
1
|
35
|
35
|
L connector
|
2
|
5
|
10
|
T connector
|
6
|
5
|
30
|
Pump components
|
3
|
10
|
30
|
3-24V Buzzer Alarm
|
1
|
15
|
15
|
330-ohm resistors
|
3
|
0.25
|
0.75
|
Led
|
3
|
0.25
|
0.75
|
Breadboard
|
1
|
20
|
20
|
Stickers
|
1
|
60
|
60
|
Wires
|
1
|
44
|
44
|
Hoes, connector & sprinkles
|
1
|
111
|
111
|
ISSG body
|
1
|
25,000
|
25,000
|
ISSG component cost in L. E
|
30,795.5
|
ISSG component cost in USD
|
1962
|
During the manufacture and implementation of the proposed portal, there were some problems that were overcome among these problems: (1) lag in the process of face recognition due to the high-definition image from camera and solved by reducing the resolution of the input image (2) how to connect between python code and MySQ and solved by adding the python as a user has the full access permission in MySQL (3) The camera takes more than one frame of the same person, so it will be recorded in the database more than once and solved by a feedback process between the database and the pythonوSo that the database is not allowed to register again (4) The detection range of the IR sensor is limited by the operation voltage. When connect it on the raspberry pi with 5v, the detection range becomes too small to detect the incoming person. To solve this problem the IR sensor is replaced by ultrasonic sensor because the detection range of the ultrasonic sensor is more than the IR sensor and it need only 5v to work. (5) How to control on the pump (AC) using the raspberry pi (DC), to solve this problem a relay is used to control pump powered from 24V DC supply.
In Figure 17, the final shape of the gate with all its parts after the completion of the manufacturing process is shown