[go: up one dir, main page]

CN106887059A - A kind of intelligent electronic lock system based on face recognition - Google Patents

A kind of intelligent electronic lock system based on face recognition Download PDF

Info

Publication number
CN106887059A
CN106887059A CN201710039118.9A CN201710039118A CN106887059A CN 106887059 A CN106887059 A CN 106887059A CN 201710039118 A CN201710039118 A CN 201710039118A CN 106887059 A CN106887059 A CN 106887059A
Authority
CN
China
Prior art keywords
module
door lock
facial
camera
lock system
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN201710039118.9A
Other languages
Chinese (zh)
Inventor
熊俊涛
麦志恒
何志良
陈泽钦
蔡任
刘振
林睿
卜榕彬
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
South China Agricultural University
Original Assignee
South China Agricultural University
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by South China Agricultural University filed Critical South China Agricultural University
Priority to CN201710039118.9A priority Critical patent/CN106887059A/en
Publication of CN106887059A publication Critical patent/CN106887059A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G07CHECKING-DEVICES
    • G07CTIME OR ATTENDANCE REGISTERS; REGISTERING OR INDICATING THE WORKING OF MACHINES; GENERATING RANDOM NUMBERS; VOTING OR LOTTERY APPARATUS; ARRANGEMENTS, SYSTEMS OR APPARATUS FOR CHECKING NOT PROVIDED FOR ELSEWHERE
    • G07C9/00Individual registration on entry or exit
    • G07C9/00174Electronically operated locks; Circuits therefor; Nonmechanical keys therefor, e.g. passive or active electrical keys or other data carriers without mechanical keys
    • G07C9/00563Electronically operated locks; Circuits therefor; Nonmechanical keys therefor, e.g. passive or active electrical keys or other data carriers without mechanical keys using personal physical data of the operator, e.g. finger prints, retinal images, voicepatterns

Landscapes

  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Collating Specific Patterns (AREA)
  • Lock And Its Accessories (AREA)

Abstract

本发明是在智能化设备的基础上,主要是利用摄像头,获得目标的图像信息,对于动态目标提取出人的面部图像,并将其与门锁联系在一起通过分析目标的面部特征与数据库的图像对比,来判断入侵者是否是外来未知人员,从而实现门锁的智能开关。本发明针对目前的人脸识别门禁系统存在成本高、环境适应性差等问题进行改进,采用ARM Cortex‑M3嵌入式芯片设计,降低硬件成本和运行功耗,提升硬件的性能。同时基于MATLAB图像处理平台,提出了改进的2DPCA人脸识别算法。同时采用基于肤色特征算法定位人脸信息,减低环境背景影响,提高人脸识别率。与比传统2DPCA算法相比,本文提出的改进算法用时更短,同时人脸匹配成功率达到87%,误判率低于3%,系统安全性达到97%以上。

The present invention is based on intelligent equipment, mainly uses the camera to obtain the image information of the target, extracts the facial image of the person for the dynamic target, and links it with the door lock by analyzing the facial features of the target and the database. Image comparison to determine whether the intruder is an unknown person from outside, so as to realize the intelligent switch of the door lock. The present invention improves the problems of high cost and poor environmental adaptability in the current face recognition access control system, adopts ARM Cortex‑M3 embedded chip design, reduces hardware cost and operating power consumption, and improves hardware performance. At the same time, based on the MATLAB image processing platform, an improved 2DPCA face recognition algorithm is proposed. At the same time, the algorithm based on the skin color feature is used to locate the face information, reduce the influence of the environmental background, and improve the face recognition rate. Compared with the traditional 2DPCA algorithm, the improved algorithm proposed in this paper takes less time. At the same time, the success rate of face matching reaches 87%, the misjudgment rate is lower than 3%, and the system security reaches more than 97%.

Description

一种基于面部识别的智能电子门锁系统An intelligent electronic door lock system based on facial recognition

技术领域technical field

本发明涉及一种智能识别装置,具体涉及一种基于面部识别的电子门锁系统。The invention relates to an intelligent identification device, in particular to an electronic door lock system based on facial recognition.

背景技术Background technique

随着社会经济的发展,技术的革新,人们渐渐达到小康社会的高生活水平,而且安防意识也在不断提高。由此,如何利用新的技术手段设计更安全、便捷、可靠的安全防卫系统,提高居民生活质量,已经成为智能安防领域关注的焦点。其中,门锁作为智能安防系统中的首道关卡,是整个安防系统的重中之重。传统门锁系统的身份验证方式有:钥匙、密码、磁卡等,然而这些验证手段都与用户具有可分离性,容易被复制、破译和盗用,已不能完全满足现代安防理念。现今,人体生物特征如指纹、面部、虹膜等因其具有唯一性,不变性和不可分离的特性,已经被广泛利用在智能安防领域。因此设计针对安全防卫的智能门锁识别系统,对社会的发展有重要的经济价值与实用意义。With the development of social economy and technological innovation, people have gradually reached a high living standard in a well-off society, and their awareness of security is constantly improving. Therefore, how to use new technical means to design a safer, more convenient and reliable security system and improve the quality of life of residents has become the focus of attention in the field of intelligent security. Among them, the door lock, as the first checkpoint in the intelligent security system, is the top priority of the entire security system. The identity verification methods of the traditional door lock system include: key, password, magnetic card, etc. However, these verification methods are separable from the user and are easy to be copied, deciphered and embezzled, which cannot fully meet the modern security concept. Nowadays, human biometrics such as fingerprints, faces, irises, etc. have been widely used in the field of intelligent security because of their uniqueness, invariance and inseparability. Therefore, designing an intelligent door lock identification system for security and defense has important economic value and practical significance for the development of society.

发明内容Contents of the invention

