题目:基于单片机的声光控开关电路的设计摘要本毕业设计就是一种简单的通过声音和光线来控制继电器的断开闭合,从而达到开关的自动断开、闭合功能,其具有很强的适用性。该设计主要由STC89C52单片机、电压源电路、声音的接收放大控制电路、光信号的接收放大控制电路以及继电器的驱动电路组成[1]。本设计通过altium软件进行原理图的绘制,proteus软件进行电路仿真图的绘制及仿真,keil软件对程序的编写,编译与执行,实物图的制作与元器件的焊接来实现总体的效果的[2]。仿真与测试均出现四种情况:无光无声时、无光有声时、有光有声时、有光无声时,结果后文皆会阐述。测试结果证明该系统性能稳定、操作方便,具有较高的实用价值。可以广泛用于楼道,小区,及其他公众地带。但是仿真电路图用开关去代替光控和声控过于简单。本设计只能解决有无光照,有无声音的灯泡亮熄,并不能算出光照强度与声音大小的阈值,也不能因光线的不同,声音大小的不同控制灯泡的亮暗程度。关键词:STC89C52;声控;光控;自动开关AbstractThegraduationdesignisasimplewaytocontroltheinterruptingandclosingoftherelaythroughthesoundandlight,sothattheswitchisautomaticallydisconnectedandclosed,andithasastrongapplicability.ThedesignismainlycomposedofSTC89C52singlechip,voltagesourcecircuit,soundreceivingandamplifyingcontrolcircuit,opticalsignalreceivingandamplifyingcontrolcircuit,anddrivingcircuitofrelay.ThedesignofthedesignthroughAltiumsoftwarefordrawingtheschematic,ProteusSoftwareforthedrawingandSimulationofthecircuitsimulationdiagram,keilsoftwareprogramming,compilationandimplementationoftheprogram,theproductionofphysicaldrawingsandtheweldingofcomponentstoachievetheoveralleffect.Therearefourcasesinsimulationandtesting:whenthereisnolight,nosound,nolight,sound,andnolight,theresultwillbeexplained.Thetestresultsshowthatthesystemhasstableperformance,convenientoperationandhighpracticalvalue.Itcanbewidelyusedincorridors,residentialareasandotherpublicareas.Buttheanalogcircuitdiagramisreplacedbyswitchinsteadoflightcontrolandvoicecontrol.Thedesigncanonlysolvethelight,nosoundlightlight,andcannotcalculatetheintensityoflightandthesizeofthesoundthreshold,andcannotvarythelightandthesiz...