The lamp has been bought, but I want to control it with my mobile phone. What should I do? Does anyone do lighting intelligence?
The era of intelligence has arrived, but it has not penetrated into every aspect of our lives, but it is not because of technology, but because of your laziness. As long as you want, you can also let your life be infiltrated by intelligence, as long as you move your hands a little. To enjoy smart life, it is necessary to make your home appliances "think" and have an intelligent "core", that is, a microcontroller. Want to control the desk lamp at will with your mobile phone? It's simple. First of all, you should prepare props, such as desk lamps, smart phones, microcontrollers, Bluetooth modules, relays, DC voltage stabilizing modules, program downloaders, circuit board connecting devices, connecting wires and so on. First, write a program for the microcontroller so that it can clearly understand the command, connect the desk lamp, relay, microcontroller and Bluetooth module, and then write a program for the mobile phone to send instructions to Bluetooth module. In this way, when you want to turn off the desk lamp, you only need to search the Bluetooth module installed on the smart desk lamp with your mobile phone, establish a wireless connection, and then press the "turn off the light" command on your mobile phone. At this time, the Bluetooth module will transmit instructions to the microcontroller, and then turn off the desk lamp through the relay. Does this give you a taste of wisdom? However, such intelligence does not seem to be advanced enough and does not help life. But imagine intelligently controlling all the lights in your home through your mobile phone? It seems that the practical value is much higher. You don't need to go to the wall to turn on and off the lights. Just take out your mobile phone and you can control it comfortably. Even in bed, you can turn off the ceiling lamp that you forgot to turn off in the bathroom. This should make you look forward to it. Because there are many lights on the ceiling, we need a main microcontroller, a Bluetooth module, a bunch of wireless switches, a bunch of sub-microcontrollers and a bunch of relays. After these are connected, you can send instructions to the main microcontroller through the Bluetooth module of the mobile phone, then to the electric light through the transmitting module of the wireless switch, and finally to the electric light through the receiving module of the wireless switch of the auxiliary microcontroller, and finally to complete the task through the relay. In smart home, the intelligent lighting system should have more advanced functions, such as the light switch can be automatically switched according to the area where people are active, the switching time of the light can be preset, and the brightness of the light can be automatically adjusted according to the indoor brightness. The realization of these functions depends on sensors. The combination of sub-microcontroller, wireless receiving module and lamp is called "intelligent lighting node", and then PIR (passive infrared) sensor is added to sense the existence of people. By adding a PIR sensor near the lighting area and connecting it to the "intelligent lighting node", people can turn on the lights when they come and turn off the lights when they leave. Wake yourself up with an alarm clock, and you may have begun to have some "immunity", and your ears will automatically filter the alarm clock. Then you can try to wake yourself up with the light. I'm also afraid that I accidentally fell asleep and forgot to turn off my cell phone? You need a smart light that can preset the switching time. A program is added to the mobile phone and the main controller respectively, so that the main controller can decide when to let which wireless transmitting module give instructions to turn on or off the corresponding lights according to the instructions of the mobile phone. So that the electric lamp can be preset. In addition, a photosensitive resistor is added, so that the sub-microcontroller of "intelligent lighting node" can continuously measure the resistance value of this photosensitive resistor, and then control the intensity of the light according to the resistance value. In this way, indoor lighting can automatically adjust the brightness. But is intelligent life just about changing electric lights? Do you expect to be able to control all the electrical appliances in your home more intelligently, such as TV sets, air conditioners, electric water heaters, water dispensers, stereos and so on? In fact, as long as some new "intelligent nodes" are added to the control network for controlling electric lights and corresponding programs are added, this expectation can be realized. Electric water heaters and drinking fountains are controlled in the same way as electric lights. The transformation of TV and air conditioner controlled by remote control will be a little more complicated, but it can still be done. Firstly, the signal of the remote controller is recorded by infrared tube, and then an infrared emitting tube is added to the intelligent node, so that it can emit the corresponding remote controller signal according to the instructions of the mobile phone. Audio can be transformed into a Bluetooth headset, and the audio output line of this headset is taken out and connected to the audio. Can only electrical appliances be intelligent? Even windows, curtains and doors can be opened and closed automatically. Of course, this requires intelligent nodes and action elements, such as motors or pneumatic pushrods. In fact, this is also the Internet of Things that has developed rapidly in recent years. Internet of Things is a kind of network that connects anything with the Internet according to the agreed protocol through information sensing devices such as radio frequency identification (RFID), infrared sensor, global positioning system and laser scanner. , information exchange and communication, realize the intelligent identification, positioning, tracking, monitoring and management of goods. In the future, your air conditioner can not only be controlled by your mobile phone, but also read your instructions online. Register a Weibo account for the air conditioner at home and let the control center surf the Internet. Even if you are outside, you can set the temperature by clicking on your air conditioner. This is the change that smart life will bring.