Zwave Object

From Hubitat Documentation
Revision as of 17:38, 11 January 2019 by Mike.maxwell (talk | contribs) (getCommand)
Jump to: navigation, search

Description

Description goes here

Methods

getCommand

Returns a zwave object given the commandClass, command and an optional version.

Signature

Command getCommand(Short commandClass, Short command, List<Short> payload, Integer version = null)

Parameters

commandClass - TODO
TODO

Returns

Command - TODO

Example

def zwaveEvent(hubitat.zwave.commands.crc16encapv1.Crc16Encap cmd) {
   def encapsulatedCommand = zwave.getCommand(cmd.commandClass, cmd.command, cmd.data,1)
   if (encapsulatedCommand) {
       zwaveEvent(encapsulatedCommand)
   } else {
       log.warn "Unable to extract CRC16 command from ${cmd}"
   }
}