Page 1 of 2

Load custom JavaScript code

Posted: 01 Jan 2016 01:39
by markolbert
I am trying to build a module which transmits RazBerry event to another app, via UDP. I cannot figure out how to load code into the z-way-server so it gets included when the server starts.

Wandering around the new UI, I noticed you can add a custom javascript app. It apparently defines an instance of CustomUserCodeZWay, which I presume gets instantiated when the server starts.

But the first field in specifying the code declares:
Z-Way instance for which execute your code:
It's a dropdown, but it has no content, and you can't type anything in the dropdown area.

What is this, and how do I define it?

Re: Load custom JavaScript code (UDP send)

Posted: 01 Jan 2016 15:24
by pz1
@markolbert
In follow-up of your PM, I did find this post that might serve as a starting point:
viewtopic.php?f=3422&t=20816&hilit=zwav ... =10#p53478

Unfortunately the thread ends there. I don't know if the example works. You may consider to continue the discussion there

Re: Load custom JavaScript code

Posted: 06 Jan 2016 14:14
by Velouria
I think he means this problem in the attached image:
Selection_999(002).jpg
Selection_999(002).jpg (90.85 KiB) Viewed 20371 times
I'm also not to sure what to do here, and as a result, I can't get any JS code in the boxes below to run.

Re: Load custom JavaScript code

Posted: 06 Jan 2016 15:03
by pz1
My remark to Markolbert was only a response on an earlier exchange of Personal Messages related to his first sentence.

I assume you are running the latest Z-Way release 2.2.0. On my test rig I have the same. I encounter the same problem as you do.

V2.20 is a very problematic release with many issues. Unfortunately developers stopped answering user feedback some three weeks ago.

Re: Load custom JavaScript code

Posted: 06 Jan 2016 15:45
by Velouria
So glad to hear this - I was beginning to think it was just me.

Seriously considering going back to Domoticz again.

Re: Load custom JavaScript code

Posted: 06 Jan 2016 15:54
by remoticz
Velouria wrote:Seriously considering going back to Domoticz again.
Can't blame you :(

Re: Load custom JavaScript code

Posted: 07 Jan 2016 00:51
by bogr
Velouria wrote: Seriously considering going back to Domoticz again.
So you've been running Domoticz before? Why did you switch - just curious? Could you just write down some pros and cons - comparing those two? A bit off topic, but would be nice to hear about your practical experience :geek:

Re: Load custom JavaScript code

Posted: 07 Jan 2016 03:14
by PoltoS
Hello. This particular module is new and there was a problem between backen developer (me) and UI developers, where a problem was not fixed before releasing this module. We will fix it very soon.

Re: Load custom JavaScript code

Posted: 08 Jan 2016 06:29
by Plainsane
bogr wrote:
Velouria wrote: Seriously considering going back to Domoticz again.
So you've been running Domoticz before? Why did you switch - just curious? Could you just write down some pros and cons - comparing those two? A bit off topic, but would be nice to hear about your practical experience :geek:
7es I'm interested as well. Considering jumping ship as I,need things like ifttt and want thinks like geofencing

Re: Load custom JavaScript code

Posted: 08 Jan 2016 15:13
by Velouria
bogr wrote:
Velouria wrote: Seriously considering going back to Domoticz again.
So you've been running Domoticz before? Why did you switch - just curious? Could you just write down some pros and cons - comparing those two? A bit off topic, but would be nice to hear about your practical experience :geek:
Domoticz is awesome, but the openzwave library is its weakness. Response times can be a little slow (several seconds to turn on a light etc). I'm keen to see if that has improved.

The upside is a very passionate core development group that are always willing to help out. And then there is the open source aspect - if you're brave enough, you can always modify/fix/improve the code yourself. The documentation is decent and current, and the community is quite helpful.

Automation was easy using Google's Blocky for beginners, or Lua for more advanced functionality.

And it integrates with pretty much anything.

The downsides - the UI looks a little dated, it's quite a learning curve at first, and it means dumping what ever you have in z-way to make the switch.