Using Home Assistant with Mycroft AI For Home Automation
In today’s blog post we are going to discuss 2 open source projects Mycroft AI and Home Assistant and how you can use them to automate your home via voice cheaply and without having to run anything really outside your network.
Mycroft AI is a open source voice personal assistant based on python. They have their own hardware called a mark 1 which is open hardware as well as the options to set it up on a Raspberry Pi or Linux. You can think of it like a open source Alexa basically that you can create your own skills for and know what it is doing and when it is listening.
Home Assistant is a open source home automation platform that also can run on a Raspberry Pi, Linux, Docker and Windows. It uses YAML configuration files to build out automation rules and connect your IoT devices like Hue Lights, Ring Doorbells, Alarm Systems, Cameras, and more.
Mycroft AI Installation/Information
This little guy to the right here is called a Mark 1 device. You can still order these from Here.
The instructions for installing Mycroft AI can be found at https://mycroft.ai/documentation/getting-mycroft/ and goes over all the different installation options.
If you already have a Raspberry Pi please consider the Picroft option as it wouldn’t cost you anything extra to set it up as long as you had a microphone and speakers.
Mycroft utilizes intents and vocab words to trigger certain custom written Python code AKA a skill that then can literally do anything, contact API’s, translate languages, the sky really is the limit since it is all open.
Also they have a new Mark 2 coming out with a screen that you can find more information as well as how to order it Here. You can see a image of it to the right of this text.
Home Assistant Info/Installation
Home Assistant as mentioned in the introduction is used to automate Internet Of Thing(IoT) devices like smart lights, alarm systems, nest, etc.
It can be installed on various different systems including Raspberry Pi, Docker, Linux and more. I would recommend if you are brand new to Home Assistant to follow the instructions Here to setup Hass IO which is a lot more user friendly.
Home Assistant calls the connectors for each device like Hue, Nest, etc components. Currently there are 1024 Components in Home Assistant. Some of the more popular ones are Hue, Nest, Device Tracking, Kodi and more.
Piecing It Together
So utilizing a Mycroft AI skill called mycroft-homeassistant that myself and a few others have contributed to you are able to voice activate Home Assistant entities like lights, switches, get sensor states via the API.
So now you can via Mycroft have custom wake words so “Hey Jarvis, turn on the kitchen light” would find the light that closest matches kitchen light using Fuzzy matching and then turns it on.
You could also do things like “Where is my wife” via the sensors option, “Open the garage” by using the covers toggle. I will be adding more to this skill over time and will add a lot more functionality to it.
It is easy to get started just head over to the Mycroft AI documentation to get started setting up your own personal assistant. After you have Mycroft setup then you can use mycroft-homeassistant to interact with your Home Assistant installation.
Don’t forget to also subscribe to my mailer below and keep looking for new posts regarding Home Assistant as well as Mycroft AI tutorials and overall use of the products in upcoming posts.