AI Binocular 3D Vision Recognition Sensor (Face/Palm Vein) ā Storage Box Application Project
Hey, you know what? Nowadays, the use of face and palmprint recognition is becoming more and more common in our life. Whether it's in the access control systems of companies, or in the entry and exit management of some high-end residential communities, and even in the unlocking functions of our commonly used mobile phones, we can see it everywhere.
Ā
Ā
What is AI Binocular 3D Vision Recognition Sensor?
Ā
Ā
DFRobot has newly released an AI binocular 3D vision recognition sensor. This sensor is a device that combines binocular 3D living body detection, deep neural network algorithms and infrared camera technology. It solves the key needs that users face in smart door locks, self-service retail payment terminals and vein palmprint recognition systems. That is, it can ensure safe, fast and reliable identity verification in dark environments or under complex lighting conditions.
I've made a simple storage box that can only be opened by face and palmprint recognition using this AI binocular vision recognition sensor. Come and check out the production process of my project!
Ā
Ā
Supplies
Ā
To follow along with this guide, youāll need the following:
Ā
DFR0216 DFRduino Uno R3 * 1: Product Link
Ā
FIT0056 USB Cable A-B for Arduino Uno * 1ļ¼Product Link
Ā
DFR0265 IO Expansion Shield for Arduino * 1: Product Link
Ā
DFR0760 Text to Speech Voice Synthesizer Module * 1: Product Link
Ā
SEN0677 AI Binocular 3D Vision Recognition Sensor * 1: Product Link
Ā
DFR0997 IPS Color Serial Display * 1: Product Link
Ā
DFR0017 Digital 5A Relay Module for Arduino * 1: Product Link
When connecting the hardware, besides making sure all the functions work properly, you also gotta think about how it looks and how easy it is to use! Feel free to get creativeāmake your storage box even more useful!


Step 1. Download and install the latest version of Arduino IDE according to your operating system
Step 2. Launch the Arduino application
Step 3. Add the AVR board package to your Arduino IDE
Navigate to Tools > Board > Boards Manager..., then type āAVRā in the search box. Download and install the latest version of the package.

Step 4. Select your board and port Boardļ¼Navigate to Tools > Board > Arduino AVR Boardsļ¼and select Arduino Unoć
Before uploading code, configure your board settings:
- USB CDC On Boot: Enabled: Print serial data via the USB interface- Port: Navigate to Tools > Port and select the correct serial port for your board. Make sure the COM number is correct; it does not need to match the chip model.
Step 5. Navigate to Sketch > Include Library > Add .ZIP Library...

In Arduino IDE, install the library by importing the .zip package. You can follow the official Arduino tutorial here: Installing Libraries (.zip).
For the library files that go with each product, just check the product wiki to download.
For the separate user guide of each product, just check the product wiki!
Step 1. Before you start the whole project, you gotta register the face and palm print info into the dual-camera face & palm module first. Seriouslyāskip this step, and later youāll find the module canāt recognize anything at all. For the details, just check the instructions that came with it:
https://wiki.dfrobot.com/SKU_SEN0677_AI_Binocular_Vision_Recognition_Sensor_Face_Palm_Vein_QR_Code

Step 2. Import those library files.This stepās a mustāotherwise, youāll get an error saying files are missing!
// Include the binocular AI sensor library
#include "DFRobot_AI10.h"
// Include the speech synthesis library
#include "DFRobot_SpeechSynthesis_V2.h"
#include <Wire.h>
#include <LiquidCrystal_I2C.h>
// Include the LCD display library
#include "DFRobot_LcdDisplay.h"Step 3. Fire up the baud rate, sensors, and actuators first.
void setup() {
// Start serial communication
Serial.begin(115200);
// Set up the electromagnetic lock
pinMode(6, INPUT_PULLUP); // Pin 6 as input with pull-up resistor
pinMode(Relay, OUTPUT); // Relay pin as output
// Initialize the LCD screen
lcd.begin();
lcd.cleanScreen(); // Clear the screen
Step 4. Figure out if itās a face or a palm print, then tell apart the user IDs. Of course, you can just set it up for face recognition only, or palm print onlyāwhatever you want, really! Youāre in charge here~
// Show what was recognized (face or palm)
Serial.print("Recognized: ");
Serial.println(recDat.type == eFace ? "Face" : "Palm");
Serial.print("User ID: ");
Serial.println(recDat.userData.UID);
// Show corresponding image based on recognition type
if(recDat.type == eFace){
Serial.println("It's a face!");
ss.speak(F("Face recognized"));
digitalWrite(Relay, HIGH); // Unlock the box
lcd.updateIcon(pictureId, 0, 0, "face.png", 256); // Show face image
} else {
Serial.println("It's a palm!");
ss.speak(F("Palm recognized"));
digitalWrite(Relay, HIGH); // Unlock the box
lcd.updateIcon(pictureId, 0, 0, "palm.png", 256); // Show palm image
}Step 5. Itāll only unlock if it recognizes the ownerās face or palm print~ If not, itāll just keep waiting for a valid scan... That way, nothing in the storage cabinet gets stolen!
// Show unlock screen and message
ss.speak(F("Unlocked"));
lcd.updateIcon(pictureId, 0, 0, "unlock.png", 256); // Show unlocked image
delay(2000); // Keep unlocked for 2 seconds
// Lock again and update display
ss.speak(F("Locked"));
lcd.updateIcon(pictureId, 0, 0, "lock.png", 256); // Show locked image
digitalWrite(Relay, LOW); // Lock the box
delay(2000);
} else {
// If nothing was recognized, show scanning message
Serial.println("Scanning...");
lcd.updateIcon(pictureId, 0, 0, "reco.png", 256); // Show scanning image
delay(1000); // Check again after 1 second
}Heads up! Make sure to set the correct pins for the sensors and actuators.
The most basic stuff for a dual-camera face and palm print storage box? Well, itās gotta recognize faces and palm prints, have an electric lock to pop open, and of course the box itself. But hereās the fun part ā you can get creative with all of it! So cāmon, use your imagination, take what Iāve got here, and make this storage box totally your own!









