I'm attempting to port the ST Mitch Pond Keypad DTH to HE. I use my keypads for things other than arming, and AFAIK that is not supported on HE. I want to finish converting from ST, and keypads are my last devices to cut over. I plan using the keypads with a remnant of my ST SHM Delay smartapp.
My ZigBee hardware message understanding is about 0. I found HE examples on Github and followed them, but nada. The commands look the same but the device does not respond.
Perhaps someone who understands this more than me can give me a clue about what I'm doing wrong. Tagging: @mike.maxwell
Aside from the getting rid of tiles, I changed the message sending as follows:
def results = cmds?.collect{ new physicalgraph.device.HubAction(it)};
to
def results = cmds?.collect{ new hubitat.device.HubAction(it,hubitat.device.Protocol.ZIGBEE) };
He Code
private sendRawStatus(status, secs = 00) {
def seconds=secs as Integer
logdebug "sendRawStatus info ${zigbee.convertToHexString(status,2)}${zigbee.convertToHexString(seconds,2)} to device..."
// Seems to require frame control 9, which indicates a "Server to client" cluster specific command (which seems backward? I thought the keypad was the server)
List cmds = ["raw 0x501 {09 01 04 ${zigbee.convertToHexString(status,2)}${zigbee.convertToHexString(seconds,2)}}",
"send 0x${device.deviceNetworkId} 1 1", 'delay 100']
def results = cmds?.collect{ new hubitat.device.HubAction(it,hubitat.device.Protocol.ZIGBEE) };
logdebug "sendRawStatus results"+results
return results
}
ST Code
private sendRawStatus(status, seconds = 00) {
log.debug "sendRawStatus info ${zigbee.convertToHexString(status)}${zigbee.convertToHexString(seconds)} to device..."
// Seems to require frame control 9, which indicates a "Server to client" cluster specific command (which seems backward? I thought the keypad was the server)
List cmds = ["raw 0x501 {09 01 04 ${zigbee.convertToHexString(status)}${zigbee.convertToHexString(seconds)}}",
"send 0x${device.deviceNetworkId} 1 1", 'delay 100']
def results = cmds?.collect { new physicalgraph.device.HubAction(it) };
log.debug "sendRawStatus results"+results
return results
}
HE trace
2019-04-10 07:49:45.189 debugParsing 'catchall: 0104 0501 01 01 0040 00 0B85 01 00 0000 07 00 '
2019-04-10 07:49:30.508 debugsendRawStatus results[raw 0x501 {09 01 04 0000}, send 0x0B85 1 1, delay 100]
2019-04-10 07:49:30.501 debugsendRawStatus info 0000 to device...
ST trace of similar device
8:01:18 AM: debug Parsing 'catchall: 0104 0501 01 01 0000 00 7397 01 00 0000 07 00'
8:01:14 AM: debug sendRawStatus results[raw 0x501 {09 01 04 0000}, send 0x7397 1 1, delay 100]
8:01:14 AM: debug sendRawStatus info 0000 to device...