How to trigger expert commands from an external application - zway.SendData ?

Discussions about Z-Way software and Z-Wave technology in general
Post Reply
judge
Posts: 4
Joined: 09 Nov 2019 15:13

How to trigger expert commands from an external application - zway.SendData ?

Post by judge »

Hi,
I'm running a z-way-server (version 3.0) on a raspberry pi. Everything works fine. I have besides many other z-wave devices a Devolo Siren (https://www.cd-jackson.com/index.php/zw ... ummary/453) which can play multiple sounds. I can play the different sounds in the expert UI (http://[ip]:8083/expert) by using CommandClass "Basic" using the different "Dimmer level" (1, 2, 3, 4), etc. but I can't do this from the "normal" UI (http://[ip]/smarthome)... as I only have 3 "views" in the normal UI: One on/off switch and 2 read-only views... The on/off switch always plays the same sound all the time...

My problem is now that I would like to integrate the different sounds in openhab but I noticed that there I only get the same items as in the normal UI, i.e. the 3 views....

My question is now
1) Can anyone explain me how I can trigger different sounds from an external application like in the expert UI?
2) In viewtopic.php?f=3422&t=24471 it is suggested to use zway.SendData. How can I call this (from the command line it is not available) so I guess it is a library I have to integrate in some sort of programming language? Can anyone explain it?
3) Is MQTT maybe an option?

Thanks.
enbemokel
Posts: 482
Joined: 08 Aug 2016 17:36

Re: How to trigger expert commands from an external application - zway.SendData ?

Post by enbemokel »

viewtopic.php?f=3422&t=24471#p72781

Here you find the CodeDevice hint, you should installthe module and try it.
I loaded it 5 times for 5 different sounds.
You may check the secure or unsecure command, this is unsecure
zway.SendData(44,[0x71,0x05,0x00,0x00,0x00,0x00,0xA,0x01,0x00,0x00])
judge
Posts: 4
Joined: 09 Nov 2019 15:13

Re: How to trigger expert commands from an external application - zway.SendData ?

Post by judge »

Thanks enbemokel,
I'm getting closer. Could you elaborate how to do it in the "secure" way, please? Below is the network queue if I trigger the command via "Expert command", so it seems that by default it uses security
Queue length: 5

Code: Select all

n	U	W	S	E	D	Ack	Resp	Cbk	Repl	Timeout	NodeId	Description	Progress	Buffer
3					D	+	+	+		9.85	3	Security, Basic Set	Response received - transfered to encapsulated jobs
												Callback received - transfered to encapsulated jobs
												Delivered	3 ... 25
2					D	+	+	+		10.22	3	Security, Basic Get	Response received - transfered to encapsulated jobs
												Callback received - transfered to encapsulated jobs
												Delivered	3 ... 25
1					D	+	+	+		10.42	3	Nonce Report	Delivered	3 ... 25
1					D	+	+	+		10.70	3	Security, Basic Get	Response received - transfered to encapsulated jobs
												Callback received - transfered to encapsulated jobs
												Delivered	3 .... 25
1					D	+	+	+		10.91	3	Nonce Report	Delivered	3 ... 25 
Legend
n = Send count, W = Wait wakeup, S = Wait security, E = Encapsulated, D = Done, U = Urgent

So, either I have to use zway.SendDataSecure or maybe I can disable the security?

Thanks.
enbemokel
Posts: 482
Joined: 08 Aug 2016 17:36

Re: How to trigger expert commands from an external application - zway.SendData ?

Post by enbemokel »

Yes, zway.SendDataSecure should work in your enviroment. There is no need to change to unsecure.
Just try my command in module code device and change the 44 to your 3 like this. It´s the door bell.

zway.SendDataSecure(3,[0x71,0x05,0x00,0x00,0x00,0x00,0x06,0x16,0x00,0x00])

In module i use toogleButton.
judge
Posts: 4
Joined: 09 Nov 2019 15:13

Re: How to trigger expert commands from an external application - zway.SendData ?

Post by judge »

Thanks again enbemokel , very much appreciated.
I use also the toggleButton. When I press it I get the following:

Code: Select all

0			S			-	-	-		0.20	3	Alarm		3 a 71 5 0 0 0 0 6 16 0 0 25
1					D	+	+	+	+	0.15	3	Nonce Get	Delivered	3 2 98 40 25 
However, the siren does not make any sound.
Note that

Code: Select all

0			S			-	-	-		0.20	3	Alarm		3 a 71 5 0 0 0 0 6 16 0 0 25 
Stays for a long time while the Nonce Get disappears quickly
enbemokel
Posts: 482
Joined: 08 Aug 2016 17:36

Re: How to trigger expert commands from an external application - zway.SendData ?

Post by enbemokel »

Here is another c&p from the other thread. maybe you can check this also.
Just another hint, I´m using a d-link siren, which is equal to the philio siren. I remember when I searched
about my issue, I found somewhere in another german forum "fhem" a description for the devolo. There was something
different.
But, as you can get your different sounds via expert menu, it may be just a simple command.
Maybe @polto can help better (for sure :-)


Oh, one more idea. Did you check in configuration tab that the 4 is set to 0?
Nº 7 - Customer Function
(0) ---
(1) ---
(2) ---
(3) ---
(4) Notification Type, 0: Using Notification Report. 1: Using Sensor Binary Report.
(5) ---
(6) ---
(7) ---
judge
Posts: 4
Joined: 09 Nov 2019 15:13

Re: How to trigger expert commands from an external application - zway.SendData ?

Post by judge »

Thanks @enbemokel, I checked everything also the Notification Report bit. I did not get it to work. I even reset the Siren completely and tried again, no success... Now I don't even get the different sounds any longer using the "Dimmer level" of the Basic command class. No matter what I write there, it is always set to 255.
Post Reply