红外遥控电子密码锁的设计摘要在我们的日常生活以及工作之中,密码锁是一种随处可见、不可或缺的必需品,也是我们个人隐私和财物的保护伞。小到个人日记本,大到国家机密,它无处不在,当然,形式也是各有不同。平时所见的机械式锁必然离不开钥匙,而且一旦钥匙丢失或者遗忘在办公室等地方,会给人们带来不必要的麻烦,显然,古老的保护装置已经无法满足新时代的要求。以前的电子锁密码结构简单,存在安全性问题。而今天的密码锁具有较高的密保性,并且生产成本低,容易操作。开锁人不需要携带钥匙,更不必担心钥匙丢失,只需记住密码就能打开。本次设计以STC89C52单片机为基础,增添了许多功能,比如矩阵型键盘、提示音和显示屏。可以设置和修改用户密码(默认密码为六位),也包括密码错误报警指令、多次输入错误锁定、多次输入错误报警等功能。当密码输入正确时,会自动显示“OPEN!”,密码错误则为“ERROR!”。当密码连着输错三次,系统就会自动锁死。关键词STC89C51LCD1602电子密码锁4×4矩阵键盘IDesignofinfraredremotecontrolelectroniccodelockAbstractInourdailylifeandwork,thepasswordlockisakindofeverywhere,indispensablenecessities,itprotectsourprivacyandpersonalpropertysafety.Smalltoindividualdiaries,largetostatesecrets,itiseverywhere,certainly,themodusismanyforms.Usuallyseethemechanicallockmustbeinseparablefromthekey,andoncethekeyislostorforgottenintheofficeandotherplaces,willgivepeopleunnecessarytrouble,obviously,theoldprotectiondevicehasbeenunabletomeettherequirementsofthenewera.Atpresent,weusetheelectroniccodelockinsteadoftheoriginalmechanicallock,tosolvethepreviouspasswordistoosimple,lackofsecurityshortcomings.Thenewelectroniccodelockisnotonlylowprocessingcost,simpleoperation,andsafetyperformanceisalsothetraditionalmechanicallockcannotbecompared.Unlockingpeopledonotneedtocarrythekey,donothavetoworryaboutthekeyislost,justrememberthepasswordwillbeabletoopen.ThisdesignisbasedonSTC89C51single-chipsystemdesign,andsubjojina4×4keyboard,showandalarmsystem.Youcansetandmodifytheuserpassword(thedefaultpasswordissix),includingpassworderroralarminstructions,multipleinputerrorlock,multipleinputerroralarmandotherfunctions.Whenthepasswordisenteredcorrectly,itwillautomaticallydisplay"OPEN!"Andthepassworderroris"error!".Iftheerrorthreetimes,itwilllock.Keywords:STC89C51LCD1602Electronicpasswordlock4×4keyboard目II录Abstract....................................................................................................................................II图清单....................................................................................................................................VII表清单...................................................................................................................................VIII1绪论......................................................................................................................................11.1课题研究背景及意义....................................................................................................11.2研究现状.......................................................................................................................11.3电子密码锁的发展趋势................................................................................................21.4本章小结.......................................................................................................................22总体设计方案..............................................................................