All-In-One Home Assistant Tablet // With The RasPad 3

References / Resources

Install Home Assistant with Docker

  • So first we need to make sure our system is up to date sudo apt-get update && sudo apt-get upgrade
  • Then we need to install the pre-reqs for Home Assistant
sudo apt-get install network-manager apparmor-utils jq -y
  • Then reboot the Pi
sudo reboot
  • Once the Pi is back, then we need to get the official docker script for RPI
curl -fsSL <https://get.docker.com> -o get-docker.sh
  • Once the script is downloaded, then we need to run it
sudo sh get-docker.sh
  • Then we need to give the PI user docker permissions
sudo usermod -aG docker pi
sudo curl -Lo installer.sh <https://github.com/home-assistant/os-agent/releases/download/1.2.2/os-agent_1.2.2_linux_armv7.deb>
  • Finally we need to run the installer
sudo dpkg -i os-agent_1.2.2_linux_armv7.deb
  • Now we install Supervisor
wget <https://github.com/home-assistant/supervised-installer/releases/latest/download/homeassistant-supervised.deb>
  • Now once the install is complete, we can test by going to:
<http://localhost:8123> or <http://homeassistant:8123>

Kiosk / Full Screen Mode

Auto Start

#!/bin/bash

# Run this script in display 0 - the monitor
export DISPLAY=:0

# Hide the mouse from the display
unclutter &

# If Chromium crashes (usually due to rebooting), clear the crash flag so we don't have the annoying warning bar
sed -i 's/"exited_cleanly":false/"exited_cleanly":true/' /home/pi/.config/chromium/Default/Preferences
sed -i 's/"exit_type":"Crashed"/"exit_type":"Normal"/' /home/pi/.config/chromium/Default/Preferences

# Run Chromium and open tabs
/usr/bin/chromium-browser --window-size=1920,1080 --start-fullscreen --window-position=0,0 http://localhost:8123 &

# Start the kiosk loop. This keystroke changes the Chromium tab
# To have just anti-idle, use this line instead:
# xdotool keydown ctrl; xdotool keyup ctrl;
# Otherwise, the ctrl+Tab is designed to switch tabs in Chrome
# #
#while (true)
#  do
#    xdotool keydown ctrl+Tab; xdotool keyup ctrl+Tab;
#    sleep 15
#done