More than 5 million for a smart home

I have already spent more than 5 million rubles on building my smart home system. What do these costs consist of?

Of course, during all this time, you constantly have to configure, adjust, reconfigure something, study something, experiment something, and of course it all takes a lot of time. I started building the system at home with various simple devices, the idea of course was initially very simple, to make the light control of one of the rooms, so that I could remotely turn it on or off when someone forgot to turn it off there in a timely manner and I don't want to go to this room or ask someone. But then I started experimenting, bought different microcontrollers, started with Arduino while they were popular, studied the protocol at a frequency of 433 megahertz, working different transmitters and receivers, bought different relays working at this frequency and tried to set up the light operation and light off in this way. But of course, the relay in the socket is not very fit to do some ugly decisions to attach next to the switch, I also tried, these relays did not want. Then there were more wireless switches from me, I also bought them and tried to connect them with such a relay, this also took a lot of time, I needed the Arduino IDE programming environment. I used and still use it, because you can make different modules for it, you can program not only Arduino, but also other microcontrollers on it, and in principle it's not difficult, and the language is similar and the libraries are similar, and so I tried to do all the management of smart home systems on Arduino, of course without a real smart home server, without real scenarios, of course, this was not very convenient to do. So after a while I bought a Rasberry it was a Pi3 version, and I bought it basically just in a nearby store, the nearest so to speak, and it was not very cheap, but I also basically did not know other ways to purchase it, I did not use it in large quantities and the price itself was not very good the big one in the region of 3.5 thousand only cost me.

Moreover, I immediately bought a fashionable beautiful white case and of course tried to learn how it works, in principle I was not very immersed in Linux, that is, I knew it a little, but of course this was not enough for everyone, the maximum that was enough was just to install it and, in principle, somehow run it. Well, the advantage of course is that Debian is used there mainly, and of course it has a graphical shell made there by default, which is basically similar to Windows and this greatly facilitates at least some initial configuration, some initial launches and at least in general understanding of how it looks how it works and how this is being installed. But then I had to study different options for connecting via ssh, respectively, different shells are installed, I put mc, i.e. this is midnight commander, an analog of far or earlier there was still norton commander, respectively, the interface is basically similar, and this also helps a lot, so that not just some editors built into Linux, it's still quite difficult to enter commands, write scripts, and accordingly, of course, such a shell greatly helps, and even the simplest copying files is much easier, of course, and I had to study it to understand how Linux works, how this entire operating system works, and then, accordingly, what commands and programming languages are there, also, I was not very familiar with python, there was still version 2.6.2, which I also had to learn, try to write different scripts in it, learn different libraries, because in fact python and its strength is only to connect different libraries, the language itself is just a language and of course there is a lot in it and you won't write it.

Then I installed the Open HAB smart home system on this Raspberry, I started studying it, too, there was version 2 of some kind, and of course it was also unfamiliar they had their own built-in programming language there, writing scripts and describing different objects, too, I had to study everything to understand how it works, also sometimes it was not installed the first time this also had to be solved and was quite difficult. And it also became interesting to use some relays, they were also connected to different microcontrollers by the same Arduino and, accordingly, it was necessary to understand how it should all interact together, how it works, wrote different scripts for working on wireless data transfer protocols, and this is also quite difficult and use standard libraries, and secondlythe first ones are difficult to understand, and secondly, they are certainly not very flexible, not very universal, something does not work for them, and accordingly it is easier to really understand the protocol and write your own script handler for this protocol, than trying to learn this library somehow, and try to configure it somehow. Well, then I studied various options related to the operation of the ESP 8266 microcontroller, what they can do, I tried to make them also like a smart home gateway, a web server, then, accordingly, in some way so that it was a solution that did not depend on the microcomputer, I thought that in principle this can also be implemented. In fact, of course it is possible, but for example, if the questions relate to saving some statistics, then of course you can't save it on the microcontroller, so you need to somehow think where else to save it, so I used it, made a site on an external hosting and store all the data there, in principle it is very convenient, it is available always via the Internet and in case of any local problems, all this will also work, and therefore this is probably also a good solution, as it seemed to me. And again, there it was necessary to study what to do it on, how to integrate it with each other, how to establish interaction between the smart home system and this hosting, i.e. it also takes a lot of time, and it's also not very easy to understand it all very quickly.

Then I started learning how to make all sorts of solutions related to autonomous operation, that is, I started studying microcontrollers that are already clean, so to speak, i.e. they were attiny 85, in fact they were most suitable for me in all their characteristics, capabilities, and I also needed to study how they work, because even at the command level it is practically impossible, i.e. libraries, it is not really possible to use it, there is not enough memory for this, and of course there is half of low-level programming there, this is some kind of classic assembly, direct port management is also a very difficult topic and also had to be studied for a very long time. But then, first of all, I had a transition from Open HAB to version 3, which also brought quite strong changes, I had to redo all the scripts that were developed, re-study the interfaces, then I already realized that Open HAB is somehow not a very interesting system, because it supports less of some here more such and such user devices that we have available from different Chinese manufacturers, that is, it is more focused on some American market, most likely, that is, all the integrations there are no more useful for us, and of course I switched, I also installed an additional Home Assistant system, started studying it, and there were also problems there, first of all, the python language version changed to the third one, there were big changes in Home Assistant related to this, and in general, in the whole smart home system I have, because python 3 works somewhat differently, there other commands are used, I had to rewrite everything, recheck, reconfigure, everything started to fall apart, it also took a very long time.

I made a complete transition to using it, almost all scripts now work in bash. That is, I generally abandoned all libraries and programming languages other than the language of the Linux operating system, this is more reliable, even in bash I do not use various additional modules, I try to make do with very basic commands to the maximum. It took a lot of time to study different ecosystems, I studied the Tuya ecosystem, studied the Xiaomi ecosystem, studied the Yandex ecosystem, integrated with Yandex with the Yandex smart home system, that is, I made my own completely, because it was not ready and only recently a more or less convenient way of integration appeared in Home Assistant, but it is also not completely complete supports all devices, not all sensors and not all parameters of these sensors, so it is also much more convenient to use your own, so you also need to study all this. This is also time-consuming.

But in the end, it turns out that for about all these days I spend somewhere on average probably three hours every evening there, on weekends it happens even more, which in principle, in total, it turns out that I have already spent about five thousand hours on a smart home, well, if you take the average programmer rate of a thousand rubles per hour, but that actually turns out to be 5 million, which I practically invested my own labor, my own time in building my smart home system.

Automation in a smart home should be useful and create additional comfort, but sometimes everything goes wrong… The reasons for this, and how to configure everything, see on my channel.

You may also watch

Article By Alex

If you have any ideas on how to improve automation, make it more reliable, fast and useful, then you can leave a comment below. I will try to implement the proposals and tell you in the following videos.