Font Size: a A A

Environment Detection And Appliance Control System Of Household Based On STM32

Posted on:2015-03-19Degree:MasterType:Thesis
Country:ChinaCandidate:L LiFull Text:PDF
GTID:2268330428465150Subject:Microelectronics and Solid State Electronics
Abstract/Summary:PDF Full Text Request
Home life plays an important part of daily life. In recent years, smart home subverts thetraditional housing concept and brings a different household experience to people. People can easilycontrol appliances and get a sense of security at the same time through smart home. On the basis ofcurrent market demand, the detection and control system was designed which used the Ethernet toimplement communication network and achieved relay control, infrared learning control, prompt oftext to speech, test of temperature, humidity, light and remote monitoring and control throughAndroid application.The main contents of this paper are divided into the following sections.1. Analyzed the design requirements of detection and control system of this topic and divided thesystem into main controller and client two parts. Hardware operation is completed by maincontroller and remote monitoring is implemented by client. These two parts communicatedwith eath other through Ethernet.2. After analyzing the communication modes and peripherals requirements of detection andcontrol system,32-bit microprocessor STM32F107was picked as the core of hardware designwhich is small and high cost performance. The connectivity chip has built-in Media AccessControl and dedicated DMA controller which provide the necessary conditions to realize theEthernet. Then reliable network communication was implemented on the basis of the existingequipment. A variety of monitoring and control front ends were provided such as control ofhousehold appliances by using relay or infrared module, environment monitors oftemperature,humidity and light factors, prompts and alerts by text to speech module.3. The software of the main controller was divided into two parts, hardware drivers andcommunication protocol. With electrical parameters and clock system configured for hardwareof the main controller first, then drivers of modules were designed which used the RS232serialport communication, analog to digital conversion and I2C bus communication and so on. RMIIwas chose as communication mode of the Ethernet in order to save the use of ports. Themodules of text to speech and infrared learning have their own command frame format andcontact with STM32via serial port which was realized by MAX3232. Relays were operated byGPIO ports directly. In the sensor module, the temperature sensor had specific working timing,the humidity sensor used ADC to sample and the light sensor used I2C as communicationprotocol.4. The lightweight uIP was chose as communication protocol of the system. Writing networkdriver, configuration of uIP clock system and setting up the relevant parameters are the three steps of transplanting uIP protocol. On the basis of uIP protocol, a simple application layerprotocol CTP(Command Transfer Protocol) was designed which was used to implementcommand sending and receiving, judgment and ultimately control the hardware.5. Android application was used to implement the remote client. After building the platform,different components were put to complete the user interfaces including login and registration,main control and sub-control interfaces. Socket communication interface was used tocommunicate main controller system and the application. And some functions like controllingdifferent relays, learning and controlling appliances by infrared signals, reading data aboutenvironment, etc were implemented by Android application.After testing and applying the system, every module worked normally and complied with thedesign requirements.
Keywords/Search Tags:Smart Home, Environment detection, Appliance control, STM32, uIP, Android
PDF Full Text Request
Related items