OmniLinkBridge to integrate Home Assistant, SmartThings, Node-RED

rsw686 said:
@grantlewis
 
The alarm_control_panel/mqtt.py component is only the backend. Before these modifications the frontend chart would show undefined when armed night. Now it shows armed night. However the button to arm night still needs to be added to the frontend. There is an issue about this on the Home Assistant github.
 
https://github.com/home-assistant/home-assistant/issues/13964
 
Sorry to be thick -- but shouldn't I be seeing something in HA related to security? Whether the system is armed, disarmed, in night mode, etc., I don't see anything.
 
pete_c said:
pete_c, on 23 Oct 2018 - 09:15, said:
Just a question relating to the MQTT Alarm Control Panel add for night mode.

Am I supposed to see armed_night over here ==>

attachicon.gif
armed night.jpg
You might have missed it, but please scroll up to post #34.
 
Thank you Ryan.  I did miss it.

Enjoying the use of Docker. Moving OmniLinkBridge to Docker.

That said still trying to figure out why OmniLinkBridge runs on one Ubuntu 18.04 build with current Mono and not on another identical build with Ubuntu and mono. Only difference is that one is running on an ARM cpu and the other an Intel CPU.
 
I just released version 1.1.2. The big feature is the addition of an extra sensor per zone, in addition to the existing binary_sensor that only shows open/close status, that will show the non secure, secure, armed, tripped, and bypassed status. You can also bypass and restores zones through MQTT.

If you are using docker you would do the following to update from your local git repo directory. If you changed the location of the config be sure to update the docker run command.
Code:
git pull
docker build --tag="omnilink-bridge" .
docker stop omnilink-bridge
docker rm omnilink-bridge
docker run -d --name="omnilink-bridge" -v /opt/omnilink-bridge:/config --net=host --restart unless-stopped omnilink-bridge
This will leave an orphaned image with the tag none as we tagged the new image with the same name. You can find and remove it by doing the following
Code:
docker image list
docker rmi REPLACE_WITH_IMAGE_ID
 
Thank you Ryan.
 
Moved all to one Intel Atom computer running Ubuntu 18.04 64bit.  Next over to the Rock64 4 Gb ARM computer running Ubuntu 18.10.
 
Updated here to using Docker for the "omnilink-bridge" and current version release version 1.1.2.
 
Still in learning monde regarding the use of Docker.
 
For email here continue to utilize stunnel and gmail.  Installed that also on the same computer.
 
Next enabling database.
 
Looking too now to utilize an Atom based Ubuntu 16.04 32 bit touchscreen for running an HA touch front end.  Got a 32 bit version of Docker running on it.
 
Jog-UBT-16B:~# docker -v
Docker version 1.6.2, build 7c8fca2
 
Curiousity question?
 
Can I run an HA dashboard talking to HA on another computer?
 
All of the above should run fine
 
Interesting you should ask about connecting HA to HA. I've been dealing with that issue for a week now. I have zwave door locks and a few random devices in my house and shop. My original plan was to use two Rasberry Pis with USB Z-wave sticks and Hassio (HA) loaded on both. I tried both HA MQTT eventstream and statestream.
 
Eventstream looked promising, but there is no way to do persistence. When I would restart the HA with Zwave stick the devices would show up on the main HA instance. After some time they would disappear until something occurred on the device.
 
Statestream solved that issue, but the devices had to be manually configured as MQTT devices on the primary HA instance. The deal breaker is there is no way to send a command back to the HA Zwave instance. I was debating about using Node Red to see the MQTT command and send the HA service call to the appropriate device.
 
For now I ended up leaving these on SmartThings and am using the smartthings-mqtt-bridge. Paritally because I have a SmartThings app to manage the lock codes and HA doesn't have one yet. However each SmartThings device handler needs a unique MAC so I have a separate VM with docker running these as it conflicts with OmniLinkBridge talking to SmartThings.
 
Yeah the Ubuntu 16.04 touchscreen is just an O2 Joggler with some modifications on it.
It runs XPe using a seabios x86 boot. It runs Ubuntu using an EFI boot.
I just want to build a touchscreen interface to HA on the Joggler connecting to main HA box.


Relating to a ZWave controller here have an RPi2 in the attic with a Razberry GPIO card in it.
 
This ZWave wave controller utilizes ser2net to talk to Homeseer.
 
Guessing you can do the same with HomeAssistant configuring a ZWave ethernet to serial port on it.
 
Current ZWave controllers here are:
 
1 - Razberry GPIO card in RPi2
2 - OmniPro 2 HAI VRCOP
3 - Samsung Smartthings
 
I have replicated the ZWave network to all three of the above.
 
Googling found this:
  RPi as Z-Wave/ZigBee-over-IP server for Hass
 
The RPi2 in the attic is POE connected and does Node Red / OWFS 1-Wire, ZWave, SDR (NOAA map downloads).  
 
You can do a Mosquitto in/out of the RPi if you do not want to use an ethernet to USB or Serial connection for HA.
 
ZWave for node-red through OpenZWave, the open source ZWave library
 
Changing the above though to using two modded Sonoff Wifi devices acting as 1-wire hubs talking Mosquitto.
 
10:00:13 MQT: /1Wire/SENSOR = {"Time":"2018-10-26T10:00:13", "DS18x20":{"DS1":{"Type":"DS18S20", "Address":"10AE56130008007B", "Temperature":70.0}, "DS2":{"Type":"DS18S20", "Address":"10A52F47000800CB", "Temperature":70.1}, "DS3":{"Type":"DS18B20", "Address":"280D7E5B04000049", "Temperature":80.6}}, "TempUnit":"F"}
 
