In order to start developing any of the features in PiIoT - DomPi: Intro there is a need to create the basic system, build the nodes and connect them. In this post I will describe the part of the architecture that should help deploy them.
Project Dashboard
The focus this week is on creating a simple project dashboard to track progress on the key developments of the nodes. There will be seven nodes.
Five of them will be Arduino based: kids´room, parents´room, living room, garage and garden. The Arduinos are perfectly fitted for the tasks that these nodes need to execute: interact with some simple sensors, managed the RF communications and be a cost effective solution. Additionally, yes, hehe, I got several Arduinos at home waiting for being used
Below there is a dashboard with the current status - the intention will be to move as many as possible to the green color!
The two remaining nodes are Raspberry Pi based and require more processing capacity than the previous ones and also interact with more complex HW to display the Home status. They are the Control Panel and Command Center nodes and besides some communications and sensors, they will also display the key information in to the TFT touchscreen of the project and to my TV. I plan to create a similar dashboard for these noes in the coming weeks - they are a bit more complex and want to give them several thoughts.
As you can see, many lines are repeated across the modules to allow some code reuse, however, as you all know, this is not a fabric… meaning that each time I will need to make sure the connections are right, also I have different Arduino types (nano, pro mini, uno, mega) making it less of a copy-paste. In the end there will be issues coming up, hence I decided to track the progress totally independently.
Living room node. First steps
I want to start with some quick-wins that show here and at home the potential of the project. I have started with two features: light control and IR detection and I´m also having a look at the temperature and humidity sensors.
Light Control
At home I have three DIO Chacon plugs that are controlled via a RF remote controller. They are like these ones. Googling for it, I have found people that have recreated the protocol like here and here. Basically it consists of 26 bits, including a code for “your set”, the plug number and if it has to go on or off.
The first step is to discover my set´s code, luckily enough there is some code around to dump the RF signal via the Serial port and extract the header - as soon as I find the one that works with me, will post the link. So far I will be using the most common RF433Mhz to receive and transmit. Like those in the picture. 
The idea is to connect the receiver RF module and dump the full packet sent by the original remote control. I will copy the code programmed in my set and will try to replicate the RF packet using the emitter module. If all goes ok, I should be able to turn on and off the three plugs at home.
Control lights with the TV remote control
The second feature I´m developing is to control the RF plugs with the TV remote control Many times we are in the living room and it becomes dark and guess where the plugs control is far away yep However the TV remote is always in the room so I thought that even better than to control it via the mobile phone(web server it is more comfortable with the TV remote control For doing this I have connected a TSOP31238TSOP31238 IR receiver like the one in the picture directly to the pin 9 of the Arduino 
The process will be similar than with the RF packet. I plan to get the IR code that my remote control sends and use it to turn on or off the Chacon plugs from the previous paragraph. Thinking about which buttons to leverage from the TV control, I need to hijack those that are seldom used at home and also that have no effect on the TV while we watch it. For example, I can´t use any number to turn light 1 on/off since it will interfere with us watching the television and... you don´t want to mess around with your hobby things and your family members, hehe. I´m thinking to use the red-yellow-green-blue buttons that are mostly used in the TV menus. I have tested them and while we are watching in the TV, they produce no effect. The Arduino library IRremote.h comes with an example to dump the IR codes, so I will be using it for this purpose. Let´s see how this evolves.
Temperature and humidity
At home I have the DHT11 sensor that measures both the humidity and the temperature. In principle, I could use this sensor, however, I have realized that the temperature provided by the DHT11 has no decimals, meaning that the precision is at 1ºC. In theory this should be ok, but since we have at home another thermometer that measures to the 0.1ºC, I need to avoid comparisons between my system and any other stuff that may look better at home
This means, I need to provide at least the same accuracy and here enters into play the Dallas sensor DS18B20. This has a resolution up to 0.0625ºC, fair enough!
The drawback is that I will need two components for the nodes, instead of only one. In principle, all of the Arduinos have enough digital pins so that should not be a problem.


Top Comments
-
DAB
-
Cancel
-
Vote Up
+1
Vote Down
-
-
Sign in to reply
-
More
-
Cancel
-
mg.sergio
in reply to DAB
-
Cancel
-
Vote Up
0
Vote Down
-
-
Sign in to reply
-
More
-
Cancel
Comment-
mg.sergio
in reply to DAB
-
Cancel
-
Vote Up
0
Vote Down
-
-
Sign in to reply
-
More
-
Cancel
Children