当今社会,基于生物识别技术的智能安防设备越来越受欢迎,由于生物识别技术具有的唯一性、不变性和不可分离等特点,是其它技术所缺乏的重要特征。而面部识别也是其中被广泛研究的话题之一。近年来基于面部识别的智能门锁系统也开始升温,但由于其市场价格十分昂贵,识别成功率受环境、光照等因素影响比较大,所以推广起来还非常困难,相比其它安防系统,其市场占有率稍低,但发展空间巨大。In today's society, intelligent security equipment based on biometric technology is becoming more and more popular. Due to the characteristics of uniqueness, invariance and inseparability of biometric technology, it is an important feature that other technologies lack. Facial recognition is also one of the widely researched topics. In recent years, the smart door lock system based on facial recognition has also begun to heat up. However, because its market price is very expensive, and the recognition success rate is greatly affected by factors such as the environment and light, it is still very difficult to promote. Compared with other security systems, its market Occupancy rate is slightly low, but the development space is huge.

本发明通过以下技术方案实现:采用ARM Cortex-M3嵌入式芯片设计,降低硬件成和运行功耗,提升硬件的性能。同时基于MATLAB图像处理平台,提出了改进的2DPCA面部识别算法,在样本训练阶段,分别对每一类人物构建不同的特征子空间,而在面部图像识别阶段,则将待识别图像分别投影到每一类人的特征子空间中进行匹配,寻找最大匹配度来确定待识别人物的归属。同时采用基于肤色特征算法定位面部信息,减低环境背景影响,提高面部识别率。The present invention is realized through the following technical solutions: adopting ARM Cortex-M3 embedded chip design, reducing hardware cost and operating power consumption, and improving hardware performance. At the same time, based on the MATLAB image processing platform, an improved 2DPCA face recognition algorithm is proposed. In the sample training stage, different feature subspaces are constructed for each type of person, and in the face image recognition stage, the image to be recognized is projected to each Matching is carried out in the feature subspace of a class of people, and the maximum matching degree is found to determine the belonging of the person to be recognized. At the same time, the algorithm based on skin color features is used to locate facial information, reduce the influence of environmental background, and improve the facial recognition rate.

在面部识别的基础上,利用设备对门外的人物进行识别与分析,然后与可以通行的人物照片进行比对,然后判断是否一致,再确定是否开锁允许进入。On the basis of facial recognition, the equipment is used to identify and analyze the people outside the door, and then compare it with the photos of people who can pass through, and then judge whether they are consistent, and then determine whether to unlock and allow entry.

一种基于面部识别的电子门锁系统,包括stm32主控模块、摄像头、串口通讯模块、人体红外感应模块、存储模块、电控锁驱动模块、显示模块、声光提示模块、电源转换模块、电源开关、遥控接收模块、声光报警模块,摄像头和电机驱动模块,其特征在于,门锁系统工作时由其他模块传递信息给主控模块,经主控模块处理后反馈给各个模块,并执行相应工作。此硬件系统具有与较强的适应性和移植特性,不需要改变硬件系统,即可进行不同环境的移植,只需要修改软件参数即可扩展成为不同环境下的门锁系统。An electronic door lock system based on facial recognition, including stm32 main control module, camera, serial port communication module, human body infrared sensor module, storage module, electric lock drive module, display module, sound and light prompt module, power conversion module, power supply switch, remote control receiving module, sound and light alarm module, camera and motor drive module, it is characterized in that when the door lock system is working, other modules transmit information to the main control module, which is fed back to each module after being processed by the main control module, and executes corresponding Work. This hardware system has strong adaptability and transplantation characteristics. It can be transplanted in different environments without changing the hardware system. It can be expanded into a door lock system in different environments only by modifying the software parameters.

优选地,所述硬件系统中,由摄像头模块、串口模块、人体红外感应模块、TFT-LCD模块等传递信息给主控模块,经主控模块处理后反馈给各个模块,并执行相应工作。Preferably, in the hardware system, the camera module, serial port module, human body infrared sensor module, TFT-LCD module, etc. transmit information to the main control module, and after being processed by the main control module, the information is fed back to each module to perform corresponding work.

优选地,所述硬件系统包括电控锁驱动模块、TFT-LCD显示模块、声光提示模块、DC电源转换模块、摄像头模块、CH340G串口通信模块、人体红外感应模块和SD卡存储模块等9大硬件模块组成。Preferably, the hardware system includes nine components including an electronically controlled lock drive module, a TFT-LCD display module, an audible and visual prompt module, a DC power conversion module, a camera module, a CH340G serial communication module, a human body infrared sensor module, and an SD card storage module. Composed of hardware modules.

优选地,所述软件系统程序部分主要分为两大块,MATLAB程序设计和STM32主控程序设计。Preferably, the software system program part is mainly divided into two parts, MATLAB program design and STM32 master control program design.

优选地,所述MATLAB程序设计,可分为串口通信、面部检测、面部匹配、用户数据库管理等四大块,使上位机基于MATLAB软件,设计出面部识别智能门锁系统的监控软件,监控程序界面简洁清晰,用户只需要点击程序界面中几个按钮就可以实现系统的实时监控,并与下位机STM32构成完整的面部识别智能门锁系统。Preferably, the MATLAB program design can be divided into four major blocks such as serial port communication, face detection, face matching, and user database management, so that the upper computer can design the monitoring software and monitoring program of the facial recognition intelligent door lock system based on the MATLAB software The interface is simple and clear. Users only need to click a few buttons in the program interface to realize real-time monitoring of the system, and form a complete facial recognition intelligent door lock system with the lower computer STM32.

