Estimated reading time: 10 minutes

Have you ever thought about how you can make your home more secure while you are away? Burglars often take the opportunity when houses are empty. But with the right technology, you can easily fool them. In this blog article, you'll find out how you can use Home Assistant and the Presence Simulation-project from the slashback100 GitHub repository to set up a presence simulation that makes your home appear inhabited.

For detailed instructions and an explanation of all configuration options, I recommend the YouTube video linked below. In this video, every single setting is explained in detail so that you receive comprehensive instructions for the exact setup. You can find any code from the video in this article so that you can use it directly without having to type it in.

What is Home Assistant?

Home Assistant is an open source platform for home automation that aims to connect and centrally control all devices in the home. It is designed to provide a unified user interface and simple, flexible control for a variety of smart home devices from different ecosystems. Here are some points in favor of Home Assistant:

  1. CompatibilityHome Assistant supports thousands of devices and services from various manufacturers, including lighting, air conditioning, heating, cameras, weather sensors, voice assistants and more.
  2. Local controlUnlike many commercial smart home platforms that rely on cloud services, Home Assistant runs locally on your network. This means increased privacy and reliability, as your smart home devices work even without an active internet connection.
  3. Automation and scenesOne of the main features of Home Assistant is the ability to create complex automations and scenarios. For example, you can have lights switch on automatically when it gets dark or turn on the heating when the temperature falls below a certain level.
  4. Simple user interfaceHome Assistant offers a user-friendly interface that makes it easy to monitor and control devices. This interface is fully customizable.
  5. Integration with voice assistantsHome Assistant can be integrated with voice assistants such as Amazon Alexa or Google Assistant to enable voice-controlled control of your smart home devices.
  6. Open source and community-drivenSince Home Assistant is open source, it is supported by an active community that is constantly developing new integrations and improving existing ones.
  7. Data protection and securityAs a locally running platform, Home Assistant has the advantage that the data remains within its own network. This protects privacy and increases security compared to cloud-based solutions.

In summary, Home Assistant is a powerful and flexible solution for those who want to design their own smart home and control their devices centrally, regardless of the manufacturer or ecosystem.

What is presence simulation useful for?

A presence simulation simulates your daily activities by switching lights on and off, raising or lowering blinds and controlling other devices. This way, you always appear to be present to outsiders, even if you are on vacation or away for a longer period of time. Burglars specifically look for houses that appear empty. However, if the lights suddenly come on in your home in the evening or the TV is on, they may think twice before attempting a break-in.

How the presence simulation works

With the Presence Simulation you can automate all these actions and control them in such a way that they appear as realistic as possible. The project offers you numerous functions that you can easily integrate into Home Assistant.

1. simulate random points in time

At the heart of presence simulation is the ability to carry out actions at random times. For example, you can set the living room light to go on and off randomly between 6:00 and 10:00 pm. This avoids rigid schedules that would be easy to see through. You set a time period and the script takes care of the rest by choosing random times for the devices to switch on within this interval.

2. automatic repetition based on historical data

Another exciting function is the ability to repeat actions based on past data. You have the option of monitoring the behavior of your smart home over a certain period of time and saving these patterns. You can then simply have them repeated. This makes your home seem just as lively as usual, even when you're not there.

3. simulation of several devices

The Presence Simulation is not just limited to switching lights on and off. You can also include other devices in the simulation, such as the TV or music system. This provides even more variety and realistic scenarios. You can also raise and lower blinds at random times so that burglars don't recognize fixed patterns.

4. time shift (delta)

Imagine if you switched your lights on at exactly 7 p.m. every day - that would be pretty conspicuous, wouldn't it? This is where the time difference comes into play. With the Delta feature you can ensure that the actions are delayed a little each time or take place earlier. This means that your lights don't always come on at exactly the same time, but sometimes a few minutes earlier or later, which enhances the effect of real people in the house.

5. configurable time intervals

You can also flexibly configure your own time intervals. For example, if you only want the light to come on between 8 p.m. and 11 p.m., you can easily set this. This ensures that the simulation is perfectly adapted to your needs.

6. easy integration into Home Assistant

