Getting Started with Home Assistant 2021 - All you need is a Raspberry Pi

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
in the first video of a getting started series today i'm going to show you how easy it is to set up home assistant with just a raspberry pi well a raspberry pi a power cord an sd card but you get it today we're finally doing the long promise getting started with home assistant series in today's video i'm going to show you how easy it is to set up home assistant with a raspberry pi i'm going to try to make this video as beginner friendly as possible i'm going to take you through each individual step and show you how to do them in detail so if you do run into a problem feel free to leave a comment or find me on social media today we're going to install home assistant on a raspberry pi 4. we're also going to go ahead and get it configured and then i'm going to show you how to install and configure some essential add-ons that are going to help you in the world of home assistant so i've been using home assistant for about four years now i started with it running on my linux server in a virtual environment and then decided to split it off and run it on a raspberry pi because the raspberry pi version had a built-in store that was able to easily install add-ons so i decided to move it to that separate device it also gives me some redundancy just in case my server goes down and i still want to be able to maintain my lights and other systems in the house so i started with home assistant on a raspberry pi 3b and then moved up to the four recently i went from the one gigabyte version to start with then i had a four gigabyte version which is the one i have here and then just recently moved up to an eight gigabyte version running inside of a fan cooled case just to give myself maximum performance so what is home assistant home assistant is an open source application that runs on top of linux it's not only a hub that can run something like zigbee or z-wave sticks in it it also acts as a central point to bring all your various devices together regardless of what technology it uses so you have a philips hue bridge and some bulbs connected to that bridge and you want to trigger that light with a xiaomi motion sensor well out of the box you can't do that but home assistant can very easily tie those systems together and allow you to run different various automations on them it's also a great single point to allow you to go in and view all the statuses of your various devices so what else can home assistant do well in my environment my home assistant ties together my zigbee z-wave xiaomi wemo wi-fi devices sprinkler systems myq garage door openers philips hue bulbs and a variety of other cloud-based services into one system so that i can quickly and easily make changes and also control them from anywhere in the world i can use applications that run on both android and on my ipad to feed data back into home assistant to make changes with it so for example on my android device i use tasker to feed different scenarios to home assistant so i can make a decision so for example if i put my phone on the wireless charger next to my bed after 9 pm it assumes i'm going to sleep turns off all the lights downstairs and activates my alarm for the next day it also turns on the sleep tracking device that i have and sets the alarm in the house so it's an extremely powerful but also easy to use application now looking at the home assistant home page you can see the variety of devices that are available to integrate with home assistant basically anything that has an open api or is a it's a very popular service has been tied into home assistant in one way or another now running home system does not require a raspberry pi you can actually run it in windows you can run it on a linux server you can also run it on a hypervisor like vmware hyper-v or proxmox but the reason that i recommend people start with the with the raspberry pi is because of how simple and easy it is to set up you basically just write to this sd card using an easy to use application pop it in and you're ready to go all right so what do you need to get started it's very simple the most basic thing you're going to need is a raspberry pi 4. this is like i said the four gigabyte version uh but you don't need that you can start with something like the one gig version if you're just getting started but as you expand your network you'll probably want to step up to a larger one optionally you need a case to hold the raspberry pi this is just the basic raspberry pi case you just need something really to hold it keeping dust and other things to fall from falling inside of it importantly you're going to need the right power supply now this is the official raspberry pi 4 power supply that you can get from amazon or wherever i recommend starting with it because it outputs enough power to run the raspberry pi efficiently and also accessories attached to it so on mine i have a solid state drive and a z-stick which it can run that without any problem and no other external power supply is necessary you also need a micro sd card i recommend starting with a 64 gig one you can really get away with anything above 32 gigs but 64 gigs gives you some expansion room for your database and allows you to install more add-ons as we go along and now it is possible to run home assistant off of a solid state drive and i actually have a video coming up so once that's up you'll see it up here in the corner but they'll be coming here next week on how to set up a solid state drive which is actually quite easy it gives you a lot of long-term capability with your home assistant instance and finally you'll need a usb or in this case a usbc card reader this is a nice one from anker it's teeny tiny my laptop has only usb c ports on it so this is great for a macbook if you have one as well and it reads both sd and micro sd cards um all links to all these are in the description below and i also have a kit.co kit available that you can click on that will take you to show you a quick getting started with some links to amazon now let's move on to flashing the sd card alright so now we're actually getting started setting up the sd card so first thing you want to do is go ahead and take the sd card and put it in your reader and attach that to your to your machine make sure you can read it and access it if you have flashed this with with linux before don't worry the application i'm going to show you will will know that and go ahead and overwrite everything on the drive so you don't have to worry about what format the drive is in already uh the application will take care of it for you now that we've confirmed that the sd card has been mounted to the machine let's go ahead and download the utility that we're going to use to flash the sd card so i like to use this application called etcher to flash all of my sd cards with uh it's free and open source and pretty fast and i found really never having any issues with never having any issues with flashing using this application so uh you can obviously download it for other versions if this is a mac or linux box you can go and download it the version you need for those um but i'm gonna go ahead and download the version for windows i actually already have it installed on my machine so i'll go ahead and bring it up and then while that's opening we'll go ahead and head over to all right so let's go ahead and um now that we've got etcher installed and ready to go let's go ahead and head over to the home assistant website and download the latest installer for home assistant so you can use the url below it's a shortened version of the bigger url or just go out and search for the hassio installation now the url here still refers to it as has io probably because home assistant was already taken on their website so just be aware that hacio is the home assistant installer that will run on on the reserve by so um they still have the older version out there for model uh pi 3 b and b plus both 64 and 32 bit um but it's advisable obviously now if you're to go ahead and run this on a raspberry pi 4. so you'll notice there's a 32-bit and a 64-bit version it used to be that the 32-bit was the advised version of for home assistant for the raspberry pi 4 but now they just they say that the 64-bit is just as compatible so i'd recommend downloading 64-bit that way if you do upgrade to the 8 gigabyte model you won't have to reflash your sd card you can just pop it over into the new compute the new raspberry pi and go ahead and keep using it so um go ahead and click on the 64-bit version and it'll go ahead it'll download the haso s raspi 64 5.10 and that's actually from the current version obviously if you're doing this later on you'll see a higher version number but we'll go ahead and download that and once that's finished downloading which it is uh we'll go ahead and bring up etcher and etcher is very simple all you have to do is click select image and find the image in your download folder and then select the drive that you want to flash so in this case it's this 32 gig sd card obviously i have more than one device here so make sure that you're selecting the proper device you do not want to select the wrong device and wipe it and erase all the data on there so in this case i am using a 32 gig drive just because it's what i had laying around i again would recommend 64 gigs or above so go ahead and hit continue once you select the drive and then we'll click flash and it's going to pop up a and on windows it'll pop up an administrator console to say yes to and once that's done you'll want to go ahead and remove the card from the reader place it into raspberry pi and then plug the pi into a network drop and apply power to get started now it's not required but if you'd like to watch the progress you can connect your raspberry pi to an hdmi monitor and watch as it sets itself up the raspberry pi should reboot at least one time during the process you'll need to wait about 10 to 20 minutes for the system to install itself on the raspberry pi you can go ahead and go to the address below homeassistant.localcolon8123 the link is in the description if the raspberry pi is not ready you'll see a notification saying please wait this could take up to 20 minutes but after refreshing a few times you should see the onboarding screen for home assistant and then here's where you'll define the name you want to use for the account the username for it and a secure password especially if you're going to be exposing this to the outside world you want to make sure you use a nice secure password then press create account all right and now you are in the home assistant home setup in this screen you want to give your home a name and you also want to define its location for things like sun up and sun down and other weather related items so first thing you want to do is go ahead and set your time zone that you're in and also your elevation also there is a detect function that can help you find your location data and then finally you want to go ahead and set your units whether they're imperial or metric then finally press the next button now home assistant will show you any devices that it automatically discovers on your network which you can select and modify here you can also click the more button to manually add an integration you can see from this list the available integrations that are built into home assistant click the finish button to finish the home assistant setup you will now be taken into the main ui so now you will see the defaults home screen and any devices that were auto detected as part of the setup process you'll also see the default weather card showing the location that you selected during the setup you are now free to finish setting up your home assistant instance so now that we have the basics done you can feel free to go off and customize your home assistant instance as you pleased however i'll show you a couple of recommended add-ons that i suggest installing day one to make sure that you make your life as easy as possible so if we move over to the supervisor tab down here this will bring up the back end for hass io or home assistant and show you any of the installed add-ins which of course a factory blank one will not have any add-ins installed but you can jump over here to the add-on store and install some official and community add-ons that are super helpful there'll be three of them from the official add-ons list and i also have a link to a video that i've previously recorded about an unofficial add-on that helps you back up your home assistant instance into google drive i recommend installing the duck dns add-on the let's encrypt add-on and the samba share add-on now these first two can be skipped if you're going to go ahead and use the navocasa edition because you don't need to open up any ports you don't need to go through any of those steps but you can so you can skip these first two if you are going to go ahead and set up the cloud using nabokasa so the duck dns add-on will allow you to set up a instance with a duck dns service you don't actually need this to set up duck dns but this helps make the install quicker and allows you to update your dynamic dns if you don't pay for a static address on your broadband so go and click install and it will go ahead and finish the installation and then the key elements on all home assistant add-ons is you can choose to either start them on boot or start the add-on if it crashes in addition some of them have a capability updating the add-on automatically so before we can start this as you can see i click start and it says fail to start add-on configuration validation failed so we need to jump over to the configuration which is here what this needs is it needs the token that's generated by the duck dns setup so we'll go and open up a new tab and go to duckdns.org and you're going to need to sign in with something like github twitter reddit google or persona you need one of these accounts to sign up with your duck dns so we'll just skip through the sign-in process here and we're zooming the other end all right now that i've signed in with my twitter account i can go ahead and set up a domain now with the free account you can get up to five sub domains that you use for different things okay so i've created this test house domain so once i get everything configured properly i can go to thistesthouse.ductdns.org and it will automatically redirect me to my instance it's going to detect your current ip based on how you're logged in so if you're doing this from a different location or if you're using a vpn you'll need to update this with your current ip address the token is the key here so this token number that you'll see right here is what we need to grab for home assistant so go ahead and grab that click back over to your home system instance and replace this null token so the token is just the first part that you need here so paste that in the second part we need is the domains you see where it says domains null so we'll replace that with this testhouse.duckdns.org and so that will replace this course with the name of your domain and click save now we can kick back over here and click start and duct dns will automatically update so if there is an instance where your ip address changes in the background it'll automatically update that for you so if you go out to the web and ping that domain it'll resolve to your ip address so now we'll go ahead and jump back to the dashboard you'll see the duck dns add-on is is installed and running so next we'll go to the add-on store again and we're going to install the let's encrypt add-on so go ahead and install the let's encrypt add-on and let's encrypt this is necessary to create that ssl certificate for a lot of items like the google assistant to function also makes your instance a lot more secure so click on the documentation so you'll have to go through a few steps here which i can't replicate because i already have an instance set up but you'll need to go ahead and the first thing you're going to have to do and we'll kind of cover this in the next section which is you'll need to go ahead and go to ford port 80 on your firewall to your home assistant instance which you can find that by bringing up a command prompt and pinging io.local and that should resolve that with the ip address of your instance so you can go to your firewall configuration which i won't show you here but if you go google your firewall maker port forwarding you can figure out how to do that so go ahead and forward port 80 in to your home assistant instance and then you'll be able to complete the setup as part of let's encrypt all right now that i have the port forwarded on my firewall which i did in the background we'll go over to configuration and you need to fill out the information in here so email would be your email address whatever you want to be using here the domain so this is going to be your duck dns so i fill out my email address i had to fill out the domain that i'm using from duckdns and then the challenge i'm doing is http as you saw in the documentation you can choose either http or dns so in my instance i'm going to go ahead and just do http click save now click back over to info and start that now it's going to reach out to the let's encrypt service and request a set of 90-day ssl certificates that are compatible with most major browsers so that way you'll be able to go ahead and go in and say hey take me to https this test house testhouse.tns.org and be able to go and forward it in so now that that's been set up and configured let's move on to the third add-on i recommend all right so now for the last step we'll go ahead and install the samba add-on now this allows you to access home assistance file system from your windows machine or you can also access it from a linux machine as well but samba cifs is most commonly used in windows so this is a super handy one to have you want to make modifications to your config.yml from a local machine or if you need to upload custom configuration components this is the easiest way to do it all right so to get started all we have to do is click on the sama share add-on it's part of the default package so it's already there and then click install it also takes just a minute and once it's installed the first thing you need to do is pop over to the configuration tab and define your username and password so by default it uses the username home assistant and the password of null so it would just be home assistant enter but i like to put in a password here just to make sure now another thing you need to pay attention to is to make sure that your host ip address range is on this list mine is 192.168.1 or my vpn is five so this is perfectly fine for me but we want to make sure that those are available so that way we can you can actually lock out so i can go ahead and remove these two because i will never have to access it from any of those ip ranges so again this is a class b so this would be anything 192.168.0.1 to 192.168.254.254. so everything looks good this will go and click save and start the add-on so click back over the info tab and click start um now with most of these add-ons you need to wait a minute before it actually comes online and you can actually utilize it so you can click over the log tab and you can scroll down and see if everything is good so yeah right here so it says it is the daemon started and it's ready to serve connections so let's go ahead and test that real quick i'm going to bring up a windows explorer window and you'll just want to go to the same ip address that you went up here with and in this case we will just enter home assistance now since this this computer i'm working on is actually a domain machine it will assume the domain here so i need to change the domain to the local scope of the server itself and then it's home assistance home assistant that's not something you're going to need to do unless your machine is already registered to a domain and there we go now i can click in and i can edit my configuration.yaml right from here or any other files if i want to drop a custom component in or add some items that i want to be able to be accessible from the web interface i can do that all from right here well there you go that's all the add-ons i'm going to show you today hopefully now you have a setup that you can customize to your liking all right so there you go now you have a fully functional and ready to go setup of home assistant you can now port forward from your router and allow external access to your instance if you don't want to go through that and you want to skip that section of it you can also sign up for the navocasa account which is just five bucks a month i'm not sure i'm just sorry it's equivalent in other countries and that allows you to have external access to home assistant through their server instead of using yours so you don't have to worry about port forwarding it also allows for external web hooks which is really nice if you're going to run another application to push changes to your home assistant which i'll show you some of that in future videos in addition it has kind of one click set up for both google assistant integration and with alexa integration so one of the ones that i really use is i've got a couple of lg tvs that are not directly supported by google assistant and so i have it set up to use the lg integration and then i use the google connection in nabokasa to do voice commands like turning on and off and pausing my lg tvs now i hope you found this video helpful uh if you did please make sure you subscribe to the channel i've got a lot of new content coming up in the next few weeks i've set myself a goal uh to get some more videos edited and out this month some more home assistant videos coming out along with some integration videos as well uh if you did like this video please make sure to give it a thumbs up or if you found it boring give it a thumbs down if you have a topic you'd like me to cover please add that in the comments below also in the description you'll see links to all of the equipment that i've shown i've got some getting started kits that you can buy through amazon that are really easy for home assistant i also have links to my camera gear and some of the other software that i use in the description if you want to support the channel um you buy items on amazon using the affiliate links in the description uh that goes to help the channel as well if you'd like to buy me a coffee or a beer there's a link to that down below as well uh big thanks to uh paulo valenti he was the first one he actually bought me three beers which was really super nice and it means quite a bit to me so if you have any other comments or questions please feel free to leave them below i try to be active in the comments on youtube you can also find links here to all of my socials they're also in the description below uh i'm fairly active on twitter so if you have a question you can send me something to my twitter handle there if not thanks for watching the video and have a great day do you
Info
Channel: This Smart House
Views: 44,277
Rating: undefined out of 5
Keywords: home assistant, smart home, home automation, home assistant guide, raspberry pi, home assistant setup, home assistant automation, home assistant raspberry pi, install home assistant raspberry pi, home assistant installation guide, home assistant raspberry pi 4, home assistant beginners guide, raspberry pi 4, install home assistant raspberry pi 4, hassio raspberry pi, install home assistant, smart home setup, smart home 2021, home automation ideas, smart home devices
Id: u_aKcf_F1MM
Channel Id: undefined
Length: 23min 13sec (1393 seconds)
Published: Sun Mar 14 2021
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.