优选地,所述STM32主控程序设计,其与硬件系统各个硬件模块相对应,包括面部定位摄像头程序、电机锁驱动模块程序、TFTLCD显示模块驱动程序、SD卡存储模块程序、人体红外检测程序、CH340通信模块程序以及低功耗模式程序等等。Preferably, the STM32 main control program design corresponds to each hardware module of the hardware system, including a face positioning camera program, a motor lock driver module program, a TFTLCD display module driver program, an SD card storage module program, a human body infrared detection program, CH340 communication module program and low power mode program, etc.

本发明的工作原理是:各个子模块工作均受到主控模块的调控,而且模块之间相互协调工作。首先通过人体红外感应模块,实时检测是否有人靠近门锁系统,如果检测到人体信号,则激活处于待机状态下的主控芯片,然后OV7670定位摄像头模块完成初始化,准备获取面部图像,利用TFT-LCD液晶显示屏辅助,实时显示面部图像位置,方便用户定位,便于头像获取。同时伴随TFT-LCD显示屏中文提示,提醒用户当前执行任务情况,每次激活面部识别门锁系统后均有3次识别机会,如果三次识别均失败,则系统会制动进入待机状态,等待下一次人体红外感应模块重新获取触发信号,电机锁驱动模块主要接收来自STM32主控的指令,执行开门和关门程序,声光提示模块则配合电机锁驱动模块,执行相应指令,起到提醒用户作用,USB高清摄像头是面部图像获取主摄像头,拍摄面部头片后传送到PC端的MATLAB程序进行面部识别,SD存储模块会实时存储每次识别获取到的图片,以便保留证据,方便随时查看记录。The working principle of the invention is: the work of each sub-module is regulated by the main control module, and the modules work in coordination with each other. Firstly, through the human body infrared sensing module, it is detected in real time whether someone is approaching the door lock system. If a human body signal is detected, the main control chip in the standby state is activated, and then the OV7670 positioning camera module completes the initialization and prepares to acquire facial images. Using TFT-LCD Assisted by the LCD screen, it can display the position of the facial image in real time, which is convenient for the user to locate and obtain the avatar. At the same time, it is accompanied by Chinese prompts on the TFT-LCD display screen to remind the user of the current task execution status. Each time the face recognition door lock system is activated, there are three recognition opportunities. If the three recognitions fail, the system will brake and enter the standby state, waiting for the next Once the human body infrared sensor module reacquires the trigger signal, the motor lock drive module mainly receives instructions from the STM32 main control, and executes the door opening and closing procedures. The USB high-definition camera is the main camera for facial image acquisition. After the facial headshot is taken, it is sent to the MATLAB program on the PC for facial recognition. The SD storage module will store the pictures obtained for each recognition in real time, so as to preserve evidence and view records at any time.

本发明与现有技术相比,具有以下的有益效果:Compared with the prior art, the present invention has the following beneficial effects:

1、根据系统分析设计目标,完成基于ARM Cortex-M3主控的硬件系统设计,执行面部定位、TFT-LCD智能提示,以及开关锁功能。1. According to the system analysis and design goals, complete the hardware system design based on the ARM Cortex-M3 main control, implement facial positioning, TFT-LCD intelligent prompts, and switch lock functions.

2、基于MATLAB图像处理平台设计的智能监控软件,完成基于肤色特征面部检测以及基于改进的2DPCA面部识别算法,同时还能对用户数据库进行实时管理,查看监控记录。2. Based on the intelligent monitoring software designed on the MATLAB image processing platform, the facial detection based on skin color features and the improved 2DPCA facial recognition algorithm are completed. At the same time, it can manage the user database in real time and view the monitoring records.

3、良好的人机交互界面设计,通过学习MATLAB的GUI设计,完成监控系统软件界面的设计,包括优化按钮、简化操作顺序、优化显示框等。3. Good human-computer interaction interface design. By learning the GUI design of MATLAB, complete the design of the monitoring system software interface, including optimizing buttons, simplifying the operation sequence, and optimizing the display frame.

4、硬件系统低功耗模式,仅当人体红外感应被触发后,系统才会被激活,三次识别失败后,系统自动进入低功耗待机模式,具有10秒无应答自动进入待机模式等低功耗设置。4. The low power consumption mode of the hardware system. The system will be activated only when the infrared sensor of the human body is triggered. After three identification failures, the system will automatically enter the low power consumption standby mode. consumption settings.

附图说明Description of drawings

图1为硬件系统的总体组成框架。Figure 1 shows the overall composition framework of the hardware system.

图2为系统硬件连接图。Figure 2 is the system hardware connection diagram.

图3为基于面部识别的智能门锁系统监控软件的总体程序流程图。Fig. 3 is the overall program flow chart of the monitoring software of the intelligent door lock system based on facial recognition.

图4基于面部识别的智能门锁系统监控软件界面图。Figure 4 is the interface diagram of the monitoring software of the smart door lock system based on facial recognition.

图5门锁系统运行图。Figure 5 is the operation diagram of the door lock system.

具体实施方式detailed description

下面结合实施例及附图对本发明作进一步详细的描述,但本发明的实施方式不限于此。The present invention will be further described in detail below in conjunction with the embodiments and the accompanying drawings, but the embodiments of the present invention are not limited thereto.

实施例Example

