Please provide your hub model (C7, C8, etc.) and its platform version from Settings>Hub Details.
Check out the following post for help troubleshooting problems and gathering details that will help others to identify and solve the problem you are experiencing: ‼ READ FIRST - Before Posting in Get Help
Hubitat Aeotec Smart Switch 7 (ZWA023-A) LED Color-Control Issue
This diagnostic summary was prepared by ChatGPT (OpenAI) after troubleshooting the issue with the me. I performed the tests described below and supplied the resulting Hubitat logs. The temporary diagnostic driver included at the end of this report was generated by ChatGPT for the purpose of isolating the problem.
Since all I wanted to do is change the LED color once, the temporary driver works for that purpose. However, overall, users wanted to set the LED color are not able to do so, limiting the use of the device with the current driver issue.
Environment
-
Hub: Hubitat Elevation C-8 Pro
-
Hubitat platform: 2.5.1.183
-
Z-Wave firmware: 7.18.1
-
Z-Wave JS: 15.26.0
-
Device: Aeotec Smart Switch 7
-
Model: ZWA023-A
-
Device firmware: Latest/current Aeotec firmware
-
Hubitat driver: Built-in
Aeotec Smart Switch 7
The issue has been observed on multiple ZWA023-A devices.
Problem
Hubitat's built-in Aeotec Smart Switch 7 driver creates the expected LED child device.
The LED child advertises these capabilities:
Actuator
ChangeLevel
ColorControl
Light
Refresh
Switch
SwitchLevel
Initially the LED child did not respond to On/Off commands. Running Configure on the parent device corrected that issue.
After configuration:
-
LED On/Off works.
-
LED Set Level/brightness works.
-
LED Set Color does not work.
-
Color commands issued from a Hubitat automation also do not work.
For example, debug logging from the built-in LED child shows that it receives color requests such as:
setColor([hue:0, level:100, saturation:100])
setColor([hue:17, level:100, saturation:100])
but the physical LED color does not change.
In contrast, Set Level works and results in the expected physical change and report, for example:
setLevel(null)
Attic-TV Lamp - LED level was set to 10%
This suggested that communication with the LED endpoint was functional but that the problem was specific to Color Switch commands.
Direct Z-Wave Test
To distinguish a Hubitat built-in-driver problem from an Aeotec hardware/firmware problem, ChatGPT generated the temporary diagnostic driver included below.
The diagnostic driver sends Z-Wave Switch Color Set (Command Class 0x33) directly to Multi Channel Endpoint 2, explicitly setting the RGB components:
Component 2 = Red
Component 3 = Green
Component 4 = Blue
For example, green is sent as:
Red = 0
Green = 255
Blue = 0
This worked.
The physical LED immediately changed to green.
Equivalent direct commands for red and blue also worked correctly.
More importantly, the ZWA023-A itself subsequently reported the requested RGB values from Endpoint 2. For the green test, Hubitat received:
Color component 2 = 0
Color component 3 = 255
Color component 4 = 0
The underlying Z-Wave JS information likewise identified these as reports from:
commandClassName: "Color Switch"
endpoint: 2
propertyName: "currentColor"
For example, the Green report contained:
propertyKey: 3
propertyKeyName: "Green"
endpoint: 2
propertyName: "currentColor"
value: 255
The Blue report after switching to green contained:
propertyKey: 4
propertyKeyName: "Blue"
endpoint: 2
propertyName: "currentColor"
value: 0
Therefore, the test demonstrates that:
-
The ZWA023-A RGB LED hardware works.
-
The device firmware accepts Switch Color commands.
-
Hubitat/Z-Wave JS can communicate successfully with Color Switch CC on Endpoint 2.
-
Multi Channel encapsulated Switch Color Set commands addressed directly to Endpoint 2 successfully change the physical LED.
-
The ZWA023-A reports the resulting RGB values back to Hubitat.
-
The failure appears limited to the
ColorControlimplementation used by Hubitat's built-inAeotec Smart Switch 7driver/LED child.
The fact that the built-in driver successfully controls LED On/Off and SwitchLevel further suggests that the LED child and endpoint communication are generally functional.
Request to Hubitat
Could Hubitat engineering please examine how the built-in Aeotec Smart Switch 7 driver implements the LED child's setColor() command under Z-Wave JS?
In particular, it may be useful to compare the driver's generated command/encapsulation with a SwitchColorSet containing RGB components 2, 3, and 4 sent via Multi Channel encapsulation to Endpoint 2.
That direct method has been verified on the same device and Z-Wave network to work correctly.
Temporary Diagnostic Driver
The following is the ChatGPT-generated diagnostic driver used for the successful test.
/*
* Aeotec ZWA023-A Smart Switch 7 - LED Diagnostic Driver
*
* TEMPORARY TEST DRIVER
*
* Generated by ChatGPT for diagnosis of Hubitat built-in
* driver LED color-control behavior.
*
* Sends Switch Color commands directly to Endpoint 2.
*/
metadata {
definition(
name: "Aeotec ZWA023 LED Test",
namespace: "diagnostic",
author: "ChatGPT / OpenAI"
) {
capability "Actuator"
capability "Refresh"
command "ledRed"
command "ledGreen"
command "ledBlue"
command "ledWhite"
command "ledOff"
command "getRed"
command "getGreen"
command "getBlue"
}
}
preferences {
input name: "debugLogging",
type: "bool",
title: "Enable debug logging",
defaultValue: true
}
/*
* -------------------------------------------------------
* Commands
* -------------------------------------------------------
*/
void ledRed() {
logDebug("LED RED: R=255 G=0 B=0")
sendRGB(255, 0, 0)
}
void ledGreen() {
logDebug("LED GREEN: R=0 G=255 B=0")
sendRGB(0, 255, 0)
}
void ledBlue() {
logDebug("LED BLUE: R=0 G=0 B=255")
sendRGB(0, 0, 255)
}
void ledWhite() {
logDebug("LED WHITE: R=255 G=255 B=255")
sendRGB(255, 255, 255)
}
void ledOff() {
logDebug("LED OFF: R=0 G=0 B=0")
sendRGB(0, 0, 0)
}
/*
* Z-Wave Color Component IDs:
*
* 2 = Red
* 3 = Green
* 4 = Blue
*/
void getRed() {
sendColorGet(2)
}
void getGreen() {
sendColorGet(3)
}
void getBlue() {
sendColorGet(4)
}
/*
* -------------------------------------------------------
* Z-Wave
* -------------------------------------------------------
*/
private void sendRGB(Integer red, Integer green, Integer blue) {
def colorCommand =
zwave.switchColorV3.switchColorSet(
colorComponents: [
2: red,
3: green,
4: blue
]
)
def endpointCommand =
zwave.multiChannelV4.multiChannelCmdEncap(
destinationEndPoint: 2
).encapsulate(colorCommand)
logDebug("Sending to Endpoint 2: ${endpointCommand}")
sendHubCommand(
new hubitat.device.HubAction(
zwaveSecureEncap(endpointCommand),
hubitat.device.Protocol.ZWAVE
)
)
}
private void sendColorGet(Integer component) {
def colorCommand =
zwave.switchColorV3.switchColorGet(
colorComponentId: component
)
def endpointCommand =
zwave.multiChannelV4.multiChannelCmdEncap(
destinationEndPoint: 2
).encapsulate(colorCommand)
logDebug("GET component ${component} from Endpoint 2")
sendHubCommand(
new hubitat.device.HubAction(
zwaveSecureEncap(endpointCommand),
hubitat.device.Protocol.ZWAVE
)
)
}
/*
* -------------------------------------------------------
* Incoming Z-Wave
* -------------------------------------------------------
*/
void parse(String description) {
logDebug("RX raw: ${description}")
def cmd = zwave.parse(
description,
[
0x33: 3, // Switch Color
0x60: 4, // Multi Channel
0x98: 1, // Security
0x9F: 1 // Security 2
]
)
if (cmd) {
logDebug("RX parsed: ${cmd}")
zwaveEvent(cmd)
}
}
void zwaveEvent(
hubitat.zwave.commands.multichannelv4.MultiChannelCmdEncap cmd
) {
logDebug(
"MultiChannel report from endpoint ${cmd.sourceEndPoint}"
)
def encapsulated = cmd.encapsulatedCommand([
0x33: 3
])
if (encapsulated) {
logDebug("Encapsulated: ${encapsulated}")
zwaveEvent(encapsulated)
}
}
void zwaveEvent(
hubitat.zwave.commands.switchcolorv3.SwitchColorReport cmd
) {
log.info "${device.displayName}: Color component " +
"${cmd.colorComponentId} = ${cmd.value}"
logDebug(
"Color report: component=${cmd.colorComponentId}, " +
"value=${cmd.value}, target=${cmd.targetValue}"
)
}
void zwaveEvent(hubitat.zwave.Command cmd) {
logDebug("Unhandled Z-Wave command: ${cmd}")
}
void refresh() {
logDebug("Reading RGB components")
getRed()
pauseExecution(250)
getGreen()
pauseExecution(250)
getBlue()
}
private void logDebug(String msg) {
if (debugLogging != false) {
log.debug "${device.displayName}: ${msg}"
}
}
Test Procedure Used
For completeness, the successful test was performed by temporarily changing one ZWA023-A parent device from Hubitat's built-in Aeotec Smart Switch 7 driver to the diagnostic driver above.
No exclusion, inclusion, factory reset, or other Z-Wave network change was performed.
The LED Red, LED Green, and LED Blue commands were tested. Each caused the corresponding physical LED color change.
The RGB GET commands also returned the corresponding Color Switch reports from Endpoint 2.
After testing, the device can simply be returned to Hubitat's built-in Aeotec Smart Switch 7 driver and Configure run again.
This provides a reproducible comparison between the built-in driver's failing setColor() path and a direct Endpoint 2 SwitchColorSet implementation that works on the same hardware.