Z-Wave

Questions and comments specific to a particular plugin should go here.
User avatar
kgschlosser
Site Admin
Posts: 5020
Joined: Fri Jun 05, 2015 5:43 am
Location: Rocky Mountains, Colorado USA

Re: Z-Wave

Post by kgschlosser » Fri Sep 13, 2019 9:15 pm

well If you have not given the ZWave plugin for EventGhost a shot you should. Everything is exposed in EG nothing is hidden from the user. If it can be changed you can change it. I know that OpenHAB downloads device (node) specific data from a device database they have set up. I do not know if it "caches" this information. For some reason I do not believe it does. I say that because they have coded into the database json versions which would lead me to believe that it grabs the data every time it starts up. If that is the case this in it's self becomes an issue if you do want to modify any of the device settings. Again I do not know how OpenHAB is written.

I really really really do hate having to have a reliance on the internet for a program to operate correctly.

I scraped the zwave-alliances entire product catalog and created xml files for OpenZWave. It needs some more tweaking and will need to have some of the files modified But the bulk of the work is done. OpenZwave also has a reliance on a device database they made. I am going to offer the xml files as an addon. compressed all of the files are only 2 MB. a total of 325 manufacturers with a total of 1897 devices. being at it is only 2MB compressed there is no reason as to why OpenZwave or even OpenHAB for that matter does not ship with all of the files. But they do not. I really dislike having a dependency on something I do not have control over. Get a nasty storm and pow internet drops.

The remote administration deal I made is nice. It allows for a more fine grained control that is outside of the Software controller to be run at the same time without needing to disconnect anything. I also coded into python-openzwave installing it as a service on Windows, Linux and OSX. This is a nice thing to have because the startup of the network is what can take a long while to complete. and most times there is no need to restart that portion of the code and only the front end. So using that same remote connection it allows for an application to connect to the service. The best part about the way I designed it is the API is identical if you write an application to use the USB stick directly or if you are making a remote connection. The app will not know the difference, all that needs to be done is instead of pointing the software at a serial port it gets pointed to an IP and port, just provide the same password that is set on the server side and it's up and running. This is also a super nice feature if you want more processing power for the application that what can be provided with a raspberry pi. but you want the USB stick centrally located in the house without having to set up a PC say in the middle of a hallway.. LOL. Now you can Stash a raspberry pi somewhere. plug the ZStick into it. install my software as a service install the app on something more powerful located elsewhere in the home. connect the 2 and you are off and running. This is a really sweet thing to be able to do. I can see this specific thing getting done in order to improve the network performance. By locating the stick in the center of the house it will literally double the network performance. #1. Not as many hops to get to the edges of the network. #2. neighbor nodes to the stick are going to see a reduced packet forward amount. If you have the stick on one side of the house you might have 5 or 6 neighbors. all network traffic has to go through these 5 or 6 nodes in order to get where it's going. in the center of the house if you have enough nodes you will max out the number of neighbors the stick can have. I do not remember what that number is exactly but I know it is higher then say 6. Plus the nodes that are neighbors to the controllers neighbors gets reduced. It's a more direct route to get to the destination.

If you had the ability to do the above would you? What is your reasoning behind running on a Raspberry Pi?
If you like the work I have been doing then feel free to Image

SimonB
Posts: 23
Joined: Mon Jul 29, 2019 2:04 pm

Re: Z-Wave

Post by SimonB » Mon Sep 16, 2019 2:39 pm

If you had the ability to do the above would you? What is your reasoning behind running on a Raspberry Pi?
Yes I would!

The reason I am running Openab on a Raspberry Pi is that is just works. I have limited time for the hardware side of my home automation let alone the software side and there is a ready-made "Raspbian" installation of Openhab on a Pi that I can just download and run without me needing to get into the inner workings of Linux or Pis. From the research I've done, It seems the best combination of flexibility, reliability, control, and controlability and the ability to hide the clever stuff under a sensible UI either of hardware switches or a web or other GUI so my wife can treat it as a self explanatory appliance. It can control a lot of stuff.