参见图1、2,硬件系统的总体组成框架和系统硬件连接图,STM32单片机增强型系列产品中的STM32F103ZET6,它是基于ARM Cortex-M3核心的32位微型CPU,处理频率72MHz,具有高达64KB SRAM和512KB FLASH,丰富的定时器资源,包括2个高级定时器、4个通用定时器、2个基本定时器,通信接口包括有5个串口、1个USB接口、3个SPI接口、2个IIC接口,此外5还有1个12位DAC、3个12位ADC、1个FSMC接口等,芯片共144引脚,其中112个通用IO口,采用LQFP-144封装结构。电控锁驱动模块采用TB6612FNG直流电机驱动芯片,它的MOSFET-H桥结构有大电流驱动能力,且具有双通道输出,可以通过PWM同时驱动两路直流电机。每个通道最高输出1.2A连续驱动电流,可控制直流电机正转/反转/停止/制动,最高支持100kHZ的PWM频率,具有片内低压检测与热停机保护电路,工作温度:-20~85℃,采用SSOP24贴片封装。液晶显示屏是采用ALIENTEK的2.8寸TFT-LCD,该液晶屏自带LCD驱动芯片IL9320,5V电源供电,工作电流130mA~350mA,分辨率达320*240以及16位真彩色显示。因此采用该显示屏功耗较低,满足本设计需求。本设计中采用了双摄像头采集数据,其中面部定位摄像头采用ALIENTEK OV7670摄像头模块,面部获取摄像头采用USB高清摄像头。面部定位摄像头OV7670直接由STM32微处理器控制,其获取的图像实时显示在TFT-LCD液晶上,方便用户定位自己面部的位置。面部获取摄像头由PC机的Matlab软件进行控制,主要功能是获取面部图像进行识别处理。两摄像头安装要求是,所获取的外界画面应当相同,安装高度、倾斜角、所在环境一致。声光提示模块包括蜂鸣器电路和共阳红绿双色LED灯电路,硬件系统被激活时,蜂鸣器会短鸣一声提示用户,当面部识别成功时,蜂鸣器也会短鸣一声,同时绿灯亮起,提示验证通过,系统执行开锁命令,当面部识别失败时,蜂鸣器会短鸣两声,同时红灯会亮起,提示验证失败,需要用户重新验证。本设计采用的RCW-0506人体红外感应模块,是基于红外线技术的自动控制模块,采用德国进口探头LHI778,超低功耗工作、体积小、灵敏度高,广泛应用于安防产品、人体感应灯具、工业自动化控制等。本设计也是采用电池供电模式,RCW-0506人体红外感应模块待机电流小于50uA,非常适合于电池供电电路使用,硬件系统非工作时间是处于待机状态的,此时红外模块将作为唯一活动的监测器,它的低功耗性能使得整个系统的待机低功耗表现显著,使本设计使用干电池供电成为可能。See Figures 1 and 2, the overall composition framework of the hardware system and the system hardware connection diagram, the STM32F103ZET6 in the STM32 MCU enhanced series products, it is a 32-bit micro CPU based on the ARM Cortex-M3 core, with a processing frequency of 72MHz and up to 64KB SRAM And 512KB FLASH, rich timer resources, including 2 advanced timers, 4 general-purpose timers, 2 basic timers, communication interface includes 5 serial ports, 1 USB interface, 3 SPI interfaces, 2 IIC In addition, there are 1 12-bit DAC, 3 12-bit ADCs, 1 FSMC interface, etc. The chip has a total of 144 pins, of which 112 are general-purpose IO ports, and adopt the LQFP-144 package structure. The electric control lock drive module adopts TB6612FNG DC motor drive chip, its MOSFET-H bridge structure has high current drive capability, and has dual-channel output, which can drive two DC motors simultaneously through PWM. Each channel can output up to 1.2A continuous drive current, which can control DC motor forward/reverse/stop/brake, supports up to 100kHZ PWM frequency, has on-chip low-voltage detection and thermal shutdown protection circuit, operating temperature: -20~ 85°C, using SSOP24 chip package. The LCD screen adopts ALIENTEK's 2.8-inch TFT-LCD. The LCD screen comes with an LCD driver chip IL9320, powered by a 5V power supply, with a working current of 130mA~350mA, a resolution of 320*240 and 16-bit true color display. Therefore, the power consumption of this display screen is low, which meets the design requirements. In this design, dual cameras are used to collect data. The face positioning camera uses the ALIENTEK OV7670 camera module, and the face acquisition camera uses a USB high-definition camera. The face positioning camera OV7670 is directly controlled by the STM32 microprocessor, and the images it acquires are displayed on the TFT-LCD in real time, which is convenient for users to locate their own face positions. The face acquisition camera is controlled by the Matlab software of the PC, and its main function is to acquire facial images for recognition processing. The requirements for the installation of the two cameras are that the obtained external images should be the same, and the installation height, inclination angle, and environment should be consistent. The sound and light prompt module includes a buzzer circuit and a common anode red and green dual-color LED light circuit. When the hardware system is activated, the buzzer will give a short beep to remind the user. When the face recognition is successful, the buzzer will also beep once. At the same time, the green light is on, indicating that the verification has passed, and the system executes the unlock command. When the facial recognition fails, the buzzer will beep twice, and the red light will be on at the same time, indicating that the verification failed, and the user needs to re-authenticate. The RCW-0506 human body infrared sensor module used in this design is an automatic control module based on infrared technology. It adopts the probe LHI778 imported from Germany. It works with ultra-low power consumption, small size and high sensitivity. It is widely used in security products, human body sensor lighting, industrial Automatic control, etc. This design also adopts battery power supply mode. The standby current of RCW-0506 human body infrared sensor module is less than 50uA, which is very suitable for battery power supply circuit. The hardware system is in standby state during non-working hours. At this time, the infrared module will be the only active monitor. , Its low power consumption performance makes the standby low power consumption of the whole system remarkable, making it possible to use dry batteries for power supply in this design.