The best thing about the Presence Simulation is the seamless integration into Home Assistant. By using YAML files, you can integrate the configuration directly into your Home Assistant system. The installation is done via the Home Assistant Community Store (HACS), which allows you to easily add the repository from GitHub and start the automation.

Installation of HACS and integration of Presence Simulation in Home Assistant

Step 1: Installing HACS in Home Assistant

Home Assistant Community Store (HACS) is a custom add-on for Home Assistant that provides access to a variety of custom integrations and plugins developed by the community. How to install HACS:

  1. Check requirements: Make sure that your Home Assistant is ideally up to date.
  2. Download Execute script: Open a terminal for the Docker container version or the core version.
    • Docker: Dial into the container with: docker exec -it homeassistant bash or (similar)
    • Core: Switch to the user who is running Home Assistant
    • Execute the following command for both variants:
      wget -O - https://get.hacs.xyz | bash -
  3. Restarting the Home Assistant: After the files have been copied, restart Home Assistant.
  4. Integrate HACS into Home AssistantGo to "Configuration" > "Integrations" > "Add" in the Home Assistant interface and search for HACS. Add it and enter your GitHub token if prompted.

For the supervised version, please refer to the Documentation of HACS itself to read about the installation.

Step 2: Add Presence Simulation integration via HACS

Once HACS is installed, you can simply add Presence Simulation:

Open your Home Assistant instance and open a repository inside the Home Assistant Community Store.
  1. Open HACS: Go to HACS in the Home Assistant interface.
  2. Search for integrationClick on "Integrations" (or here: Open your Home Assistant instance and show your integrations.) and use the search function to search for "Presence Simulation".
  3. Install Presence SimulationFind Presence Simulation in the list and click on "Install". This will add the integration to your Home Assistant.
  4. Restarting the Home Assistant: Start Home Assistant again to apply the changes.
  5. Presence Simulation ConfigureAfter restarting, you can set up and customize Presence Simulation via "Configuration" > "Integrations" in Home Assistant.

Conclusion

With these steps, you have successfully installed HACS in your Home Assistant and added the Presence Simulation integration. This powerful combination opens up a world of additional features and customizations that have been and are being developed by the Home Assistant community. More blog posts and videos on useful integrations to follow. If you don't want to miss out, subscribe to my YouTube channel!

Requirements

To really be able to use the presence simulation in Home Assistant, you need to take another precaution:

The History integration must be activated - which is the case by default. The period stored in the database should be longer than the delta used in the simulation. By default, the data is saved for 10 days, and this period can be changed using the Recorder integration can be configured. You can configure both in the configuration.yaml of your Home Assistant instance.

Ideas for devices

For an even more realistic presence simulation, you can use a variety of entities ranging from the Presence Simulation-integration are supported. These include

  • Lights (light)You can set smart lights to switch on and off randomly in different rooms. For example, the living room light could come on in the evening and go off again after a while, as if you were moving around the house.
  • Blinds/roller blinds (cover)With this entity, you can automatically raise smart blinds in the morning and close them again in the evening. This simulates the typical activities in an occupied house and looks particularly realistic when the times vary.
  • Media devices (media_player)Smart TVs, radios and loudspeakers can also be controlled. For example, switch on the TV for an hour or start music via a loudspeaker - perfect for simulating presence.
  • Switch (switch)All devices that can be switched on and off via smart sockets or switches can also be integrated. This means you can switch coffee machines, fans or other household appliances on and off to create more variety.
  • Automations, groups (automation, group)You can also use automations and groups of devices that are controlled together. For example, you could switch a group of lights and switches on or off together to simulate more complex scenarios, such as switching on hallway lights and the living room TV.

The broad support of these entities makes your presence simulation very flexible and can be perfectly adapted to your everyday life.

YouTube video implementation

https://youtu.be/80mgrayZkfg

Conclusion

With the Presence Simulation For Home Assistant, you can make your home safer by deceiving burglars and making it look as if you are always at home. By randomizing times, repeating actions based on historical data and controlling different devices, you can create a realistic presence simulation that is not only practical but also effective.

Now you no longer have to worry the next time you go on vacation. Your smart home will do the work and keep uninvited guests out!

The display of the products was implemented with the affiliate-toolkit plugin.

0 Comments

Leave a Reply

Avatar placeholder

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

en_US