So I have my lights operated by "fairly regular looking" momentary switches but with a little bit of code they can come on a different dim levels (or indeed different colour temperatures) at different times of the day or be controlled by schedules or other events or from abroad(!). My wife has no interest in why they do that let alone how so long as they do something intuitively sensible when she pushes a switch.

I looked at Smartthings but it's not flexible enough. Things like Nest just don't do what I want. Fibaro / Vera / Homeseer - meh! Philips Hue and similar are too proprietary and I'm certainly not interested in getting my phone out, unlocking it, opening an app and then pressing a button just to turn my lights on. I do have a few Hue lights for a specific purpose but only controlled through Openhab using regular switches built into the walls like switches have been since they were invented.

That's why I'm enjoying Eventghost. It gives me some detailed low-level control that I can't get with Openhab - especially IR control of my media PC and TV / AV setup but I can integrate that into the bigger-picture automation provided by Openhab and link it to presence and location information, weather, heating, lighting etc etc.

You're mostly right about z-wave and Openhab although Openhab does run stand-alone day-to-day without needing any connection to the internet (another reason I like Openhab - I run my own cloud server because I don't trust the cloud and my wife won't let Alexa or Google into the house!). You do have to wait for new devices to be integrated into new builds which can take time but doesn't happen very often unless you're desperate to introduce bleeding-edge products. The zwave database maintained by Chris Jackson is excellent but I do worry what might happen if he gets bored of it all one day. Most of the time it's not an issue and he is very responsive when it comes to new feature requests etc but you're right that system does put a degree of separation between you and the individual command classes because it applies control through bindings and channels. So you do have to wait for it to catch up if you need something slightly different. I can see the logic though; Eventghost is perhaps one level of detail and control closer to the inner workings than Openhab is and it has some very unique features like CEC control (and IR these days) that you just can't get anywhere else (and for which I''m very grateful by the way).

There's room for both in this world though.

User avatar
kgschlosser
Site Admin
Posts: 5020
Joined: Fri Jun 05, 2015 5:43 am
Location: Rocky Mountains, Colorado USA

Re: Z-Wave

Post by kgschlosser » Tue Sep 17, 2019 7:57 am

The reason why EG is not more popular is because it lacks a web interface. People fail to understand what Home "Automation" is. as you stated.. pulling out my cell phone or a tablet and bring up a GUI and press a button to turn a light on only means someone ass is going to get bigger and bigger because that is the definition of laziness. and there is not a damned thing automatic about it. web gui's that offer fancy interfaces for doing thing like turning lights on and off. or changing the channel on your tv do not belong being grouped with home automation. now those GUI's are the defining thing in a smart home. EG is not what gives you a smart home. It is a component that would be considered the backbone of a smart home. but it does not provide the "fluff" interfaces seen in a smart home. An automatic home is what EG can provide. Having different tasks carried out without the intervention of a user is what EG is all about.

There is not 1 piece of software (that i have been able to locate) that is being developed currently that offers home automation on the level that eg does. most of them require you to shutdown the system manually edit files and then start it back up. can you imagine doing that over and over and over again until you get it working right?? EG is designed to be used by peopel of any skill level from the developer right down to someone like my grandma (who is 95). This is a great use case example. Take someone that is 80-90... years old. and tell them you are going to give them a "smart home" and they will be able to turn the lights on from a cell phone.. and then tell them you want to give them an "Automatic Home" one that will turn the lights on as you are walking up to the door and there is no need to press a button on a cell phone to do it.. and ask them which one they would rather have... I am going to bet you know what the response is going to be.

Take the different we gui systems out there and see how difficult it is to set up turning the lights on as you walk up to the door. No motion sensors BTW. we only want it to turn the lights on when grandma or grandpa is walking up.