参见图3、4,基于面部识别的智能门锁系统监控软件的总体程序流程图和基于面部识别的智能门锁系统监控软件界面图,正常工作下,首先把门锁硬件系统通过数据线与电脑USB口相连通,然后启动MATLAB端监控程序,点击程序初始化按钮,等待初始化完毕,此时采集面部图像框会出现摄像头实时画面,再点击运行监控,程序将进入实时监控,至此PC端设置完毕,接下来启动门锁系统硬件部分,STM32会进入待机状态,只有人体红外感应模块维持正常检测工作,当有人进入红外感应模块检测范围,并且被持续检测到2秒以上时,STM32主控模块将被唤醒,此时需要2秒左右的时间进行硬件系统初始化,初始化完毕后,LCD屏幕会提示用户定位面部头像,准备获取面部图片进行识别,当用户面部定位后,OV7670摄像头和USB高清摄像头会及时捕捉用户定位头像,照片被捕捉完毕后,蜂鸣器短鸣一声,LCD刷新显示刚才捕获的用户头像,此时PC端MATLAB将执行面部检测和面部识别程序,LCD显示“正在识别,请稍后……”等语句,等待PC端识别完毕后的指令,若识别结果是合法用户,则STM32接收到开门指令后控制电控锁驱动模块执行开门动作,否则STM32将会接收到锁门指令,LCD显示“识别失败,请重试!”,这时用户需要重新定位面部,重新拍照进行检测,如果三次识别均失败时,STM32系统将会进入待机模式,人体红外感应模块也会进入10秒封锁时间,在此段时间内,人体红外感应模块将不再检测外界信号,用户只能等待下一次触发时间的到来,才能重新拍照识别。Refer to Figure 3 and 4, the overall program flow chart of the monitoring software of the intelligent door lock system based on facial recognition and the interface diagram of the monitoring software of the intelligent door lock system based on facial recognition. The port is connected, then start the monitoring program on the MATLAB side, click the program initialization button, and wait for the initialization to complete. At this time, the real-time camera screen will appear in the facial image collection frame, and then click Run Monitoring, the program will enter real-time monitoring. Start the hardware part of the door lock system, and the STM32 will enter the standby state. Only the human body infrared sensor module maintains normal detection work. When someone enters the infrared sensor module detection range and is continuously detected for more than 2 seconds, the STM32 main control module will be woken up. , it takes about 2 seconds to initialize the hardware system. After the initialization is completed, the LCD screen will prompt the user to locate the face head and prepare to obtain the face picture for recognition. When the user's face is located, the OV7670 camera and USB HD camera will capture the user Locate the avatar, after the photo is captured, the buzzer will give a short beep, and the LCD will refresh and display the user avatar just captured. At this time, MATLAB on the PC will execute the face detection and facial recognition program, and the LCD will display "Recognizing, please wait... " and other statements, wait for the command after the PC end has completed the recognition. If the recognition result is a legitimate user, the STM32 will control the electric lock drive module to perform the door opening action after receiving the door opening command. Otherwise, the STM32 will receive the door lock command and the LCD will display " Recognition failed, please try again!" At this time, the user needs to reposition the face and take a photo again for detection. If the three recognitions fail, the STM32 system will enter the standby mode, and the human body infrared sensor module will also enter a 10-second lockout period. During this period of time, the infrared sensing module of the human body will no longer detect external signals, and the user can only wait for the next trigger time to take pictures and identify them again.

此外,用户可以在PC端的面部识别的智能门锁系统监控软件进行各种数据库管理操作:例如查看当前合法用户情况,点击“查看合法用户”后,自动弹出窗口显示当前全部合法用户的头像图片,当需要录入新用户时,点击“录入新用户”按钮,弹窗提示“连续录入50张面部图片,请点击‘确认’继续”,这时程序会调用USB高清摄像头,对新用户进行拍照构建图片库,大约30秒后图片获取完毕会弹出窗口提示“新用户信息录入完毕,请点击‘确定’继续”,这时新用户已经在面部识别系统中了,再次点击程序初始化,就可以更新合法用户信息,当需要删除合法用户时,点击“删除用户”按钮,系统就会弹出用户图片库根目录,只需要把想要删除的人物“delete”即可。以上就是用户数据库管理模块功能。除了用户数据的增、删、改,系统还设置了“查看记录”按钮,便于查看用户进门记录,同时也可以作为家庭监控记录,当家里不幸被盗贼撬门了,用户可以通过监控记录查看撬门记录,如此可作为侦破案件的重要资料之一。In addition, users can perform various database management operations on the face recognition intelligent door lock system monitoring software on the PC side: for example, to view the status of current legal users, click "View Legal Users", and a pop-up window will automatically display the avatar pictures of all current legal users. When you need to register a new user, click the "Register New User" button, and a pop-up window will prompt "Continuously register 50 face pictures, please click 'Confirm' to continue." At this time, the program will call the USB HD camera to take pictures of the new user and build a picture library, about 30 seconds after the image is acquired, a pop-up window will prompt "The new user information has been entered, please click 'OK' to continue". At this time, the new user is already in the facial recognition system. Click the program initialization again to update the legal user Information, when you need to delete a legitimate user, click the "Delete User" button, the system will pop up the root directory of the user's picture library, just "delete" the character you want to delete. The above is the function of the user database management module. In addition to the addition, deletion, and modification of user data, the system also sets up a "view record" button, which is convenient for checking the user's entry record, and can also be used as a home monitoring record. Door records, which can be used as one of the important materials to solve the case.

基于PCA的面部识别算法:本文面部识别主要应用PCA(主成分分析法),该算法是一种基于多元统计的方法。PCA主要是利用降维的思想,研究如何利用少数几个主要成分来解释多变量的方差,其中每个主成分都能反映原始变量中大部分信息,且所含的信息互不相关。由于主成分分析把数据转换成低维,让人更加直观看到数据结构,因此PCA也常用于模式识别技术、数据压缩技术和数据特征提取技术。PCA-based facial recognition algorithm: This paper mainly uses PCA (Principal Component Analysis) for facial recognition, which is a method based on multivariate statistics. PCA mainly uses the idea of dimensionality reduction to study how to use a few principal components to explain the variance of multiple variables, where each principal component can reflect most of the information in the original variable, and the information contained is not related to each other. PCA is also commonly used in pattern recognition technology, data compression technology and data feature extraction technology because principal component analysis converts data into low-dimensional and makes people more intuitive to see the data structure.

