I’m on the development version of Home Assistant, and patched ozwcp and python-openzwave with the Barrier Operator class, but I’m still getting only sensors. Does anyone actually have this working in the latest Home Assistant?
Is this garage door opener supported yet on 0.34.5 of HA without having to patch OZW and OZWCP?
I have a fresh install of HASS using the all in one installer and I can’t seem to get it working with the version of OZWCP included. I am able to pair the opener but it doesn’t show an option for “open” under the current values. I do see the sensor, however it doesn’t seem to be updating when I open or close the garage door.
This is unfortunately one of those threads that is best read from start to finish. Your answer lies up above. There is currently no built-in solution yet to get it working, however following the steps mentioned earlier does make it work fairly reliably. I’m now on the latest version of HA (the one that re-numbered all the Z-Wave devices) and it’s still working l ike a champ.
Using the OZ/OZCP patches and one of my own for building, I finally got a working docker image for OZWCP and a docker images based off HA-0.37.1 working.
I can open/close the garage door and the sensor reads open/close correctly on changes.
The only problem is it doesn’t show up as a garage door, it shows up as Linear Unknown: type=4744, id=3530:
cover.linear_unknown_type4744_id3530_open_9_0 closed node_id: 9 friendly_name: Linear Unknown: type=4744, id=3530 Open
sensor.linear_unknown_type4744_id3530_access_control_9_9 254 friendly_name: Linear Unknown: type=4744, id=3530 Access Control node_id: 9
sensor.linear_unknown_type4744_id3530_alarm_level_9_1 0 friendly_name: Linear Unknown: type=4744, id=3530 Alarm Level node_id: 9
sensor.linear_unknown_type4744_id3530_alarm_type_9_0 0 friendly_name: Linear Unknown: type=4744, id=3530 Alarm Type node_id: 9
sensor.linear_unknown_type4744_id3530_burglar_9_10 254 friendly_name: Linear Unknown: type=4744, id=3530 Burglar node_id: 9
sensor.linear_unknown_type4744_id3530_sourcenodeid_9_2 0 friendly_name: Linear Unknown: type=4744, id=3530 SourceNodeId node_id: 9
I couldn’t get the master branch working, it didn’t detect it and had a core dump.
I haven’t tried the dev branch. Should I, what is the difference between dev and master?
What else is needed so it shows up as a garage door?
It looks like this patch is still there in 0.37.1, just a lot of code has moved around.
@turbokongen, any ideas?
Thanks you @josh, @turbokongen and body else that helped with this! (sorry, new user can only tag two people on a post)
From the snippet above, it seems you have it working. It will never show as a garage_door but as a cover. Garage_door and the rollershutter has been deprecated in favout if cover. The name can be set for the frontend with the friendly_name attribute in the customize section of the configuration.
The naming is from OZW, so if it is not a specific configuration file for it, it will show as unknown.
@jrowberg, I would definitely be interested in your tutorial. I have tried manually patching everything but must be doing something wrong.
I also tried following the steps above but failed to get this working.
This is the patch I am using based off git tag 0.37.1 to build docker images. Not 100% sure it works for straight building/install, but might get you close:
http://www.brianfrance.com/software/home-assistant/barrier.diff
@hawk259 – you have the following, correct?
cover:
platform: zwave
Other than that, there’s nothing in my config… just put that entity in a group, and it should show up as a cover that can be opened/closed. See attached pics for everything I have.
On the hass page:
In the config:
On my page:
@josh – Yes, I have that in my config. I have everything working now, BIG THANK YOU!
I just got confused when it showed up as linear_unknown_type, because scrolling through the thread there were a few that show up with garage door in the name. I easily fixed that the with a friendly_name change and it is all good.
I updated my patch for building a docker container based on 0.38.3:
http://www.brianfrance.com/software/home-assistant/barrier-0.38.3.diff
@hawk259
Just trying to work through this as well. For the OZWCP portion, do you happen to have a diff and base repo that you were working off of for that?
Thanks for taking the effort to put up the patches. It’s definitely a big boost getting started.
If any newcomers are using the hassbian image for raspberry pi, I’ve made changes to the install_openzwave.sh
script which will apply the garage door opener (barrier_operator) additions to openzwave and openzwave-control-panel automatically before building and installing them. This should make things really simple for absolute beginners.
Here are instructions for those starting off from scratch:
-
Download the hassbian image and follow the instructions, then verify that you can successfully browse to
http://hassbian.local:8123
as mentioned. -
ssh into your Raspberry Pi and replace the existing install_openzwave.sh script. To make that modification, edit the existing script with nano:
nano hassbian-scripts/install_openzwave.sh
then replace its contents by holding down CTRL+K to remove everything, then pasting in the new script below (usually by right clicking, if using putty or Windows 10’s bash):#!/bin/bash
echo
echo “Open Z-Wave Installer for Hassbian”
echo “Modified by Landrash for use with Hassbian.”
echo “Remodified by unt1tled for use with Linear NGDZ00-4 (barrier_operator).”
echo “Copyright© 2016 Dale Higgs https://gitter.im/dale3h”
echoif [ “$(id -u)” != “0” ]; then
echo “This script must be run with sudo. Use “sudo ${0} ${*}”” 1>&2
exit 1
fiecho “Running apt-get preparation”
apt-get update
apt-get upgrade -y
apt-get install -y make python3-dev libudev-dev python3-sphinx python3-setuptools libgnutlsxx28 libgnutls28-dev libssl-devecho “Changing to homeassistant user”
sudo -u homeassistant -H /bin/bash <<EOFecho “Activating virtualenv”
source /srv/homeassistant/bin/activateecho “Installing latest version of cython”
Currently locked to this version since build fails for later versions.
pip3 install --upgrade cython==0.24.1
echo “Creating source directory”
mkdir -p /srv/homeassistant/src
chown -R homeassistant:homeassistant /srv/homeassistant/srcecho “Cloning python-openzwave”
cd /srv/homeassistant/src
git clone https://github.com/OpenZWave/python-openzwave.git
chown homeassistant:homeassistant python-openzwave
cd python-openzwaveecho “Cloning openzwave”
git checkout python3
rm -rf openzwave
git clone git://github.com/OpenZWave/open-zwave.git openzwaveecho “Replacing openzwave source files to add barrier_operator support”
wget -O openzwave/config/device_classes.xml https://raw.githubusercontent.com/OpenZWave/open-zwave/c808b7431fb6c28b408e7fdc5492e46420cb6926/config/device_classes.xml
wget -O openzwave/cpp/src/command_classes/BarrierOperator.cpp https://raw.githubusercontent.com/OpenZWave/open-zwave/c808b7431fb6c28b408e7fdc5492e46420cb6926/cpp/src/command_classes/BarrierOperator.cpp
wget -O openzwave/cpp/src/command_classes/BarrierOperator.h https://raw.githubusercontent.com/OpenZWave/open-zwave/c808b7431fb6c28b408e7fdc5492e46420cb6926/cpp/src/command_classes/BarrierOperator.h
wget -O openzwave/cpp/src/command_classes/CommandClasses.cpp https://raw.githubusercontent.com/OpenZWave/open-zwave/c808b7431fb6c28b408e7fdc5492e46420cb6926/cpp/src/command_classes/CommandClasses.cppecho “Building python-openzwave with barrier_operator support”
make build
make installecho “Deactivating virtualenv”
deactivate
EOFecho “Creating libmicrohttpd directory”
cd /srv/homeassistant/src
mkdir libmicrohttpd
chown homeassistant:homeassistant libmicrohttpd
cd /srv/homeassistant/src/libmicrohttpdecho “Downloading libmicrohttpd-0.9.19”
wget ftp://ftp.gnu.org/gnu/libmicrohttpd/libmicrohttpd-0.9.19.tar.gz
chown homeassistant:homeassistant libmicrohttpd-0.9.19.tar.gz
tar zxvf libmicrohttpd-0.9.19.tar.gz
chown homeassistant:homeassistant libmicrohttpd-0.9.19echo “Building libmicrohttpd-0.9.19”
cd libmicrohttpd-0.9.19
./configure
make
make installecho “Cloning open-zwave-control-panel”
cd /srv/homeassistant/src
git clone https://github.com/OpenZWave/open-zwave-control-panel.git
chown -R homeassistant:homeassistant open-zwave-control-panel
cd open-zwave-control-panelecho “Replacing open-zwave-control-panel source files with barrier_operator support”
wget -O zwavelib.cpp https://raw.githubusercontent.com/legrego/open-zwave-control-panel/0925251a566a36543e0c6b5cb0b2c1498bddfa68/zwavelib.cppecho “Building open-zwave-control-panel”
rm Makefile
wget https://raw.githubusercontent.com/home-assistant/fabric-home-assistant/master/Makefile
chown homeassistant:homeassistant Makefile
makeecho “Linking ozwcp config directory”
ln -sd /srv/homeassistant/lib/python3./site-packages/libopenzwave-0.-linux*.egg/config
chown -R homeassistant:homeassistant /srv/homeassistant/srcecho “Linking Home Assistant OpenZWave config directory”
cd /home/homeassistant/.homeassistant
sudo -u homeassistant ln -sd /srv/homeassistant/lib/python3./site-packages/libopenzwave--linux*.egg/config
chown -R homeassistant:homeassistant /home/homeassistant/.homeassistantecho
echo “Installation done!”
echo
echo “If you have issues with this script, please contact @Landrash on gitter.im”
echo “Original script by @dale3h on gitter.im”
echo
Overwrite the existing file by hitting CTRL+X, then Y to save changes.
3. Now run the new script with this command:
sudo ./hassbian-scripts/install_openzwave.sh
and wait (and wait) for it to complete.
4. If your NGDZ00-4 is already paired, then you’ll need to re-add your security key to your options.xml
. Or if this is your first time pairing it, you’ll need to generate a new security key.
Either way, follow the instructions here and modify your options.xml
by entering:
nano /srv/homeassistant/lib/python3.4/site-packages/libopenzwave-0.3.2-py3.4-linux-armv7l.egg/config/options.xml
(note to people in the future: the version numbers in this path may have changed)
5. Also, you’ll need add the zwave and cover platforms to your configuration.xml
:
Edit the configuration.xml
by entering
nano /home/homeassistant/.homeassistant/configuration.yaml
Then append the following on the bottom:
zwave:
usb_path: /dev/ttyACM0
config_path: /srv/homeassistant/lib/python3.4/site-packages/libopenzwave-0.3.2-py3.4-linux-armv7l.egg/config/
cover:
platform: zwave
6. Reboot the pi by entering sudo reboot
and then, if required, securely add your NGDZ00-4 device with zwave.add_node_secure
. If done correctly, you’ll have your shiny new automated garage door opener working under a “cover” device like this:
From here, refer to the documentation on customizing the name, etc.
Cheers!
Would you be willing to write a step by step guide just like this for those of us with existing installations? I have had to keep my wink hub up solely for my linear garage door opener because I was unable to get it to work with OpenZWave Controlpanel.
I used the all-in-one installer and would likewise be interested in any guidance on how to patch the existing open-zwave install that was part of the AIO install…
I would also really appreciate someone doing a guide for this. I can see the device in OZCP but cant control it from there and I can also see it in HA AIO install.
would be interested in a step by step guide for existing installations as well
I got bored and grabbed another SD card to start over and give the steps described and I’m stuck on #4, I cannot locate my options.xml nor do I know how to generate or re-add my security key (my NGDZ00-4 is already paired to the stick)
Any insight anyone can offer me?