In EG it is wicked easy. install an app on the cell phone. add a plugin to EG. draw a little circle around your house in the app on the phone and connect the app to EG. plug in a USB ZStick plug in a zwave module into the wall outlet plug the lamp into it. press a button to pair the stick to the module. add the zwave plugin to EG. couple of click of the mouse.. little bit of drag and drop.. and presto it works. no editing config file no needing to know things like serial ports and com ports. the most technical thing that is needed is the IP address of the PC that EG is running on.. That's it! It would take 10 minutes at most (not an exaggeration). Picture having your arms full of groceries and trying to pull out your phone to turn the lights on. Now picture grandma or grandpa doing that as well. I can already hear the conversation that takes place whent he phone call gets made to bitch that the groceries got dropped. or the phone got dropped and broke. LOL

I like to use this as an example. It is not that hard to set something like this up either.

say you have 4 TV's varying brands and models, different Audio components in each room. or possibly none at all. maybe some rooms have HTPC's. there are 4 remote controls

Now most setups that are like this will have a remote control for each of the rooms where the TV's are located yes? would a remote control from 1 room work in a different room.. Possibly. would it be able to work in all of the other rooms. NO...... well.... YES! with EG you can. and the proverbial cherry on top.. you don't have to do a thing to make the remote work in a different room, only walk into it holding the remote. no changing devices all buttons function identical to every other room. actually all 4 remotes are identical. because EG has the ability to interface will all of the devices mentioned above you can connect them all to a single running copy of EG. You can use global cache IR to IP bridges (expensive at 100+ a piece) or you can spend < 10.00 USD and get an arduino that can do the same thing as the global cache part but either will work. set the "ir receiver" to a static IP address.. program your remotes so they all use the exact same IR codes... connect EG to the IR receivers. Now when you press a button on the remote say in room A an event shows up in EG saying that ian ir code from say 192.168.1.1 was received..... now walk into room B and press the same button.. guess what the event is going to be... it's going to be an event with the ip address for that room and the same ir code that was pressed in room A. This is how you know what devices to control. This is the way you keep the entire system uniform no matter the brand of TV or AVR or even if the device is a projector and not a TV. if you press the button to turn the TV off it is going to turn off whatever device you have set to display video in that room. if a room does not have an AVR or the AVR is not turned on.. the remote will set the TV volume instead when you press volume up and down. No need to do anything!

press the power button once to turn the TV on.. press and hold it to turn the whole system on ... (button shifting).. SWEEEEEET!

Now that's a trick the wife would be ticked to death over.. and you would as well (not having to hear the wife ask over and over again how to use the remote)
If you like the work I have been doing then feel free to Image

User avatar
kgschlosser
Site Admin
Posts: 5020
Joined: Fri Jun 05, 2015 5:43 am
Location: Rocky Mountains, Colorado USA

Re: Z-Wave

Post by kgschlosser » Tue Sep 17, 2019 8:12 am

and since you really like the remote control functionality of EG.. Here is the remote you want.
https://www.amazon.com/One-All-OARUSB04 ... B00HNIHM5S


12.00 USD for that remote. It is hands down the most durable remote I have ever seen. it weighs more then a typical remote of the same size with batteries when it has no batteries in it. that remote can literally be thrown on the ground and picked up and still function (without having to reassemble... errr tape it back together). that remote is branded "One4All" it is actually made by Universal Remote Control (URC) and that company makes super high end remote controls.

It uses the JP1 protocol... What this means is... If you can't hack it you don't own it. Remote Master is the software to use to "program" (more like injecting it with steroids). This is the software that will unlock all of the potential. You can even deign your own IR protocol if you wanted to.. ever use the 4 digit codes to program a device to a remote.. ever notice that 30% of the buttons on the remote end up not being used and the features you want are not available on the remote.. That goes bye bye if you use that software to program the remote.