传统的PCA方法基本原理是:利用K-L变换来提取面部中主要特征成分,构建特征脸空间矩阵,在面部识别时,将待识别图像投影到特征空间上,得到一组投影系数,然后通过与每个人的面部特征进行比对识别。利用这种去相关的坐标变换方法,使得图像压缩前后均方差误差最小,而且变换成低维空间后仍有很好的识别能力。The basic principle of the traditional PCA method is: use K-L transformation to extract the main feature components in the face, construct the eigenface space matrix, and project the image to be recognized onto the feature space during face recognition to obtain a set of projection coefficients, and then pass each Individual facial features are compared and identified. Using this de-correlation coordinate transformation method, the mean square error error before and after image compression is minimized, and it still has a good recognition ability after being transformed into a low-dimensional space.

本文面部识别方法是基于传统的2DPCA算法进行了改进,传统的2DPCA在训练阶段将不同的面部图像共同构建起特征子空间,在面部识别时,将待识别的面部图像投影23到特征子空间上进行比较。当样本库有多个不同类别人物时,若将不同类别人物共同构建一个特征子空间,这样其类内欧氏距离偏小,不同类之间的欧氏距离相对类内较大,而识别阈值T又根据样本间最大欧氏距离来确定,所以往往因为识别阈值T偏大,造成误判。由此,本文提出了一种基于多个特征子空间的2DPCA面部识别算法,在样本训练阶段,分别对每一类人物构建不同的特征子空间,而在面部图像识别阶段,则分别将待识别图像投影到每一类人的特征子空间中进行匹配,匹配成功则待识别图像属于该类人物,否则认为待识别图像是非法人物。The facial recognition method in this paper is improved based on the traditional 2DPCA algorithm. The traditional 2DPCA constructs a feature subspace with different facial images in the training phase. During facial recognition, the facial image to be recognized is projected 23 onto the feature subspace. Compare. When there are many different types of persons in the sample base, if different types of persons are jointly constructed into a feature subspace, the intra-class Euclidean distance is relatively small, the Euclidean distance between different classes is relatively large, and the recognition threshold T is determined according to the maximum Euclidean distance between samples, so the recognition threshold T is often too large, resulting in misjudgment. Therefore, this paper proposes a 2DPCA face recognition algorithm based on multiple feature subspaces. In the sample training stage, different feature subspaces are constructed for each type of person, while in the face image recognition stage, the to-be-recognized The image is projected into the feature subspace of each type of person for matching. If the matching is successful, the image to be recognized belongs to this type of person, otherwise the image to be recognized is considered to be an illegal person.

图5门锁系统运行图。Figure 5 is the operation diagram of the door lock system.

上述为本发明较佳的实施方式,但本发明的实施方式并不受上述内容的限制,其他的任何未背离本发明的精神实质与原理下所作的改变、修饰、替代、组合、简化,均应为等效的置换方式,都包含在本发明的保护范围之内。The above is a preferred embodiment of the present invention, but the embodiment of the present invention is not limited by the above content, and any other changes, modifications, substitutions, combinations, and simplifications that do not deviate from the spirit and principles of the present invention are all Replacement methods that should be equivalent are all included within the protection scope of the present invention.

Claims (7)

