欢迎来到天天文库
浏览记录
ID:6251829
大小:469.28 KB
页数:42页
时间:2018-01-07
《基于单片机室内无线环境监控系统》由会员上传分享,免费在线阅读,更多相关内容在学术论文-天天文库。
1、本科毕业设计(论文)基于单片机的室内无线环境监控系统摘要我们知道温湿度是温室大棚种植里面关键的环境变量,因此对温度和湿度进行监控成为温室大棚种植的重要任务之一。本系统是以温室大棚种植为背景,设计一个基于STC12C560S2单片机的温室内无线环境监控系统,可以远程监控温度和湿度。温湿度传感器DHT21采集到室内的温度和湿度后,通过单总线将数据发送给上位机进行处理。单片机把处理好的数据经过SPI接口传输给无线收发模块NRF905。无线模块将数据进行打包,加上CRC检验码后,放入发送数据寄存器。系统等待NRF905启动发送模
2、式,然后把温室度的数据和接收端的地址一起发送出去。下位机的NRF905无线模块不断地检测空中的电磁波。当接收到与自身的地址相配的地址后,模块开始接收到数据。对数据进行解包,去除CRC检验码后,无线模块把数据存储在数据接收寄存器。下位机通过SPI接口读取数据,将温度和湿度显示在液晶屏上,同时判断是否需要启动报警。系统采用C语言进行编程,同时可以通过按键对温度和湿度的报警范围进行设定。关键字:单片机,无线收发模块,温湿度传感器,室内环境AbstractWeknowthattemperatureandhumidityareke
3、yenvironmentalvariablessingreenhousesplanting,thereforetomonitortemperatureandhumiditybecomeoneoftheimportanttasksofgreenhousesplanting.Thissystemisbasedonbackgroundofgreenhousesplanting.DesigningawirelessenvironmentmonitoringsystemingreenhousebasedonSTC12C560S2m
4、icrocontroller.Thissystemcanremotelymonitorandcontroltemperatureandhumidity.AftertemperatureandhumiditysensorsDHT21havecollectedtheindoortemperatureandhumidity,thedataissenttothemastermachineforprocessingthroughthesinglebus.MCUprocessesthedataandthentransmittoNRF
5、905wirelesstransceivermodulethroughSPIinterface.Afterpackagingdataandaddingthecheckcodeintothedata,wirelessmoduleputsthedataintoregister.ThesystemwaitforNRF905startingdeliverymode,andthenthedataofgreenhouseandaddressissenttogethertothereceivingend.TheNRF905wirele
6、ssmoduleofslavemachinecontinuouslydetectstheelectromagneticwavesintheair.Whenreceivingmatchingaddress,themodulebegantoreceivedata.TounpackthedataafterremovingCRCcheckcode,thewirelessmodulestoresthedatainthedatareceiveregister.SlavermachinereadsdatafromtheSPIinter
7、face,andthendisplaysthetemperatureandhumidityontheLCDscreen,andjudgeswhethertostartthealarmatthesametime.SystemusestheClanguagetoprogram,andcanbesetalarmrangeoftemperatureandhumiditythroughthebutton.Keywords:Singlechipmicrocomputer,Wirelesstransceivermodule,Tempe
8、ratureandhumiditysensor,Indoorenvironment目录1绪论11.1课题研究的背景和意义11.2我国温室种植的发展及研究现状11.3论文研究的主要内容22室内无线环境监控系统总体方案32.1系统设计的基本思想32.2系统总体架构32.3系统软件开发环境53系统器件方案选择63.1单片机
此文档下载收益归作者所有