BONUS 1: it has almost 400 usable buttons between normal, shifting and long press
BONUS 2: has the ability to have macros programmed to a button (that means they can shoot more then one code with a single press)
BONUS 3: button shifting! doubles the number of physical buttons.
BONUS 4: long press. shots a different code when the button is held down.
BONUS 5: rolling codes... program every single input/source ir code into a single button. it will cycle through them with repeated presses of the button.
BONUS 6: it's backlit.. and when i say it's backlit i do not mean that the buttons you don't use are backlit (typical remote back lighting) this remote has the proper kind of back lighting, ALL of the buttons are backlit.
BONUS 7: Program ANY IR code for ANY IR protocol to ANY button.. so you want to do a little mix and match.. have the volume buttons control the AVR and the channel button control the cable box have the input buttons change the source on the TV.. all without having to change the "device" the remote is controlling.

for 12.00 dollars.... makes you want to buy one just to see what i am blubbering on about.
If you like the work I have been doing then feel free to Image

SimonB
Posts: 23
Joined: Mon Jul 29, 2019 2:04 pm

Re: Z-Wave

Post by SimonB » Tue Sep 17, 2019 2:32 pm

LOL - I know what you mean!

Home automation is not being able to control your heating from your phone. Home automation is not having to think about your heating at all because it does it automatically. And if it needs to know something, you tell it a simple thing like "I'm going to be at home tomorrow" or "we have guests for the weekend" and it does everything else like heat up my office, heat the kitchen at lunchtime as well as for breakfast, heat the guest rooms etc AUTOMATICALLY! Most "smart" heating controls are anything but.

I've been aware of Eventghost for some time but only got into it recently because of my AV setup needs. I'm getting more into it each week and really appreciating what you are doing Kevin.

User avatar
kgschlosser
Site Admin
Posts: 5020
Joined: Fri Jun 05, 2015 5:43 am
Location: Rocky Mountains, Colorado USA

Re: Z-Wave

Post by kgschlosser » Tue Sep 17, 2019 11:32 pm

no worries m8. if there is anything I can help you with let me know. remember EG is not just limited to controlling hardware and software. It can draw full OSD menu systems handle real time streaming for security cameras and traffic cameras. There is a HUGE amount that EG can do. One of these days I will actually get everything back up and going again at my house. I am int he middle of a multi year renovation. I have the 3 best workers they do the highest quality work. but they are slower then shit. they are My, Myself and I. :shock: :lol: I am finally to the point of doing alot of finish type work, wood floors, trim, painting.. I have 1 HUGE project left on the house. I have to replace a 30x24 gable end wall it's rotten inside. this happened because of a porch roof that was added. and that has to come down also. the bitch is it.s between the second and 3rd floors of the house. and the gable end wall is the second and what would be the 3rd story (vaulted ceiling). No easy task. My only saving grace is that the house is a gabrel so the roof is almost self supporting. I have to make sure i tie the 2 side walls together with a large cable so they won't push out. but the ridge of the roof shouldn't move when i take the gable wall out if i do that. so my home automation is in shambles..
If you like the work I have been doing then feel free to Image

User avatar
kgschlosser
Site Admin
Posts: 5020
Joined: Fri Jun 05, 2015 5:43 am
Location: Rocky Mountains, Colorado USA

Re: Z-Wave

Post by kgschlosser » Tue Oct 01, 2019 10:59 pm

I did want to let you folks know that I am working on this..
It's a huge project involving a handful of people.

with all components involved it is close to 200,000 lines of code so there is a whole lot to test and bug fix.
If you like the work I have been doing then feel free to Image

piert
Experienced User
Posts: 315
Joined: Tue Jun 14, 2011 2:53 pm

Re: Z-Wave

Post by piert » Wed Oct 02, 2019 8:45 am