1.一种基于面部识别的电子门锁系统,包括stm32主控模块、摄像头、串口通讯模块、人体红外感应模块、存储模块、电控锁驱动模块、显示模块、声光提示模块、电源转换模块、电源开关、遥控接收模块、声光报警模块,摄像头和电机驱动模块,其特征在于,门锁系统工作时由摄像头模块、串口模块、人体红外感应模块、TFT-LCD模块等传递信息给主控模块,经主控模块处理后反馈给各个模块,并执行相应工作,此系统具有与较强的适应性和移植特性,不需要改变硬件系统,即可进行不同环境的移植,只需要修改软件参数即可扩展成为不同环境下的门锁系统。1. An electronic door lock system based on facial recognition, including stm32 main control module, camera, serial port communication module, human body infrared sensor module, storage module, electric lock drive module, display module, sound and light prompt module, power conversion module , power switch, remote control receiving module, sound and light alarm module, camera and motor drive module, characterized in that, when the door lock system is working, the camera module, serial port module, human body infrared sensing module, TFT-LCD module, etc. transmit information to the main control The module, after being processed by the main control module, feeds back to each module and performs corresponding work. This system has strong adaptability and transplantation characteristics. It can be transplanted in different environments without changing the hardware system, and only needs to modify the software parameters. It can be expanded into a door lock system in different environments. 2.根据权利要求1所述的基于面部识别的电子门锁系统,其特征在于,使用以内核ARMCortex-M3为架构的STM32F103ZET6芯片,和嵌入式芯片相比,其执行代码效率更高,支持外部存储器的扩展,支持低功耗模式等优点。2. The electronic door lock system based on facial recognition according to claim 1, characterized in that, using the STM32F103ZET6 chip with the core ARM Cortex-M3 as the framework, compared with the embedded chip, its execution code efficiency is higher, and it supports external Memory expansion, support for low power consumption modes, etc. 3.根据权利要求2所述的基于面部识别的电子门锁系统,其特征在于,本系统选用的是电控阳锁,因为本门锁系统涉及大量硬件模块和外围设备,需要统一集成到门锁内,采用电控阳锁方案进行设计,避免了布线、安装工序的繁琐,可移植性更强,嵌入式系统完全集成到门锁内,用户安装时只需要更换原本的锁体即可。3. The electronic door lock system based on facial recognition according to claim 2, characterized in that the system uses an electronically controlled male lock, because the door lock system involves a large number of hardware modules and peripheral devices, which need to be integrated into the door The inside of the lock is designed with an electronically controlled male lock solution, which avoids cumbersome wiring and installation procedures, and is more portable. The embedded system is fully integrated into the door lock, and the user only needs to replace the original lock body when installing. 4.根据权利要求1所述的基于面部识别的电子门锁系统,其特征在于,此系统采用了双摄像头采集数据,其中面部定位摄像头采用ALIENTEK OV7670摄像头模块,面部获取摄像头采用USB高清摄像头。4. the electronic door lock system based on facial recognition according to claim 1, is characterized in that, this system has adopted double camera to gather data, and wherein facial positioning camera adopts ALIENTEK OV7670 camera module, and facial acquisition camera adopts USB high-definition camera. 5.根据权利要求1所述的基于面部识别的电子门锁系统,其特征在于,采用的RCW-0506人体红外感应模块,是基于红外线技术的自动控制模块,采用德国进口探头LHI778,超低功耗工作、体积小、灵敏度高。而声光提示模块包括蜂鸣器电路和共阳红绿双色LED灯电路,硬件系统被激活时,蜂鸣器会短鸣一声提示用户,当面部识别成功时,蜂鸣器也会短鸣一声,同时绿灯亮起,提示验证通过,系统执行开锁命令,当面部识别失败时,蜂鸣器会短鸣两声,同时红灯会亮起,提示验证失败,需要用户重新验证。5. The electronic door lock system based on facial recognition according to claim 1, characterized in that the RCW-0506 human body infrared sensor module used is an automatic control module based on infrared technology, and the German imported probe LHI778 is used, which is ultra-low power Power consumption, small size, high sensitivity. The sound and light prompt module includes a buzzer circuit and a common anode red and green dual-color LED light circuit. When the hardware system is activated, the buzzer will give a short beep to remind the user. When the face recognition is successful, the buzzer will also beep once. , at the same time the green light is on, indicating that the verification has passed, and the system executes the unlock command. When the face recognition fails, the buzzer will beep twice, and the red light will be on at the same time, indicating that the verification has failed and the user needs to re-authenticate. 6.根据权利要求1所述的基于面部识别的电子门锁系统,其特征在于,基于肤色特征的面部检测方法,通过对颜色特征分析,发现在YCgCr与YCgCb颜色空间下加以约束,能够很好满足亚洲人的肤色检测,而且YCgCr与YCgCb颜色空间下,受亮度影响影响比较小,在面部处于复杂背景下也能迅速检测出面部位置,能够排除大量非肤色特征,极好的保留肤色部分图像。6. The electronic door lock system based on facial recognition according to claim 1, characterized in that, based on the facial detection method based on skin color features, by analyzing the color features, it is found that under the constraints of YCgCr and YCgCb color spaces, it can be well Satisfy the skin color detection of Asians, and under the YCgCr and YCgCb color spaces, the influence of brightness is relatively small, and the face position can be quickly detected even when the face is in a complex background. . 7.根据权利要求4所述的基于面部识别的电子门锁系统,其特征在于,提出了改进的2DPCA面部识别算法,在样本训练阶段,分别对每一类人物构建不同的特征子空间,而在面部图像识别阶段,则将待识别图像分别投影到每一类人的特征子空间中进行匹配,寻找最大匹配度来确定待识别人物的归属。7. The electronic door lock system based on facial recognition according to claim 4, characterized in that, an improved 2DPCA facial recognition algorithm is proposed, and in the sample training stage, different feature subspaces are constructed for each class of characters respectively, and In the facial image recognition stage, the image to be recognized is projected into the feature subspace of each type of person for matching, and the maximum matching degree is found to determine the identity of the person to be recognized.
CN201710039118.9A 2017-01-18 2017-01-18 A kind of intelligent electronic lock system based on face recognition Pending CN106887059A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710039118.9A CN106887059A (en) 2017-01-18 2017-01-18 A kind of intelligent electronic lock system based on face recognition

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710039118.9A CN106887059A (en) 2017-01-18 2017-01-18 A kind of intelligent electronic lock system based on face recognition

Publications (1)

Publication Number Publication Date
CN106887059A true CN106887059A (en) 2017-06-23

Family

ID=59175715

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710039118.9A Pending CN106887059A (en) 2017-01-18 2017-01-18 A kind of intelligent electronic lock system based on face recognition

Country Status (1)

Country Link
CN (1) CN106887059A (en)

