Note: This instructable is still work in progress (WIP), since I don't have much time because of the school and I am having problems with Edison. And because I am perfectionist, while the instructable is in state WIP, I will only publish partial schematics and block schematics. The software will be available when I'll be sure that is without any bugs.
The idea for this project came when one weekend I came to our weekend house at the seaside and even that was outside 33°C, I had a feeling that I will freeze, since the AC was working all week on 16°C. The main idea is, that the Edison will have connection to the internet so you can monitor the situation in the building (temperature, humidity, used water, used rain water, consumption of energy from grid/solar panels, etc) and also have function to control some things (blinds, heating/AC, watering system, music system, etc.). But because of the safety reasons I decided to include control of safety switches and sensor as well (valve on main water intake, kill switch for AC, gas sensor, etc.). And because actions of the safety switches will be controlled automatically, I added a SIM800 module so I would get SMS, when something unpredictable happened. But I can also use SIM800 for controlling the Edison.
Teachers! Did you use this instructable in your classroom?
Add a Teacher Note to share how you incorporated it into your lesson.
Step 1: Brains of the System
The brain and the heart of the system is Intel Edison, but because is doesn't have enough of I/O ports and it would be without sense to use it for controlling less important features as PWM-ing the LED strips, controlling the pump for watering system etc. I decided to use Edison in formation with other controllers. Which are Raspberry Pi, Arduino UNO, XMC1100 (I only have one Arduino) and XMC2go. Among them self they will be connected via I2C.
Raspberry Pi 2 Model B: Its function is to work as HTPC (home theatre PC) which means it will be controlling music and video. It will be connected to my two external HDDs on which is content for playing, but it will also be connected to internet, so you could use Netflix and other streaming services. But it will also have the dongle for a wireless mouse and keyboard so you could surf the web from the comfort of couch. For the software I am still testing, but I will probably chose XBMC and in case the RPi won't be powerful enough I will replace it with Intel NUC.
Arduino UNO: Its function is controlling the blinds and LED strips. Because it isn't possible to control blinds or strips directly from arduino, I had to use a few external components, which will be explained in one of the next steps.
XMC1100: Its function is control and collect data from outside. Which means control of the watering system, sliding sunroof and collecting data from temperature sensor, humidity sensor and UV sensor.
XMC2go: In the main product I will probably use AtTiny2313, but for proof of concept this one will do. It will control AC and will collect data from light sensor, temperature sensor and humidity sensor.
Step 2: Blinds
Electronic blinds are very useful, because not only that you can control them via uC, but they are much more robust that hand blinds. And in case you didn't know the function of the blinds is also reflecting the heat out of the room, which means that they have to be installed outside. At the seaside is in the morning fairly cold, so we can use this that the blinds will be opened in the morning (when the window will be also open) and when the temperature outside raises over certain level the blinds will close and AC will turn on.
The motor in the blinds has 4 wires. Neutral, Live for opening, Live for closing and PE. Because when you control 230V with Arduino is it reasonable to protect it with galvanic isolation. Which means I had to use optocouplers to drive relays. But to prevent connecting Live to wire for closing and opening at once, I had to wire relays in safety wiring which means when one relay is connected there is no way the other can be connected. The signal from end switched from blinds is connected via optocoupler to arduino so it can know when to turn off relay. But some relays are very noisy and a solution to this problem is a little bit more expensive, but it is certainly worth it. It is a solid state relay. And safety latching here is done with a NPN transistor on a primary side. Which will pull down (via resistor) the positive side of a SSR.
Step 3: LED Strips
Because I LOVE LEDs I said that I have to include them in this project. And since everyone that has come to my place was enthused about RGB 5050 strips that I had installed in my living room and bedroom, I decided to install them in weekend house as well. So now is on its way from china 30m of LED strip (oops o:) ). At first I planned to use CD4094 8-bit shift register with inverter and IRFZ44N N-mosfets. But because of all the PWM-ing I am deciding to use LED controller such as STP24DP05. At first I wanted to use WS2812, but I wanted 30m of them I would probably have to sell my liver (LOL). For lightning in kitchen I'll use cold white 5050 strip. All the strips will be power from chinese 12V switchers. They are pretty cheap and work for quite long time.
And because we don't want to waste energy, if outside temperature will be acceptable, the leds will dim or completely turn off and the blinds will open. To control that the digital light sensor will be used.
Step 4: Entertainment System
Because what is better on a rainy afternoon that to lay down on a couch with your SO and watch a good movie (or a two). But most films played on TV are old and most of the time boring. So a solution is a renting or streaming a movie. And for this job the Raspberry Pi 2, model B would be perfect. It has HDMI output, 4 USBs, ethernet and you can interface with it via I2C. I also connected a wireless mouse and a keyboard, so I can interfere with it.
But here comes the problems. You have to turn on the TV and the stereo system. In a future, I am planning to set up an IR transmitter and record the signal from remotes, so the RPi could replace them.
Step 5: Rainwater Collection & Distribution System
We have a 1000l tank (IBC container) which collects rainwater from the roof. We use rainwater for watering the garden and grass. But if its very hot and no one is there to water them they quickly dry up. So the watering system is made from: magnetic valves, flow sensor (used only for statistics), moisture sensors, pressure pumps (ones from dental showers work the best), some power circuitry and XMC1100 microcontroller. Main magnetic valve is at the output of the IBC and after it there is a flow sensor. Than there are smaller magnetic valves at the intakes for each "sector". And than depending on the sector there is diferent configuration of the pumps and sensors.
Step 6: Please Stand By
Please be patient, since I don't have much free time, so I can't finish the instructable. I will try to finish it ASAP.
Participated in the
Intel® IoT Invitational