Home Automation Ramblings Part 1 - My Setup

avatar
(Edited)

After seeing @emrebeyler write a post about his home automation stuff, I figured it was time for me to pull my finger out and finally get round to writing something down about my own setup. It's something I've been wanting to do for a while but I have not been able to work out a good way to present all the information in a post that wouldn't end up being a massive tome with too much information in it. I think I'll start with an overview of what I have so far and then do some more posts on the finer details in the future.

image.png

Not my family details - this is the generic Home Assistant image

The underlying technology I use for linking all my stuff up is Home Assistant. Their tagline is

Open source home automation that puts local control and privacy first. Powered by a worldwide community of tinkerers and DIY enthusiasts. Perfect to run on a Raspberry Pi or a local server.

That's pretty much all you would want from something like this if you want to get into the low-level guts of setting up some home automation. I think that if you are a bit less technically minded, you might want to look at some of the all in one hubs like the ZWave or Homekit systems and use their packaged tools and interfaces. Home Assistant can easily integrate into these systems however and gives much more control, so if you wanted to get more involved once you have these kits - no problemo.

Examples of what I've done

So far I have a few things set up, mainly to test out the platform in preparation for a house extension I am having done this year (hopefully). These include..

  • Front room light that turns on 15 minutes before sunset and turns off one minute after the TV turns off (as long as it's after 21:30). Can use the Home Assistant UI to control this lamp independently too.
  • Outdoor lighting by my front door that I can control using Alexa ("turn on/off the front door lights") or the Home Assistant UI. They also turn off after 5 minutes automatically. I have also previously had these hooked into some cameras that detect motion but that needs more tweaking as it was getting triggered by spiders building webs on the outdoor camera.
  • Geofencing of family members - I can tell when there is someone in the house or if the house is empty. I have also geofenced my work and various places on my commute so that my wife knows I arrive safely or leave certain places (as I use trains and cycle)
  • Security camera - I have a security camera outdoors that records motion and sends a message to Home Assistant, alerting me to any motion on my front driveway. I use an app called MotionEye to handle the motion detection.
  • Phone finder - I can shout at Alexa and she will message my phone even when it is on silent mode.

Technical details

I'll give you a brief overview of what I have set up from a technical point of view and will go into more details in other posts on some of these things

image.png

Node Red UI

  • Home Assistant is running on a Raspberry Pi 4 with 4G mem and 32G SD using a dockerized container. I manage this container and a few others using docker-compose
  • I have a couple of other docker containers running on the pi - Portainer for managing the containers in an easy UI, and Node Red which is a super cool tool for managing automation workflows (in addition to the workflow language that you get in Home Assistant)
  • The whole system sits behind a duckdns dynamic IP manager so that I can connect into it from anywhere, certificate management for https is handled by a free LetsEncrypt cert. You need this for the Amazon Alexa integration to work as well. Home Assistant has 2FA to help protect against anyone hacking in... cos turning my lights off is the end goal of any hacker :)
  • I backup my config nightly to a Backblaze B2 bucket
  • The switches that I use are Sonoff basic switches that I have flashed with Tasmota firmware which gives you full control of the switches using MQTT. This allows me to send messages to them from Home Assistant to get their status as well as change it (ie, turn them on and off).
  • Outside I have a couple of Reolink RLC-410 cameras which are great value, have really good night vision and integrate well with MotionEye
  • My Motion Eye instance runs on an Ubuntu 18 server (as it's too processor-intensive for the RPI to handle). This has motion detection hooks that call Home Assistant endpoint to notify it of motion. Home Assistant then in-turn sends a message to my phone and/or the television/Alexa etc.

So that's a quick overview of what I've done so far and how I'm doing it. I think in my next post on HA, i'll go into how I have set up some of my basic automations such as my front room light control using Home Assistant YAML as well as Node Red.

Thanks for reading (if you got this far)

Mark



0
0
0.000
12 comments
avatar

The switches that I use are Sonoff basic switches that I have flashed with Tasmota firmware which gives you full control of the switches using MQTT.

Even your switches are running free softare! Awesome.

I've dabbled in smart home with Phillips Hue lights, Google Nest Wifi, and Wifi air conditioners (which I hesitate to call smart). But having control and privacy as provided by open source community maintained software would really increase my appetite for a "smart home".

Is it still at the stage where configuring home assistant takes a considerable amount of effort?

0
0
0.000
avatar

I would say that if you wanted to use HassOS and Node-red for your automations, its pretty easy once you get over the initial learning curve. There's a great community and loads of documentation on it all. The hardest thing for me was setting up all the software as I wanted it on the PI and getting the video stuff working. Basic automations are dead easy.

0
0
0.000
avatar
(Edited)

Will put this on my todo list of digital home improvements! Probably will take a back seat to setting up a home Bitcoin node in a box.

0
0
0.000
avatar

Thanks for sharing your creative and inspirational post on HIVE!



This post got curated by our fellow curator @tibfox and you received a 100% upvote from our non-profit curation service!

Join the official DIYHub community on HIVE and show us more of your amazing work!

0
0
0.000
avatar

I am very new to this but do I have to buy a smart lamp so this whole thing works?

0
0
0.000
avatar

Either a smart bulb (which can be switched on or off), or a smart switch and a normal bulb (so the smart switch replaces your normal switch)

0
0
0.000
avatar

Thanks ! I am googling that now. I found tutorials with arduino, relay board and jumper wires while I am really on a budget :')

0
0
0.000
avatar

To be honest, if you just want to control a light, a Sonoff Basic will be by far your cheapest option. You don't have to update the firmware if you don't want to - you can use other software to control them

0
0
0.000
avatar

Thanks a lot for your time, checking that out !

0
0
0.000
avatar

Owww WOW, that seems as complicated as one of my friends showed me what he did in his house. He uses a RASP as well, has different lamp technologies in his house which he all can control. Although I have most of my lights on remote control for almost two decades (initially using something from IKEA and later from the Dutch company 'klikaan klikuit' with all sort of buildin switches and dimmer switches, I thought a few years ago it was time to modernise everything. But as my friends was showing, I read similar complexity involved from your post. Guess it'll be one of those things that will have a low prio. It works what have; I even have the ability to auto control my lights through a programmable remote control.

For lesser DIY project, what would you recommend at this stage regarding mainly light and electronic switching/dimming? Something that is modular enough it can be part of a future (maybe more DIY) setup?

0
0
0.000
avatar

The thing you will probably find is that anything that is less technical to use is going to be more expensive as they have to build the clever stuff in. I think for futureproofing you can't help but look at the Philips hue stuff for lighting. It can all work with their integrated stuff (and probably IFTTT i imagine, although i havent looked). If you have the Hue bridge it will integrate with home assistant. The only problem is the price of course, but it's good stuff. You get what you pay for

https://www.home-assistant.io/integrations/hue/

The IKEA stuff also integrates with Home Assistant, as does your Kaku stuff (as it's just on radio frequencies I believe - you can just get an RF transceiver plugged into your system to control them )

Don't be put off by how complicated this seems. There is no reason why you couldn't get a single Philips hue light and a bridge, use that as it is packaged and then tinker around with Home Assistant on your Windows/Mac/Linux box. I guess it depends how much you like tinkering.

0
0
0.000
avatar
(Edited)

I used to tinker quite a bit, but that is something like 25 years ago :)
Totally out of being an engineer, so I'll need to dig deep.
I may ask my friend to set things up; Maybe a likes to do so; Maybe not; Will see.
Philips Hue: good suggestion, I know my friend also has HUE integrated, also uses some compute board he got from China and attached all sort of other things incl camera, and a bunch of sensors.

0
0
0.000