Z-Wave Raw Commands?

Posted on
Sat Oct 27, 2018 7:00 am
autolog offline
Posts: 3988
Joined: Sep 10, 2013
Location: West Sussex, UK [GMT aka UTC]

Z-Wave Raw Commands?

In the Indigo documentation, in the section Z-Wave hooks and improvements, it shows the following detail:
Code: Select all
# Send a Z-Wave command
indigo.zwave.sendRaw(device,        # device arg is optional - if not specified you must specify a nodeId
               nodeId,              # optional - if not specified you must specify a device
               endpoint,            # optional - if a nodeId is specified and supports multiple endpoints
               cmdBytes,
               sendMode,            # 0: immediate, 1: immediate first, if no ACK wait for wake, 2: wait for wake
               waitUntilAck         # defaults to True if not specified
There is no example code to show how to format the call. I am unclear as to how you skip past the optional fields. The various things I have tried have not resulted in success. :|

All the various calls in that section could do with specific examples. :wink:

Some guidance would be much appreciated. :)

Posted on
Sat Oct 27, 2018 7:04 am
FlyingDiver offline
User avatar
Posts: 7217
Joined: Jun 07, 2014
Location: Southwest Florida, USA

Re: Z-Wave Raw Commands?

In Python, if you want to skip parameters, you have to name anything after that.

Code: Select all
cmdString = "XYZ"
indigo.zwave.sendRaw(myDevice, cmdBytes = cmdString, sendMode = 0, waitUntilAck = False)

or

Code: Select all
cmdString = "XYZ"
indigo.zwave.sendRaw(nodeId = 4, cmdBytes = cmdString, sendMode = 0, waitUntilAck = False)

joe (aka FlyingDiver)
my plugins: http://forums.indigodomo.com/viewforum.php?f=177

Posted on
Sat Oct 27, 2018 8:49 am
autolog offline
Posts: 3988
Joined: Sep 10, 2013
Location: West Sussex, UK [GMT aka UTC]

Re: Z-Wave Raw Commands?

Thanks Joe :D

My test code looks like this:
Code: Select all
# Send a Z-Wave command - open valve to 50%
cmdString = [0x26, 0x01, 0x32]
indigo.zwave.sendRaw(device = dev, cmdBytes = cmdString, sendMode = 1) 
Thanks again for your help :)

Posted on
Fri Mar 27, 2020 3:54 pm
dduff617 offline
Posts: 660
Joined: Jul 05, 2006
Location: Massachusetts, USA

Re: Z-Wave Raw Commands?

anyone know how to see the results returned from the z-wave command? does that make sense for this function? ... i recall you could get these from indigo.sendRawExtended command using the replyBytes property of the returned result.

Posted on
Fri Mar 27, 2020 4:28 pm
matt (support) offline
Site Admin
User avatar
Posts: 21417
Joined: Jan 27, 2003
Location: Texas

Re: Z-Wave Raw Commands?

Unfortunately, for Z-Wave commands the replies are broadcast back asynchronously (except the ACK), so the only way to catch them would be in a plugin that defines the callback to receive all Z-Wave commands. Extended Insteon commands are different and the Indigo Server is able to send those replies to the caller.

Image

Page 1 of 1

Who is online

Users browsing this forum: No registered users and 5 guests