Integration of Home Assistant and Yandex smart home
At first, I started using OpenHAB as the main smart home system, it was version 2, and in principle, I tried to build full integration with all different systems on it, with systems from Xiaomi and Tuya manufacturers, but in fact there are few integrations in OpenHAB that I needed, and one of the main such integrations is there was no integration with the smart home from Yandex, but in principle, even when I started there was no integration with Yandex at all, and Yandex did not even have a smart home, that is, it was an opportunity simply through the skill to use a connection to a smart home and already using a smart speaker, to speak different commands through this skill, and all processing was on the side of this skill, that is, if the developer made it possible to somehow transmit a command to turn on the device in the smart home system, then in principle, then it could work like this, then when Yandex had a smart home, a separate type of skill, integration was done by one of the developers, which in principle allowed the device to be normally transferred from OpenHAB to Yandex.
I tried it, but after a while, firstly, it was a third-party developer and there was no guarantee of the reliability of this solution, that is, that the data would not go anywhere, because in principle I had to enter the password from OpenHAB directly on the website of this developer, and of course the integration itself supported very few features, then that is, in principle, it was possible to turn on or off only sockets or lamps, on the openhab side it was necessary to set up all the objects specifically, but this was also not very convenient in principle, and as a result, in order to make normal integration with column support, I started looking for another system, in principle, I chose the Home Assistant system, integration was already implemented in it, it was basically only available there, and then they tried to bend it into several other smart home systems, but by and large, the main one is still the Home Assistant.
This is an integration for managing smart speakers, the control was done both locally and via the cloud from Yandex, and allowed you to turn on music normally and perform various commands on the speaker, that is, in principle, this module was for integration with the speaker for voice control, that is, this skill did not support any additional control systems or sensor control by itself. since these commands were executed by a voice assistant, it was possible to formulate the command in such a way that it simply launched a certain scenario, turned on and off a certain device mode.
The Home Assistant had to go through the move to the python 3 version, for a very long time there was an error due to the fact that previous versions were no longer supported, but the move itself was of course very difficult, integration stopped working, including integration with Yandex stopped working, and after a while, of course, it was fixed and, in principle, it became It was used normally, everything started working fine, and I finally decided that my Home Assistant would be the integration system, but by the way, the Home Assistant itself allows a lot of additional features for integration with other ecosystems, that is, with the same Xiaomi with MiHome and Tuya ecosystem, it allows you to integrate normally with HomeKit as well, you can integrate to connect to Apple devices, that is, in principle, there are quite a lot of features, but still the main opportunity, since I used it specifically for integration with Yandex, I lacked the current capabilities and I tried to do the integration on my own, well, since the interface itself was not closed, there was even a module, then it appeared, which allowed integration with this Yandex smart home skill, but for this it was necessary to deploy locally on the server where the Home Assistant is located, deploy remote access so that Yandex could see this server from the outside, so that an SSL certificate had to be installed on this server, that is, in principle, it was necessary to deploy a full-fledged server for external access from this skill, and then they had to be connected, and after that, everything that was available in the Home Assistant began to flow normally into the Yandex smart home, but in fact not so much was transmitted, of course, I didn't use this mode, because in principle I didn't have an external IP address, and it wasn't very easy to implement it and I didn't want to buy it, so I just went the other way, that I created my own server on the Internet and just made the necessary settings on it that allow the Yandex smart home to connect and everything is there, and the SSL certificate is installed, everything that was needed, and then from this server I already send commands to my internal server, this is done in various ways, but lately I have been using a special type of requests, which allow you not to poll the server constantly, but to expect changes from the server, confirmation of the command, if the command arrives, then it is instantly executed in my smart home system, that is, in principle, I implemented an alternative option on my own, in principle, it all works well.
But in a recent update, another addon appeared that allows you to create your own scripts, first there was an addon that allows you to create your own scripts, that is, you can write a special description of the script directly at the code level in the Home Assistant, make a special description of the script, and this script will be forwarded to Yandex and then through the script you can either run it by voice or it will simply be executed according to triggers, some conditions, that is, the principle of such full-fledged management of the Yandex smart home, that is, it will be possible to configure it remotely, but then I saw that there was another component, it was also like the development of all these technologies that were available for integration by Yandex, but in general, this integration itself is not official, and of course Yandex can block it at any time, but for now it works, and they made a separate component, a separate external server through which We have fully implemented the forwarding of all devices from the Home Assistant to Yandex, but in fact there is a mode that you must first select the devices that will be forwarded, next, Yandex and the Home Assistant communicate with each other and, in principle, information is sent through this server to the Yandex smart home system, these objects immediately appear there, everything works quite quickly, there are no delays, additionally, in addition to simply turning on and off if a device that is switched on from the Home Assistant is switched on, and there are different modes If there is dimming, then this will also be uploaded to the Yandex smart home system, that is, an object with this name will appear there, and accordingly it will also be possible directly either by voice or from the Yandex application, turning these devices on or off, which in principle already gives quite a lot of possibilities, but if, for example, some specific device, then of course it will not be transmitted in such a volume, and even many parameters from devices from the Home Assistant do not appear there either, in the smart home system, I did not even send sensors there, that is it will be possible to check if something has changed, but at the moment when I was setting it up, there was no such possibility, because now the Yandex smart home also allows you to send different sensors, temperature, humidity, opening and closing, motion sensors, and based on these sensors, we can already make different scenarios, that is, use these sensors as triggers, that is, in principle, it is very convenient, and since I also use my own connection system, my own way of connecting to the Yandex smart home, I use it, there are some scenarios that are handled by Yandex, I have a system the smart home just sends a signal to open the door, and then it processes itself.
But the Home Assistant also has some devices, the developers promise that they will also develop and additional different devices will appear, but since, in principle, even on the Yandex side it is not structured, that is, there are some different types of devices, light bulbs, switches, televisions, irons, kettles, robots, vacuum cleaners, washing machines, but all this is just a general name, in fact, you can configure any device with any parameters as needed, for example, you can additionally transfer the temperature parameter from a light bulb, therefore, of course, it will be difficult for developers to unify on the Home Assistant side, manufacturers must first unify their devices and when they are added to the Home Assistant through different integrations, they should already be presented more uniformly there, that is, now, for example, if I connect two different sockets, for example, there even different sockets that are from Tuya, can also it turns out that the parameters will be different in principle, it is clear that the on/off is most likely the same, but the rest of the parameters are no longer even output as standard, because they may have a significant difference, they can be deduced, but additionally, and they are also not transmitted to the Yandex smart home, for example, it will be impossible to look at the energy consumption already on this outlet in the Yandex smart home, or ask the speaker what the energy consumption of such an outlet is.
And another great interesting feature of this addon in the Home Assistant is that you can use it to transfer different cameras that are connected to the Home Assistant, that is, the Home Assistant supports different cameras via Onvif and RTSP stream, that is, you can either start the stream directly or configure it through Onvif so that the camera is also controlled, turns on or off if there are parameters, the camera is rotatable, then it also turns, but Yandex itself may not support this particular camera from this manufacturer, but since the integration goes through an external server from the developers of this addon, it is of course still apparently done with some conversion so that the stream can continue to be transmitted through this service to the Yandex smart home system, and already directly in the Yandex application, you can also open and view this camera, which becomes very convenient and the only thing that is of course sometimes there is a big delay, sometimes, of course, for unknown reasons, it's just that the camera doesn't open and doesn't show.
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.