Back to Advanced Projects

🔒 Fingerprint Door Lock

Secure your room with biometrics. Actuate a servo mechanism with an optical scanner.

📋 Overview

The AS608 fingerprint scanner handles the complex image processing and template matching on-board. It simply tells the Arduino if a match was found and what ID it corresponds to.

What you'll learn: SoftwareSerial communication, biometric module interfacing, and securing physical mechanisms.

Estimated time: 2-3 hours. Difficulty: ⭐⭐⭐ Intermediate.

🧩 Components Needed

ComponentSpecificationQtyNotes
Arduino Uno R35V1
AS608 Fingerprint SensorOptical1
Servo MotorMG996R1Heavy duty for lock
Relay/External Power5V 2A1Servos draw heavy current

📖 Step-by-Step Tutorial

1

Enroll Fingerprints

First, run the "Enroll" example sketch from the Adafruit Fingerprint library to save your fingerprints to the sensors memory.
2

Wiring Scanner

Sensor VCC to 5V (or 3.3V depending on module), TX to Pin 2, RX to Pin 3.
3

Wiring Servo

Connect the servo signal to Pin 9. Power it externally if using a heavy-duty servo.
4

Upload the Lock Code

The lock sketch checks for matches and sweeps the servo if ID is validated.
💡
Optical fingerprint scanners are sensitive to dirt and moisture. Keep the glass clean for reliable matches.

💻 Code / Configuration

fingerprint_lock.ino
INO
// Fingerprint Lock
#include <Adafruit_Fingerprint.h>
#include <Servo.h>
#include <SoftwareSerial.h>

SoftwareSerial mySerial(2, 3);
Adafruit_Fingerprint finger = Adafruit_Fingerprint(&mySerial);
Servo lockServo;

void setup() {
  Serial.begin(9600);
  finger.begin(57600);
  lockServo.attach(9);
  lockServo.write(0); // Locked position
}

void loop() {
  int p = finger.getImage();
  if (p != FINGERPRINT_OK) return;
  
  p = finger.image2Tz();
  if (p != FINGERPRINT_OK) return;
  
  p = finger.fingerFastSearch();
  if (p == FINGERPRINT_OK) {

Reviews & Ratings

0 reviews
5★
0
4★
0
3★
0
2★
0
1★
0
...

Loading reviews...

volt-X / Fingerprint Door Lock — Advanced IoT Tutorial