1wire.jpg
 
Well the issue is I need two Zwave networks (one for house and one for shop) and HA only supports one Zwave controller. Ideally I'd like to have three networks as the lock in my garage can be flaky even though I have a Zwave outlet right next to it to help with repeating the signal.
 
With Mosquitto you can manage multiple ZWave networks.
 
Just build a controller with an RPi talking ZWave and Mosquitto.
 
I didn't have time to sleuth out a "why," but Home Assistant 0.81.6 broke OmniLinkBridge for me. Reverting to 0.81.2 fixed it.
 
Looks like I need to eat a few words. I've experienced something strange two times in the last 24 hours and I'm not sure if involves OmniProBridge or not. I'll relate everything that's happened with an apology in advance ( a ) for being overly detailed and ( b ) that it may have nothing whatsoever to do with OmniLinkBridge.
 
As I mentioned above, I was running 0.81.2 with OmniLinkBridge. Everything's been ticking along great for literally weeks. A couple of days ago I'd backed everything up in Hass.io -- took a snapshot and also backed up most of the individual files in my /config/ folder separately (thank goodness). Then yesterday I performed the upgrade to 0.81.6 and things started to go haywire. I can't exactly remember the sequence of events, but at one point I believe I remember that HA had lost connection to the OmniLinkBridge entities as they were reporting "unavailable." The only change of any significance I'd made was upgrading to 0.81.6. I did a net stop/start of the OmniLinkBridge and then used the HA Configuration menu option to Restart. The restart process seemed to hang, so via a terminal/SSH session I performed a hassio host reboot. 
 
That's when things start to deteriorate even more quickly, and eventually my whole Home Assistant setup went down. I tried restarting multiple times, but nothing worked. Trying to load up the HA web UI resulted in "Unable to connect to Home Assistant" (I tried my DuckDNS domain name, http://hassio.local:8123 and http://192.168.1.35:8123/ -- no luck). I could ping the RPi3, but both SSH and SMB were down. The entire system was totally inaccessible.  Because I couldn't get at the system, I couldn't check logs. Frustrating.
 
I assumed it was due to a faulty snapshot or maybe a corrupted SD card file system, so I imaged a new SD card with 0.81.6 and tried restoring to my 0.81.2 Hassio snapshot. That failed: system hung/wouldn't load UI, etc. Thinking that the snapshot might be corrupt, I tried a 0.81.1 snapshot. That also failed. 
 
I eventually had success by re-imaging the new SD card with 0.81.6, downgrading to 0.81.2 with
Code:
hassio homeassistant update --options version=0.81.2 
, getting SMB and SSH running again, and then restoring the remaining addons from my prior setup using the 0.81.2 snapshot file. That was at 3:00 AM this morning. I went to bed with everything working once again.
 
So then a couple of hours ago I was doing some other work that again involved multiple restarts. I was on 0.81.2 at this point and the system seemed fine. I assumed that whatever problems I'd encountered before were due to the .6 release and a couple of corrupted snapshot files. Then as I was working I noticed once again that all of the OmniPro II entities were reporting "unavailable." I tried what I tried earlier: net stop/start of omnilinkbridge, and restarting via the HA Restart option which seemed to hang as before. So as before I performed a hassio host reboot via terminal/SSH. You see where this is going, right?
 
Once again I've received "Unable to connect to Home Assistant" when trying to load up the UI. Although I can ping the RPi's IP, I can't connect with either SSH or SMB. I've done nothing unusual that I can think of. Power cord is firmly seated, heat's not a problem, nothing physical that I can spot might be the culprit.
 
I'm going to rebuild everything again as I did previously and will post an update as I have time. It doesn't seem to make sense that this would have anything to do with OmniLinkBridge, but I'm at a loss as to what could be happening. The pattern seems the same: OmniLinkBridge entities become unavailable (which admittedly might be only a symptom), and then rebooting results in total failure.
 
Never updated here so tried to update and I know I must be doing something wrong.
 
~# docker stop home-assistant
home-assistant
 
~# docker rm home-assistant
home-assistant
 
~# docker pull homeassistant/home-assistant:0.81.4
0.81.4: Pulling from homeassistant/home-assistant
Status: Downloaded newer image for homeassistant/home-assistant:0.81.4
 
~# docker run -d --name="home-assistant" -v /opt/home-assistant/config:/config -v /etc/localtime:/etc/localtime:ro --net=host --restart unless-stopped homeassistant/home-assistant
 
~# docker restart  home-assistant
 
Still showing 0.80.3 here.
 
Thinking I skipped something here?

Deleted the old container

~# docker image list
REPOSITORY TAG IMAGE ID CREATED SIZE
homeassistant/home-assistant 0.81.4 e4ce187f1b99 3 days ago 1.78GB
omnilink-bridge latest 16f65f94f78f 10 days ago 666MB
mono latest f10d48e24cfd 2 weeks ago 605MB
nodered/node-red-docker v8 d7b7ac4d8df7 7 weeks ago 720MB

restarted HA

Got it...

docker run -d --name="home-assistant" -v /opt/home-assistant/config:/config -v /etc/localtime:/etc/localtime:ro --net=host --restart unless-stopped homeassistant/home-assistant:0.81.4
 
Pete

Either leave the version number off the docker pull or append the version number to the docker run command. If you do docker image list you see both the home assistant versions.
 
Back
Top