Optional post-installation steps
Running as a system service
HomeGenie can be installed as a service. The procedure is different depending on the hosting operating system.
Recommended procedure for Linux
- Add a specific user for the service and copy the content of
homegenie
folder to the new user home directory:
sudo useradd homegenie
sudo cp -ar ./path-to-extracted-folder/homegenie /home/homegenie
sudo chown -R homegenie:homegenie /home/homegenie
- Create the file
/etc/systemd/system/homegenie.service
with the following content:
[Unit]
Description=HomeGenie
[Service]
Type=notify
User=homegenie
WorkingDirectory=/home/homegenie/
ExecStart=/home/homegenie/HomeGenie
Restart=on-failure
[Install]
WantedBy=multi-user.target
- Refresh
SystemD
configuration
sudo systemctl daemon-reload
- Start the service and enable HomeGenie to auto-start on next system boot:
sudo systemctl start homegenie.service
sudo systemctl enable homegenie.service
Other possible commands are status
, stop
and disable
.
See also:
Depending on the hosting operating system, it might be required to run additional steps in order to allow the service to access the Serial port, USB devices and GPIO hardware.
Additional packages and settings
Enabling audio playback and voice synthesis:
# Audio playback utilities
sudo apt-get install alsa-utils lame
# Embedded speech synthesis engine
sudo apt-get install libttspico-utils
Granting access to the Serial port and/or GPIO to the homegenie user:
sudo gpasswd -a homegenie dialout
sudo gpasswd -a homegenie gpio
Enabling CM15/CM19 USB controller for X10 home automation:
sudo apt-get install libusb-1.0-0 libusb-1.0-0-dev
then, to grant access to CM15/CM19 USB devices to the homegenie user, create a new text file with the name /etc/udev/rules.d/98-cm15_cm19.rules
and add the following lines to it:
# CM15 AND CM19 X10 controllers
ATTRS{idVendor}=="0bc7", ATTRS{idProduct}=="0001", MODE="0660", GROUP="homegenie"
ATTRS{idVendor}=="0bc7", ATTRS{idProduct}=="0002", MODE="0660", GROUP="homegenie"
save the file and unplug and replug the device again.