kgschlosser wrote:
Tue Sep 17, 2019 8:12 am
and since you really like the remote control functionality of EG.. Here is the remote you want.
https://www.amazon.com/One-All-OARUSB04 ... B00HNIHM5S
Kevin, is it possible to copy the entire learned contents of the remote to another one (like you can with Logitech's remotes)?

Edit: never mind, found the answer in the comments of the referred Amazon product page:
This is a JP1 remote so there is a lot of support for it out there on forums and by enthusiasts. Also you can plug it into your PC and copy the settings.bin file off, as a backup. So you can buy another of this model of remote, and transfer the settings.bin file, and all of your custom remote commands will just start working on the second remote.

Cons? Not all buttons are backlit, the OK, direction ring buttons, and the pause button, are not backlit, but since all the others are, you know where everything is. Of course your fingers get used to where all the buttons are after a few days of use anyway. Also, the direction ring buttons are kind of thin and right next to the OK button, so at first you really have to feel for these buttons. But again, after a few days of use, it's a non-issue.

These cons are not enough for me to knock off a star, given that this is a backlit, learning remote, for under $20. You can't really expect more.
Interesting to note that the commenter mentions that not all of the buttons are backlit (but also that it is not a big issue).
Thanks for the tip, Kevin. My livingroom Logitech remote's keys are dying and I will consider this as a replacement!

User avatar
kgschlosser
Site Admin
Posts: 5020
Joined: Fri Jun 05, 2015 5:43 am
Location: Rocky Mountains, Colorado USA

Re: Z-Wave

Post by kgschlosser » Sat Oct 05, 2019 8:02 am

There are more then a single version of that same remote. It could be the one that is on the amazon page is not the identical one to mine. But it will have the JP connector under the battery cover. it is going to already be a USB so no buying of special cables is going to be needed. If you open up the batter cover on any remote if you see a 6 pin header and it is labeled as JP1 then you can use the Remote Master software to hack the remote but you will need a special cable to do so. and you can order it from the makers of Remote Master.

I would have to check my remote I can swear that all of the buttons light up on it.. Maybe I made a mistake... I wonder if it is the device buttons that possibly do not light up as these buttons I have no use for because EG automatically changes what to control based on what is turned on and what room I am on. so I only use a single "set" of buttons. I do have some of them that are shifted or are macro buttons. I also have long presses set on a few of them as well.

I do not like having to remember what a hole second layer of buttons do. hence the reason why I have EG handle all of that.. So in my Media room if the TV is on and the AVR is on when I press the volume up and down it is going to change the volume on the AVR. if I turn the AVR off then when i press volume up or down it is going to change the volume on the TV.. I do not have to do anything for this to work. If I have the AVR on and the source is set to FM radio when i press the channel up and down it changes the station on the AVR. if the AVR is set to Cable TV and the TV is also on then the channel up and down are going to change the cable station. Buttons will automatically change control also if say I press the menu button a single time. this will bring up the setting for the TV. If i long press it it will bring up the setting for the AVR. and the buttons will change according to that as well.

You can create some really elaborate remote setups with EG..
If you like the work I have been doing then feel free to Image

User avatar
kgschlosser
Site Admin
Posts: 5020
Joined: Fri Jun 05, 2015 5:43 am
Location: Rocky Mountains, Colorado USA

Re: Z-Wave

Post by kgschlosser » Sat Oct 05, 2019 8:06 am

I jusr ran and grabbed one of my remotes.. and that user is right.. there is a ring that has 4 buttons that does not light up.. I never noticed it.. But to be honest because all of the rest of the buttons light up it is not a problem seeing the ring. and also as the user had stated you get used to it.. and very quickly because the buttons form a complete circle. so knowing where the 4 positions are is easy to know by feel. I don't have to look at the remote to know where buttons are.. feel works for me. But it is nice if you want to read something in a dim lit room. they are bright enough to be able to do that .. LOL
If you like the work I have been doing then feel free to Image

piert
Experienced User
Posts: 315
Joined: Tue Jun 14, 2011 2:53 pm

Re: Z-Wave

Post by piert » Sat Oct 05, 2019 1:26 pm

Thanks for the feedback! The exact model of this brand appears not to be available where I live (The Netherlands), so I will do some more digging around to find the best alternative.

User avatar
kgschlosser
Site Admin
Posts: 5020
Joined: Fri Jun 05, 2015 5:43 am
Location: Rocky Mountains, Colorado USA

Re: Z-Wave

Post by kgschlosser » Tue Oct 22, 2019 4:25 pm

if you want one or more let me know. I will order the thing and send it to you...
If you like the work I have been doing then feel free to Image

User avatar
kgschlosser
Site Admin
Posts: 5020
Joined: Fri Jun 05, 2015 5:43 am
Location: Rocky Mountains, Colorado USA

Re: Z-Wave

Post by kgschlosser » Mon Dec 02, 2019 6:49 am

I am still crunching away on this folks.

I decided to drop using OpenZwave . There are large portions of the ZWave API Specification that is not added or is being handled incorrectly by OpenZwave and the author does not want to correct the incorrect parts and also does not want to add the missing bits to some of the device control because "it is to much work and doesn't see it as an important feature". One specific feature I want to have is this..

The specification for multilevel switches has a command to start the light changing in a direction up or down and then another command to stop it. It has several options but the 2 that are most important are speed and increment size. The thing is in order to have an application able to use these command correctly I would need to know the exact time when the command to start the change is sent and I also need to be able to inject the command to stop it to be the next command sent.. You have to utilize a send queue when working with ZWave because some of the commands being executed can take a while to complete. so if there are 10 commands ahead of the command to start the change I need to know when it gets sent.. OpenZwave does not provide this ability.. so If I wanted to dim the lights slowly over a 2 minute duration if the command does not get sent until a minute after I told OpenZwave to send it then I will be stopping the ramp when it has only run for a minute. thus not getting the light to the correct level.. the other thing is if I send the command and during that 2 minutes a bunch of other commands get queued when I want to stop the change it is not going to get stopped when it is supposed to because it has to wait for all of the other commands to get carried out first. This would overshoot the target light level.. again not the desired outcome.

I also dropped using it because python-openzwave is a dying library. I was the only one working on it. There is another HA application that uses it and the author of that application expects people to make the library work with his application instead of making the application work with the library. The users and also the developers were driving me crazy having to code around problems in the app.. so I said.. F@&$ this bunch of donkey dung.
I have learned a tremendous amount about the ZWave Specification while I was rewriting python-openzwave. The specification documentation kind of stinks and it is hard to follow it because it is spread across a grip of files and all of the file are not in a single place or a single download. so it is quite a bit of hunting to locate the information.

I have been chatting with Silabs and getting information from them and also making them aware of documentation problems along with problems in the specification. I am pretty sure there are going to be some changes being made in the next couple of revisions of it.

The other thing that puts a hair across my ass is that it seems that no one has written a complete ZWave engine. Or a correctly functioning one either. Now I know there is bound to be problems, but there are more problems caused by bad planning and design then anything else. and you couple that with the issues not getting fixed because "it's to much work" really gets me fired up.

So Now I am in about 140,000 lines of code into writing a complete engine. I have all of the structures coded and the serial communications done, I also have the public portions of the engine complete as well. I now have to bring them together. I have alot of confidence in myself and I am fairly certain it is going to be the fastest ZWave engine made. I am pretty sure it is also going to be the most stable one as well

I am writing it in python but I am going to compile it into c++ DLL this way I can get speed in the execution of the code. Plus I do not think I am going to publicly release the source code. I might release the DLL so it can be used.

The end game is it is still going to be a while until I am done. once I get it running I will need some folks that are willing to bug test the thing for me.. Let me know if you are willing I would appreciate the help in that department.
If you like the work I have been doing then feel free to Image

Post Reply