Some things I don't love:
* A lot of the integrations seem half-baked or to not quite fit the generic Lovelace cards. I think to some extent this is an inherent problem in supporting a lot of devices that have crappy, non-standardized APIs. Example: if I bump up the low temp on my Venstar thermostat on the Home Assistant dashboard, Home Assistant will immediately set it back. If I dig through logs, I see the thermostat complained that in auto mode (heating or cooling as needed), the low set point and the high set point have to be (at least) six degrees apart. When I adjust the thermostat through its own touch screen, the high set point automatically raises to meet that constraint. Home Assistant should do the same. I've been meaning to look into fixing it myself, but there seem to be weird things like this on every integration.
* You need multiple automation rules to do almost anything. I think it's common to want the state of one thing to match another (for example, garage door open => sticky notification on my phone, person in driveway after sunset within last 5 minutes or switch on => driveway light on). You need a rule in their YAML DSL to for the off->on transition and another for the on->off. It'd be nice to set a rule that defines a level rather than an edge and have it internally do the transformation. It'd also be nice to define the actions of a notification's buttons inline, rather than as a separate automation.
* The companion Android app's notifications seem to be flaky. At least, they're sometimes slow. I think they can be delivered out of order and possibly are lossy, which aggravates the problem with not having something that just sets the state reliably. I assume it's pretty hopeless to have it reliably be in the right state if your phone was off when a notification was supposed to be delivered or Home Assistant was down on state transition or the like.
* Some things seem to be only checked at startup, so my house has race conditions after power outages. For example, if Home Assistant starts up more quickly than my Yamaha AV receiver (+ network switch + DHCP server), I can't control my home theater setup until I restart Home Assistant.
The "solution" I found was to poll, and use "choose", and sometimes some helper switches for state, to do what is needed. But, I think at any reasonable level of complexity, you're better off using one of the three python components: the one built into Home Assistant, pyscript, or AppDaemon.
Home Assistant Python: https://www.home-assistant.io/integrations/python_script/ No imports.
pyscript: https://github.com/custom-components/pyscript Full python. Supports Jupyter. Straightforward.
AppDaemon: https://appdaemon.readthedocs.io/en/latest/HASS_TUTORIAL.htm... Full python. A little lower level. Allows the creation of dashboards.
Related, the Matter protocol is on its way. I'm waiting for these devices before I redo my house, or put much more effort into any of this: https://en.wikipedia.org/wiki/Matter_(standard)
[1] https://hacs-pyscript.readthedocs.io/en/stable/tutorial.html
> The project group was launched and introduced by Amazon, Apple, Google, Comcast and the Zigbee Alliance, now Connectivity Standards Alliance (CSA).
I'm having a real hard time believing that anything user-beneficial will come of this, unless you're willing to sell out your smarthome and privacy to big tech.
At this level, the way data is handled is vendor agnostic.
I see Matter as more akin to USB, or indeed, the internet, as the idea is that devices are supposed to be able to communicate via IP, not just by ZigBee.
I'd be inclined to find something with an SNMP counter that counts up either "seconds since boot" or "megabits of traffic passed" or whatever else and have a script that runs shortly after the RPi boots to reboot the Pi if that counter if below some threshold.
Running this from the pi will query the uptime on my router in milliseconds:
snmpwalk -v 2c -On -c public 192.168.2.1 .1.3.6.1.2.1.25.1.1.0
You could have a startup script on the Pi do something like "wait until you get a valid reading of this uptime and if that reading is less than 180000 [3 minutes], then sleep for N minutes [long enough to not double/triple reboot on a power outage] and reboot the RPi (or restart HA)"If HomeAssistant needs to be recycled after every router reboot (not just on a power dump), have that script run in a cron job looking for an uptime less than some threshold and rebooting the Pi.
It might feel inelegant or even "gross", but I look at it as just reliably automating the fix and therefore better than what you're doing manually already.
Looks like that integration is implemented on top of an external library (so you have 3 layers of implementation):
https://github.com/hpeyerl/venstar_colortouch/blob/master/sr...
The HA integration doesn't use it, but the library exposes the spread value.
If you use the docker version it is crippled with no "supervisor" mode.
Also every now and then a light or switch will go greyed out in HA, their official apps still work, and I have to restart HA to be able to use it in HA again. Pretty annoying when you get home after a long day, soaked in rain, fumbling in the dark to turn on lights and now you have to fumble more to restart the damn server before you can use your lights.
It seems fine that this isn't available in docker, since you can do all of this via docker and your host's configuration system. It would be nice to have a GUI for it, but if you need a GUI then you probably aren't running HA via docker, you used their image.
An anecdotal data point, but I've been running the home-assistant container image on k8s without any issue, and I have a lot of integrations.
I'd go as far as to argue the (officially supported!) container release is the best way to get a production quality install of HA - containers are a great way to package and release complex web apps like HA. Mines automatically updates itself every time new container image released, has done so with no intervention from me for over a year. With the container lifecycle/config, you don't really need Supervisor mode either.
To say it is crippled is nonsense, it is literally one of the two officially recommended install paths:
> https://www.home-assistant.io/installation/
Official support for Docker release in HACS:
> https://hacs.xyz/docs/setup/download#home-assistant-containe...
That behaviour kind of makes it hard to trust that it won't lead to the next Marak situation.
That said you have a point but in my usage of Home Assistant almost since birth when it was a single pip install command I can tell you the sheer functionality, integrations, etc make getting it fully running a nightmare. Not to mention from their perspective actually supporting it almost impossible. Maybe this speaks to a wider problem but I'm very happy to install it with docker on the distro and hardware of my choice and have everything more-or-less just work.
I referenced the operating system approach here because it's the quickest and easiest path to get up and running on a Raspberry Pi and therefore relevant to the article.
I even do USB passthrough to give it access to my z-wave stick.
So I just used homebridge for everything, with a smattering of Node-RED for (very few) device shims (it is _very_ easy to do MQTT handling with it).
Also, I now have zero YAML to maintain, which is also a boon.
Kudos, though, for Home Assistant auto-discovery, which I use with my Tasmota-reflashed devices (there is a homebridge plugin that transparently adds them to HomeKit as soon as they're set up).
Once you are there, you can write shared libraries, abstract away whatever you want, have legit tests, and just do anything you would normally want in your coding environment (vscode, auto-formatters, source control, etc). Obviously not the right recommendation for a consumer system, but if you are like me and feel more comfortable with a programming language, it's the way to go.
Interested about the tests though. I’m not a professional python developer but would love automated tests for my appdaemon code. How did you set it up, and how do you run the tests?
It doesn't test that the service calls are correctly written, just that they were made. So, very useful for unit testing syntax / logic, but not a full end-to-end integration test solution. Still, with python being an interpreted language, this is super useful. I don't want to have to wait for it actually to be sunset to determine I have a syntax error in that branch of the code, for example.
I don't actually have the tests running on the HA device. I have them on my desktop where I develop the appdaemon scripts, and then I copy only the scripts over to HA. I'm sure there are multiple ways to do it.
The weather station post in particular with the sensors is here [2]
[1] https://partofthething.com/thoughts/category/electronics-and...
[2] https://partofthething.com/thoughts/weather-and-air-quality-...
https://www.zigbee2mqtt.io/devices/TS0601_air_quality_sensor...
The one caveat in my experience has been trying to run Pi-Hole on the same server as HA Supervised or using Adguard Home. Trying to run HA and PiH, even though they were both in docker containers, caused the Pi 3B+ to freeze every few hours. HA makes it clear running anything else is a bad idea, and that proved correct. I deleted PiH and tried the Adguard Home addon for my DNS for awhile, it was really slick and had a lot of features, but I found myself missing the PiH for several reasons. For one, it really sucked to be tinkering with HA while other people on the network were on the web; every time I needed to restart HA (which was often setting up the cameras), I'd get constant groaning and moaning about the internet being out. I also found it harder to control white/black lists; adding individual sites here and there was not as simple as it is in PiH. It also lacked the simple "disable for X minutes/seconds" feature I used so much.
I ended up installing just PiH on the Pi 3B+ and grabbing a cheap Chromebox off ebay to run HA. All the things I was doing on HA really pushed the Pi at times and I read one too many stories about SD cards dying from heavy use. Now everything is zippy and I feel safer with HA installed on the internal M.2 SSD.
My personal focus would be on cloud-free/self-hosted systems. Looping through the cloud as a convenience is fine but I don't really want to rely on cloudshit 100% for the operation of my house.
Also I've heard really good things about the Lutreon stuff? Not open, and not cheap, but it works, and I've heard the z-wave stuff isn't always 100%.
I have most devices connected to an old wireless router that is completely disconnected from the internet. The raspberry pi is connected to my main network through ethernet and is connected to my “smart network” over wifi. I like to think of the HA instance as a two way mirror since it can reach the internet and see the devices but the devices themselves can’t phone home or access the internet in anyway.
For bulbs, light switches, and smart plugs I generally stick with TP-Link Kasa. The local API works great with HA though I believe they are removing this in future firmware updates [0]. This appears to be for the UK only but I’m not 100% sure on that. I purchased a plug a few months ago that still works.
My thermostat is a Venstar color touch with the local API. I have it connected to the internet but I could disconnect it and everything would still work how I want.
You can flash Wyze v2 cameras with the official RTSP firmware to view them locally. You lose some of the features of the Wyze cams but I think this is a fine trade off. While this works with the Pi, streaming video taxes it a lot. It isn’t a perfect experience by any means.
I also use Zigbee devices instead of Z-Wave (no real reason other than the first device I wanted was Zigbee). I have a Sonoff Zigbee bridge flashed with Tasmota that allows me to use any compliant (or quasi compliant in the case of Xiaomi Aqara) plug, motion sensor, temp sensor, etc across brands. The Zigbee bridge is also has access to the internet because it needs to connect to an NTP server. This means that these devices work fine when the internet goes out but if for some reason the hub gets power cycled while having an internet outage they stop working.
You can get Zigbee antennas that connect directly to the Pi but I avoided this because the USB ports can cause interference. You can fix this by getting a USB cable extender.
Feel free to ask any other questions about my setup.
Since then I started adding in door sensors and my thermostat. I just need to find a way to see how much propane I'm using and I'll be set.
Wow, the future is truly here folks!
Do not buy Gree. Check.
That being said, anything that can be flashed using tuya-convert will be good. But beware, because not all Tuya lightbulbs hava an ESP chip inside and they have patched the exploit tuya-convert uses in newer firmwares. So check your model on google.
/me having a Gree unit that is to be installed
If I recall correctly, the data was encrypted using a static AES key, and I think the unit checked if the data decrypted correctly, but don't quote me on that.
I've really been trying to move away from cloud based stuff not only because of data privacy, but concerns about services going away and (most importantly) latency.
My old wifi smart plugs had 2+ seconds of latency from when I'd hit the button in HA to actually turning on. Zigbee/Z-wave stuff is (from my meatsack perspective) instant. I have a zigbee door sensor on the door to get into my garage, and a zigbee smart plug connected to the overhead florescent lights. By the time the door opens enough for me to actually see inside the garage, the lights are on. Sometimes I think they never turned off. It's fantastic.
https://www.ui.com/unifi/unifi-ap-ac-pro/ for the wired AP, https://store.ui.com/products/uap-beaconhd for the extension into the back of the house. Pricy, but not completely outrageous IMO.
For an actual router, I run OPNsense in a VM (on the same box as HA, funnily enough). My server has dual 10 gig ports, so I pass through one of them to OPNsense and run it as a "router on a stick", where the basic internal network is the untagged VLAN, and the public side is VLAN 99. My switch then strips the VLAN 99 tag from the packet before sending it to the cable modem, and vice-versa. My switch is https://mikrotik.com/product/crs328_24p_4s_rm, which was $379 in 2018. However, you can get similar functionality from MUCH cheaper microtik or unifi/ubiquity switches if you don't need 10 gig support.
If you're starting from scratch I might get something like https://store.ui.com/collections/unifi-network-unifi-os-cons..., and an el cheapo dumb switch, as long as it'd pass through vlan tagged traffic. You want anything that's crossing a vlan boundary to end up on the router anyway, so you can apply firewall rules to it.
Security risk? Not in the slightest. I'm running an up to date proxmox which is just KVM+QEMU with some scripting and a website on top, basically. I know how to setup IOMMU groups and such. If it's good enough for the big cloud providers, it's good enough for me.
> Wireless Uplink functionality enables wireless connectivity between APs for extended range. One wired UniFi AP uplink supports up to four wireless downlinks on a single operating band, allowing wireless adoption of devices in their default state and real-time changes to network topology. For devices that support Plug & Play Mesh, this functionality is extended to allow multi-hop wireless uplink – so wirelessly uplinked APs can support uplink to other wirelessly uplinked APs.
(quote is from the datasheet PDF)
The least-involved way to set this up would be to set up an old wifi router to create a second network, don't connect this router to your existing network or uplink, and then set up your home automation server with two ethernet ports.
[0] eg TP-Link Kasa, although I heard this may have changed for recent ones? Either way, with this setup you'll be immediately aware of whether local control functionality works, so you're well within the return window. FWIW I stay away from Amazon's GENSYM brands, even though they'd be easy to flash with Tasmota etc, because I don't trust them to get line voltage design considerations right and I don't feel like QAing every single device.
Don't forget to set up a reverse proxy with ssl and automatic cert renewsl, even in your home network. Wifi can be hacked with trivial ease. Caddy or nginx/certbot will do you well there. If you also run a pi-hole you can have the pi on your local network pass ssl checks by overriding some DNS entries.
It's extremely inconvenient to have IoT devices segregated from, say, TVs and media devices, especially if you rely on AirPlay or Chromecast to get audio around the place, so I just secure my Macs (and PCs) properly as if we were still traveling and visiting clients.
I keep tabs on Apple security bulletins (HomeKit has relatively few issues, and works mostly inside the LAN except if you're outside the house - it then switches to a variation of the old iCloud "back to my X" tunneling).
A second option is finding devices that can be flashed with Tasmota or ESPHome. This could also mean putting together your own devices with an ESP8266, ESPHome is basically plug and play for simple things like temperature sensors. You assemble the device, configure which pins to use via YAML, and then flash it to the ESP.
You don't even need to download a local build toolchain, the ESPHome add-on to Home Assistant can flash devices plugged into your computer just from the web interface, and then do OTA firmware updates.
I also don't use Wifi for any of these devices anymore. It's usually a bad experience. Either use ethernet or a dedicated IoT-oriented wireless protocol. Z-wave seems OK but not very flexible, Zigbee is a pain in the rear (but the only option for many device classes), and I'm hopeful that Thread will actually be good.
I am sadden that wifi seems to be taking over and ZigBee and Zwave are starting to lose favor.
But, I think it's actually because wifi is easier for the average person to get working. With Zigbee, you need a Zigbee hub, but sometimes you need a brand specific Zigbee hub, sometimes you don't (even though it's advertised that you do), and sometimes the Zigbee compliance is so bad that adding a device from another vendor break your whole Zigbee network (looking at you Aquara). Zwave throws more incompatible hubs to the mix. And, even within these, it's rare to have devices work with each other in a way that makes sense.
Hopefully matter saves us, so I don't have to install 5 integrations in Home Assistant to remind me that my car isn't plugged in at night or my back window is open, while the heater is on, and then another to make any of it accessible to HomeKit.
I have several vendors of both Zwave and Zigbee Sensors, HVAC thermostat, Bulbs, Switches, etc.. All of them play nice with each other, and FAR FAR simpler to setup than WiFi which often requires the use of some weird mobile app, and play hopsotch with the networks..
Zigbee I just pair them to the GoControl and it is done
hell I even bought some no name used Door Sensors off ebay that were Zigbee, I mainly use them for Temp monitoring in various places.. They had no problem connecting to my network either
> all running Transmitting to Nortek GoControl USB stick attached to a rPI running Home Assistant
> and FAR FAR simpler to setup than WiFi
These two sentences are absolutely silly, for that average consumer. An average consumer can install a proprietary app in a few minutes and is totally uninterested in installing operating systems on little computers.
That was also very easy out of the box, far easier than WiFi Device
I am not sure why you are doubling down on WiFi being easier, it is not
The reason these companies are going for WiFi is because they want to Lock People into continue Telemetry being sent to the cloud, not local hubs.
It has nothing to do with ease of access, or consumer friendly and everything to do with Lock in, and Privacy violating data collection
No offense, but I think you've already proved that your perspective is a bit skewed towards the technical. I don't understand how buying and installing a hub, then installing an app to connect with that hub, and then using that app to pair is somehow easier than installing and app, and then using that app to pair.
> It has nothing to do with ease of access...
Looking at Amazon, I'm seeing many times the reviews for WiFi smart switches. This would make it appear that people are purchasing them. Why? Are they already locked in? My theory is that people see the product description, see WiFi, and say "I have that!". People see Zigbee or "hub" and say "I don't have that, it's $50 more!". If we could do a word count for "incompatible" between the two, I'm sure it would be many times lower for WiFi devices. I know I see that word often when I look through Z-Wave and Zigbee reviews.
If you try Home Assistant again, you'll probably like Home Assistant Core. No separate OS or container needed, just a Python virtual environment. That's how I have it installed. I have to do the updates and backups manually (rather than it self-updating automatically / through the UI) but I find that preferable to dealing with an extra machine, VM, or container.
Also, plugging in a half-decent zigbee controller usb dongle and receive native zigbee controls in the system, no need for a bridge like mqtt
My heuristic since then has been to minimize the amount of node.js in my home automation codebase and this has worked wonders for its reliability and usability; currently the only component I still have that's node-based is zigbee2mqtt, which (possibly not) incidentally gives me more issues than any other component.
The best approach I've found has been to have (in isolated jails/containers) zigbee2mqtt dealing with zigbee network stuff (you must use CC2652 based coordinators and routers for any kind of reliability), mosquitto acting as an MQTT broker, and a custom program (write it in whatever you like) talking to mosquitto, with Pushover for push notifications.
One of HA's selling points for me originally was that everything was written in Python. It's frustrating that I am now faced with pulling a javascript service into the mix. Most of my devices are z-wave and I'm still running on the legacy integration and dreading this migration.
I would vastly prefer all of this crap to be written in Rust or Haskell or OCaml or anything oriented towards correctness. It's relatively very important that the code which runs your home works correctly.
Here is an example of an automation script, turning a zigbee plug on/off depending on solar roof output: https://gist.githubusercontent.com/bonzini/c705bdd47fd5cd16a...
Is this about right? Is it possible to combine Home Assistant and node-red, or has Home Assistant outgrown the need for something like node-red?
https://flows.nodered.org/node/node-red-contrib-home-assista...
But then this is about Node-Red integrated into HA.
I have zero YAML to maintain, and I'm happier for it.
If you mean how they compare when you plug in node-red to HA and use it for automations, rather than use HA's "native" automations... I believe the consensus is that node-red is more user-friendly in that way, and because it can plug to other things on its own it can provide more flexibility. On the other hand, HA has recently worked on the UI of their automations, and it is already pretty good for simple flows. In the end both of these approaches are great, each with its own pros and cons.
I found this much more powerful than the base GUI, and much more expressive (and less clunky) than Nodered or the yaml automations.
In terms of disk, you want multiple disks as either raid/zfs/btrfs/lvm. It will probably be better to do this on a separate machine and mount it via nfs.
For your boot volume, you can also use a usb thumb drive to help avoid sd card fatigue.
In the future I'll consider the mini-PC, thanks. This will have to do for now.
It expresses everything from every integration as an entity in various device classes so as long as some random tech is supported by an integration you can group them seamlessly. For example - I have Z-wave based motion detectors but I can control Hue lights and Wemo switches for motion detection - but only if I'm home as reported by the zone feature in their iOS companion application.
Their supervisor/docker based install for Raspberry Pi is pretty slick[4]. Write an image to disk as you usually would and you get a bare-bones OS with Home Assistant running in docker. Then there are additional docker-based add-ons you can install for stuff like MQTT, Z-Wave, Let's Encrypt, SSH access, nginx, and more. All managed in the web ui. Pretty cool.
[1] https://www.home-assistant.io/
[2] https://www.home-assistant.io/integrations/
[3] https://hacs.xyz/
[4] https://www.home-assistant.io/installation/raspberrypi