Adding a Current Month Numeric Sensor to Home Assistant

I have a number of Christmas light strands in various windows around my house. These get turned on once a year when we remember they exist and its around Christmas time. I decided that these would be a good use for home assistant to add some Christmas lighting during November and December.

To do this, I wanted an automation that would turn on the lights during specific months, and not during others. Thus I needed the current month available as a condition for my automation. I quickly found out that Home Assistant does not have this type of data built in, but can have it added relatively easily. I didn’t know how most of this was supposed to go together, so after a little bit of guess and check, here is what I ended up with.

Continue reading “Adding a Current Month Numeric Sensor to Home Assistant”

Automated Stairway Night Lights

I wanted a simple but useful project as my first bit of home automation after getting some CloudFree smart plugs. We have fairy (christmas) lights on our banisters going upstairs that we plug in whenever we want to use them, so why not set them up on the smart plugs and setup an automation to turn them on at night, and turn them off around when we should be going to bed. This seemed like a simple enough project for a first shot at it, and something that we would use.

Goal

  • Stairway lights turn on before sundown
  • Stairway lights turn off around bedtime on weekdays
  • Stairway lights turn off slightly later on weekends
Continue reading “Automated Stairway Night Lights”

CloudFree Tasmota Smart Plug Setup

I’ve wanted to mess about with the whole home automation craze that seems to be going on, but on a fully self-hosted installation (no alexa, no google assistant, my data staying all on my network). After the SelfHosted Podcast mentioned the CloudFree smart plugs, I knew they were the right gear to try out. The smart plugs come from CloudFree which has the plugs pre-flashed with Tasmota.

The quick start guide worked perfectly for the initial setup and getting the smart plugs on my WiFi network. I’ll have that guide below (in case its lost) and continue on with my own instructions for connecting to Home Assistant via MQTT afterwards.

Continue reading “CloudFree Tasmota Smart Plug Setup”

Home Assistant Supervised

I was originally running a home assistant VM using a script that loaded HASS into proxmox, however the HASS.io image didn’t have the tooling that I like having on a machine for general management of the system. I started researching and took a few turns around to find the right installation script, but I did and included the commands below. The following shell commands and script install Home Assistant Supervised on a general X86 machine. This worked fine on Ubuntu 18.04 LTS.

sudo su
apt-get install -y software-properties-common apparmor-utils apt-transport-https avahi-daemon ca-certificates curl dbus jq network-manager socat

systemctl disable ModemManager
systemctl stop ModemManager

curl -fsSL get.docker.com | sh

curl -sL "https://raw.githubusercontent.com/Kanga-Who/home-assistant/master/supervised-installer.sh" | bash -s -- -m qemux86-64

The default port for HASS is 8123, so go to the server IP:8123 to finish configuration. This will give you all the benefits of the HASSio images for raspberry pi and intel nucs but with your own preferred operating system rather than using the build thats included with the home assistant built images (which are very limited).