Cited By (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107742105A (en) * 2017-10-17 2018-02-27 广东码识图信息科技有限公司 Portable identification authenticating device, identity identifying method
CN108764037A (en) * 2018-04-24 2018-11-06 石狮市森科智能科技有限公司 A kind of Face datection implementation method based on ARM Cotex-A series platforms
CN108843100A (en) * 2018-07-13 2018-11-20 佛山市远阳五金制品有限公司 A kind of ground lock with face recognition function
CN109377624A (en) * 2018-11-23 2019-02-22 卢伟涛 A kind of door intelligent opening system based on facial image identification
CN110020442A (en) * 2019-04-12 2019-07-16 上海电机学院 A kind of portable translating machine
CN112184977A (en) * 2020-10-10 2021-01-05 武汉科卫通智能系统有限公司 Dynamic face recognition entrance guard attendance system
CN117009188A (en) * 2023-09-28 2023-11-07 中核国电漳州能源有限公司 A computer system error-preventing operating system and method
CN119625872A (en) * 2025-02-12 2025-03-14 深圳市银方加博科技有限公司 Access control method, device, equipment and storage medium based on induction
CN119649498A (en) * 2024-12-04 2025-03-18 亿源智行科技(天津)有限公司 An intelligent alarm system for IoT locks based on adaptive learning

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101706874A (en) * 2009-12-25 2010-05-12 青岛朗讯科技通讯设备有限公司 Method for face detection based on features of skin colors
CN102074056A (en) * 2010-04-09 2011-05-25 张宏鑫 Intelligent network burglar-proof door
CN202559880U (en) * 2012-05-01 2012-11-28 齐齐哈尔大学 Intelligent door lock system with face detection function
CN102982349A (en) * 2012-11-09 2013-03-20 深圳市捷顺科技实业股份有限公司 Image recognition method and device
CN104392526A (en) * 2014-11-27 2015-03-04 苏州福丰科技有限公司 Door lock system based on face recognition
CN104636730A (en) * 2015-02-10 2015-05-20 北京信息科技大学 Method and device for face verification

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101706874A (en) * 2009-12-25 2010-05-12 青岛朗讯科技通讯设备有限公司 Method for face detection based on features of skin colors
CN102074056A (en) * 2010-04-09 2011-05-25 张宏鑫 Intelligent network burglar-proof door
CN202559880U (en) * 2012-05-01 2012-11-28 齐齐哈尔大学 Intelligent door lock system with face detection function
CN102982349A (en) * 2012-11-09 2013-03-20 深圳市捷顺科技实业股份有限公司 Image recognition method and device
CN104392526A (en) * 2014-11-27 2015-03-04 苏州福丰科技有限公司 Door lock system based on face recognition
CN104636730A (en) * 2015-02-10 2015-05-20 北京信息科技大学 Method and device for face verification

Non-Patent Citations (4)

* Cited by examiner, † Cited by third party
Title
HE ZHILIANG等: "Research of Face Recognition System Based on Visual Intelligent Monitoring", 《INTERNATIONAL JOURNAL OF MULTIMEDIA AND UBIQUITOUS ENGINEERING》 *
乐丹: "基于2DPCA和Fisher的嵌入式人脸识别系统的实现", 《科技广场》 *
张争珍: "YCgCr与YCgCb颜色空间的肤色检测", 《计算机工程与应用》 *
李晓东: "一种改进的模块2DPCA人脸识别新方法", 《系统仿真学报》 *

Cited By (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107742105A (en) * 2017-10-17 2018-02-27 广东码识图信息科技有限公司 Portable identification authenticating device, identity identifying method
CN108764037A (en) * 2018-04-24 2018-11-06 石狮市森科智能科技有限公司 A kind of Face datection implementation method based on ARM Cotex-A series platforms
CN108843100A (en) * 2018-07-13 2018-11-20 佛山市远阳五金制品有限公司 A kind of ground lock with face recognition function
CN109377624A (en) * 2018-11-23 2019-02-22 卢伟涛 A kind of door intelligent opening system based on facial image identification
CN110020442A (en) * 2019-04-12 2019-07-16 上海电机学院 A kind of portable translating machine
CN112184977A (en) * 2020-10-10 2021-01-05 武汉科卫通智能系统有限公司 Dynamic face recognition entrance guard attendance system
CN117009188A (en) * 2023-09-28 2023-11-07 中核国电漳州能源有限公司 A computer system error-preventing operating system and method
CN117009188B (en) * 2023-09-28 2024-02-13 中核国电漳州能源有限公司 Computer system misoperation prevention system and method
CN119649498A (en) * 2024-12-04 2025-03-18 亿源智行科技(天津)有限公司 An intelligent alarm system for IoT locks based on adaptive learning
CN119625872A (en) * 2025-02-12 2025-03-14 深圳市银方加博科技有限公司 Access control method, device, equipment and storage medium based on induction

Similar Documents

Publication Publication Date Title
CN106887059A (en) A kind of intelligent electronic lock system based on face recognition
CN101414387B (en) Embedded human face recognition gate prohibition attendance-recording machine
CN104217480B (en) A kind of intelligent access control system based on fingerprint and finger vein joint identification
CN108197445A (en) Computer user's identity recognition device and application method
CN107578519A (en) A kind of intelligent access control system and intelligent entrance guard method for unlocking
WO2019128087A1 (en) Dual unlocking method, device and system
WO2016019590A1 (en) Intelligent door lock system, and intelligent door lock and intelligent alarm door
CN1971630A (en) Access control device and check on work attendance tool based on human face identification technique
CN207337495U (en) Laboratory Intelligent entrance guard management system based on recognition of face
CN110718008A (en) 3D face recognition module, door lock and door
CN209357127U (en) An access control device based on multiple biometric identification
CN203366348U (en) Face recognition system and entrance guard system
US20200057882A1 (en) Method and system for unlocking electronic cigarette
CN103856614A (en) Method and device for avoiding error hibernation of mobile terminal
CN103336950A (en) Human face identification method and system
CN101521723B (en) Iris recognition start-up control method and television
Elechi et al. Facial Recognition Based Smart Door Lock System.
CN205158487U (en) Biological identification entrance guard's equipment
CN204595965U (en) Electromagnetic type identifies and control door access control system automatically
CN202767667U (en) Burglarproof door lock control system by finger identification
CN109727346A (en) Directly locking the networking door-locking system and testimony of a witness comparison method for realizing that the testimony of a witness compares
CN205910709U (en) An intelligent finger vein authentication device
CN205654255U (en) Face identification intelligence door
CN205845128U (en) One refers to vein card-swiping intelligent access control system
CN204204058U (en) A kind of based on fingerprint and the intelligent access control system referring to combined with intravenous identification

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
RJ01 Rejection of invention patent application after publication
RJ01 Rejection of invention patent application after publication

Application publication date: 20170623