From 52d781c605299c65f307ecb42c13686cd6f65487 Mon Sep 17 00:00:00 2001 From: Chris Jackson Date: Thu, 28 Feb 2019 22:10:13 +0000 Subject: [PATCH] Refactor to remove ZclCommandType enumeration Signed-off-by: Chris Jackson --- .../zigbee/autocode/ZigBeeCodeGenerator.java | 1 - .../ZigBeeZclCommandTypeGenerator.java | 188 -- ...ZigBeeConsoleCommandsSupportedCommand.java | 3 +- .../zigbee/ZigBeeNetworkManager.java | 42 +- .../zsmartsystems/zigbee/zcl/ZclCluster.java | 61 +- .../zcl/clusters/ZclCommissioningCluster.java | 43 +- .../zcl/clusters/ZclGeneralCluster.java | 609 ----- .../zigbee/zcl/protocol/ZclCommandType.java | 2042 ----------------- .../zigbee/ZigBeeNetworkManagerTest.java | 60 +- .../zcl/cluster/ZclAlarmsClusterTest.java | 16 +- .../zcl/cluster/ZclOnOffClusterTest.java | 10 +- .../clusters/ZclColorControlClusterTest.java | 37 +- .../zcl/clusters/ZclDoorLockClusterTest.java | 18 +- .../clusters/ZclPollControlClusterTest.java | 13 +- .../zcl/protocol/ZclCommandTypeTest.java | 72 - .../resource/logs/cluster-0500-IasZone.txt | 8 +- .../resource/logs/cluster-FFFF-General.txt | 24 +- .../src/test/resource/logs/zdo.txt | 34 +- 18 files changed, 242 insertions(+), 3039 deletions(-) delete mode 100644 com.zsmartsystems.zigbee.autocode/src/main/java/com/zsmartsystems/zigbee/autocode/ZigBeeZclCommandTypeGenerator.java delete mode 100644 com.zsmartsystems.zigbee/src/main/java/com/zsmartsystems/zigbee/zcl/clusters/ZclGeneralCluster.java delete mode 100644 com.zsmartsystems.zigbee/src/main/java/com/zsmartsystems/zigbee/zcl/protocol/ZclCommandType.java delete mode 100644 com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/zcl/protocol/ZclCommandTypeTest.java diff --git a/com.zsmartsystems.zigbee.autocode/src/main/java/com/zsmartsystems/zigbee/autocode/ZigBeeCodeGenerator.java b/com.zsmartsystems.zigbee.autocode/src/main/java/com/zsmartsystems/zigbee/autocode/ZigBeeCodeGenerator.java index 8422d22ae..360cc820b 100644 --- a/com.zsmartsystems.zigbee.autocode/src/main/java/com/zsmartsystems/zigbee/autocode/ZigBeeCodeGenerator.java +++ b/com.zsmartsystems.zigbee.autocode/src/main/java/com/zsmartsystems/zigbee/autocode/ZigBeeCodeGenerator.java @@ -119,7 +119,6 @@ public static void main(final String[] args) { new ZigBeeZclConstantGenerator(zclClusters, generatedDate, zclTypes); new ZigBeeZclStructureGenerator(zclClusters, generatedDate, zclTypes); new ZigBeeZclClusterTypeGenerator(zclClusters, generatedDate, zclTypes); - new ZigBeeZclCommandTypeGenerator(zclClusters, generatedDate, zclTypes); new ZigBeeZclDataTypeGenerator(dataTypes, generatedDate); new ZigBeeZclCommandGenerator(zdoClusters, generatedDate, zclTypes); diff --git a/com.zsmartsystems.zigbee.autocode/src/main/java/com/zsmartsystems/zigbee/autocode/ZigBeeZclCommandTypeGenerator.java b/com.zsmartsystems.zigbee.autocode/src/main/java/com/zsmartsystems/zigbee/autocode/ZigBeeZclCommandTypeGenerator.java deleted file mode 100644 index f1422b304..000000000 --- a/com.zsmartsystems.zigbee.autocode/src/main/java/com/zsmartsystems/zigbee/autocode/ZigBeeZclCommandTypeGenerator.java +++ /dev/null @@ -1,188 +0,0 @@ -/** - * Copyright (c) 2016-2019 by the respective copyright holders. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - */ -package com.zsmartsystems.zigbee.autocode; - -import java.io.File; -import java.io.IOException; -import java.io.PrintWriter; -import java.util.List; -import java.util.Map; -import java.util.TreeMap; - -import com.zsmartsystems.zigbee.autocode.xml.ZigBeeXmlCluster; -import com.zsmartsystems.zigbee.autocode.xml.ZigBeeXmlCommand; - -/** - * - * @author Chris Jackson (zsmartsystems.com) - * - */ -public class ZigBeeZclCommandTypeGenerator extends ZigBeeBaseClassGenerator { - - ZigBeeZclCommandTypeGenerator(List clusters, String generatedDate, - Map dependencies) { - this.generatedDate = generatedDate; - this.dependencies = dependencies; - - try { - generateZclClusterCommands(clusters, packageRoot, new File(sourceRootPath)); - } catch (IOException e) { - // TODO Auto-generated catch block - e.printStackTrace(); - } - } - - private void generateZclClusterCommands(List clusters, String packageRootPrefix, - File sourceRootPath) throws IOException { - - final String className = "ZclCommandType"; - - final String packageRoot = packageRootPrefix + packageZclProtocol; - final String packagePath = getPackagePath(sourceRootPath, packageRoot); - final File packageFile = getPackageFile(packagePath); - - final PrintWriter out = getClassOut(packageFile, className); - - Map commandEnum = new TreeMap<>(); - - outputLicense(out); - - importsClear(); - out.println("package " + packageRoot + ";"); - out.println(); - importsAdd("javax.annotation.Generated"); - importsAdd("java.lang.reflect.Constructor"); - importsAdd(packageRootPrefix + packageZcl + ".ZclCommand"); - importsAdd(packageRootPrefix + packageZclProtocol + ".ZclCommandDirection"); - - // Produce an ordered list of clusters/commands and add the imports... - for (final ZigBeeXmlCluster cluster : clusters) { - for (ZigBeeXmlCommand command : cluster.commands) { - importsAdd(getZclClusterCommandPackage(cluster) + "." + stringToUpperCamelCase(command.name)); - commandEnum.put(getZclClusterCommandPackage(cluster) + "." + stringToUpperCamelCase(command.name), - new CommandId(cluster, command)); - } - } - - outputImports(out); - out.println(); - - // outputClassJavaDoc(out, "Enumeration of ZigBee Cluster Library commands"); - outputClassGenerated(out); - out.println("public enum " + className + " {"); - boolean first = true; - for (CommandId commandId : commandEnum.values()) { - ZigBeeXmlCluster cluster = commandId.cluster; - ZigBeeXmlCommand command = commandId.command; - if (!first) { - out.println(","); - } - first = false; - - String commandType = stringToConstant(command.name); - String commandClass = stringToUpperCamelCase(command.name); - out.println(" /**"); - out.println(" * " + commandType + ": " + command.name); - out.println(" *

"); - out.println(" * See {@link " + commandClass + "}"); - out.println(" */"); - - out.print(" " + commandType + "(" + String.format("0x%04X", cluster.code) + ", " + command.code + ", " - + commandClass + ".class" + ", ZclCommandDirection." - + (command.source.equals("client") ? "CLIENT_TO_SERVER" : "SERVER_TO_CLIENT") + ")"); - } - out.println(";"); - out.println(); - - out.println(" private final int commandId;"); - out.println(" private final int clusterType;"); - out.println(" private final Class commandClass;"); - // out.println(" private final String label;"); - out.println(" private final ZclCommandDirection direction;"); - out.println(); - out.println(" " + className - + "(final int clusterType, final int commandId, final Class commandClass, final ZclCommandDirection direction) {"); - out.println(" this.clusterType = clusterType;"); - out.println(" this.commandId = commandId;"); - out.println(" this.commandClass = commandClass;"); - // out.println(" this.label = label;"); - out.println(" this.direction = direction;"); - out.println(" }"); - out.println(); - - out.println(" public int getClusterType() {"); - out.println(" return clusterType;"); - out.println(" }"); - out.println(); - out.println(" public int getId() {"); - out.println(" return commandId;"); - out.println(" }"); - out.println(); - // out.println(" public String getLabel() { return label; }"); - out.println(" public boolean isGeneric() {"); - out.println(" return clusterType==0xFFFF;"); - out.println(" }"); - out.println(); - out.println(" public ZclCommandDirection getDirection() {"); - out.println(" return direction;"); - out.println(" }"); - out.println(); - out.println(" public Class getCommandClass() {"); - out.println(" return commandClass;"); - out.println(" }"); - out.println(); - out.println( - " public static ZclCommandType getCommandType(final int clusterType, final int commandId,\n"); - out.println(" ZclCommandDirection direction) {\n"); - out.println(" for (final ZclCommandType value : values()) {\n"); - out.println( - " if (value.direction == direction && value.clusterType == clusterType && value.commandId == commandId) {\n"); - out.println(" return value;\n"); - out.println(" }\n"); - out.println(" }\n"); - out.println(" return null;\n"); - out.println(" }"); - - out.println(); - out.println(" public static ZclCommandType getGeneric(final int commandId) {"); - out.println(" for (final ZclCommandType value : values()) {"); - out.println(" if (value.clusterType == 0xFFFF && value.commandId == commandId) {"); - out.println(" return value;"); - out.println(" }"); - out.println(" }"); - out.println(" return null;"); - out.println(" }"); - - out.println(); - out.println(" public ZclCommand instantiateCommand() {"); - out.println(" Constructor cmdConstructor;"); - out.println(" try {"); - out.println(" cmdConstructor = commandClass.getConstructor();"); - out.println(" return cmdConstructor.newInstance();"); - out.println(" } catch (Exception e) {"); - out.println(" // logger.debug(\"Error instantiating cluster command {}\", this);"); - out.println(" }"); - out.println(" return null;"); - out.println(" }"); - - out.println("}"); - - out.flush(); - out.close(); - } - - private class CommandId { - ZigBeeXmlCluster cluster; - ZigBeeXmlCommand command; - - public CommandId(ZigBeeXmlCluster cluster, ZigBeeXmlCommand command) { - this.cluster = cluster; - this.command = command; - } - } -} diff --git a/com.zsmartsystems.zigbee.console/src/main/java/com/zsmartsystems/zigbee/console/ZigBeeConsoleCommandsSupportedCommand.java b/com.zsmartsystems.zigbee.console/src/main/java/com/zsmartsystems/zigbee/console/ZigBeeConsoleCommandsSupportedCommand.java index ad0e624e8..792f88b57 100644 --- a/com.zsmartsystems.zigbee.console/src/main/java/com/zsmartsystems/zigbee/console/ZigBeeConsoleCommandsSupportedCommand.java +++ b/com.zsmartsystems.zigbee.console/src/main/java/com/zsmartsystems/zigbee/console/ZigBeeConsoleCommandsSupportedCommand.java @@ -15,6 +15,7 @@ import com.zsmartsystems.zigbee.ZigBeeNetworkManager; import com.zsmartsystems.zigbee.zcl.ZclCluster; import com.zsmartsystems.zigbee.zcl.ZclCommand; +import com.zsmartsystems.zigbee.zcl.ZclFrameType; /** * Console command that prints the commands that are supported by a given cluster. @@ -81,7 +82,7 @@ public void process(ZigBeeNetworkManager networkManager, String[] args, PrintStr private void printCommands(PrintStream out, ZclCluster cluster, Set commandIds) { out.println("CommandId Command"); for (Integer commandId : commandIds) { - ZclCommand command = cluster.getCommandFromId(commandId); + ZclCommand command = cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, commandId); String commandName = (command != null) ? command.getClass().getSimpleName() : "unknown"; out.println(String.format("%8d %s", commandId, commandName)); } diff --git a/com.zsmartsystems.zigbee/src/main/java/com/zsmartsystems/zigbee/ZigBeeNetworkManager.java b/com.zsmartsystems.zigbee/src/main/java/com/zsmartsystems/zigbee/ZigBeeNetworkManager.java index cb736b1e7..4ecc4254f 100644 --- a/com.zsmartsystems.zigbee/src/main/java/com/zsmartsystems/zigbee/ZigBeeNetworkManager.java +++ b/com.zsmartsystems.zigbee/src/main/java/com/zsmartsystems/zigbee/ZigBeeNetworkManager.java @@ -50,12 +50,13 @@ import com.zsmartsystems.zigbee.transport.ZigBeeTransportReceive; import com.zsmartsystems.zigbee.transport.ZigBeeTransportState; import com.zsmartsystems.zigbee.transport.ZigBeeTransportTransmit; +import com.zsmartsystems.zigbee.zcl.ZclCluster; import com.zsmartsystems.zigbee.zcl.ZclCommand; import com.zsmartsystems.zigbee.zcl.ZclFieldDeserializer; import com.zsmartsystems.zigbee.zcl.ZclFieldSerializer; import com.zsmartsystems.zigbee.zcl.ZclFrameType; import com.zsmartsystems.zigbee.zcl.ZclHeader; -import com.zsmartsystems.zigbee.zcl.protocol.ZclCommandType; +import com.zsmartsystems.zigbee.zcl.protocol.ZclCommandDirection; import com.zsmartsystems.zigbee.zdo.ZdoCommand; import com.zsmartsystems.zigbee.zdo.ZdoCommandType; import com.zsmartsystems.zigbee.zdo.command.ManagementLeaveRequest; @@ -752,6 +753,8 @@ private ZigBeeCommand receiveZdoCommand(final ZclFieldDeserializer fieldDeserial final ZigBeeApsFrame apsFrame) { ZdoCommandType commandType = ZdoCommandType.getValueById(apsFrame.getCluster()); if (commandType == null) { + logger.debug("Error instantiating ZDO command: Unknown cluster {}", + String.format("%04X", apsFrame.getCluster())); return null; } @@ -778,25 +781,36 @@ private ZigBeeCommand receiveZclCommand(final ZclFieldDeserializer fieldDeserial ZclHeader zclHeader = new ZclHeader(fieldDeserializer); logger.debug("RX ZCL: {}", zclHeader); - // Get the command type - ZclCommandType commandType = null; - if (zclHeader.getFrameType() == ZclFrameType.ENTIRE_PROFILE_COMMAND) { - commandType = ZclCommandType.getGeneric(zclHeader.getCommandId()); - } else { - commandType = ZclCommandType.getCommandType(apsFrame.getCluster(), zclHeader.getCommandId(), - zclHeader.getDirection()); + ZigBeeNode node = getNode(apsFrame.getSourceAddress()); + if (node == null) { + logger.debug("Unknown node {}", apsFrame.getSourceAddress()); + return null; } - if (commandType == null) { - logger.debug("No command type found for {}, cluster={}, command={}, direction={}", zclHeader.getFrameType(), - apsFrame.getCluster(), zclHeader.getCommandId(), zclHeader.getDirection()); + ZigBeeEndpoint endpoint = node.getEndpoint(apsFrame.getSourceEndpoint()); + if (endpoint == null) { + logger.debug("Unknown endpoint {}", apsFrame.getSourceEndpoint()); return null; } - ZclCommand command = commandType.instantiateCommand(); + ZclCommand command; + if (zclHeader.getDirection() == ZclCommandDirection.SERVER_TO_CLIENT) { + ZclCluster cluster = endpoint.getInputCluster(apsFrame.getCluster()); + if (cluster == null) { + logger.debug("Unknown input cluster {}", apsFrame.getCluster()); + return null; + } + command = cluster.getResponseFromId(zclHeader.getFrameType(), zclHeader.getCommandId()); + } else { + ZclCluster cluster = endpoint.getOutputCluster(apsFrame.getCluster()); + if (cluster == null) { + logger.debug("Unknown output cluster {}", apsFrame.getCluster()); + return null; + } + command = cluster.getCommandFromId(zclHeader.getFrameType(), zclHeader.getCommandId()); + } if (command == null) { - logger.debug("No command found for {}, cluster={}, command={}", zclHeader.getFrameType(), - apsFrame.getCluster(), zclHeader.getCommandId()); + logger.debug("Unknown command {}", zclHeader.getCommandId()); return null; } diff --git a/com.zsmartsystems.zigbee/src/main/java/com/zsmartsystems/zigbee/zcl/ZclCluster.java b/com.zsmartsystems.zigbee/src/main/java/com/zsmartsystems/zigbee/zcl/ZclCluster.java index 6f753a5eb..a05085252 100644 --- a/com.zsmartsystems.zigbee/src/main/java/com/zsmartsystems/zigbee/zcl/ZclCluster.java +++ b/com.zsmartsystems.zigbee/src/main/java/com/zsmartsystems/zigbee/zcl/ZclCluster.java @@ -8,6 +8,7 @@ package com.zsmartsystems.zigbee.zcl; import java.util.Collections; +import java.util.HashMap; import java.util.HashSet; import java.util.List; import java.util.Map; @@ -31,8 +32,11 @@ import com.zsmartsystems.zigbee.database.ZclClusterDao; import com.zsmartsystems.zigbee.internal.NotificationService; import com.zsmartsystems.zigbee.zcl.clusters.general.ConfigureReportingCommand; +import com.zsmartsystems.zigbee.zcl.clusters.general.ConfigureReportingResponse; import com.zsmartsystems.zigbee.zcl.clusters.general.DefaultResponse; import com.zsmartsystems.zigbee.zcl.clusters.general.DiscoverAttributesCommand; +import com.zsmartsystems.zigbee.zcl.clusters.general.DiscoverAttributesExtended; +import com.zsmartsystems.zigbee.zcl.clusters.general.DiscoverAttributesExtendedResponse; import com.zsmartsystems.zigbee.zcl.clusters.general.DiscoverAttributesResponse; import com.zsmartsystems.zigbee.zcl.clusters.general.DiscoverCommandsGenerated; import com.zsmartsystems.zigbee.zcl.clusters.general.DiscoverCommandsGeneratedResponse; @@ -40,8 +44,16 @@ import com.zsmartsystems.zigbee.zcl.clusters.general.DiscoverCommandsReceivedResponse; import com.zsmartsystems.zigbee.zcl.clusters.general.ReadAttributesCommand; import com.zsmartsystems.zigbee.zcl.clusters.general.ReadAttributesResponse; +import com.zsmartsystems.zigbee.zcl.clusters.general.ReadAttributesStructuredCommand; import com.zsmartsystems.zigbee.zcl.clusters.general.ReadReportingConfigurationCommand; +import com.zsmartsystems.zigbee.zcl.clusters.general.ReadReportingConfigurationResponse; +import com.zsmartsystems.zigbee.zcl.clusters.general.ReportAttributesCommand; import com.zsmartsystems.zigbee.zcl.clusters.general.WriteAttributesCommand; +import com.zsmartsystems.zigbee.zcl.clusters.general.WriteAttributesNoResponse; +import com.zsmartsystems.zigbee.zcl.clusters.general.WriteAttributesResponse; +import com.zsmartsystems.zigbee.zcl.clusters.general.WriteAttributesStructuredCommand; +import com.zsmartsystems.zigbee.zcl.clusters.general.WriteAttributesStructuredResponse; +import com.zsmartsystems.zigbee.zcl.clusters.general.WriteAttributesUndividedCommand; import com.zsmartsystems.zigbee.zcl.field.AttributeInformation; import com.zsmartsystems.zigbee.zcl.field.AttributeRecord; import com.zsmartsystems.zigbee.zcl.field.AttributeReport; @@ -133,6 +145,11 @@ public abstract class ZclCluster { */ protected Map> clientCommands = initializeClientCommands(); + /** + * Map of the generic commands as implemented by all clusters + */ + protected static Map> genericCommands = new HashMap<>(); + /** * The {@link ZclAttributeNormalizer} is used to normalize attribute data types to ensure that data types are * consistent with the ZCL definition. This ensures that the application can rely on consistent and deterministic @@ -146,6 +163,32 @@ public abstract class ZclCluster { */ private boolean apsSecurityRequired = false; + static { + genericCommands.put(0x0000, ReadAttributesCommand.class); + genericCommands.put(0x0001, ReadAttributesResponse.class); + genericCommands.put(0x0002, WriteAttributesCommand.class); + genericCommands.put(0x0003, WriteAttributesUndividedCommand.class); + genericCommands.put(0x0004, WriteAttributesResponse.class); + genericCommands.put(0x0005, WriteAttributesNoResponse.class); + genericCommands.put(0x0006, ConfigureReportingCommand.class); + genericCommands.put(0x0007, ConfigureReportingResponse.class); + genericCommands.put(0x0008, ReadReportingConfigurationCommand.class); + genericCommands.put(0x0009, ReadReportingConfigurationResponse.class); + genericCommands.put(0x000A, ReportAttributesCommand.class); + genericCommands.put(0x000B, DefaultResponse.class); + genericCommands.put(0x000C, DiscoverAttributesCommand.class); + genericCommands.put(0x000D, DiscoverAttributesResponse.class); + genericCommands.put(0x000E, ReadAttributesStructuredCommand.class); + genericCommands.put(0x000F, WriteAttributesStructuredCommand.class); + genericCommands.put(0x0010, WriteAttributesStructuredResponse.class); + genericCommands.put(0x0011, DiscoverCommandsReceived.class); + genericCommands.put(0x0012, DiscoverCommandsReceivedResponse.class); + genericCommands.put(0x0013, DiscoverCommandsGenerated.class); + genericCommands.put(0x0014, DiscoverCommandsGeneratedResponse.class); + genericCommands.put(0x0015, DiscoverAttributesExtended.class); + genericCommands.put(0x0016, DiscoverAttributesExtendedResponse.class); + } + /** * Abstract method called when the cluster starts to initialise the list of attributes defined in this cluster by * the cluster library @@ -965,22 +1008,32 @@ public void handleCommand(ZclCommand command) { * Gets a command from the command ID (ie a command from client to server). If no command with the requested id is * found, null is returned. * + * @param zclFrameType the {@link ZclFrameType} of the command * @param commandId the command ID * @return the {@link ZclCommand} or null if no command was found. */ - public ZclCommand getCommandFromId(int commandId) { - return getCommand(commandId, clientCommands); + public ZclCommand getCommandFromId(ZclFrameType zclFrameType, int commandId) { + if (zclFrameType == ZclFrameType.CLUSTER_SPECIFIC_COMMAND) { + return getCommand(commandId, clientCommands); + } else { + return getCommand(commandId, genericCommands); + } } /** * Gets a response from the command ID (ie a command from server to client). If no command with the requested id is * found, null is returned. * + * @param zclFrameType the {@link ZclFrameType} of the command * @param commandId the command ID * @return the {@link ZclCommand} or null if no command was found. */ - public ZclCommand getResponseFromId(int commandId) { - return getCommand(commandId, serverCommands); + public ZclCommand getResponseFromId(ZclFrameType zclFrameType, int commandId) { + if (zclFrameType == ZclFrameType.CLUSTER_SPECIFIC_COMMAND) { + return getCommand(commandId, serverCommands); + } else { + return getCommand(commandId, genericCommands); + } } private ZclCommand getCommand(int commandId, Map> commands) { diff --git a/com.zsmartsystems.zigbee/src/main/java/com/zsmartsystems/zigbee/zcl/clusters/ZclCommissioningCluster.java b/com.zsmartsystems.zigbee/src/main/java/com/zsmartsystems/zigbee/zcl/clusters/ZclCommissioningCluster.java index a0c810065..2205b3815 100644 --- a/com.zsmartsystems.zigbee/src/main/java/com/zsmartsystems/zigbee/zcl/clusters/ZclCommissioningCluster.java +++ b/com.zsmartsystems.zigbee/src/main/java/com/zsmartsystems/zigbee/zcl/clusters/ZclCommissioningCluster.java @@ -7,11 +7,16 @@ */ package com.zsmartsystems.zigbee.zcl.clusters; +import java.util.Map; +import java.util.concurrent.ConcurrentHashMap; +import java.util.concurrent.Future; + +import javax.annotation.Generated; + import com.zsmartsystems.zigbee.CommandResult; import com.zsmartsystems.zigbee.ZigBeeEndpoint; import com.zsmartsystems.zigbee.zcl.ZclAttribute; import com.zsmartsystems.zigbee.zcl.ZclCluster; -import com.zsmartsystems.zigbee.zcl.ZclCommand; import com.zsmartsystems.zigbee.zcl.clusters.commissioning.ResetStartupParametersCommand; import com.zsmartsystems.zigbee.zcl.clusters.commissioning.ResetStartupParametersResponse; import com.zsmartsystems.zigbee.zcl.clusters.commissioning.RestartDeviceCommand; @@ -20,10 +25,6 @@ import com.zsmartsystems.zigbee.zcl.clusters.commissioning.RestoreStartupParametersResponse; import com.zsmartsystems.zigbee.zcl.clusters.commissioning.SaveStartupParametersCommand; import com.zsmartsystems.zigbee.zcl.clusters.commissioning.SaveStartupParametersResponse; -import java.util.Map; -import java.util.concurrent.ConcurrentHashMap; -import java.util.concurrent.Future; -import javax.annotation.Generated; /** * Commissioning cluster implementation (Cluster ID 0x0015). @@ -43,6 +44,7 @@ public class ZclCommissioningCluster extends ZclCluster { public static final String CLUSTER_NAME = "Commissioning"; // Attribute initialisation + @Override protected Map initializeAttributes() { Map attributeMap = new ConcurrentHashMap(0); @@ -188,35 +190,4 @@ public Future resetStartupParametersResponse(Integer status) { return send(command); } - @Override - public ZclCommand getCommandFromId(int commandId) { - switch (commandId) { - case 0: // RESTART_DEVICE_COMMAND - return new RestartDeviceCommand(); - case 1: // SAVE_STARTUP_PARAMETERS_COMMAND - return new SaveStartupParametersCommand(); - case 2: // RESTORE_STARTUP_PARAMETERS_COMMAND - return new RestoreStartupParametersCommand(); - case 3: // RESET_STARTUP_PARAMETERS_COMMAND - return new ResetStartupParametersCommand(); - default: - return null; - } - } - - @Override - public ZclCommand getResponseFromId(int commandId) { - switch (commandId) { - case 0: // RESTART_DEVICE_RESPONSE_RESPONSE - return new RestartDeviceResponseResponse(); - case 1: // SAVE_STARTUP_PARAMETERS_RESPONSE - return new SaveStartupParametersResponse(); - case 2: // RESTORE_STARTUP_PARAMETERS_RESPONSE - return new RestoreStartupParametersResponse(); - case 3: // RESET_STARTUP_PARAMETERS_RESPONSE - return new ResetStartupParametersResponse(); - default: - return null; - } - } } diff --git a/com.zsmartsystems.zigbee/src/main/java/com/zsmartsystems/zigbee/zcl/clusters/ZclGeneralCluster.java b/com.zsmartsystems.zigbee/src/main/java/com/zsmartsystems/zigbee/zcl/clusters/ZclGeneralCluster.java deleted file mode 100644 index 5990b30fb..000000000 --- a/com.zsmartsystems.zigbee/src/main/java/com/zsmartsystems/zigbee/zcl/clusters/ZclGeneralCluster.java +++ /dev/null @@ -1,609 +0,0 @@ -/** - * Copyright (c) 2016-2019 by the respective copyright holders. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - */ -package com.zsmartsystems.zigbee.zcl.clusters; - -import com.zsmartsystems.zigbee.CommandResult; -import com.zsmartsystems.zigbee.ZigBeeEndpoint; -import com.zsmartsystems.zigbee.zcl.ZclAttribute; -import com.zsmartsystems.zigbee.zcl.ZclCluster; -import com.zsmartsystems.zigbee.zcl.ZclCommand; -import com.zsmartsystems.zigbee.zcl.ZclStatus; -import com.zsmartsystems.zigbee.zcl.clusters.general.ConfigureReportingCommand; -import com.zsmartsystems.zigbee.zcl.clusters.general.ConfigureReportingResponse; -import com.zsmartsystems.zigbee.zcl.clusters.general.DefaultResponse; -import com.zsmartsystems.zigbee.zcl.clusters.general.DiscoverAttributesCommand; -import com.zsmartsystems.zigbee.zcl.clusters.general.DiscoverAttributesExtended; -import com.zsmartsystems.zigbee.zcl.clusters.general.DiscoverAttributesExtendedResponse; -import com.zsmartsystems.zigbee.zcl.clusters.general.DiscoverAttributesResponse; -import com.zsmartsystems.zigbee.zcl.clusters.general.DiscoverCommandsGenerated; -import com.zsmartsystems.zigbee.zcl.clusters.general.DiscoverCommandsGeneratedResponse; -import com.zsmartsystems.zigbee.zcl.clusters.general.DiscoverCommandsReceived; -import com.zsmartsystems.zigbee.zcl.clusters.general.DiscoverCommandsReceivedResponse; -import com.zsmartsystems.zigbee.zcl.clusters.general.ReadAttributesCommand; -import com.zsmartsystems.zigbee.zcl.clusters.general.ReadAttributesResponse; -import com.zsmartsystems.zigbee.zcl.clusters.general.ReadAttributesStructuredCommand; -import com.zsmartsystems.zigbee.zcl.clusters.general.ReadReportingConfigurationCommand; -import com.zsmartsystems.zigbee.zcl.clusters.general.ReadReportingConfigurationResponse; -import com.zsmartsystems.zigbee.zcl.clusters.general.ReportAttributesCommand; -import com.zsmartsystems.zigbee.zcl.clusters.general.WriteAttributesCommand; -import com.zsmartsystems.zigbee.zcl.clusters.general.WriteAttributesNoResponse; -import com.zsmartsystems.zigbee.zcl.clusters.general.WriteAttributesResponse; -import com.zsmartsystems.zigbee.zcl.clusters.general.WriteAttributesStructuredCommand; -import com.zsmartsystems.zigbee.zcl.clusters.general.WriteAttributesStructuredResponse; -import com.zsmartsystems.zigbee.zcl.clusters.general.WriteAttributesUndividedCommand; -import com.zsmartsystems.zigbee.zcl.field.AttributeInformation; -import com.zsmartsystems.zigbee.zcl.field.AttributeRecord; -import com.zsmartsystems.zigbee.zcl.field.AttributeReport; -import com.zsmartsystems.zigbee.zcl.field.AttributeReportingConfigurationRecord; -import com.zsmartsystems.zigbee.zcl.field.AttributeStatusRecord; -import com.zsmartsystems.zigbee.zcl.field.ExtendedAttributeInformation; -import com.zsmartsystems.zigbee.zcl.field.ReadAttributeStatusRecord; -import com.zsmartsystems.zigbee.zcl.field.WriteAttributeRecord; -import com.zsmartsystems.zigbee.zcl.field.WriteAttributeStatusRecord; -import java.util.List; -import java.util.Map; -import java.util.concurrent.ConcurrentHashMap; -import java.util.concurrent.Future; -import javax.annotation.Generated; - -/** - * General cluster implementation (Cluster ID 0xFFFF). - *

- * Code is auto-generated. Modifications may be overwritten! - */ -@Generated(value = "com.zsmartsystems.zigbee.autocode.ZclProtocolCodeGenerator", date = "2018-10-24T19:40:52Z") -public class ZclGeneralCluster extends ZclCluster { - /** - * The ZigBee Cluster Library Cluster ID - */ - public static final int CLUSTER_ID = 0xFFFF; - - /** - * The ZigBee Cluster Library Cluster Name - */ - public static final String CLUSTER_NAME = "General"; - - // Attribute initialisation - protected Map initializeAttributes() { - Map attributeMap = new ConcurrentHashMap(0); - - return attributeMap; - } - - /** - * Default constructor to create a General cluster. - * - * @param zigbeeEndpoint the {@link ZigBeeEndpoint} - */ - public ZclGeneralCluster(final ZigBeeEndpoint zigbeeEndpoint) { - super(zigbeeEndpoint, CLUSTER_ID, CLUSTER_NAME); - } - - /** - * The Read Attributes Command - *

- * The read attributes command is generated when a device wishes to determine the - * values of one or more attributes located on another device. Each attribute - * identifier field shall contain the identifier of the attribute to be read. - * - * @param identifiers {@link List} Identifiers - * @return the {@link Future} command result future - */ - public Future readAttributesCommand(List identifiers) { - ReadAttributesCommand command = new ReadAttributesCommand(); - - // Set the fields - command.setIdentifiers(identifiers); - - return send(command); - } - - /** - * The Read Attributes Response - *

- * The read attributes response command is generated in response to a read attributes - * or read attributes structured command. The command frame shall contain a read - * attribute status record for each attribute identifier specified in the original read - * attributes or read attributes structured command. For each read attribute status - * record, the attribute identifier field shall contain the identifier specified in the - * original read attributes or read attributes structured command. - * - * @param records {@link List} Records - * @return the {@link Future} command result future - */ - public Future readAttributesResponse(List records) { - ReadAttributesResponse command = new ReadAttributesResponse(); - - // Set the fields - command.setRecords(records); - - return send(command); - } - - /** - * The Write Attributes Command - *

- * The write attributes command is generated when a device wishes to change the - * values of one or more attributes located on another device. Each write attribute - * record shall contain the identifier and the actual value of the attribute to be - * written. - * - * @param records {@link List} Records - * @return the {@link Future} command result future - */ - public Future writeAttributesCommand(List records) { - WriteAttributesCommand command = new WriteAttributesCommand(); - - // Set the fields - command.setRecords(records); - - return send(command); - } - - /** - * The Write Attributes Undivided Command - *

- * The write attributes undivided command is generated when a device wishes to - * change the values of one or more attributes located on another device, in such a - * way that if any attribute cannot be written (e.g. if an attribute is not implemented - * on the device, or a value to be written is outside its valid range), no attribute - * values are changed. - *
- * In all other respects, including generation of a write attributes response command, - * the format and operation of the command is the same as that of the write attributes - * command, except that the command identifier field shall be set to indicate the - * write attributes undivided command. - * - * @param records {@link List} Records - * @return the {@link Future} command result future - */ - public Future writeAttributesUndividedCommand(List records) { - WriteAttributesUndividedCommand command = new WriteAttributesUndividedCommand(); - - // Set the fields - command.setRecords(records); - - return send(command); - } - - /** - * The Write Attributes Response - *

- * The write attributes response command is generated in response to a write - * attributes command. - * - * @param records {@link List} Records - * @return the {@link Future} command result future - */ - public Future writeAttributesResponse(List records) { - WriteAttributesResponse command = new WriteAttributesResponse(); - - // Set the fields - command.setRecords(records); - - return send(command); - } - - /** - * The Write Attributes No Response - *

- * The write attributes no response command is generated when a device wishes to - * change the value of one or more attributes located on another device but does not - * require a response. Each write attribute record shall contain the identifier and the - * actual value of the attribute to be written. - * - * @param records {@link List} Records - * @return the {@link Future} command result future - */ - public Future writeAttributesNoResponse(List records) { - WriteAttributesNoResponse command = new WriteAttributesNoResponse(); - - // Set the fields - command.setRecords(records); - - return send(command); - } - - /** - * The Configure Reporting Command - *

- * The Configure Reporting command is used to configure the reporting mechanism - * for one or more of the attributes of a cluster. - *
- * The individual cluster definitions specify which attributes shall be available to this - * reporting mechanism, however specific implementations of a cluster may make - * additional attributes available. - * - * @param records {@link List} Records - * @return the {@link Future} command result future - */ - public Future configureReportingCommand(List records) { - ConfigureReportingCommand command = new ConfigureReportingCommand(); - - // Set the fields - command.setRecords(records); - - return send(command); - } - - /** - * The Configure Reporting Response - *

- * The Configure Reporting Response command is generated in response to a - * Configure Reporting command. - * - * @param status {@link ZclStatus} Status - * @param records {@link List} Records - * @return the {@link Future} command result future - */ - public Future configureReportingResponse(ZclStatus status, List records) { - ConfigureReportingResponse command = new ConfigureReportingResponse(); - - // Set the fields - command.setStatus(status); - command.setRecords(records); - - return send(command); - } - - /** - * The Read Reporting Configuration Command - *

- * The Read Reporting Configuration command is used to read the configuration - * details of the reporting mechanism for one or more of the attributes of a cluster. - * - * @param records {@link List} Records - * @return the {@link Future} command result future - */ - public Future readReportingConfigurationCommand(List records) { - ReadReportingConfigurationCommand command = new ReadReportingConfigurationCommand(); - - // Set the fields - command.setRecords(records); - - return send(command); - } - - /** - * The Read Reporting Configuration Response - *

- * The Read Reporting Configuration Response command is used to respond to a - * Read Reporting Configuration command. - * - * @param records {@link List} Records - * @return the {@link Future} command result future - */ - public Future readReportingConfigurationResponse(List records) { - ReadReportingConfigurationResponse command = new ReadReportingConfigurationResponse(); - - // Set the fields - command.setRecords(records); - - return send(command); - } - - /** - * The Report Attributes Command - *

- * The report attributes command is used by a device to report the values of one or - * more of its attributes to another device, bound a priori. Individual clusters, defined - * elsewhere in the ZCL, define which attributes are to be reported and at what - * interval. - * - * @param reports {@link List} Reports - * @return the {@link Future} command result future - */ - public Future reportAttributesCommand(List reports) { - ReportAttributesCommand command = new ReportAttributesCommand(); - - // Set the fields - command.setReports(reports); - - return send(command); - } - - /** - * The Default Response - *

- * The default response command is generated when a device receives a unicast - * command, there is no other relevant response specified for the command, and - * either an error results or the Disable default response bit of its Frame control field - * is set to 0. - * - * @param commandIdentifier {@link Integer} Command identifier - * @param statusCode {@link ZclStatus} Status code - * @return the {@link Future} command result future - */ - public Future defaultResponse(Integer commandIdentifier, ZclStatus statusCode) { - DefaultResponse command = new DefaultResponse(); - - // Set the fields - command.setCommandIdentifier(commandIdentifier); - command.setStatusCode(statusCode); - - return send(command); - } - - /** - * The Discover Attributes Command - *

- * The discover attributes command is generated when a remote device wishes to - * discover the identifiers and types of the attributes on a device which are supported - * within the cluster to which this command is directed. - * - * @param startAttributeIdentifier {@link Integer} Start attribute identifier - * @param maximumAttributeIdentifiers {@link Integer} Maximum attribute identifiers - * @return the {@link Future} command result future - */ - public Future discoverAttributesCommand(Integer startAttributeIdentifier, Integer maximumAttributeIdentifiers) { - DiscoverAttributesCommand command = new DiscoverAttributesCommand(); - - // Set the fields - command.setStartAttributeIdentifier(startAttributeIdentifier); - command.setMaximumAttributeIdentifiers(maximumAttributeIdentifiers); - - return send(command); - } - - /** - * The Discover Attributes Response - *

- * The discover attributes response command is generated in response to a discover - * attributes command. - * - * @param discoveryComplete {@link Boolean} Discovery Complete - * @param attributeInformation {@link List} Attribute Information - * @return the {@link Future} command result future - */ - public Future discoverAttributesResponse(Boolean discoveryComplete, List attributeInformation) { - DiscoverAttributesResponse command = new DiscoverAttributesResponse(); - - // Set the fields - command.setDiscoveryComplete(discoveryComplete); - command.setAttributeInformation(attributeInformation); - - return send(command); - } - - /** - * The Read Attributes Structured Command - *

- * The read attributes command is generated when a device wishes to determine the - * values of one or more attributes, or elements of attributes, located on another - * device. Each attribute identifier field shall contain the identifier of the attribute to - * be read. - * - * @param attributeSelectors {@link Object} Attribute selectors - * @return the {@link Future} command result future - */ - public Future readAttributesStructuredCommand(Object attributeSelectors) { - ReadAttributesStructuredCommand command = new ReadAttributesStructuredCommand(); - - // Set the fields - command.setAttributeSelectors(attributeSelectors); - - return send(command); - } - - /** - * The Write Attributes Structured Command - *

- * The write attributes structured command is generated when a device wishes to - * change the values of one or more attributes located on another device. Each write - * attribute record shall contain the identifier and the actual value of the attribute, or - * element thereof, to be written. - * - * @param status {@link ZclStatus} Status - * @param attributeSelectors {@link Object} Attribute selectors - * @return the {@link Future} command result future - */ - public Future writeAttributesStructuredCommand(ZclStatus status, Object attributeSelectors) { - WriteAttributesStructuredCommand command = new WriteAttributesStructuredCommand(); - - // Set the fields - command.setStatus(status); - command.setAttributeSelectors(attributeSelectors); - - return send(command); - } - - /** - * The Write Attributes Structured Response - *

- * The write attributes structured response command is generated in response to a - * write attributes structured command. - * - * @param status {@link ZclStatus} Status - * @param records {@link List} Records - * @return the {@link Future} command result future - */ - public Future writeAttributesStructuredResponse(ZclStatus status, List records) { - WriteAttributesStructuredResponse command = new WriteAttributesStructuredResponse(); - - // Set the fields - command.setStatus(status); - command.setRecords(records); - - return send(command); - } - - /** - * The Discover Commands Received - *

- * The Discover Commands Received command is generated when a remote device wishes to discover the - * optional and mandatory commands the cluster to which this command is sent can process. - * - * @param startCommandIdentifier {@link Integer} Start command identifier - * @param maximumCommandIdentifiers {@link Integer} Maximum command identifiers - * @return the {@link Future} command result future - */ - public Future discoverCommandsReceived(Integer startCommandIdentifier, Integer maximumCommandIdentifiers) { - DiscoverCommandsReceived command = new DiscoverCommandsReceived(); - - // Set the fields - command.setStartCommandIdentifier(startCommandIdentifier); - command.setMaximumCommandIdentifiers(maximumCommandIdentifiers); - - return send(command); - } - - /** - * The Discover Commands Received Response - *

- * The Discover Commands Received Response is generated in response to a Discover Commands Received - * command. - * - * @param discoveryComplete {@link Boolean} Discovery complete - * @param commandIdentifiers {@link List} Command identifiers - * @return the {@link Future} command result future - */ - public Future discoverCommandsReceivedResponse(Boolean discoveryComplete, List commandIdentifiers) { - DiscoverCommandsReceivedResponse command = new DiscoverCommandsReceivedResponse(); - - // Set the fields - command.setDiscoveryComplete(discoveryComplete); - command.setCommandIdentifiers(commandIdentifiers); - - return send(command); - } - - /** - * The Discover Commands Generated - *

- * The Discover Commands Generated command is generated when a remote device wishes to discover the - * commands that a cluster may generate on the device to which this command is directed. - * - * @param startCommandIdentifier {@link Integer} Start command identifier - * @param maximumCommandIdentifiers {@link Integer} Maximum command identifiers - * @return the {@link Future} command result future - */ - public Future discoverCommandsGenerated(Integer startCommandIdentifier, Integer maximumCommandIdentifiers) { - DiscoverCommandsGenerated command = new DiscoverCommandsGenerated(); - - // Set the fields - command.setStartCommandIdentifier(startCommandIdentifier); - command.setMaximumCommandIdentifiers(maximumCommandIdentifiers); - - return send(command); - } - - /** - * The Discover Commands Generated Response - *

- * The Discover Commands Generated Response is generated in response to a Discover Commands Generated - * command. - * - * @param discoveryComplete {@link Boolean} Discovery complete - * @param commandIdentifiers {@link List} Command identifiers - * @return the {@link Future} command result future - */ - public Future discoverCommandsGeneratedResponse(Boolean discoveryComplete, List commandIdentifiers) { - DiscoverCommandsGeneratedResponse command = new DiscoverCommandsGeneratedResponse(); - - // Set the fields - command.setDiscoveryComplete(discoveryComplete); - command.setCommandIdentifiers(commandIdentifiers); - - return send(command); - } - - /** - * The Discover Attributes Extended - *

- * The Discover Attributes Extended command is generated when a remote device wishes to discover the - * identifiers and types of the attributes on a device which are supported within the cluster to which this - * command is directed, including whether the attribute is readable, writeable or reportable. - * - * @param startAttributeIdentifier {@link Integer} Start attribute identifier - * @param maximumAttributeIdentifiers {@link Integer} Maximum attribute identifiers - * @return the {@link Future} command result future - */ - public Future discoverAttributesExtended(Integer startAttributeIdentifier, Integer maximumAttributeIdentifiers) { - DiscoverAttributesExtended command = new DiscoverAttributesExtended(); - - // Set the fields - command.setStartAttributeIdentifier(startAttributeIdentifier); - command.setMaximumAttributeIdentifiers(maximumAttributeIdentifiers); - - return send(command); - } - - /** - * The Discover Attributes Extended Response - *

- * The Discover Attributes Extended Response command is generated in response to a Discover Attributes - * Extended command. - * - * @param discoveryComplete {@link Boolean} Discovery complete - * @param attributeInformation {@link List} Attribute Information - * @return the {@link Future} command result future - */ - public Future discoverAttributesExtendedResponse(Boolean discoveryComplete, List attributeInformation) { - DiscoverAttributesExtendedResponse command = new DiscoverAttributesExtendedResponse(); - - // Set the fields - command.setDiscoveryComplete(discoveryComplete); - command.setAttributeInformation(attributeInformation); - - return send(command); - } - - @Override - public ZclCommand getCommandFromId(int commandId) { - switch (commandId) { - case 0: // READ_ATTRIBUTES_COMMAND - return new ReadAttributesCommand(); - case 1: // READ_ATTRIBUTES_RESPONSE - return new ReadAttributesResponse(); - case 2: // WRITE_ATTRIBUTES_COMMAND - return new WriteAttributesCommand(); - case 3: // WRITE_ATTRIBUTES_UNDIVIDED_COMMAND - return new WriteAttributesUndividedCommand(); - case 4: // WRITE_ATTRIBUTES_RESPONSE - return new WriteAttributesResponse(); - case 5: // WRITE_ATTRIBUTES_NO_RESPONSE - return new WriteAttributesNoResponse(); - case 6: // CONFIGURE_REPORTING_COMMAND - return new ConfigureReportingCommand(); - case 7: // CONFIGURE_REPORTING_RESPONSE - return new ConfigureReportingResponse(); - case 8: // READ_REPORTING_CONFIGURATION_COMMAND - return new ReadReportingConfigurationCommand(); - case 9: // READ_REPORTING_CONFIGURATION_RESPONSE - return new ReadReportingConfigurationResponse(); - case 10: // REPORT_ATTRIBUTES_COMMAND - return new ReportAttributesCommand(); - case 11: // DEFAULT_RESPONSE - return new DefaultResponse(); - case 12: // DISCOVER_ATTRIBUTES_COMMAND - return new DiscoverAttributesCommand(); - case 13: // DISCOVER_ATTRIBUTES_RESPONSE - return new DiscoverAttributesResponse(); - case 14: // READ_ATTRIBUTES_STRUCTURED_COMMAND - return new ReadAttributesStructuredCommand(); - case 15: // WRITE_ATTRIBUTES_STRUCTURED_COMMAND - return new WriteAttributesStructuredCommand(); - case 16: // WRITE_ATTRIBUTES_STRUCTURED_RESPONSE - return new WriteAttributesStructuredResponse(); - case 17: // DISCOVER_COMMANDS_RECEIVED - return new DiscoverCommandsReceived(); - case 18: // DISCOVER_COMMANDS_RECEIVED_RESPONSE - return new DiscoverCommandsReceivedResponse(); - case 19: // DISCOVER_COMMANDS_GENERATED - return new DiscoverCommandsGenerated(); - case 20: // DISCOVER_COMMANDS_GENERATED_RESPONSE - return new DiscoverCommandsGeneratedResponse(); - case 21: // DISCOVER_ATTRIBUTES_EXTENDED - return new DiscoverAttributesExtended(); - case 22: // DISCOVER_ATTRIBUTES_EXTENDED_RESPONSE - return new DiscoverAttributesExtendedResponse(); - default: - return null; - } - } -} diff --git a/com.zsmartsystems.zigbee/src/main/java/com/zsmartsystems/zigbee/zcl/protocol/ZclCommandType.java b/com.zsmartsystems.zigbee/src/main/java/com/zsmartsystems/zigbee/zcl/protocol/ZclCommandType.java deleted file mode 100644 index bac34fe08..000000000 --- a/com.zsmartsystems.zigbee/src/main/java/com/zsmartsystems/zigbee/zcl/protocol/ZclCommandType.java +++ /dev/null @@ -1,2042 +0,0 @@ -/** - * Copyright (c) 2016-2019 by the respective copyright holders. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - */ -package com.zsmartsystems.zigbee.zcl.protocol; - -import java.lang.reflect.Constructor; - -import javax.annotation.Generated; - -import com.zsmartsystems.zigbee.zcl.ZclCommand; -import com.zsmartsystems.zigbee.zcl.clusters.alarms.AlarmCommand; -import com.zsmartsystems.zigbee.zcl.clusters.alarms.GetAlarmCommand; -import com.zsmartsystems.zigbee.zcl.clusters.alarms.GetAlarmResponse; -import com.zsmartsystems.zigbee.zcl.clusters.alarms.ResetAlarmCommand; -import com.zsmartsystems.zigbee.zcl.clusters.alarms.ResetAlarmLogCommand; -import com.zsmartsystems.zigbee.zcl.clusters.alarms.ResetAllAlarmsCommand; -import com.zsmartsystems.zigbee.zcl.clusters.basic.ResetToFactoryDefaultsCommand; -import com.zsmartsystems.zigbee.zcl.clusters.colorcontrol.ColorLoopSetCommand; -import com.zsmartsystems.zigbee.zcl.clusters.colorcontrol.EnhancedMoveToHueAndSaturationCommand; -import com.zsmartsystems.zigbee.zcl.clusters.colorcontrol.EnhancedMoveToHueCommand; -import com.zsmartsystems.zigbee.zcl.clusters.colorcontrol.EnhancedStepHueCommand; -import com.zsmartsystems.zigbee.zcl.clusters.colorcontrol.MoveColorCommand; -import com.zsmartsystems.zigbee.zcl.clusters.colorcontrol.MoveHueCommand; -import com.zsmartsystems.zigbee.zcl.clusters.colorcontrol.MoveSaturationCommand; -import com.zsmartsystems.zigbee.zcl.clusters.colorcontrol.MoveToColorCommand; -import com.zsmartsystems.zigbee.zcl.clusters.colorcontrol.MoveToColorTemperatureCommand; -import com.zsmartsystems.zigbee.zcl.clusters.colorcontrol.MoveToHueAndSaturationCommand; -import com.zsmartsystems.zigbee.zcl.clusters.colorcontrol.MoveToHueCommand; -import com.zsmartsystems.zigbee.zcl.clusters.colorcontrol.MoveToSaturationCommand; -import com.zsmartsystems.zigbee.zcl.clusters.colorcontrol.StepColorCommand; -import com.zsmartsystems.zigbee.zcl.clusters.colorcontrol.StepHueCommand; -import com.zsmartsystems.zigbee.zcl.clusters.colorcontrol.StepSaturationCommand; -import com.zsmartsystems.zigbee.zcl.clusters.demandresponseandloadcontrol.CancelAllLoadControlEvents; -import com.zsmartsystems.zigbee.zcl.clusters.demandresponseandloadcontrol.CancelLoadControlEvent; -import com.zsmartsystems.zigbee.zcl.clusters.demandresponseandloadcontrol.GetScheduledEvents; -import com.zsmartsystems.zigbee.zcl.clusters.demandresponseandloadcontrol.LoadControlEventCommand; -import com.zsmartsystems.zigbee.zcl.clusters.demandresponseandloadcontrol.ReportEventStatus; -import com.zsmartsystems.zigbee.zcl.clusters.doorlock.LockDoorCommand; -import com.zsmartsystems.zigbee.zcl.clusters.doorlock.LockDoorResponse; -import com.zsmartsystems.zigbee.zcl.clusters.doorlock.Toggle; -import com.zsmartsystems.zigbee.zcl.clusters.doorlock.ToggleResponse; -import com.zsmartsystems.zigbee.zcl.clusters.doorlock.UnlockDoorCommand; -import com.zsmartsystems.zigbee.zcl.clusters.doorlock.UnlockDoorResponse; -import com.zsmartsystems.zigbee.zcl.clusters.doorlock.UnlockWithTimeout; -import com.zsmartsystems.zigbee.zcl.clusters.doorlock.UnlockWithTimeoutResponse; -import com.zsmartsystems.zigbee.zcl.clusters.electricalmeasurement.GetMeasurementProfileCommand; -import com.zsmartsystems.zigbee.zcl.clusters.electricalmeasurement.GetMeasurementProfileResponseCommand; -import com.zsmartsystems.zigbee.zcl.clusters.electricalmeasurement.GetProfileInfoCommand; -import com.zsmartsystems.zigbee.zcl.clusters.electricalmeasurement.GetProfileInfoResponseCommand; -import com.zsmartsystems.zigbee.zcl.clusters.general.ConfigureReportingCommand; -import com.zsmartsystems.zigbee.zcl.clusters.general.ConfigureReportingResponse; -import com.zsmartsystems.zigbee.zcl.clusters.general.DefaultResponse; -import com.zsmartsystems.zigbee.zcl.clusters.general.DiscoverAttributesCommand; -import com.zsmartsystems.zigbee.zcl.clusters.general.DiscoverAttributesExtended; -import com.zsmartsystems.zigbee.zcl.clusters.general.DiscoverAttributesExtendedResponse; -import com.zsmartsystems.zigbee.zcl.clusters.general.DiscoverAttributesResponse; -import com.zsmartsystems.zigbee.zcl.clusters.general.DiscoverCommandsGenerated; -import com.zsmartsystems.zigbee.zcl.clusters.general.DiscoverCommandsGeneratedResponse; -import com.zsmartsystems.zigbee.zcl.clusters.general.DiscoverCommandsReceived; -import com.zsmartsystems.zigbee.zcl.clusters.general.DiscoverCommandsReceivedResponse; -import com.zsmartsystems.zigbee.zcl.clusters.general.ReadAttributesCommand; -import com.zsmartsystems.zigbee.zcl.clusters.general.ReadAttributesResponse; -import com.zsmartsystems.zigbee.zcl.clusters.general.ReadAttributesStructuredCommand; -import com.zsmartsystems.zigbee.zcl.clusters.general.ReadReportingConfigurationCommand; -import com.zsmartsystems.zigbee.zcl.clusters.general.ReadReportingConfigurationResponse; -import com.zsmartsystems.zigbee.zcl.clusters.general.ReportAttributesCommand; -import com.zsmartsystems.zigbee.zcl.clusters.general.WriteAttributesCommand; -import com.zsmartsystems.zigbee.zcl.clusters.general.WriteAttributesNoResponse; -import com.zsmartsystems.zigbee.zcl.clusters.general.WriteAttributesResponse; -import com.zsmartsystems.zigbee.zcl.clusters.general.WriteAttributesStructuredCommand; -import com.zsmartsystems.zigbee.zcl.clusters.general.WriteAttributesStructuredResponse; -import com.zsmartsystems.zigbee.zcl.clusters.general.WriteAttributesUndividedCommand; -import com.zsmartsystems.zigbee.zcl.clusters.groups.AddGroupCommand; -import com.zsmartsystems.zigbee.zcl.clusters.groups.AddGroupIfIdentifyingCommand; -import com.zsmartsystems.zigbee.zcl.clusters.groups.AddGroupResponse; -import com.zsmartsystems.zigbee.zcl.clusters.groups.GetGroupMembershipCommand; -import com.zsmartsystems.zigbee.zcl.clusters.groups.GetGroupMembershipResponse; -import com.zsmartsystems.zigbee.zcl.clusters.groups.RemoveAllGroupsCommand; -import com.zsmartsystems.zigbee.zcl.clusters.groups.RemoveGroupCommand; -import com.zsmartsystems.zigbee.zcl.clusters.groups.RemoveGroupResponse; -import com.zsmartsystems.zigbee.zcl.clusters.groups.ViewGroupCommand; -import com.zsmartsystems.zigbee.zcl.clusters.groups.ViewGroupResponse; -import com.zsmartsystems.zigbee.zcl.clusters.iasace.ArmCommand; -import com.zsmartsystems.zigbee.zcl.clusters.iasace.ArmResponse; -import com.zsmartsystems.zigbee.zcl.clusters.iasace.BypassCommand; -import com.zsmartsystems.zigbee.zcl.clusters.iasace.BypassResponse; -import com.zsmartsystems.zigbee.zcl.clusters.iasace.EmergencyCommand; -import com.zsmartsystems.zigbee.zcl.clusters.iasace.FireCommand; -import com.zsmartsystems.zigbee.zcl.clusters.iasace.GetBypassedZoneListCommand; -import com.zsmartsystems.zigbee.zcl.clusters.iasace.GetPanelStatusCommand; -import com.zsmartsystems.zigbee.zcl.clusters.iasace.GetPanelStatusResponse; -import com.zsmartsystems.zigbee.zcl.clusters.iasace.GetZoneIdMapCommand; -import com.zsmartsystems.zigbee.zcl.clusters.iasace.GetZoneIdMapResponse; -import com.zsmartsystems.zigbee.zcl.clusters.iasace.GetZoneInformationCommand; -import com.zsmartsystems.zigbee.zcl.clusters.iasace.GetZoneInformationResponse; -import com.zsmartsystems.zigbee.zcl.clusters.iasace.GetZoneStatusCommand; -import com.zsmartsystems.zigbee.zcl.clusters.iasace.GetZoneStatusResponse; -import com.zsmartsystems.zigbee.zcl.clusters.iasace.PanelStatusChangedCommand; -import com.zsmartsystems.zigbee.zcl.clusters.iasace.PanicCommand; -import com.zsmartsystems.zigbee.zcl.clusters.iasace.SetBypassedZoneListCommand; -import com.zsmartsystems.zigbee.zcl.clusters.iasace.ZoneStatusChangedCommand; -import com.zsmartsystems.zigbee.zcl.clusters.iaswd.Squawk; -import com.zsmartsystems.zigbee.zcl.clusters.iaswd.StartWarningCommand; -import com.zsmartsystems.zigbee.zcl.clusters.iaszone.InitiateNormalOperationModeCommand; -import com.zsmartsystems.zigbee.zcl.clusters.iaszone.InitiateTestModeCommand; -import com.zsmartsystems.zigbee.zcl.clusters.iaszone.ZoneEnrollRequestCommand; -import com.zsmartsystems.zigbee.zcl.clusters.iaszone.ZoneEnrollResponse; -import com.zsmartsystems.zigbee.zcl.clusters.iaszone.ZoneStatusChangeNotificationCommand; -import com.zsmartsystems.zigbee.zcl.clusters.identify.IdentifyCommand; -import com.zsmartsystems.zigbee.zcl.clusters.identify.IdentifyQueryCommand; -import com.zsmartsystems.zigbee.zcl.clusters.identify.IdentifyQueryResponse; -import com.zsmartsystems.zigbee.zcl.clusters.keyestablishment.ConfirmKeyDataRequestCommand; -import com.zsmartsystems.zigbee.zcl.clusters.keyestablishment.ConfirmKeyResponse; -import com.zsmartsystems.zigbee.zcl.clusters.keyestablishment.EphemeralDataRequestCommand; -import com.zsmartsystems.zigbee.zcl.clusters.keyestablishment.EphemeralDataResponse; -import com.zsmartsystems.zigbee.zcl.clusters.keyestablishment.InitiateKeyEstablishmentRequestCommand; -import com.zsmartsystems.zigbee.zcl.clusters.keyestablishment.InitiateKeyEstablishmentResponse; -import com.zsmartsystems.zigbee.zcl.clusters.keyestablishment.TerminateKeyEstablishment; -import com.zsmartsystems.zigbee.zcl.clusters.levelcontrol.MoveCommand; -import com.zsmartsystems.zigbee.zcl.clusters.levelcontrol.MoveToLevelCommand; -import com.zsmartsystems.zigbee.zcl.clusters.levelcontrol.MoveToLevelWithOnOffCommand; -import com.zsmartsystems.zigbee.zcl.clusters.levelcontrol.MoveWithOnOffCommand; -import com.zsmartsystems.zigbee.zcl.clusters.levelcontrol.StepCommand; -import com.zsmartsystems.zigbee.zcl.clusters.levelcontrol.StepWithOnOffCommand; -import com.zsmartsystems.zigbee.zcl.clusters.levelcontrol.Stop2Command; -import com.zsmartsystems.zigbee.zcl.clusters.levelcontrol.StopCommand; -import com.zsmartsystems.zigbee.zcl.clusters.messaging.CancelAllMessages; -import com.zsmartsystems.zigbee.zcl.clusters.messaging.CancelAllMessagesCommand; -import com.zsmartsystems.zigbee.zcl.clusters.messaging.CancelMessageCommand; -import com.zsmartsystems.zigbee.zcl.clusters.messaging.DisplayMessageCommand; -import com.zsmartsystems.zigbee.zcl.clusters.messaging.DisplayProtectedMessageCommand; -import com.zsmartsystems.zigbee.zcl.clusters.messaging.GetLastMessage; -import com.zsmartsystems.zigbee.zcl.clusters.messaging.GetMessageCancellation; -import com.zsmartsystems.zigbee.zcl.clusters.messaging.MessageConfirmation; -import com.zsmartsystems.zigbee.zcl.clusters.metering.ChangeSupply; -import com.zsmartsystems.zigbee.zcl.clusters.metering.ConfigureMirror; -import com.zsmartsystems.zigbee.zcl.clusters.metering.ConfigureNotificationFlags; -import com.zsmartsystems.zigbee.zcl.clusters.metering.ConfigureNotificationScheme; -import com.zsmartsystems.zigbee.zcl.clusters.metering.GetNotifiedMessage; -import com.zsmartsystems.zigbee.zcl.clusters.metering.GetProfile; -import com.zsmartsystems.zigbee.zcl.clusters.metering.GetProfileResponse; -import com.zsmartsystems.zigbee.zcl.clusters.metering.GetSampledData; -import com.zsmartsystems.zigbee.zcl.clusters.metering.GetSampledDataResponse; -import com.zsmartsystems.zigbee.zcl.clusters.metering.GetSnapshot; -import com.zsmartsystems.zigbee.zcl.clusters.metering.LocalChangeSupply; -import com.zsmartsystems.zigbee.zcl.clusters.metering.MirrorRemoved; -import com.zsmartsystems.zigbee.zcl.clusters.metering.MirrorReportAttributeResponse; -import com.zsmartsystems.zigbee.zcl.clusters.metering.PublishSnapshot; -import com.zsmartsystems.zigbee.zcl.clusters.metering.RemoveMirror; -import com.zsmartsystems.zigbee.zcl.clusters.metering.RequestFastPollMode; -import com.zsmartsystems.zigbee.zcl.clusters.metering.RequestFastPollModeResponse; -import com.zsmartsystems.zigbee.zcl.clusters.metering.RequestMirror; -import com.zsmartsystems.zigbee.zcl.clusters.metering.RequestMirrorResponse; -import com.zsmartsystems.zigbee.zcl.clusters.metering.ResetLoadLimitCounter; -import com.zsmartsystems.zigbee.zcl.clusters.metering.ScheduleSnapshot; -import com.zsmartsystems.zigbee.zcl.clusters.metering.ScheduleSnapshotResponse; -import com.zsmartsystems.zigbee.zcl.clusters.metering.SetSupplyStatus; -import com.zsmartsystems.zigbee.zcl.clusters.metering.SetUncontrolledFlowThreshold; -import com.zsmartsystems.zigbee.zcl.clusters.metering.StartSampling; -import com.zsmartsystems.zigbee.zcl.clusters.metering.StartSamplingResponse; -import com.zsmartsystems.zigbee.zcl.clusters.metering.SupplyStatusResponse; -import com.zsmartsystems.zigbee.zcl.clusters.metering.TakeSnapshot; -import com.zsmartsystems.zigbee.zcl.clusters.metering.TakeSnapshotResponse; -import com.zsmartsystems.zigbee.zcl.clusters.onoff.OffCommand; -import com.zsmartsystems.zigbee.zcl.clusters.onoff.OffWithEffectCommand; -import com.zsmartsystems.zigbee.zcl.clusters.onoff.OnCommand; -import com.zsmartsystems.zigbee.zcl.clusters.onoff.OnWithRecallGlobalSceneCommand; -import com.zsmartsystems.zigbee.zcl.clusters.onoff.OnWithTimedOffCommand; -import com.zsmartsystems.zigbee.zcl.clusters.onoff.ToggleCommand; -import com.zsmartsystems.zigbee.zcl.clusters.otaupgrade.ImageBlockCommand; -import com.zsmartsystems.zigbee.zcl.clusters.otaupgrade.ImageBlockResponse; -import com.zsmartsystems.zigbee.zcl.clusters.otaupgrade.ImageNotifyCommand; -import com.zsmartsystems.zigbee.zcl.clusters.otaupgrade.ImagePageCommand; -import com.zsmartsystems.zigbee.zcl.clusters.otaupgrade.QueryNextImageCommand; -import com.zsmartsystems.zigbee.zcl.clusters.otaupgrade.QueryNextImageResponse; -import com.zsmartsystems.zigbee.zcl.clusters.otaupgrade.QuerySpecificFileCommand; -import com.zsmartsystems.zigbee.zcl.clusters.otaupgrade.QuerySpecificFileResponse; -import com.zsmartsystems.zigbee.zcl.clusters.otaupgrade.UpgradeEndCommand; -import com.zsmartsystems.zigbee.zcl.clusters.otaupgrade.UpgradeEndResponse; -import com.zsmartsystems.zigbee.zcl.clusters.pollcontrol.CheckInCommand; -import com.zsmartsystems.zigbee.zcl.clusters.pollcontrol.CheckInResponse; -import com.zsmartsystems.zigbee.zcl.clusters.pollcontrol.FastPollStopCommand; -import com.zsmartsystems.zigbee.zcl.clusters.pollcontrol.SetLongPollIntervalCommand; -import com.zsmartsystems.zigbee.zcl.clusters.pollcontrol.SetShortPollIntervalCommand; -import com.zsmartsystems.zigbee.zcl.clusters.prepayment.ChangeDebt; -import com.zsmartsystems.zigbee.zcl.clusters.prepayment.ChangePaymentMode; -import com.zsmartsystems.zigbee.zcl.clusters.prepayment.ChangePaymentModeResponse; -import com.zsmartsystems.zigbee.zcl.clusters.prepayment.ConsumerTopUp; -import com.zsmartsystems.zigbee.zcl.clusters.prepayment.ConsumerTopUpResponse; -import com.zsmartsystems.zigbee.zcl.clusters.prepayment.CreditAdjustment; -import com.zsmartsystems.zigbee.zcl.clusters.prepayment.EmergencyCreditSetup; -import com.zsmartsystems.zigbee.zcl.clusters.prepayment.GetDebtRepaymentLog; -import com.zsmartsystems.zigbee.zcl.clusters.prepayment.GetPrepaySnapshot; -import com.zsmartsystems.zigbee.zcl.clusters.prepayment.GetTopUpLog; -import com.zsmartsystems.zigbee.zcl.clusters.prepayment.PublishDebtLog; -import com.zsmartsystems.zigbee.zcl.clusters.prepayment.PublishPrepaySnapshot; -import com.zsmartsystems.zigbee.zcl.clusters.prepayment.PublishTopUpLog; -import com.zsmartsystems.zigbee.zcl.clusters.prepayment.SelectAvailableEmergencyCredit; -import com.zsmartsystems.zigbee.zcl.clusters.prepayment.SetLowCreditWarningLevel; -import com.zsmartsystems.zigbee.zcl.clusters.prepayment.SetMaximumCreditLimit; -import com.zsmartsystems.zigbee.zcl.clusters.prepayment.SetOverallDebtCap; -import com.zsmartsystems.zigbee.zcl.clusters.price.CancelTariffCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.CppEventResponse; -import com.zsmartsystems.zigbee.zcl.clusters.price.GetBillingPeriodCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.GetBlockPeriodCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.GetBlockThresholdsCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.GetCalorificValueCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.GetCo2ValueCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.GetConsolidatedBillCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.GetConversionFactorCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.GetCreditPaymentCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.GetCurrencyConversionCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.GetCurrentPriceCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.GetPriceMatrixCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.GetScheduledPricesCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.GetTariffCancellationCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.GetTariffInformationCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.GetTierLabelsCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.PriceAcknowledgementCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.PublishBillingPeriodCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.PublishBlockPeriodCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.PublishBlockThresholdsCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.PublishCalorificValueCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.PublishCo2ValueCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.PublishConsolidatedBillCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.PublishConversionFactorCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.PublishCppEventCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.PublishCreditPaymentCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.PublishCurrencyConversionCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.PublishPriceCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.PublishPriceMatrixCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.PublishTariffInformationCommand; -import com.zsmartsystems.zigbee.zcl.clusters.price.PublishTierLabelsCommand; -import com.zsmartsystems.zigbee.zcl.clusters.rssilocation.AnchorNodeAnnounceCommand; -import com.zsmartsystems.zigbee.zcl.clusters.rssilocation.CompactLocationDataNotificationCommand; -import com.zsmartsystems.zigbee.zcl.clusters.rssilocation.DeviceConfigurationResponse; -import com.zsmartsystems.zigbee.zcl.clusters.rssilocation.GetDeviceConfigurationCommand; -import com.zsmartsystems.zigbee.zcl.clusters.rssilocation.GetLocationDataCommand; -import com.zsmartsystems.zigbee.zcl.clusters.rssilocation.LocationDataNotificationCommand; -import com.zsmartsystems.zigbee.zcl.clusters.rssilocation.LocationDataResponse; -import com.zsmartsystems.zigbee.zcl.clusters.rssilocation.ReportRssiMeasurementsCommand; -import com.zsmartsystems.zigbee.zcl.clusters.rssilocation.RequestOwnLocationCommand; -import com.zsmartsystems.zigbee.zcl.clusters.rssilocation.RssiPingCommand; -import com.zsmartsystems.zigbee.zcl.clusters.rssilocation.RssiRequestCommand; -import com.zsmartsystems.zigbee.zcl.clusters.rssilocation.RssiResponse; -import com.zsmartsystems.zigbee.zcl.clusters.rssilocation.SendPingsCommand; -import com.zsmartsystems.zigbee.zcl.clusters.rssilocation.SetAbsoluteLocationCommand; -import com.zsmartsystems.zigbee.zcl.clusters.rssilocation.SetDeviceConfigurationCommand; -import com.zsmartsystems.zigbee.zcl.clusters.scenes.AddSceneCommand; -import com.zsmartsystems.zigbee.zcl.clusters.scenes.AddSceneResponse; -import com.zsmartsystems.zigbee.zcl.clusters.scenes.GetSceneMembershipCommand; -import com.zsmartsystems.zigbee.zcl.clusters.scenes.GetSceneMembershipResponse; -import com.zsmartsystems.zigbee.zcl.clusters.scenes.RecallSceneCommand; -import com.zsmartsystems.zigbee.zcl.clusters.scenes.RemoveAllScenesCommand; -import com.zsmartsystems.zigbee.zcl.clusters.scenes.RemoveAllScenesResponse; -import com.zsmartsystems.zigbee.zcl.clusters.scenes.RemoveSceneCommand; -import com.zsmartsystems.zigbee.zcl.clusters.scenes.RemoveSceneResponse; -import com.zsmartsystems.zigbee.zcl.clusters.scenes.StoreSceneCommand; -import com.zsmartsystems.zigbee.zcl.clusters.scenes.StoreSceneResponse; -import com.zsmartsystems.zigbee.zcl.clusters.scenes.ViewSceneCommand; -import com.zsmartsystems.zigbee.zcl.clusters.scenes.ViewSceneResponse; -import com.zsmartsystems.zigbee.zcl.clusters.smartenergytunneling.AckTransferDataClientToServer; -import com.zsmartsystems.zigbee.zcl.clusters.smartenergytunneling.AckTransferDataServerToClient; -import com.zsmartsystems.zigbee.zcl.clusters.smartenergytunneling.CloseTunnel; -import com.zsmartsystems.zigbee.zcl.clusters.smartenergytunneling.GetSupportedTunnelProtocols; -import com.zsmartsystems.zigbee.zcl.clusters.smartenergytunneling.ReadyDataClientToServer; -import com.zsmartsystems.zigbee.zcl.clusters.smartenergytunneling.ReadyDataServerToClient; -import com.zsmartsystems.zigbee.zcl.clusters.smartenergytunneling.RequestTunnel; -import com.zsmartsystems.zigbee.zcl.clusters.smartenergytunneling.RequestTunnelResponse; -import com.zsmartsystems.zigbee.zcl.clusters.smartenergytunneling.SupportedTunnelProtocolsResponse; -import com.zsmartsystems.zigbee.zcl.clusters.smartenergytunneling.TransferDataClientToServer; -import com.zsmartsystems.zigbee.zcl.clusters.smartenergytunneling.TransferDataErrorClientToServer; -import com.zsmartsystems.zigbee.zcl.clusters.smartenergytunneling.TransferDataErrorServerToClient; -import com.zsmartsystems.zigbee.zcl.clusters.smartenergytunneling.TransferDataServerToClient; -import com.zsmartsystems.zigbee.zcl.clusters.smartenergytunneling.TunnelClosureNotification; -import com.zsmartsystems.zigbee.zcl.clusters.thermostat.ClearWeeklySchedule; -import com.zsmartsystems.zigbee.zcl.clusters.thermostat.GetRelayStatusLog; -import com.zsmartsystems.zigbee.zcl.clusters.thermostat.GetRelayStatusLogResponse; -import com.zsmartsystems.zigbee.zcl.clusters.thermostat.GetWeeklySchedule; -import com.zsmartsystems.zigbee.zcl.clusters.thermostat.GetWeeklyScheduleResponse; -import com.zsmartsystems.zigbee.zcl.clusters.thermostat.SetWeeklySchedule; -import com.zsmartsystems.zigbee.zcl.clusters.thermostat.SetpointRaiseLowerCommand; -import com.zsmartsystems.zigbee.zcl.clusters.windowcovering.WindowCoveringDownClose; -import com.zsmartsystems.zigbee.zcl.clusters.windowcovering.WindowCoveringGoToLiftPercentage; -import com.zsmartsystems.zigbee.zcl.clusters.windowcovering.WindowCoveringGoToLiftValue; -import com.zsmartsystems.zigbee.zcl.clusters.windowcovering.WindowCoveringGoToTiltPercentage; -import com.zsmartsystems.zigbee.zcl.clusters.windowcovering.WindowCoveringGoToTiltValue; -import com.zsmartsystems.zigbee.zcl.clusters.windowcovering.WindowCoveringStop; -import com.zsmartsystems.zigbee.zcl.clusters.windowcovering.WindowCoveringUpOpen; -import com.zsmartsystems.zigbee.zcl.protocol.ZclCommandDirection; - -@Generated(value = "com.zsmartsystems.zigbee.autocode.ZigBeeCodeGenerator", date = "2019-02-09T15:23:12Z") -public enum ZclCommandType { - /** - * ALARM_COMMAND: Alarm Command - *

- * See {@link AlarmCommand} - */ - ALARM_COMMAND(0x0009, 0, AlarmCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * GET_ALARM_COMMAND: Get Alarm Command - *

- * See {@link GetAlarmCommand} - */ - GET_ALARM_COMMAND(0x0009, 2, GetAlarmCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_ALARM_RESPONSE: Get Alarm Response - *

- * See {@link GetAlarmResponse} - */ - GET_ALARM_RESPONSE(0x0009, 1, GetAlarmResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * RESET_ALARM_COMMAND: Reset Alarm Command - *

- * See {@link ResetAlarmCommand} - */ - RESET_ALARM_COMMAND(0x0009, 0, ResetAlarmCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * RESET_ALARM_LOG_COMMAND: Reset Alarm Log Command - *

- * See {@link ResetAlarmLogCommand} - */ - RESET_ALARM_LOG_COMMAND(0x0009, 3, ResetAlarmLogCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * RESET_ALL_ALARMS_COMMAND: Reset All Alarms Command - *

- * See {@link ResetAllAlarmsCommand} - */ - RESET_ALL_ALARMS_COMMAND(0x0009, 1, ResetAllAlarmsCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * RESET_TO_FACTORY_DEFAULTS_COMMAND: Reset To Factory Defaults Command - *

- * See {@link ResetToFactoryDefaultsCommand} - */ - RESET_TO_FACTORY_DEFAULTS_COMMAND(0x0000, 0, ResetToFactoryDefaultsCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * COLOR_LOOP_SET_COMMAND: Color Loop Set Command - *

- * See {@link ColorLoopSetCommand} - */ - COLOR_LOOP_SET_COMMAND(0x0300, 67, ColorLoopSetCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * ENHANCED_MOVE_TO_HUE_AND_SATURATION_COMMAND: Enhanced Move To Hue And Saturation Command - *

- * See {@link EnhancedMoveToHueAndSaturationCommand} - */ - ENHANCED_MOVE_TO_HUE_AND_SATURATION_COMMAND(0x0300, 66, EnhancedMoveToHueAndSaturationCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * ENHANCED_MOVE_TO_HUE_COMMAND: Enhanced Move To Hue Command - *

- * See {@link EnhancedMoveToHueCommand} - */ - ENHANCED_MOVE_TO_HUE_COMMAND(0x0300, 64, EnhancedMoveToHueCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * ENHANCED_STEP_HUE_COMMAND: Enhanced Step Hue Command - *

- * See {@link EnhancedStepHueCommand} - */ - ENHANCED_STEP_HUE_COMMAND(0x0300, 65, EnhancedStepHueCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * MOVE_COLOR_COMMAND: Move Color Command - *

- * See {@link MoveColorCommand} - */ - MOVE_COLOR_COMMAND(0x0300, 8, MoveColorCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * MOVE_HUE_COMMAND: Move Hue Command - *

- * See {@link MoveHueCommand} - */ - MOVE_HUE_COMMAND(0x0300, 1, MoveHueCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * MOVE_SATURATION_COMMAND: Move Saturation Command - *

- * See {@link MoveSaturationCommand} - */ - MOVE_SATURATION_COMMAND(0x0300, 4, MoveSaturationCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * MOVE_TO_COLOR_COMMAND: Move To Color Command - *

- * See {@link MoveToColorCommand} - */ - MOVE_TO_COLOR_COMMAND(0x0300, 7, MoveToColorCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * MOVE_TO_COLOR_TEMPERATURE_COMMAND: Move To Color Temperature Command - *

- * See {@link MoveToColorTemperatureCommand} - */ - MOVE_TO_COLOR_TEMPERATURE_COMMAND(0x0300, 10, MoveToColorTemperatureCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * MOVE_TO_HUE_AND_SATURATION_COMMAND: Move To Hue And Saturation Command - *

- * See {@link MoveToHueAndSaturationCommand} - */ - MOVE_TO_HUE_AND_SATURATION_COMMAND(0x0300, 6, MoveToHueAndSaturationCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * MOVE_TO_HUE_COMMAND: Move To Hue Command - *

- * See {@link MoveToHueCommand} - */ - MOVE_TO_HUE_COMMAND(0x0300, 0, MoveToHueCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * MOVE_TO_SATURATION_COMMAND: Move To Saturation Command - *

- * See {@link MoveToSaturationCommand} - */ - MOVE_TO_SATURATION_COMMAND(0x0300, 3, MoveToSaturationCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * STEP_COLOR_COMMAND: Step Color Command - *

- * See {@link StepColorCommand} - */ - STEP_COLOR_COMMAND(0x0300, 9, StepColorCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * STEP_HUE_COMMAND: Step Hue Command - *

- * See {@link StepHueCommand} - */ - STEP_HUE_COMMAND(0x0300, 2, StepHueCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * STEP_SATURATION_COMMAND: Step Saturation Command - *

- * See {@link StepSaturationCommand} - */ - STEP_SATURATION_COMMAND(0x0300, 5, StepSaturationCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * CANCEL_ALL_LOAD_CONTROL_EVENTS: Cancel All Load Control Events - *

- * See {@link CancelAllLoadControlEvents} - */ - CANCEL_ALL_LOAD_CONTROL_EVENTS(0x0701, 2, CancelAllLoadControlEvents.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * CANCEL_LOAD_CONTROL_EVENT: Cancel Load Control Event - *

- * See {@link CancelLoadControlEvent} - */ - CANCEL_LOAD_CONTROL_EVENT(0x0701, 1, CancelLoadControlEvent.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * GET_SCHEDULED_EVENTS: Get Scheduled Events - *

- * See {@link GetScheduledEvents} - */ - GET_SCHEDULED_EVENTS(0x0701, 1, GetScheduledEvents.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * LOAD_CONTROL_EVENT_COMMAND: Load Control Event Command - *

- * See {@link LoadControlEventCommand} - */ - LOAD_CONTROL_EVENT_COMMAND(0x0701, 0, LoadControlEventCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * REPORT_EVENT_STATUS: Report Event Status - *

- * See {@link ReportEventStatus} - */ - REPORT_EVENT_STATUS(0x0701, 0, ReportEventStatus.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * LOCK_DOOR_COMMAND: Lock Door Command - *

- * See {@link LockDoorCommand} - */ - LOCK_DOOR_COMMAND(0x0101, 0, LockDoorCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * LOCK_DOOR_RESPONSE: Lock Door Response - *

- * See {@link LockDoorResponse} - */ - LOCK_DOOR_RESPONSE(0x0101, 0, LockDoorResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * TOGGLE: Toggle - *

- * See {@link Toggle} - */ - TOGGLE(0x0101, 2, Toggle.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * TOGGLE_RESPONSE: Toggle Response - *

- * See {@link ToggleResponse} - */ - TOGGLE_RESPONSE(0x0101, 2, ToggleResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * UNLOCK_DOOR_COMMAND: Unlock Door Command - *

- * See {@link UnlockDoorCommand} - */ - UNLOCK_DOOR_COMMAND(0x0101, 1, UnlockDoorCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * UNLOCK_DOOR_RESPONSE: Unlock Door Response - *

- * See {@link UnlockDoorResponse} - */ - UNLOCK_DOOR_RESPONSE(0x0101, 1, UnlockDoorResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * UNLOCK_WITH_TIMEOUT: Unlock With Timeout - *

- * See {@link UnlockWithTimeout} - */ - UNLOCK_WITH_TIMEOUT(0x0101, 3, UnlockWithTimeout.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * UNLOCK_WITH_TIMEOUT_RESPONSE: Unlock With Timeout Response - *

- * See {@link UnlockWithTimeoutResponse} - */ - UNLOCK_WITH_TIMEOUT_RESPONSE(0x0101, 3, UnlockWithTimeoutResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * GET_MEASUREMENT_PROFILE_COMMAND: Get Measurement Profile Command - *

- * See {@link GetMeasurementProfileCommand} - */ - GET_MEASUREMENT_PROFILE_COMMAND(0x0B04, 1, GetMeasurementProfileCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_MEASUREMENT_PROFILE_RESPONSE_COMMAND: Get Measurement Profile Response Command - *

- * See {@link GetMeasurementProfileResponseCommand} - */ - GET_MEASUREMENT_PROFILE_RESPONSE_COMMAND(0x0B04, 1, GetMeasurementProfileResponseCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * GET_PROFILE_INFO_COMMAND: Get Profile Info Command - *

- * See {@link GetProfileInfoCommand} - */ - GET_PROFILE_INFO_COMMAND(0x0B04, 0, GetProfileInfoCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_PROFILE_INFO_RESPONSE_COMMAND: Get Profile Info Response Command - *

- * See {@link GetProfileInfoResponseCommand} - */ - GET_PROFILE_INFO_RESPONSE_COMMAND(0x0B04, 0, GetProfileInfoResponseCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * CONFIGURE_REPORTING_COMMAND: Configure Reporting Command - *

- * See {@link ConfigureReportingCommand} - */ - CONFIGURE_REPORTING_COMMAND(0xFFFF, 6, ConfigureReportingCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * CONFIGURE_REPORTING_RESPONSE: Configure Reporting Response - *

- * See {@link ConfigureReportingResponse} - */ - CONFIGURE_REPORTING_RESPONSE(0xFFFF, 7, ConfigureReportingResponse.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * DEFAULT_RESPONSE: Default Response - *

- * See {@link DefaultResponse} - */ - DEFAULT_RESPONSE(0xFFFF, 11, DefaultResponse.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * DISCOVER_ATTRIBUTES_COMMAND: Discover Attributes Command - *

- * See {@link DiscoverAttributesCommand} - */ - DISCOVER_ATTRIBUTES_COMMAND(0xFFFF, 12, DiscoverAttributesCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * DISCOVER_ATTRIBUTES_EXTENDED: Discover Attributes Extended - *

- * See {@link DiscoverAttributesExtended} - */ - DISCOVER_ATTRIBUTES_EXTENDED(0xFFFF, 21, DiscoverAttributesExtended.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * DISCOVER_ATTRIBUTES_EXTENDED_RESPONSE: Discover Attributes Extended Response - *

- * See {@link DiscoverAttributesExtendedResponse} - */ - DISCOVER_ATTRIBUTES_EXTENDED_RESPONSE(0xFFFF, 22, DiscoverAttributesExtendedResponse.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * DISCOVER_ATTRIBUTES_RESPONSE: Discover Attributes Response - *

- * See {@link DiscoverAttributesResponse} - */ - DISCOVER_ATTRIBUTES_RESPONSE(0xFFFF, 13, DiscoverAttributesResponse.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * DISCOVER_COMMANDS_GENERATED: Discover Commands Generated - *

- * See {@link DiscoverCommandsGenerated} - */ - DISCOVER_COMMANDS_GENERATED(0xFFFF, 19, DiscoverCommandsGenerated.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * DISCOVER_COMMANDS_GENERATED_RESPONSE: Discover Commands Generated Response - *

- * See {@link DiscoverCommandsGeneratedResponse} - */ - DISCOVER_COMMANDS_GENERATED_RESPONSE(0xFFFF, 20, DiscoverCommandsGeneratedResponse.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * DISCOVER_COMMANDS_RECEIVED: Discover Commands Received - *

- * See {@link DiscoverCommandsReceived} - */ - DISCOVER_COMMANDS_RECEIVED(0xFFFF, 17, DiscoverCommandsReceived.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * DISCOVER_COMMANDS_RECEIVED_RESPONSE: Discover Commands Received Response - *

- * See {@link DiscoverCommandsReceivedResponse} - */ - DISCOVER_COMMANDS_RECEIVED_RESPONSE(0xFFFF, 18, DiscoverCommandsReceivedResponse.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * READ_ATTRIBUTES_COMMAND: Read Attributes Command - *

- * See {@link ReadAttributesCommand} - */ - READ_ATTRIBUTES_COMMAND(0xFFFF, 0, ReadAttributesCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * READ_ATTRIBUTES_RESPONSE: Read Attributes Response - *

- * See {@link ReadAttributesResponse} - */ - READ_ATTRIBUTES_RESPONSE(0xFFFF, 1, ReadAttributesResponse.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * READ_ATTRIBUTES_STRUCTURED_COMMAND: Read Attributes Structured Command - *

- * See {@link ReadAttributesStructuredCommand} - */ - READ_ATTRIBUTES_STRUCTURED_COMMAND(0xFFFF, 14, ReadAttributesStructuredCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * READ_REPORTING_CONFIGURATION_COMMAND: Read Reporting Configuration Command - *

- * See {@link ReadReportingConfigurationCommand} - */ - READ_REPORTING_CONFIGURATION_COMMAND(0xFFFF, 8, ReadReportingConfigurationCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * READ_REPORTING_CONFIGURATION_RESPONSE: Read Reporting Configuration Response - *

- * See {@link ReadReportingConfigurationResponse} - */ - READ_REPORTING_CONFIGURATION_RESPONSE(0xFFFF, 9, ReadReportingConfigurationResponse.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * REPORT_ATTRIBUTES_COMMAND: Report Attributes Command - *

- * See {@link ReportAttributesCommand} - */ - REPORT_ATTRIBUTES_COMMAND(0xFFFF, 10, ReportAttributesCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * WRITE_ATTRIBUTES_COMMAND: Write Attributes Command - *

- * See {@link WriteAttributesCommand} - */ - WRITE_ATTRIBUTES_COMMAND(0xFFFF, 2, WriteAttributesCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * WRITE_ATTRIBUTES_NO_RESPONSE: Write Attributes No Response - *

- * See {@link WriteAttributesNoResponse} - */ - WRITE_ATTRIBUTES_NO_RESPONSE(0xFFFF, 5, WriteAttributesNoResponse.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * WRITE_ATTRIBUTES_RESPONSE: Write Attributes Response - *

- * See {@link WriteAttributesResponse} - */ - WRITE_ATTRIBUTES_RESPONSE(0xFFFF, 4, WriteAttributesResponse.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * WRITE_ATTRIBUTES_STRUCTURED_COMMAND: Write Attributes Structured Command - *

- * See {@link WriteAttributesStructuredCommand} - */ - WRITE_ATTRIBUTES_STRUCTURED_COMMAND(0xFFFF, 15, WriteAttributesStructuredCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * WRITE_ATTRIBUTES_STRUCTURED_RESPONSE: Write Attributes Structured Response - *

- * See {@link WriteAttributesStructuredResponse} - */ - WRITE_ATTRIBUTES_STRUCTURED_RESPONSE(0xFFFF, 16, WriteAttributesStructuredResponse.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * WRITE_ATTRIBUTES_UNDIVIDED_COMMAND: Write Attributes Undivided Command - *

- * See {@link WriteAttributesUndividedCommand} - */ - WRITE_ATTRIBUTES_UNDIVIDED_COMMAND(0xFFFF, 3, WriteAttributesUndividedCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * ADD_GROUP_COMMAND: Add Group Command - *

- * See {@link AddGroupCommand} - */ - ADD_GROUP_COMMAND(0x0004, 0, AddGroupCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * ADD_GROUP_IF_IDENTIFYING_COMMAND: Add Group If Identifying Command - *

- * See {@link AddGroupIfIdentifyingCommand} - */ - ADD_GROUP_IF_IDENTIFYING_COMMAND(0x0004, 5, AddGroupIfIdentifyingCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * ADD_GROUP_RESPONSE: Add Group Response - *

- * See {@link AddGroupResponse} - */ - ADD_GROUP_RESPONSE(0x0004, 0, AddGroupResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * GET_GROUP_MEMBERSHIP_COMMAND: Get Group Membership Command - *

- * See {@link GetGroupMembershipCommand} - */ - GET_GROUP_MEMBERSHIP_COMMAND(0x0004, 2, GetGroupMembershipCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_GROUP_MEMBERSHIP_RESPONSE: Get Group Membership Response - *

- * See {@link GetGroupMembershipResponse} - */ - GET_GROUP_MEMBERSHIP_RESPONSE(0x0004, 2, GetGroupMembershipResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * REMOVE_ALL_GROUPS_COMMAND: Remove All Groups Command - *

- * See {@link RemoveAllGroupsCommand} - */ - REMOVE_ALL_GROUPS_COMMAND(0x0004, 4, RemoveAllGroupsCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * REMOVE_GROUP_COMMAND: Remove Group Command - *

- * See {@link RemoveGroupCommand} - */ - REMOVE_GROUP_COMMAND(0x0004, 3, RemoveGroupCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * REMOVE_GROUP_RESPONSE: Remove Group Response - *

- * See {@link RemoveGroupResponse} - */ - REMOVE_GROUP_RESPONSE(0x0004, 3, RemoveGroupResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * VIEW_GROUP_COMMAND: View Group Command - *

- * See {@link ViewGroupCommand} - */ - VIEW_GROUP_COMMAND(0x0004, 1, ViewGroupCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * VIEW_GROUP_RESPONSE: View Group Response - *

- * See {@link ViewGroupResponse} - */ - VIEW_GROUP_RESPONSE(0x0004, 1, ViewGroupResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * ARM_COMMAND: Arm Command - *

- * See {@link ArmCommand} - */ - ARM_COMMAND(0x0501, 0, ArmCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * ARM_RESPONSE: Arm Response - *

- * See {@link ArmResponse} - */ - ARM_RESPONSE(0x0501, 0, ArmResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * BYPASS_COMMAND: Bypass Command - *

- * See {@link BypassCommand} - */ - BYPASS_COMMAND(0x0501, 1, BypassCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * BYPASS_RESPONSE: Bypass Response - *

- * See {@link BypassResponse} - */ - BYPASS_RESPONSE(0x0501, 7, BypassResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * EMERGENCY_COMMAND: Emergency Command - *

- * See {@link EmergencyCommand} - */ - EMERGENCY_COMMAND(0x0501, 2, EmergencyCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * FIRE_COMMAND: Fire Command - *

- * See {@link FireCommand} - */ - FIRE_COMMAND(0x0501, 3, FireCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_BYPASSED_ZONE_LIST_COMMAND: Get Bypassed Zone List Command - *

- * See {@link GetBypassedZoneListCommand} - */ - GET_BYPASSED_ZONE_LIST_COMMAND(0x0501, 8, GetBypassedZoneListCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_PANEL_STATUS_COMMAND: Get Panel Status Command - *

- * See {@link GetPanelStatusCommand} - */ - GET_PANEL_STATUS_COMMAND(0x0501, 7, GetPanelStatusCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_PANEL_STATUS_RESPONSE: Get Panel Status Response - *

- * See {@link GetPanelStatusResponse} - */ - GET_PANEL_STATUS_RESPONSE(0x0501, 5, GetPanelStatusResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * GET_ZONE_ID_MAP_COMMAND: Get Zone ID Map Command - *

- * See {@link GetZoneIdMapCommand} - */ - GET_ZONE_ID_MAP_COMMAND(0x0501, 5, GetZoneIdMapCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_ZONE_ID_MAP_RESPONSE: Get Zone ID Map Response - *

- * See {@link GetZoneIdMapResponse} - */ - GET_ZONE_ID_MAP_RESPONSE(0x0501, 1, GetZoneIdMapResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * GET_ZONE_INFORMATION_COMMAND: Get Zone Information Command - *

- * See {@link GetZoneInformationCommand} - */ - GET_ZONE_INFORMATION_COMMAND(0x0501, 6, GetZoneInformationCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_ZONE_INFORMATION_RESPONSE: Get Zone Information Response - *

- * See {@link GetZoneInformationResponse} - */ - GET_ZONE_INFORMATION_RESPONSE(0x0501, 2, GetZoneInformationResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * GET_ZONE_STATUS_COMMAND: Get Zone Status Command - *

- * See {@link GetZoneStatusCommand} - */ - GET_ZONE_STATUS_COMMAND(0x0501, 9, GetZoneStatusCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_ZONE_STATUS_RESPONSE: Get Zone Status Response - *

- * See {@link GetZoneStatusResponse} - */ - GET_ZONE_STATUS_RESPONSE(0x0501, 8, GetZoneStatusResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * PANEL_STATUS_CHANGED_COMMAND: Panel Status Changed Command - *

- * See {@link PanelStatusChangedCommand} - */ - PANEL_STATUS_CHANGED_COMMAND(0x0501, 4, PanelStatusChangedCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * PANIC_COMMAND: Panic Command - *

- * See {@link PanicCommand} - */ - PANIC_COMMAND(0x0501, 4, PanicCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * SET_BYPASSED_ZONE_LIST_COMMAND: Set Bypassed Zone List Command - *

- * See {@link SetBypassedZoneListCommand} - */ - SET_BYPASSED_ZONE_LIST_COMMAND(0x0501, 6, SetBypassedZoneListCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * ZONE_STATUS_CHANGED_COMMAND: Zone Status Changed Command - *

- * See {@link ZoneStatusChangedCommand} - */ - ZONE_STATUS_CHANGED_COMMAND(0x0501, 3, ZoneStatusChangedCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * SQUAWK: Squawk - *

- * See {@link Squawk} - */ - SQUAWK(0x0502, 1, Squawk.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * START_WARNING_COMMAND: Start Warning Command - *

- * See {@link StartWarningCommand} - */ - START_WARNING_COMMAND(0x0502, 0, StartWarningCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * INITIATE_NORMAL_OPERATION_MODE_COMMAND: Initiate Normal Operation Mode Command - *

- * See {@link InitiateNormalOperationModeCommand} - */ - INITIATE_NORMAL_OPERATION_MODE_COMMAND(0x0500, 1, InitiateNormalOperationModeCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * INITIATE_TEST_MODE_COMMAND: Initiate Test Mode Command - *

- * See {@link InitiateTestModeCommand} - */ - INITIATE_TEST_MODE_COMMAND(0x0500, 2, InitiateTestModeCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * ZONE_ENROLL_REQUEST_COMMAND: Zone Enroll Request Command - *

- * See {@link ZoneEnrollRequestCommand} - */ - ZONE_ENROLL_REQUEST_COMMAND(0x0500, 1, ZoneEnrollRequestCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * ZONE_ENROLL_RESPONSE: Zone Enroll Response - *

- * See {@link ZoneEnrollResponse} - */ - ZONE_ENROLL_RESPONSE(0x0500, 0, ZoneEnrollResponse.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * ZONE_STATUS_CHANGE_NOTIFICATION_COMMAND: Zone Status Change Notification Command - *

- * See {@link ZoneStatusChangeNotificationCommand} - */ - ZONE_STATUS_CHANGE_NOTIFICATION_COMMAND(0x0500, 0, ZoneStatusChangeNotificationCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * IDENTIFY_COMMAND: Identify Command - *

- * See {@link IdentifyCommand} - */ - IDENTIFY_COMMAND(0x0003, 0, IdentifyCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * IDENTIFY_QUERY_COMMAND: Identify Query Command - *

- * See {@link IdentifyQueryCommand} - */ - IDENTIFY_QUERY_COMMAND(0x0003, 1, IdentifyQueryCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * IDENTIFY_QUERY_RESPONSE: Identify Query Response - *

- * See {@link IdentifyQueryResponse} - */ - IDENTIFY_QUERY_RESPONSE(0x0003, 0, IdentifyQueryResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * CONFIRM_KEY_DATA_REQUEST_COMMAND: Confirm Key Data Request Command - *

- * See {@link ConfirmKeyDataRequestCommand} - */ - CONFIRM_KEY_DATA_REQUEST_COMMAND(0x0800, 2, ConfirmKeyDataRequestCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * CONFIRM_KEY_RESPONSE: Confirm Key Response - *

- * See {@link ConfirmKeyResponse} - */ - CONFIRM_KEY_RESPONSE(0x0800, 2, ConfirmKeyResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * EPHEMERAL_DATA_REQUEST_COMMAND: Ephemeral Data Request Command - *

- * See {@link EphemeralDataRequestCommand} - */ - EPHEMERAL_DATA_REQUEST_COMMAND(0x0800, 1, EphemeralDataRequestCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * EPHEMERAL_DATA_RESPONSE: Ephemeral Data Response - *

- * See {@link EphemeralDataResponse} - */ - EPHEMERAL_DATA_RESPONSE(0x0800, 1, EphemeralDataResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * INITIATE_KEY_ESTABLISHMENT_REQUEST_COMMAND: Initiate Key Establishment Request Command - *

- * See {@link InitiateKeyEstablishmentRequestCommand} - */ - INITIATE_KEY_ESTABLISHMENT_REQUEST_COMMAND(0x0800, 0, InitiateKeyEstablishmentRequestCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * INITIATE_KEY_ESTABLISHMENT_RESPONSE: Initiate Key Establishment Response - *

- * See {@link InitiateKeyEstablishmentResponse} - */ - INITIATE_KEY_ESTABLISHMENT_RESPONSE(0x0800, 0, InitiateKeyEstablishmentResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * TERMINATE_KEY_ESTABLISHMENT: Terminate Key Establishment - *

- * See {@link TerminateKeyEstablishment} - */ - TERMINATE_KEY_ESTABLISHMENT(0x0800, 3, TerminateKeyEstablishment.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * MOVE_COMMAND: Move Command - *

- * See {@link MoveCommand} - */ - MOVE_COMMAND(0x0008, 1, MoveCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * MOVE_TO_LEVEL_COMMAND: Move To Level Command - *

- * See {@link MoveToLevelCommand} - */ - MOVE_TO_LEVEL_COMMAND(0x0008, 0, MoveToLevelCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * MOVE_TO_LEVEL_WITH_ON_OFF_COMMAND: Move To Level (with On/Off) Command - *

- * See {@link MoveToLevelWithOnOffCommand} - */ - MOVE_TO_LEVEL_WITH_ON_OFF_COMMAND(0x0008, 4, MoveToLevelWithOnOffCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * MOVE_WITH_ON_OFF_COMMAND: Move (with On/Off) Command - *

- * See {@link MoveWithOnOffCommand} - */ - MOVE_WITH_ON_OFF_COMMAND(0x0008, 5, MoveWithOnOffCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * STEP_COMMAND: Step Command - *

- * See {@link StepCommand} - */ - STEP_COMMAND(0x0008, 2, StepCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * STEP_WITH_ON_OFF_COMMAND: Step (with On/Off) Command - *

- * See {@link StepWithOnOffCommand} - */ - STEP_WITH_ON_OFF_COMMAND(0x0008, 6, StepWithOnOffCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * STOP_2_COMMAND: Stop 2 Command - *

- * See {@link Stop2Command} - */ - STOP_2_COMMAND(0x0008, 7, Stop2Command.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * STOP_COMMAND: Stop Command - *

- * See {@link StopCommand} - */ - STOP_COMMAND(0x0008, 3, StopCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * CANCEL_ALL_MESSAGES: Cancel All Messages - *

- * See {@link CancelAllMessages} - */ - CANCEL_ALL_MESSAGES(0x0703, 3, CancelAllMessages.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * CANCEL_ALL_MESSAGES_COMMAND: Cancel All Messages Command - *

- * See {@link CancelAllMessagesCommand} - */ - CANCEL_ALL_MESSAGES_COMMAND(0x0703, 3, CancelAllMessagesCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * CANCEL_MESSAGE_COMMAND: Cancel Message Command - *

- * See {@link CancelMessageCommand} - */ - CANCEL_MESSAGE_COMMAND(0x0703, 1, CancelMessageCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * DISPLAY_MESSAGE_COMMAND: Display Message Command - *

- * See {@link DisplayMessageCommand} - */ - DISPLAY_MESSAGE_COMMAND(0x0703, 0, DisplayMessageCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * DISPLAY_PROTECTED_MESSAGE_COMMAND: Display Protected Message Command - *

- * See {@link DisplayProtectedMessageCommand} - */ - DISPLAY_PROTECTED_MESSAGE_COMMAND(0x0703, 2, DisplayProtectedMessageCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_LAST_MESSAGE: Get Last Message - *

- * See {@link GetLastMessage} - */ - GET_LAST_MESSAGE(0x0703, 0, GetLastMessage.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * GET_MESSAGE_CANCELLATION: Get Message Cancellation - *

- * See {@link GetMessageCancellation} - */ - GET_MESSAGE_CANCELLATION(0x0703, 2, GetMessageCancellation.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * MESSAGE_CONFIRMATION: Message Confirmation - *

- * See {@link MessageConfirmation} - */ - MESSAGE_CONFIRMATION(0x0703, 1, MessageConfirmation.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * CHANGE_SUPPLY: Change Supply - *

- * See {@link ChangeSupply} - */ - CHANGE_SUPPLY(0x0702, 11, ChangeSupply.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * CONFIGURE_MIRROR: Configure Mirror - *

- * See {@link ConfigureMirror} - */ - CONFIGURE_MIRROR(0x0702, 8, ConfigureMirror.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * CONFIGURE_NOTIFICATION_FLAGS: Configure Notification Flags - *

- * See {@link ConfigureNotificationFlags} - */ - CONFIGURE_NOTIFICATION_FLAGS(0x0702, 10, ConfigureNotificationFlags.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * CONFIGURE_NOTIFICATION_SCHEME: Configure Notification Scheme - *

- * See {@link ConfigureNotificationScheme} - */ - CONFIGURE_NOTIFICATION_SCHEME(0x0702, 9, ConfigureNotificationScheme.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * GET_NOTIFIED_MESSAGE: Get Notified Message - *

- * See {@link GetNotifiedMessage} - */ - GET_NOTIFIED_MESSAGE(0x0702, 11, GetNotifiedMessage.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * GET_PROFILE: Get Profile - *

- * See {@link GetProfile} - */ - GET_PROFILE(0x0702, 0, GetProfile.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_PROFILE_RESPONSE: Get Profile Response - *

- * See {@link GetProfileResponse} - */ - GET_PROFILE_RESPONSE(0x0702, 0, GetProfileResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * GET_SAMPLED_DATA: Get Sampled Data - *

- * See {@link GetSampledData} - */ - GET_SAMPLED_DATA(0x0702, 8, GetSampledData.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_SAMPLED_DATA_RESPONSE: Get Sampled Data Response - *

- * See {@link GetSampledDataResponse} - */ - GET_SAMPLED_DATA_RESPONSE(0x0702, 7, GetSampledDataResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * GET_SNAPSHOT: Get Snapshot - *

- * See {@link GetSnapshot} - */ - GET_SNAPSHOT(0x0702, 6, GetSnapshot.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * LOCAL_CHANGE_SUPPLY: Local Change Supply - *

- * See {@link LocalChangeSupply} - */ - LOCAL_CHANGE_SUPPLY(0x0702, 12, LocalChangeSupply.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * MIRROR_REMOVED: Mirror Removed - *

- * See {@link MirrorRemoved} - */ - MIRROR_REMOVED(0x0702, 2, MirrorRemoved.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * MIRROR_REPORT_ATTRIBUTE_RESPONSE: Mirror Report Attribute Response - *

- * See {@link MirrorReportAttributeResponse} - */ - MIRROR_REPORT_ATTRIBUTE_RESPONSE(0x0702, 9, MirrorReportAttributeResponse.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * PUBLISH_SNAPSHOT: Publish Snapshot - *

- * See {@link PublishSnapshot} - */ - PUBLISH_SNAPSHOT(0x0702, 6, PublishSnapshot.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * REMOVE_MIRROR: Remove Mirror - *

- * See {@link RemoveMirror} - */ - REMOVE_MIRROR(0x0702, 2, RemoveMirror.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * REQUEST_FAST_POLL_MODE: Request Fast Poll Mode - *

- * See {@link RequestFastPollMode} - */ - REQUEST_FAST_POLL_MODE(0x0702, 3, RequestFastPollMode.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * REQUEST_FAST_POLL_MODE_RESPONSE: Request Fast Poll Mode Response - *

- * See {@link RequestFastPollModeResponse} - */ - REQUEST_FAST_POLL_MODE_RESPONSE(0x0702, 3, RequestFastPollModeResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * REQUEST_MIRROR: Request Mirror - *

- * See {@link RequestMirror} - */ - REQUEST_MIRROR(0x0702, 1, RequestMirror.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * REQUEST_MIRROR_RESPONSE: Request Mirror Response - *

- * See {@link RequestMirrorResponse} - */ - REQUEST_MIRROR_RESPONSE(0x0702, 1, RequestMirrorResponse.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * RESET_LOAD_LIMIT_COUNTER: Reset Load Limit Counter - *

- * See {@link ResetLoadLimitCounter} - */ - RESET_LOAD_LIMIT_COUNTER(0x0702, 10, ResetLoadLimitCounter.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * SCHEDULE_SNAPSHOT: Schedule Snapshot - *

- * See {@link ScheduleSnapshot} - */ - SCHEDULE_SNAPSHOT(0x0702, 4, ScheduleSnapshot.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * SCHEDULE_SNAPSHOT_RESPONSE: Schedule Snapshot Response - *

- * See {@link ScheduleSnapshotResponse} - */ - SCHEDULE_SNAPSHOT_RESPONSE(0x0702, 4, ScheduleSnapshotResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * SET_SUPPLY_STATUS: Set Supply Status - *

- * See {@link SetSupplyStatus} - */ - SET_SUPPLY_STATUS(0x0702, 13, SetSupplyStatus.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * SET_UNCONTROLLED_FLOW_THRESHOLD: Set Uncontrolled Flow Threshold - *

- * See {@link SetUncontrolledFlowThreshold} - */ - SET_UNCONTROLLED_FLOW_THRESHOLD(0x0702, 14, SetUncontrolledFlowThreshold.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * START_SAMPLING: Start Sampling - *

- * See {@link StartSampling} - */ - START_SAMPLING(0x0702, 7, StartSampling.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * START_SAMPLING_RESPONSE: Start Sampling Response - *

- * See {@link StartSamplingResponse} - */ - START_SAMPLING_RESPONSE(0x0702, 13, StartSamplingResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * SUPPLY_STATUS_RESPONSE: Supply Status Response - *

- * See {@link SupplyStatusResponse} - */ - SUPPLY_STATUS_RESPONSE(0x0702, 12, SupplyStatusResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * TAKE_SNAPSHOT: Take Snapshot - *

- * See {@link TakeSnapshot} - */ - TAKE_SNAPSHOT(0x0702, 5, TakeSnapshot.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * TAKE_SNAPSHOT_RESPONSE: Take Snapshot Response - *

- * See {@link TakeSnapshotResponse} - */ - TAKE_SNAPSHOT_RESPONSE(0x0702, 5, TakeSnapshotResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * OFF_COMMAND: Off Command - *

- * See {@link OffCommand} - */ - OFF_COMMAND(0x0006, 0, OffCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * OFF_WITH_EFFECT_COMMAND: Off With Effect Command - *

- * See {@link OffWithEffectCommand} - */ - OFF_WITH_EFFECT_COMMAND(0x0006, 64, OffWithEffectCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * ON_COMMAND: On Command - *

- * See {@link OnCommand} - */ - ON_COMMAND(0x0006, 1, OnCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * ON_WITH_RECALL_GLOBAL_SCENE_COMMAND: On With Recall Global Scene Command - *

- * See {@link OnWithRecallGlobalSceneCommand} - */ - ON_WITH_RECALL_GLOBAL_SCENE_COMMAND(0x0006, 65, OnWithRecallGlobalSceneCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * ON_WITH_TIMED_OFF_COMMAND: On With Timed Off Command - *

- * See {@link OnWithTimedOffCommand} - */ - ON_WITH_TIMED_OFF_COMMAND(0x0006, 66, OnWithTimedOffCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * TOGGLE_COMMAND: Toggle Command - *

- * See {@link ToggleCommand} - */ - TOGGLE_COMMAND(0x0006, 2, ToggleCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * IMAGE_BLOCK_COMMAND: Image Block Command - *

- * See {@link ImageBlockCommand} - */ - IMAGE_BLOCK_COMMAND(0x0019, 3, ImageBlockCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * IMAGE_BLOCK_RESPONSE: Image Block Response - *

- * See {@link ImageBlockResponse} - */ - IMAGE_BLOCK_RESPONSE(0x0019, 5, ImageBlockResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * IMAGE_NOTIFY_COMMAND: Image Notify Command - *

- * See {@link ImageNotifyCommand} - */ - IMAGE_NOTIFY_COMMAND(0x0019, 0, ImageNotifyCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * IMAGE_PAGE_COMMAND: Image Page Command - *

- * See {@link ImagePageCommand} - */ - IMAGE_PAGE_COMMAND(0x0019, 4, ImagePageCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * QUERY_NEXT_IMAGE_COMMAND: Query Next Image Command - *

- * See {@link QueryNextImageCommand} - */ - QUERY_NEXT_IMAGE_COMMAND(0x0019, 1, QueryNextImageCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * QUERY_NEXT_IMAGE_RESPONSE: Query Next Image Response - *

- * See {@link QueryNextImageResponse} - */ - QUERY_NEXT_IMAGE_RESPONSE(0x0019, 2, QueryNextImageResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * QUERY_SPECIFIC_FILE_COMMAND: Query Specific File Command - *

- * See {@link QuerySpecificFileCommand} - */ - QUERY_SPECIFIC_FILE_COMMAND(0x0019, 8, QuerySpecificFileCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * QUERY_SPECIFIC_FILE_RESPONSE: Query Specific File Response - *

- * See {@link QuerySpecificFileResponse} - */ - QUERY_SPECIFIC_FILE_RESPONSE(0x0019, 9, QuerySpecificFileResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * UPGRADE_END_COMMAND: Upgrade End Command - *

- * See {@link UpgradeEndCommand} - */ - UPGRADE_END_COMMAND(0x0019, 6, UpgradeEndCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * UPGRADE_END_RESPONSE: Upgrade End Response - *

- * See {@link UpgradeEndResponse} - */ - UPGRADE_END_RESPONSE(0x0019, 7, UpgradeEndResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * CHECK_IN_COMMAND: Check In Command - *

- * See {@link CheckInCommand} - */ - CHECK_IN_COMMAND(0x0020, 0, CheckInCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * CHECK_IN_RESPONSE: Check In Response - *

- * See {@link CheckInResponse} - */ - CHECK_IN_RESPONSE(0x0020, 0, CheckInResponse.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * FAST_POLL_STOP_COMMAND: Fast Poll Stop Command - *

- * See {@link FastPollStopCommand} - */ - FAST_POLL_STOP_COMMAND(0x0020, 1, FastPollStopCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * SET_LONG_POLL_INTERVAL_COMMAND: Set Long Poll Interval Command - *

- * See {@link SetLongPollIntervalCommand} - */ - SET_LONG_POLL_INTERVAL_COMMAND(0x0020, 2, SetLongPollIntervalCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * SET_SHORT_POLL_INTERVAL_COMMAND: Set Short Poll Interval Command - *

- * See {@link SetShortPollIntervalCommand} - */ - SET_SHORT_POLL_INTERVAL_COMMAND(0x0020, 3, SetShortPollIntervalCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * CHANGE_DEBT: Change Debt - *

- * See {@link ChangeDebt} - */ - CHANGE_DEBT(0x0705, 2, ChangeDebt.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * CHANGE_PAYMENT_MODE: Change Payment Mode - *

- * See {@link ChangePaymentMode} - */ - CHANGE_PAYMENT_MODE(0x0705, 6, ChangePaymentMode.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * CHANGE_PAYMENT_MODE_RESPONSE: Change Payment Mode Response - *

- * See {@link ChangePaymentModeResponse} - */ - CHANGE_PAYMENT_MODE_RESPONSE(0x0705, 2, ChangePaymentModeResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * CONSUMER_TOP_UP: Consumer Top Up - *

- * See {@link ConsumerTopUp} - */ - CONSUMER_TOP_UP(0x0705, 4, ConsumerTopUp.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * CONSUMER_TOP_UP_RESPONSE: Consumer Top Up Response - *

- * See {@link ConsumerTopUpResponse} - */ - CONSUMER_TOP_UP_RESPONSE(0x0705, 3, ConsumerTopUpResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * CREDIT_ADJUSTMENT: Credit Adjustment - *

- * See {@link CreditAdjustment} - */ - CREDIT_ADJUSTMENT(0x0705, 5, CreditAdjustment.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * EMERGENCY_CREDIT_SETUP: Emergency Credit Setup - *

- * See {@link EmergencyCreditSetup} - */ - EMERGENCY_CREDIT_SETUP(0x0705, 3, EmergencyCreditSetup.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_DEBT_REPAYMENT_LOG: Get Debt Repayment Log - *

- * See {@link GetDebtRepaymentLog} - */ - GET_DEBT_REPAYMENT_LOG(0x0705, 10, GetDebtRepaymentLog.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_PREPAY_SNAPSHOT: Get Prepay Snapshot - *

- * See {@link GetPrepaySnapshot} - */ - GET_PREPAY_SNAPSHOT(0x0705, 7, GetPrepaySnapshot.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_TOP_UP_LOG: Get Top Up Log - *

- * See {@link GetTopUpLog} - */ - GET_TOP_UP_LOG(0x0705, 8, GetTopUpLog.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * PUBLISH_DEBT_LOG: Publish Debt Log - *

- * See {@link PublishDebtLog} - */ - PUBLISH_DEBT_LOG(0x0705, 6, PublishDebtLog.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * PUBLISH_PREPAY_SNAPSHOT: Publish Prepay Snapshot - *

- * See {@link PublishPrepaySnapshot} - */ - PUBLISH_PREPAY_SNAPSHOT(0x0705, 1, PublishPrepaySnapshot.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * PUBLISH_TOP_UP_LOG: Publish Top Up Log - *

- * See {@link PublishTopUpLog} - */ - PUBLISH_TOP_UP_LOG(0x0705, 5, PublishTopUpLog.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * SELECT_AVAILABLE_EMERGENCY_CREDIT: Select Available Emergency Credit - *

- * See {@link SelectAvailableEmergencyCredit} - */ - SELECT_AVAILABLE_EMERGENCY_CREDIT(0x0705, 0, SelectAvailableEmergencyCredit.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * SET_LOW_CREDIT_WARNING_LEVEL: Set Low Credit Warning Level - *

- * See {@link SetLowCreditWarningLevel} - */ - SET_LOW_CREDIT_WARNING_LEVEL(0x0705, 9, SetLowCreditWarningLevel.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * SET_MAXIMUM_CREDIT_LIMIT: Set Maximum Credit Limit - *

- * See {@link SetMaximumCreditLimit} - */ - SET_MAXIMUM_CREDIT_LIMIT(0x0705, 11, SetMaximumCreditLimit.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * SET_OVERALL_DEBT_CAP: Set Overall Debt Cap - *

- * See {@link SetOverallDebtCap} - */ - SET_OVERALL_DEBT_CAP(0x0705, 12, SetOverallDebtCap.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * CANCEL_TARIFF_COMMAND: Cancel Tariff Command - *

- * See {@link CancelTariffCommand} - */ - CANCEL_TARIFF_COMMAND(0x0700, 14, CancelTariffCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * CPP_EVENT_RESPONSE: Cpp Event Response - *

- * See {@link CppEventResponse} - */ - CPP_EVENT_RESPONSE(0x0700, 13, CppEventResponse.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_BILLING_PERIOD_COMMAND: Get Billing Period Command - *

- * See {@link GetBillingPeriodCommand} - */ - GET_BILLING_PERIOD_COMMAND(0x0700, 11, GetBillingPeriodCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_BLOCK_PERIOD_COMMAND: Get Block Period Command - *

- * See {@link GetBlockPeriodCommand} - */ - GET_BLOCK_PERIOD_COMMAND(0x0700, 3, GetBlockPeriodCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_BLOCK_THRESHOLDS_COMMAND: Get Block Thresholds Command - *

- * See {@link GetBlockThresholdsCommand} - */ - GET_BLOCK_THRESHOLDS_COMMAND(0x0700, 8, GetBlockThresholdsCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_CALORIFIC_VALUE_COMMAND: Get Calorific Value Command - *

- * See {@link GetCalorificValueCommand} - */ - GET_CALORIFIC_VALUE_COMMAND(0x0700, 5, GetCalorificValueCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_CO2_VALUE_COMMAND: Get CO2 Value Command - *

- * See {@link GetCo2ValueCommand} - */ - GET_CO2_VALUE_COMMAND(0x0700, 9, GetCo2ValueCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_CONSOLIDATED_BILL_COMMAND: Get Consolidated Bill Command - *

- * See {@link GetConsolidatedBillCommand} - */ - GET_CONSOLIDATED_BILL_COMMAND(0x0700, 12, GetConsolidatedBillCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_CONVERSION_FACTOR_COMMAND: Get Conversion Factor Command - *

- * See {@link GetConversionFactorCommand} - */ - GET_CONVERSION_FACTOR_COMMAND(0x0700, 4, GetConversionFactorCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_CREDIT_PAYMENT_COMMAND: Get Credit Payment Command - *

- * See {@link GetCreditPaymentCommand} - */ - GET_CREDIT_PAYMENT_COMMAND(0x0700, 14, GetCreditPaymentCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_CURRENCY_CONVERSION_COMMAND: Get Currency Conversion Command - *

- * See {@link GetCurrencyConversionCommand} - */ - GET_CURRENCY_CONVERSION_COMMAND(0x0700, 15, GetCurrencyConversionCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_CURRENT_PRICE_COMMAND: Get Current Price Command - *

- * See {@link GetCurrentPriceCommand} - */ - GET_CURRENT_PRICE_COMMAND(0x0700, 0, GetCurrentPriceCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_PRICE_MATRIX_COMMAND: Get Price Matrix Command - *

- * See {@link GetPriceMatrixCommand} - */ - GET_PRICE_MATRIX_COMMAND(0x0700, 7, GetPriceMatrixCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_SCHEDULED_PRICES_COMMAND: Get Scheduled Prices Command - *

- * See {@link GetScheduledPricesCommand} - */ - GET_SCHEDULED_PRICES_COMMAND(0x0700, 1, GetScheduledPricesCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_TARIFF_CANCELLATION_COMMAND: Get Tariff Cancellation Command - *

- * See {@link GetTariffCancellationCommand} - */ - GET_TARIFF_CANCELLATION_COMMAND(0x0700, 16, GetTariffCancellationCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_TARIFF_INFORMATION_COMMAND: Get Tariff Information Command - *

- * See {@link GetTariffInformationCommand} - */ - GET_TARIFF_INFORMATION_COMMAND(0x0700, 6, GetTariffInformationCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_TIER_LABELS_COMMAND: Get Tier Labels Command - *

- * See {@link GetTierLabelsCommand} - */ - GET_TIER_LABELS_COMMAND(0x0700, 10, GetTierLabelsCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * PRICE_ACKNOWLEDGEMENT_COMMAND: Price Acknowledgement Command - *

- * See {@link PriceAcknowledgementCommand} - */ - PRICE_ACKNOWLEDGEMENT_COMMAND(0x0700, 2, PriceAcknowledgementCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * PUBLISH_BILLING_PERIOD_COMMAND: Publish Billing Period Command - *

- * See {@link PublishBillingPeriodCommand} - */ - PUBLISH_BILLING_PERIOD_COMMAND(0x0700, 9, PublishBillingPeriodCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * PUBLISH_BLOCK_PERIOD_COMMAND: Publish Block Period Command - *

- * See {@link PublishBlockPeriodCommand} - */ - PUBLISH_BLOCK_PERIOD_COMMAND(0x0700, 1, PublishBlockPeriodCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * PUBLISH_BLOCK_THRESHOLDS_COMMAND: Publish Block Thresholds Command - *

- * See {@link PublishBlockThresholdsCommand} - */ - PUBLISH_BLOCK_THRESHOLDS_COMMAND(0x0700, 6, PublishBlockThresholdsCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * PUBLISH_CALORIFIC_VALUE_COMMAND: Publish Calorific Value Command - *

- * See {@link PublishCalorificValueCommand} - */ - PUBLISH_CALORIFIC_VALUE_COMMAND(0x0700, 3, PublishCalorificValueCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * PUBLISH_CO2_VALUE_COMMAND: Publish CO2 Value Command - *

- * See {@link PublishCo2ValueCommand} - */ - PUBLISH_CO2_VALUE_COMMAND(0x0700, 7, PublishCo2ValueCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * PUBLISH_CONSOLIDATED_BILL_COMMAND: Publish Consolidated Bill Command - *

- * See {@link PublishConsolidatedBillCommand} - */ - PUBLISH_CONSOLIDATED_BILL_COMMAND(0x0700, 10, PublishConsolidatedBillCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * PUBLISH_CONVERSION_FACTOR_COMMAND: Publish Conversion Factor Command - *

- * See {@link PublishConversionFactorCommand} - */ - PUBLISH_CONVERSION_FACTOR_COMMAND(0x0700, 2, PublishConversionFactorCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * PUBLISH_CPP_EVENT_COMMAND: Publish Cpp Event Command - *

- * See {@link PublishCppEventCommand} - */ - PUBLISH_CPP_EVENT_COMMAND(0x0700, 11, PublishCppEventCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * PUBLISH_CREDIT_PAYMENT_COMMAND: Publish Credit Payment Command - *

- * See {@link PublishCreditPaymentCommand} - */ - PUBLISH_CREDIT_PAYMENT_COMMAND(0x0700, 12, PublishCreditPaymentCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * PUBLISH_CURRENCY_CONVERSION_COMMAND: Publish Currency Conversion Command - *

- * See {@link PublishCurrencyConversionCommand} - */ - PUBLISH_CURRENCY_CONVERSION_COMMAND(0x0700, 13, PublishCurrencyConversionCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * PUBLISH_PRICE_COMMAND: Publish Price Command - *

- * See {@link PublishPriceCommand} - */ - PUBLISH_PRICE_COMMAND(0x0700, 0, PublishPriceCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * PUBLISH_PRICE_MATRIX_COMMAND: Publish Price Matrix Command - *

- * See {@link PublishPriceMatrixCommand} - */ - PUBLISH_PRICE_MATRIX_COMMAND(0x0700, 5, PublishPriceMatrixCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * PUBLISH_TARIFF_INFORMATION_COMMAND: Publish Tariff Information Command - *

- * See {@link PublishTariffInformationCommand} - */ - PUBLISH_TARIFF_INFORMATION_COMMAND(0x0700, 4, PublishTariffInformationCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * PUBLISH_TIER_LABELS_COMMAND: Publish Tier Labels Command - *

- * See {@link PublishTierLabelsCommand} - */ - PUBLISH_TIER_LABELS_COMMAND(0x0700, 8, PublishTierLabelsCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * ANCHOR_NODE_ANNOUNCE_COMMAND: Anchor Node Announce Command - *

- * See {@link AnchorNodeAnnounceCommand} - */ - ANCHOR_NODE_ANNOUNCE_COMMAND(0x000B, 6, AnchorNodeAnnounceCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * COMPACT_LOCATION_DATA_NOTIFICATION_COMMAND: Compact Location Data Notification Command - *

- * See {@link CompactLocationDataNotificationCommand} - */ - COMPACT_LOCATION_DATA_NOTIFICATION_COMMAND(0x000B, 3, CompactLocationDataNotificationCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * DEVICE_CONFIGURATION_RESPONSE: Device Configuration Response - *

- * See {@link DeviceConfigurationResponse} - */ - DEVICE_CONFIGURATION_RESPONSE(0x000B, 0, DeviceConfigurationResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * GET_DEVICE_CONFIGURATION_COMMAND: Get Device Configuration Command - *

- * See {@link GetDeviceConfigurationCommand} - */ - GET_DEVICE_CONFIGURATION_COMMAND(0x000B, 2, GetDeviceConfigurationCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_LOCATION_DATA_COMMAND: Get Location Data Command - *

- * See {@link GetLocationDataCommand} - */ - GET_LOCATION_DATA_COMMAND(0x000B, 3, GetLocationDataCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * LOCATION_DATA_NOTIFICATION_COMMAND: Location Data Notification Command - *

- * See {@link LocationDataNotificationCommand} - */ - LOCATION_DATA_NOTIFICATION_COMMAND(0x000B, 2, LocationDataNotificationCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * LOCATION_DATA_RESPONSE: Location Data Response - *

- * See {@link LocationDataResponse} - */ - LOCATION_DATA_RESPONSE(0x000B, 1, LocationDataResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * REPORT_RSSI_MEASUREMENTS_COMMAND: Report RSSI Measurements Command - *

- * See {@link ReportRssiMeasurementsCommand} - */ - REPORT_RSSI_MEASUREMENTS_COMMAND(0x000B, 6, ReportRssiMeasurementsCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * REQUEST_OWN_LOCATION_COMMAND: Request Own Location Command - *

- * See {@link RequestOwnLocationCommand} - */ - REQUEST_OWN_LOCATION_COMMAND(0x000B, 7, RequestOwnLocationCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * RSSI_PING_COMMAND: RSSI Ping Command - *

- * See {@link RssiPingCommand} - */ - RSSI_PING_COMMAND(0x000B, 4, RssiPingCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * RSSI_REQUEST_COMMAND: RSSI Request Command - *

- * See {@link RssiRequestCommand} - */ - RSSI_REQUEST_COMMAND(0x000B, 5, RssiRequestCommand.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * RSSI_RESPONSE: RSSI Response - *

- * See {@link RssiResponse} - */ - RSSI_RESPONSE(0x000B, 4, RssiResponse.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * SEND_PINGS_COMMAND: Send Pings Command - *

- * See {@link SendPingsCommand} - */ - SEND_PINGS_COMMAND(0x000B, 5, SendPingsCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * SET_ABSOLUTE_LOCATION_COMMAND: Set Absolute Location Command - *

- * See {@link SetAbsoluteLocationCommand} - */ - SET_ABSOLUTE_LOCATION_COMMAND(0x000B, 0, SetAbsoluteLocationCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * SET_DEVICE_CONFIGURATION_COMMAND: Set Device Configuration Command - *

- * See {@link SetDeviceConfigurationCommand} - */ - SET_DEVICE_CONFIGURATION_COMMAND(0x000B, 1, SetDeviceConfigurationCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * ADD_SCENE_COMMAND: Add Scene Command - *

- * See {@link AddSceneCommand} - */ - ADD_SCENE_COMMAND(0x0005, 0, AddSceneCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * ADD_SCENE_RESPONSE: Add Scene Response - *

- * See {@link AddSceneResponse} - */ - ADD_SCENE_RESPONSE(0x0005, 0, AddSceneResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * GET_SCENE_MEMBERSHIP_COMMAND: Get Scene Membership Command - *

- * See {@link GetSceneMembershipCommand} - */ - GET_SCENE_MEMBERSHIP_COMMAND(0x0005, 6, GetSceneMembershipCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_SCENE_MEMBERSHIP_RESPONSE: Get Scene Membership Response - *

- * See {@link GetSceneMembershipResponse} - */ - GET_SCENE_MEMBERSHIP_RESPONSE(0x0005, 5, GetSceneMembershipResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * RECALL_SCENE_COMMAND: Recall Scene Command - *

- * See {@link RecallSceneCommand} - */ - RECALL_SCENE_COMMAND(0x0005, 5, RecallSceneCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * REMOVE_ALL_SCENES_COMMAND: Remove All Scenes Command - *

- * See {@link RemoveAllScenesCommand} - */ - REMOVE_ALL_SCENES_COMMAND(0x0005, 3, RemoveAllScenesCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * REMOVE_ALL_SCENES_RESPONSE: Remove All Scenes Response - *

- * See {@link RemoveAllScenesResponse} - */ - REMOVE_ALL_SCENES_RESPONSE(0x0005, 3, RemoveAllScenesResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * REMOVE_SCENE_COMMAND: Remove Scene Command - *

- * See {@link RemoveSceneCommand} - */ - REMOVE_SCENE_COMMAND(0x0005, 2, RemoveSceneCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * REMOVE_SCENE_RESPONSE: Remove Scene Response - *

- * See {@link RemoveSceneResponse} - */ - REMOVE_SCENE_RESPONSE(0x0005, 2, RemoveSceneResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * STORE_SCENE_COMMAND: Store Scene Command - *

- * See {@link StoreSceneCommand} - */ - STORE_SCENE_COMMAND(0x0005, 4, StoreSceneCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * STORE_SCENE_RESPONSE: Store Scene Response - *

- * See {@link StoreSceneResponse} - */ - STORE_SCENE_RESPONSE(0x0005, 4, StoreSceneResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * VIEW_SCENE_COMMAND: View Scene Command - *

- * See {@link ViewSceneCommand} - */ - VIEW_SCENE_COMMAND(0x0005, 1, ViewSceneCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * VIEW_SCENE_RESPONSE: View Scene Response - *

- * See {@link ViewSceneResponse} - */ - VIEW_SCENE_RESPONSE(0x0005, 1, ViewSceneResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * ACK_TRANSFER_DATA_CLIENT_TO_SERVER: Ack Transfer Data Client To Server - *

- * See {@link AckTransferDataClientToServer} - */ - ACK_TRANSFER_DATA_CLIENT_TO_SERVER(0x0704, 4, AckTransferDataClientToServer.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * ACK_TRANSFER_DATA_SERVER_TO_CLIENT: Ack Transfer Data Server To Client - *

- * See {@link AckTransferDataServerToClient} - */ - ACK_TRANSFER_DATA_SERVER_TO_CLIENT(0x0704, 3, AckTransferDataServerToClient.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * CLOSE_TUNNEL: Close Tunnel - *

- * See {@link CloseTunnel} - */ - CLOSE_TUNNEL(0x0704, 1, CloseTunnel.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_SUPPORTED_TUNNEL_PROTOCOLS: Get Supported Tunnel Protocols - *

- * See {@link GetSupportedTunnelProtocols} - */ - GET_SUPPORTED_TUNNEL_PROTOCOLS(0x0704, 6, GetSupportedTunnelProtocols.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * READY_DATA_CLIENT_TO_SERVER: Ready Data Client To Server - *

- * See {@link ReadyDataClientToServer} - */ - READY_DATA_CLIENT_TO_SERVER(0x0704, 5, ReadyDataClientToServer.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * READY_DATA_SERVER_TO_CLIENT: Ready Data Server To Client - *

- * See {@link ReadyDataServerToClient} - */ - READY_DATA_SERVER_TO_CLIENT(0x0704, 4, ReadyDataServerToClient.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * REQUEST_TUNNEL: Request Tunnel - *

- * See {@link RequestTunnel} - */ - REQUEST_TUNNEL(0x0704, 0, RequestTunnel.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * REQUEST_TUNNEL_RESPONSE: Request Tunnel Response - *

- * See {@link RequestTunnelResponse} - */ - REQUEST_TUNNEL_RESPONSE(0x0704, 0, RequestTunnelResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * SUPPORTED_TUNNEL_PROTOCOLS_RESPONSE: Supported Tunnel Protocols Response - *

- * See {@link SupportedTunnelProtocolsResponse} - */ - SUPPORTED_TUNNEL_PROTOCOLS_RESPONSE(0x0704, 5, SupportedTunnelProtocolsResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * TRANSFER_DATA_CLIENT_TO_SERVER: Transfer Data Client To Server - *

- * See {@link TransferDataClientToServer} - */ - TRANSFER_DATA_CLIENT_TO_SERVER(0x0704, 2, TransferDataClientToServer.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * TRANSFER_DATA_ERROR_CLIENT_TO_SERVER: Transfer Data Error Client To Server - *

- * See {@link TransferDataErrorClientToServer} - */ - TRANSFER_DATA_ERROR_CLIENT_TO_SERVER(0x0704, 3, TransferDataErrorClientToServer.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * TRANSFER_DATA_ERROR_SERVER_TO_CLIENT: Transfer Data Error Server To Client - *

- * See {@link TransferDataErrorServerToClient} - */ - TRANSFER_DATA_ERROR_SERVER_TO_CLIENT(0x0704, 2, TransferDataErrorServerToClient.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * TRANSFER_DATA_SERVER_TO_CLIENT: Transfer Data Server To Client - *

- * See {@link TransferDataServerToClient} - */ - TRANSFER_DATA_SERVER_TO_CLIENT(0x0704, 1, TransferDataServerToClient.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * TUNNEL_CLOSURE_NOTIFICATION: Tunnel Closure Notification - *

- * See {@link TunnelClosureNotification} - */ - TUNNEL_CLOSURE_NOTIFICATION(0x0704, 6, TunnelClosureNotification.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * CLEAR_WEEKLY_SCHEDULE: Clear Weekly Schedule - *

- * See {@link ClearWeeklySchedule} - */ - CLEAR_WEEKLY_SCHEDULE(0x0201, 3, ClearWeeklySchedule.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_RELAY_STATUS_LOG: Get Relay Status Log - *

- * See {@link GetRelayStatusLog} - */ - GET_RELAY_STATUS_LOG(0x0201, 4, GetRelayStatusLog.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_RELAY_STATUS_LOG_RESPONSE: Get Relay Status Log Response - *

- * See {@link GetRelayStatusLogResponse} - */ - GET_RELAY_STATUS_LOG_RESPONSE(0x0201, 1, GetRelayStatusLogResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * GET_WEEKLY_SCHEDULE: Get Weekly Schedule - *

- * See {@link GetWeeklySchedule} - */ - GET_WEEKLY_SCHEDULE(0x0201, 2, GetWeeklySchedule.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * GET_WEEKLY_SCHEDULE_RESPONSE: Get Weekly Schedule Response - *

- * See {@link GetWeeklyScheduleResponse} - */ - GET_WEEKLY_SCHEDULE_RESPONSE(0x0201, 0, GetWeeklyScheduleResponse.class, ZclCommandDirection.SERVER_TO_CLIENT), - /** - * SET_WEEKLY_SCHEDULE: Set Weekly Schedule - *

- * See {@link SetWeeklySchedule} - */ - SET_WEEKLY_SCHEDULE(0x0201, 1, SetWeeklySchedule.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * SETPOINT_RAISE_LOWER_COMMAND: Setpoint Raise/Lower Command - *

- * See {@link SetpointRaiseLowerCommand} - */ - SETPOINT_RAISE_LOWER_COMMAND(0x0201, 0, SetpointRaiseLowerCommand.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * WINDOW_COVERING_DOWN_CLOSE: Window Covering Down Close - *

- * See {@link WindowCoveringDownClose} - */ - WINDOW_COVERING_DOWN_CLOSE(0x0102, 1, WindowCoveringDownClose.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * WINDOW_COVERING_GO_TO_LIFT_PERCENTAGE: Window Covering Go To Lift Percentage - *

- * See {@link WindowCoveringGoToLiftPercentage} - */ - WINDOW_COVERING_GO_TO_LIFT_PERCENTAGE(0x0102, 5, WindowCoveringGoToLiftPercentage.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * WINDOW_COVERING_GO_TO_LIFT_VALUE: Window Covering Go To Lift Value - *

- * See {@link WindowCoveringGoToLiftValue} - */ - WINDOW_COVERING_GO_TO_LIFT_VALUE(0x0102, 4, WindowCoveringGoToLiftValue.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * WINDOW_COVERING_GO_TO_TILT_PERCENTAGE: Window Covering Go To Tilt Percentage - *

- * See {@link WindowCoveringGoToTiltPercentage} - */ - WINDOW_COVERING_GO_TO_TILT_PERCENTAGE(0x0102, 8, WindowCoveringGoToTiltPercentage.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * WINDOW_COVERING_GO_TO_TILT_VALUE: Window Covering Go To Tilt Value - *

- * See {@link WindowCoveringGoToTiltValue} - */ - WINDOW_COVERING_GO_TO_TILT_VALUE(0x0102, 7, WindowCoveringGoToTiltValue.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * WINDOW_COVERING_STOP: Window Covering Stop - *

- * See {@link WindowCoveringStop} - */ - WINDOW_COVERING_STOP(0x0102, 2, WindowCoveringStop.class, ZclCommandDirection.CLIENT_TO_SERVER), - /** - * WINDOW_COVERING_UP_OPEN: Window Covering Up Open - *

- * See {@link WindowCoveringUpOpen} - */ - WINDOW_COVERING_UP_OPEN(0x0102, 0, WindowCoveringUpOpen.class, ZclCommandDirection.CLIENT_TO_SERVER); - - private final int commandId; - private final int clusterType; - private final Class commandClass; - private final ZclCommandDirection direction; - - ZclCommandType(final int clusterType, final int commandId, final Class commandClass, final ZclCommandDirection direction) { - this.clusterType = clusterType; - this.commandId = commandId; - this.commandClass = commandClass; - this.direction = direction; - } - - public int getClusterType() { - return clusterType; - } - - public int getId() { - return commandId; - } - - public boolean isGeneric() { - return clusterType==0xFFFF; - } - - public ZclCommandDirection getDirection() { - return direction; - } - - public Class getCommandClass() { - return commandClass; - } - - public static ZclCommandType getCommandType(final int clusterType, final int commandId, - - ZclCommandDirection direction) { - - for (final ZclCommandType value : values()) { - - if (value.direction == direction && value.clusterType == clusterType && value.commandId == commandId) { - - return value; - - } - - } - - return null; - - } - - public static ZclCommandType getGeneric(final int commandId) { - for (final ZclCommandType value : values()) { - if (value.clusterType == 0xFFFF && value.commandId == commandId) { - return value; - } - } - return null; - } - - public ZclCommand instantiateCommand() { - Constructor cmdConstructor; - try { - cmdConstructor = commandClass.getConstructor(); - return cmdConstructor.newInstance(); - } catch (Exception e) { - // logger.debug("Error instantiating cluster command {}", this); - } - return null; - } -} diff --git a/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/ZigBeeNetworkManagerTest.java b/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/ZigBeeNetworkManagerTest.java index ddafc29f1..e904a176b 100644 --- a/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/ZigBeeNetworkManagerTest.java +++ b/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/ZigBeeNetworkManagerTest.java @@ -47,10 +47,19 @@ import com.zsmartsystems.zigbee.transaction.ZigBeeTransactionManager; import com.zsmartsystems.zigbee.transport.ZigBeeTransportState; import com.zsmartsystems.zigbee.transport.ZigBeeTransportTransmit; +import com.zsmartsystems.zigbee.zcl.ZclCluster; import com.zsmartsystems.zigbee.zcl.ZclCommand; import com.zsmartsystems.zigbee.zcl.ZclFieldSerializer; import com.zsmartsystems.zigbee.zcl.ZclFrameType; import com.zsmartsystems.zigbee.zcl.ZclHeader; +import com.zsmartsystems.zigbee.zcl.clusters.ZclColorControlCluster; +import com.zsmartsystems.zigbee.zcl.clusters.ZclElectricalMeasurementCluster; +import com.zsmartsystems.zigbee.zcl.clusters.ZclIasZoneCluster; +import com.zsmartsystems.zigbee.zcl.clusters.ZclLevelControlCluster; +import com.zsmartsystems.zigbee.zcl.clusters.ZclMeteringCluster; +import com.zsmartsystems.zigbee.zcl.clusters.ZclOnOffCluster; +import com.zsmartsystems.zigbee.zcl.clusters.ZclOtaUpgradeCluster; +import com.zsmartsystems.zigbee.zcl.clusters.ZclThermostatCluster; import com.zsmartsystems.zigbee.zcl.clusters.general.ReadAttributesCommand; import com.zsmartsystems.zigbee.zcl.clusters.onoff.OnCommand; @@ -231,6 +240,17 @@ public void testReceiveZclCommand() throws Exception { ZigBeeNetworkManager networkManager = mockZigBeeNetworkManager(); networkManager.setSerializer(DefaultSerializer.class, DefaultDeserializer.class); + ZigBeeEndpoint endpoint = Mockito.mock(ZigBeeEndpoint.class); + ZclCluster cluster = new ZclOnOffCluster(endpoint); + Mockito.when(endpoint.getOutputCluster(6)).thenReturn(cluster); + + ZigBeeNode node = Mockito.mock(ZigBeeNode.class); + Mockito.when(node.getIeeeAddress()).thenReturn(new IeeeAddress("1111111111111111")); + Mockito.when(node.getNetworkAddress()).thenReturn(1234); + Mockito.when(node.getEndpoint(5)).thenReturn(endpoint); + + networkManager.addNode(node); + ZigBeeApsFrame apsFrame = new ZigBeeApsFrame(); apsFrame.setSourceAddress(1234); apsFrame.setDestinationAddress(0); @@ -499,6 +519,41 @@ private ZigBeeCommand getZigBeeCommand(ZigBeeApsFrame apsFrame) throws Exception ZigBeeNetworkManager networkManager = mockZigBeeNetworkManager(); networkManager.setSerializer(DefaultSerializer.class, DefaultDeserializer.class); + ZigBeeEndpoint endpoint = Mockito.mock(ZigBeeEndpoint.class); + ZclCluster cluster; + + cluster = new ZclOnOffCluster(endpoint); + Mockito.when(endpoint.getInputCluster(0x0006)).thenReturn(cluster); + Mockito.when(endpoint.getOutputCluster(0x0006)).thenReturn(cluster); + cluster = new ZclLevelControlCluster(endpoint); + Mockito.when(endpoint.getInputCluster(0x0008)).thenReturn(cluster); + Mockito.when(endpoint.getOutputCluster(0x0008)).thenReturn(cluster); + cluster = new ZclOtaUpgradeCluster(endpoint); + Mockito.when(endpoint.getInputCluster(0x0019)).thenReturn(cluster); + Mockito.when(endpoint.getOutputCluster(0x0019)).thenReturn(cluster); + cluster = new ZclThermostatCluster(endpoint); + Mockito.when(endpoint.getInputCluster(0x0201)).thenReturn(cluster); + Mockito.when(endpoint.getOutputCluster(0x0201)).thenReturn(cluster); + cluster = new ZclColorControlCluster(endpoint); + Mockito.when(endpoint.getInputCluster(0x0300)).thenReturn(cluster); + Mockito.when(endpoint.getOutputCluster(0x0300)).thenReturn(cluster); + cluster = new ZclIasZoneCluster(endpoint); + Mockito.when(endpoint.getInputCluster(0x0500)).thenReturn(cluster); + Mockito.when(endpoint.getOutputCluster(0x0500)).thenReturn(cluster); + cluster = new ZclMeteringCluster(endpoint); + Mockito.when(endpoint.getInputCluster(0x0702)).thenReturn(cluster); + Mockito.when(endpoint.getOutputCluster(0x0702)).thenReturn(cluster); + cluster = new ZclElectricalMeasurementCluster(endpoint); + Mockito.when(endpoint.getInputCluster(0x0B04)).thenReturn(cluster); + Mockito.when(endpoint.getOutputCluster(0x0B04)).thenReturn(cluster); + + ZigBeeNode node = Mockito.mock(ZigBeeNode.class); + Mockito.when(node.getIeeeAddress()).thenReturn(new IeeeAddress("1111111111111111")); + Mockito.when(node.getNetworkAddress()).thenReturn(0); + Mockito.when(node.getEndpoint(1)).thenReturn(endpoint); + + networkManager.addNode(node); + networkManager.receiveCommand(apsFrame); Awaitility.await().until(() -> commandListenerUpdated()); if (commandListenerCapture.size() == 0) { @@ -768,8 +823,8 @@ private String uppercaseFirst(String input) { public void processLogEntry(String apsString, String zclString) throws Exception { System.out.println("---> Processing log"); - System.out.println(" -> " + apsString); - System.out.println(" -> " + zclString); + System.out.println(" => " + apsString); + System.out.println(" => " + zclString); ZigBeeApsFrame apsFrame = getApsFrame(apsString); System.out.println(" <- " + apsFrame); @@ -825,7 +880,6 @@ private Object convertData(String data, Class clazz) { public void processLogs() throws Exception { File dir = FileSystems.getDefault().getPath("./src/test/resource/logs").toFile(); - // File dir = new File(file.toFile()); File[] directoryListing = dir.listFiles(); if (directoryListing != null) { for (File file : directoryListing) { diff --git a/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/zcl/cluster/ZclAlarmsClusterTest.java b/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/zcl/cluster/ZclAlarmsClusterTest.java index c87868e9d..d9968b55d 100644 --- a/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/zcl/cluster/ZclAlarmsClusterTest.java +++ b/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/zcl/cluster/ZclAlarmsClusterTest.java @@ -13,12 +13,14 @@ import org.mockito.Mockito; import com.zsmartsystems.zigbee.ZigBeeEndpoint; +import com.zsmartsystems.zigbee.zcl.ZclFrameType; import com.zsmartsystems.zigbee.zcl.clusters.ZclAlarmsCluster; import com.zsmartsystems.zigbee.zcl.clusters.alarms.AlarmCommand; import com.zsmartsystems.zigbee.zcl.clusters.alarms.GetAlarmCommand; import com.zsmartsystems.zigbee.zcl.clusters.alarms.GetAlarmResponse; import com.zsmartsystems.zigbee.zcl.clusters.alarms.ResetAlarmCommand; import com.zsmartsystems.zigbee.zcl.clusters.alarms.ResetAllAlarmsCommand; +import com.zsmartsystems.zigbee.zcl.clusters.general.ReadAttributesCommand; /** * @@ -30,16 +32,20 @@ public class ZclAlarmsClusterTest { public void getCommandFromId() { ZclAlarmsCluster cluster = new ZclAlarmsCluster(Mockito.mock(ZigBeeEndpoint.class)); - assertTrue(cluster.getCommandFromId(0) instanceof ResetAlarmCommand); - assertTrue(cluster.getCommandFromId(1) instanceof ResetAllAlarmsCommand); - assertTrue(cluster.getCommandFromId(2) instanceof GetAlarmCommand); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 0) instanceof ResetAlarmCommand); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 1) instanceof ResetAllAlarmsCommand); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 2) instanceof GetAlarmCommand); + + assertTrue(cluster.getCommandFromId(ZclFrameType.ENTIRE_PROFILE_COMMAND, 0) instanceof ReadAttributesCommand); } @Test public void getResponseFromId() { ZclAlarmsCluster cluster = new ZclAlarmsCluster(Mockito.mock(ZigBeeEndpoint.class)); - assertTrue(cluster.getResponseFromId(0) instanceof AlarmCommand); - assertTrue(cluster.getResponseFromId(1) instanceof GetAlarmResponse); + assertTrue(cluster.getResponseFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 0) instanceof AlarmCommand); + assertTrue(cluster.getResponseFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 1) instanceof GetAlarmResponse); + + assertTrue(cluster.getResponseFromId(ZclFrameType.ENTIRE_PROFILE_COMMAND, 0) instanceof ReadAttributesCommand); } } diff --git a/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/zcl/cluster/ZclOnOffClusterTest.java b/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/zcl/cluster/ZclOnOffClusterTest.java index 90d9da2d4..b7bc67237 100644 --- a/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/zcl/cluster/ZclOnOffClusterTest.java +++ b/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/zcl/cluster/ZclOnOffClusterTest.java @@ -13,7 +13,9 @@ import org.mockito.Mockito; import com.zsmartsystems.zigbee.ZigBeeEndpoint; +import com.zsmartsystems.zigbee.zcl.ZclFrameType; import com.zsmartsystems.zigbee.zcl.clusters.ZclOnOffCluster; +import com.zsmartsystems.zigbee.zcl.clusters.general.ReadAttributesCommand; import com.zsmartsystems.zigbee.zcl.clusters.onoff.OffCommand; import com.zsmartsystems.zigbee.zcl.clusters.onoff.OnCommand; import com.zsmartsystems.zigbee.zcl.clusters.onoff.ToggleCommand; @@ -28,8 +30,10 @@ public class ZclOnOffClusterTest { public void getCommandFromId() { ZclOnOffCluster cluster = new ZclOnOffCluster(Mockito.mock(ZigBeeEndpoint.class)); - assertTrue(cluster.getCommandFromId(0) instanceof OffCommand); - assertTrue(cluster.getCommandFromId(1) instanceof OnCommand); - assertTrue(cluster.getCommandFromId(2) instanceof ToggleCommand); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 0) instanceof OffCommand); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 1) instanceof OnCommand); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 2) instanceof ToggleCommand); + + assertTrue(cluster.getCommandFromId(ZclFrameType.ENTIRE_PROFILE_COMMAND, 0) instanceof ReadAttributesCommand); } } diff --git a/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/zcl/clusters/ZclColorControlClusterTest.java b/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/zcl/clusters/ZclColorControlClusterTest.java index 5c910434e..5c28f00eb 100644 --- a/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/zcl/clusters/ZclColorControlClusterTest.java +++ b/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/zcl/clusters/ZclColorControlClusterTest.java @@ -13,6 +13,7 @@ import org.mockito.Mockito; import com.zsmartsystems.zigbee.ZigBeeEndpoint; +import com.zsmartsystems.zigbee.zcl.ZclFrameType; import com.zsmartsystems.zigbee.zcl.clusters.colorcontrol.ColorLoopSetCommand; import com.zsmartsystems.zigbee.zcl.clusters.colorcontrol.EnhancedMoveToHueAndSaturationCommand; import com.zsmartsystems.zigbee.zcl.clusters.colorcontrol.EnhancedMoveToHueCommand; @@ -39,20 +40,26 @@ public class ZclColorControlClusterTest { public void test() { ZclColorControlCluster cluster = new ZclColorControlCluster(Mockito.mock(ZigBeeEndpoint.class)); - assertTrue(cluster.getCommandFromId(0) instanceof MoveToHueCommand); - assertTrue(cluster.getCommandFromId(1) instanceof MoveHueCommand); - assertTrue(cluster.getCommandFromId(2) instanceof StepHueCommand); - assertTrue(cluster.getCommandFromId(3) instanceof MoveToSaturationCommand); - assertTrue(cluster.getCommandFromId(4) instanceof MoveSaturationCommand); - assertTrue(cluster.getCommandFromId(5) instanceof StepSaturationCommand); - assertTrue(cluster.getCommandFromId(6) instanceof MoveToHueAndSaturationCommand); - assertTrue(cluster.getCommandFromId(7) instanceof MoveToColorCommand); - assertTrue(cluster.getCommandFromId(8) instanceof MoveColorCommand); - assertTrue(cluster.getCommandFromId(9) instanceof StepColorCommand); - assertTrue(cluster.getCommandFromId(10) instanceof MoveToColorTemperatureCommand); - assertTrue(cluster.getCommandFromId(64) instanceof EnhancedMoveToHueCommand); - assertTrue(cluster.getCommandFromId(65) instanceof EnhancedStepHueCommand); - assertTrue(cluster.getCommandFromId(66) instanceof EnhancedMoveToHueAndSaturationCommand); - assertTrue(cluster.getCommandFromId(67) instanceof ColorLoopSetCommand); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 0) instanceof MoveToHueCommand); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 1) instanceof MoveHueCommand); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 2) instanceof StepHueCommand); + assertTrue( + cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 3) instanceof MoveToSaturationCommand); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 4) instanceof MoveSaturationCommand); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 5) instanceof StepSaturationCommand); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, + 6) instanceof MoveToHueAndSaturationCommand); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 7) instanceof MoveToColorCommand); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 8) instanceof MoveColorCommand); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 9) instanceof StepColorCommand); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, + 10) instanceof MoveToColorTemperatureCommand); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, + 64) instanceof EnhancedMoveToHueCommand); + assertTrue( + cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 65) instanceof EnhancedStepHueCommand); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, + 66) instanceof EnhancedMoveToHueAndSaturationCommand); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 67) instanceof ColorLoopSetCommand); } } diff --git a/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/zcl/clusters/ZclDoorLockClusterTest.java b/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/zcl/clusters/ZclDoorLockClusterTest.java index e667ae531..c69396cc5 100644 --- a/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/zcl/clusters/ZclDoorLockClusterTest.java +++ b/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/zcl/clusters/ZclDoorLockClusterTest.java @@ -13,6 +13,7 @@ import org.mockito.Mockito; import com.zsmartsystems.zigbee.ZigBeeEndpoint; +import com.zsmartsystems.zigbee.zcl.ZclFrameType; import com.zsmartsystems.zigbee.zcl.clusters.doorlock.LockDoorCommand; import com.zsmartsystems.zigbee.zcl.clusters.doorlock.LockDoorResponse; import com.zsmartsystems.zigbee.zcl.clusters.doorlock.Toggle; @@ -32,14 +33,15 @@ public class ZclDoorLockClusterTest { public void test() { ZclDoorLockCluster cluster = new ZclDoorLockCluster(Mockito.mock(ZigBeeEndpoint.class)); - assertTrue(cluster.getCommandFromId(0) instanceof LockDoorCommand); - assertTrue(cluster.getCommandFromId(1) instanceof UnlockDoorCommand); - assertTrue(cluster.getCommandFromId(2) instanceof Toggle); - assertTrue(cluster.getCommandFromId(3) instanceof UnlockWithTimeout); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 0) instanceof LockDoorCommand); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 1) instanceof UnlockDoorCommand); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 2) instanceof Toggle); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 3) instanceof UnlockWithTimeout); - assertTrue(cluster.getResponseFromId(0) instanceof LockDoorResponse); - assertTrue(cluster.getResponseFromId(1) instanceof UnlockDoorResponse); - assertTrue(cluster.getResponseFromId(2) instanceof ToggleResponse); - assertTrue(cluster.getResponseFromId(3) instanceof UnlockWithTimeoutResponse); + assertTrue(cluster.getResponseFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 0) instanceof LockDoorResponse); + assertTrue(cluster.getResponseFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 1) instanceof UnlockDoorResponse); + assertTrue(cluster.getResponseFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 2) instanceof ToggleResponse); + assertTrue(cluster.getResponseFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, + 3) instanceof UnlockWithTimeoutResponse); } } diff --git a/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/zcl/clusters/ZclPollControlClusterTest.java b/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/zcl/clusters/ZclPollControlClusterTest.java index c9499f997..caca77ba2 100644 --- a/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/zcl/clusters/ZclPollControlClusterTest.java +++ b/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/zcl/clusters/ZclPollControlClusterTest.java @@ -13,6 +13,7 @@ import org.mockito.Mockito; import com.zsmartsystems.zigbee.ZigBeeEndpoint; +import com.zsmartsystems.zigbee.zcl.ZclFrameType; import com.zsmartsystems.zigbee.zcl.clusters.pollcontrol.CheckInCommand; import com.zsmartsystems.zigbee.zcl.clusters.pollcontrol.CheckInResponse; import com.zsmartsystems.zigbee.zcl.clusters.pollcontrol.FastPollStopCommand; @@ -29,11 +30,13 @@ public class ZclPollControlClusterTest { public void test() { ZclPollControlCluster cluster = new ZclPollControlCluster(Mockito.mock(ZigBeeEndpoint.class)); - assertTrue(cluster.getCommandFromId(0) instanceof CheckInResponse); - assertTrue(cluster.getCommandFromId(1) instanceof FastPollStopCommand); - assertTrue(cluster.getCommandFromId(2) instanceof SetLongPollIntervalCommand); - assertTrue(cluster.getCommandFromId(3) instanceof SetShortPollIntervalCommand); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 0) instanceof CheckInResponse); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 1) instanceof FastPollStopCommand); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, + 2) instanceof SetLongPollIntervalCommand); + assertTrue(cluster.getCommandFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, + 3) instanceof SetShortPollIntervalCommand); - assertTrue(cluster.getResponseFromId(0) instanceof CheckInCommand); + assertTrue(cluster.getResponseFromId(ZclFrameType.CLUSTER_SPECIFIC_COMMAND, 0) instanceof CheckInCommand); } } diff --git a/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/zcl/protocol/ZclCommandTypeTest.java b/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/zcl/protocol/ZclCommandTypeTest.java deleted file mode 100644 index 27c34f1a4..000000000 --- a/com.zsmartsystems.zigbee/src/test/java/com/zsmartsystems/zigbee/zcl/protocol/ZclCommandTypeTest.java +++ /dev/null @@ -1,72 +0,0 @@ -/** - * Copyright (c) 2016-2019 by the respective copyright holders. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - */ -package com.zsmartsystems.zigbee.zcl.protocol; - -import static org.junit.Assert.assertEquals; -import static org.junit.Assert.assertTrue; - -import org.junit.Test; - -import com.zsmartsystems.zigbee.zcl.ZclCommand; -import com.zsmartsystems.zigbee.zcl.clusters.groups.AddGroupCommand; - -/** - * - * @author Chris Jackson - * - */ -public class ZclCommandTypeTest { - @Test - public void instantiateCommand() { - ZclCommandType cmd = ZclCommandType.ADD_GROUP_COMMAND; - - ZclCommand cmdClass = cmd.instantiateCommand(); - assertTrue(cmdClass instanceof AddGroupCommand); - } - - @Test - public void getClusterType() { - ZclCommandType cmd = ZclCommandType.ALARM_COMMAND; - - assertEquals(0x0009, cmd.getClusterType()); - } - - @Test - public void getId() { - ZclCommandType cmd = ZclCommandType.ALARM_COMMAND; - - assertEquals(0x0000, cmd.getId()); - } - - @Test - public void getDirection() { - ZclCommandType cmd = ZclCommandType.ALARM_COMMAND; - - assertEquals(ZclCommandDirection.SERVER_TO_CLIENT, cmd.getDirection()); - } - - @Test - public void isGeneric() { - ZclCommandType cmd = ZclCommandType.ALARM_COMMAND; - assertEquals(false, cmd.isGeneric()); - - cmd = ZclCommandType.READ_ATTRIBUTES_COMMAND; - assertEquals(true, cmd.isGeneric()); - } - - @Test - public void getGeneric() { - assertEquals(ZclCommandType.READ_ATTRIBUTES_COMMAND, ZclCommandType.getGeneric(0)); - } - - @Test - public void getResponse() { - assertEquals(ZclCommandType.ADD_GROUP_COMMAND, - ZclCommandType.getCommandType(4, 0, ZclCommandDirection.CLIENT_TO_SERVER)); - } -} diff --git a/com.zsmartsystems.zigbee/src/test/resource/logs/cluster-0500-IasZone.txt b/com.zsmartsystems.zigbee/src/test/resource/logs/cluster-0500-IasZone.txt index 217cb36fe..44196cf67 100644 --- a/com.zsmartsystems.zigbee/src/test/resource/logs/cluster-0500-IasZone.txt +++ b/com.zsmartsystems.zigbee/src/test/resource/logs/cluster-0500-IasZone.txt @@ -3,11 +3,11 @@ # Comments can be added with the # on the first character and empty lines are allowed -ZigBeeApsFrame [sourceAddress=33197/1, destinationAddress=0/1, profile=0104, cluster=0500, addressMode=DEVICE, radius=0, apsSecurity=false, apsCounter=A9, payload=19 43 00 02 00 00 00 00 00] -ZoneStatusChangeNotificationCommand [IAS Zone: 33197/1 -> 0/1, cluster=0500, TID=43, zoneStatus=2, extendedStatus=0] +ZigBeeApsFrame [sourceAddress=0/1, destinationAddress=0/1, profile=0104, cluster=0500, addressMode=DEVICE, radius=0, apsSecurity=false, apsCounter=A9, payload=19 43 00 02 00 00 00 00 00] +ZoneStatusChangeNotificationCommand [IAS Zone: 0/1 -> 0/1, cluster=0500, TID=43, zoneStatus=2, extendedStatus=0] -ZigBeeApsFrame [sourceAddress=33197/1, destinationAddress=0/1, profile=0104, cluster=0500, addressMode=DEVICE, radius=0, apsSecurity=false, apsCounter=8F, payload=19 04 01 0D 00 37 10] -ZoneEnrollRequestCommand [IAS Zone: 33197/1 -> 0/1, cluster=0500, TID=04, zoneType=13, manufacturerCode=4151] +ZigBeeApsFrame [sourceAddress=0/1, destinationAddress=0/1, profile=0104, cluster=0500, addressMode=DEVICE, radius=0, apsSecurity=false, apsCounter=8F, payload=19 04 01 0D 00 37 10] +ZoneEnrollRequestCommand [IAS Zone: 0/1 -> 0/1, cluster=0500, TID=04, zoneType=13, manufacturerCode=4151] ZigBeeApsFrame [sourceAddress=0/1, destinationAddress=33197/1, profile=0104, cluster=0500, addressMode=DEVICE, radius=31, apsSecurity=false, apsCounter=93, payload=01 93 00 00 00] ZoneEnrollResponse [IAS Zone: 0/0 -> 33197/1, cluster=0500, TID=93, enrollResponseCode=0, zoneId=0] diff --git a/com.zsmartsystems.zigbee/src/test/resource/logs/cluster-FFFF-General.txt b/com.zsmartsystems.zigbee/src/test/resource/logs/cluster-FFFF-General.txt index 15e103555..e40442a85 100644 --- a/com.zsmartsystems.zigbee/src/test/resource/logs/cluster-FFFF-General.txt +++ b/com.zsmartsystems.zigbee/src/test/resource/logs/cluster-FFFF-General.txt @@ -3,25 +3,25 @@ # Comments can be added with the # on the first character and empty lines are allowed ZigBeeApsFrame [sourceAddress=0/1, destinationAddress=29303/3, profile=0104, cluster=0006, addressMode=DEVICE, radius=31, apsSecurity=false, apsCounter=51, payload=00 51 06 00 00 00 10 01 00 20 1C] -ConfigureReportingCommand [On/Off: 0/0 -> 29303/3, cluster=0006, TID=51, records=[AttributeReportingConfigurationRecord: [attributeDataType=BOOLEAN, attributeIdentifier=0, direction=0, minimumReportingInterval=1, maximumReportingInterval=7200]]] +ConfigureReportingCommand [On/Off: 0/1 -> 29303/3, cluster=0006, TID=51, records=[AttributeReportingConfigurationRecord: [attributeDataType=BOOLEAN, attributeIdentifier=0, direction=0, minimumReportingInterval=1, maximumReportingInterval=7200]]] ZigBeeApsFrame [sourceAddress=0/1, destinationAddress=18314/3, profile=0104, cluster=0006, addressMode=DEVICE, radius=31, apsSecurity=false, apsCounter=15, payload=00 15 0C 00 00 0A] -DiscoverAttributesCommand [On/Off: 0/0 -> 18314/3, cluster=0006, TID=15, startAttributeIdentifier=0, maximumAttributeIdentifiers=10] +DiscoverAttributesCommand [On/Off: 0/1 -> 18314/3, cluster=0006, TID=15, startAttributeIdentifier=0, maximumAttributeIdentifiers=10] -ZigBeeApsFrame [sourceAddress=18314/3, destinationAddress=0/1, profile=0104, cluster=0006, addressMode=DEVICE, radius=0, apsSecurity=false, apsCounter=17, payload=18 15 0D 01 00 00 10 00 40 10 01 40 21 02 40 21] -DiscoverAttributesResponse [On/Off: 18314/3 -> 0/1, cluster=0006, TID=15, discoveryComplete=true, attributeInformation=[Attribute Information [dataType=BOOLEAN, identifier=0], Attribute Information [dataType=BOOLEAN, identifier=16384], Attribute Information [dataType=UNSIGNED_16_BIT_INTEGER, identifier=16385], Attribute Information [dataType=UNSIGNED_16_BIT_INTEGER, identifier=16386]]] +ZigBeeApsFrame [sourceAddress=0/1, destinationAddress=0/1, profile=0104, cluster=0006, addressMode=DEVICE, radius=0, apsSecurity=false, apsCounter=17, payload=18 15 0D 01 00 00 10 00 40 10 01 40 21 02 40 21] +DiscoverAttributesResponse [On/Off: 0/1 -> 0/1, cluster=0006, TID=15, discoveryComplete=true, attributeInformation=[Attribute Information [dataType=BOOLEAN, identifier=0], Attribute Information [dataType=BOOLEAN, identifier=16384], Attribute Information [dataType=UNSIGNED_16_BIT_INTEGER, identifier=16385], Attribute Information [dataType=UNSIGNED_16_BIT_INTEGER, identifier=16386]]] -ZigBeeApsFrame [sourceAddress=32274/1, destinationAddress=0/1, profile=0104, cluster=0201, addressMode=DEVICE, radius=0, apsSecurity=false, apsCounter=00, payload=18 3D 0D 01] -DiscoverAttributesResponse [Thermostat: 32274/1 -> 0/1, cluster=0201, TID=3D, discoveryComplete=true, attributeInformation=[]] +ZigBeeApsFrame [sourceAddress=0/1, destinationAddress=0/1, profile=0104, cluster=0201, addressMode=DEVICE, radius=0, apsSecurity=false, apsCounter=00, payload=18 3D 0D 01] +DiscoverAttributesResponse [Thermostat: 0/1 -> 0/1, cluster=0201, TID=3D, discoveryComplete=true, attributeInformation=[]] ZigBeeApsFrame [sourceAddress=0/1, destinationAddress=18314/3, profile=0104, cluster=0006, addressMode=DEVICE, radius=31, apsSecurity=false, apsCounter=11, payload=00 11 11 00 14] -DiscoverCommandsReceived [On/Off: 0/0 -> 18314/3, cluster=0006, TID=11, startCommandIdentifier=0, maximumCommandIdentifiers=20] +DiscoverCommandsReceived [On/Off: 0/1 -> 0/1, cluster=0006, TID=11, startCommandIdentifier=0, maximumCommandIdentifiers=20] ZigBeeApsFrame [sourceAddress=0/1, destinationAddress=37410/1, profile=0104, cluster=0B04, addressMode=DEVICE, radius=31, sequence=40, payload=00 28 06 00 08 05 21 03 00 20 1C 01 00] -ConfigureReportingCommand [Electrical Measurement: 0/0 -> 37410/1, cluster=0B04, TID=28, records=[AttributeReportingConfigurationRecord: [attributeDataType=UNSIGNED_16_BIT_INTEGER, attributeIdentifier=1288, direction=0, minimumReportingInterval=3, maximumReportingInterval=7200, reportableChange=1]]] +ConfigureReportingCommand [Electrical Measurement: 0/1 -> 37410/1, cluster=0B04, TID=28, records=[AttributeReportingConfigurationRecord: [attributeDataType=UNSIGNED_16_BIT_INTEGER, attributeIdentifier=1288, direction=0, minimumReportingInterval=3, maximumReportingInterval=7200, reportableChange=1]]] -ZigBeeApsFrame [sourceAddress=37410/1, destinationAddress=0/0, profile=0104, cluster=0B04, addressMode=DEVICE, radius=0, sequence=0, payload=08 28 07 00] -ConfigureReportingResponse [Electrical Measurement: 37410/1 -> 0/0, cluster=0B04, TID=28, status=SUCCESS, records=null] +ZigBeeApsFrame [sourceAddress=0/1, destinationAddress=0/0, profile=0104, cluster=0B04, addressMode=DEVICE, radius=0, sequence=0, payload=08 28 07 00] +ConfigureReportingResponse [Electrical Measurement: 0/1 -> 0/0, cluster=0B04, TID=28, status=SUCCESS, records=null] -ZigBeeApsFrame [sourceAddress=0/2, destinationAddress=54832/1, profile=0104, cluster=0702, addressMode=DEVICE, radius=0, apsSecurity=false, apsCounter=4C, payload=08 7A 0B 0C 01] -DefaultResponse [Metering: 0/2 -> 54832/1, cluster=0702, TID=7A, commandIdentifier=12, statusCode=FAILURE] +ZigBeeApsFrame [sourceAddress=0/1, destinationAddress=0/1, profile=0104, cluster=0702, addressMode=DEVICE, radius=0, apsSecurity=false, apsCounter=4C, payload=08 7A 0B 0C 01] +DefaultResponse [Metering: 0/1 -> 0/1, cluster=0702, TID=7A, commandIdentifier=12, statusCode=FAILURE] diff --git a/com.zsmartsystems.zigbee/src/test/resource/logs/zdo.txt b/com.zsmartsystems.zigbee/src/test/resource/logs/zdo.txt index 65527d1c5..6b774376a 100644 --- a/com.zsmartsystems.zigbee/src/test/resource/logs/zdo.txt +++ b/com.zsmartsystems.zigbee/src/test/resource/logs/zdo.txt @@ -4,11 +4,11 @@ # This file contains test definitions for the ZDO commands -ZigBeeApsFrame [sourceAddress=47113/0, destinationAddress=0/0, profile=0000, cluster=8031, addressMode=null, radius=0, apsSecurity=false, apsCounter=22, payload=00 00 16 12 03 8F 39 65 98 FE E6 CF 6D 0B 28 09 00 00 26 18 84 C7 6D 25 01 02 18 8F 39 65 98 FE E6 CF 6D 0A 09 0B 00 00 26 18 84 8F 9D 25 01 02 18 8F 39 65 98 FE E6 CF 6D EE CD 00 12 00 6F 0D 00 00 00 24 01 02 2A] -ManagementLqiResponse [47113/0 -> 0/0, cluster=8031, TID=22, status=SUCCESS, neighborTableEntries=22, startIndex=18, neighborTableList=[NeighborTable [extendedPanId=6DCFE6FE9865398F, extendedAddress=841826000009280B, networkAddress=28103, deviceType=ROUTER, rxOnWhenIdle=RX_ON, relationship=SIBLING, permitJoining=ENABLED, depth=2, lqi=24], NeighborTable [extendedPanId=6DCFE6FE9865398F, extendedAddress=84182600000B090A, networkAddress=40335, deviceType=ROUTER, rxOnWhenIdle=RX_ON, relationship=SIBLING, permitJoining=ENABLED, depth=2, lqi=24], NeighborTable [extendedPanId=6DCFE6FE9865398F, extendedAddress=000D6F001200CDEE, networkAddress=0, deviceType=COORDINATOR, rxOnWhenIdle=RX_ON, relationship=SIBLING, permitJoining=ENABLED, depth=2, lqi=42]]] +ZigBeeApsFrame [sourceAddress=0/0, destinationAddress=0/0, profile=0000, cluster=8031, addressMode=null, radius=0, apsSecurity=false, apsCounter=22, payload=00 00 16 12 03 8F 39 65 98 FE E6 CF 6D 0B 28 09 00 00 26 18 84 C7 6D 25 01 02 18 8F 39 65 98 FE E6 CF 6D 0A 09 0B 00 00 26 18 84 8F 9D 25 01 02 18 8F 39 65 98 FE E6 CF 6D EE CD 00 12 00 6F 0D 00 00 00 24 01 02 2A] +ManagementLqiResponse [0/0 -> 0/0, cluster=8031, TID=22, status=SUCCESS, neighborTableEntries=22, startIndex=18, neighborTableList=[NeighborTable [extendedPanId=6DCFE6FE9865398F, extendedAddress=841826000009280B, networkAddress=28103, deviceType=ROUTER, rxOnWhenIdle=RX_ON, relationship=SIBLING, permitJoining=ENABLED, depth=2, lqi=24], NeighborTable [extendedPanId=6DCFE6FE9865398F, extendedAddress=84182600000B090A, networkAddress=40335, deviceType=ROUTER, rxOnWhenIdle=RX_ON, relationship=SIBLING, permitJoining=ENABLED, depth=2, lqi=24], NeighborTable [extendedPanId=6DCFE6FE9865398F, extendedAddress=000D6F001200CDEE, networkAddress=0, deviceType=COORDINATOR, rxOnWhenIdle=RX_ON, relationship=SIBLING, permitJoining=ENABLED, depth=2, lqi=42]]] ZigBeeApsFrame [sourceAddress=0/0, destinationAddress=40335/0, profile=0000, cluster=0021, addressMode=DEVICE, radius=31, apsSecurity=false, apsCounter=3E, payload=00 0A 09 0B 00 00 26 18 84 03 06 00 03 EE CD 00 12 00 6F 0D 00 01] -BindRequest [0/0 -> 40335/3, cluster=0021, TID=3E, srcAddress=84182600000B090A, srcEndpoint=3, bindCluster=6, dstAddrMode=3, dstAddress=000D6F001200CDEE, dstEndpoint=1] +BindRequest [0/0 -> 0/3, cluster=0021, TID=3E, srcAddress=84182600000B090A, srcEndpoint=3, bindCluster=6, dstAddrMode=3, dstAddress=000D6F001200CDEE, dstEndpoint=1] ZigBeeApsFrame [sourceAddress=0/0, destinationAddress=35000/0, profile=0000, cluster=0032, addressMode=DEVICE, radius=31, apsSecurity=false, apsCounter=91, payload=00 00] ManagementRoutingRequest [0/0 -> 35000/0, cluster=0032, TID=91, startIndex=0] @@ -31,41 +31,41 @@ PowerDescriptorRequest [0/0 -> 31259/0, cluster=0003, TID=1C, nwkAddrOfInterest= ZigBeeApsFrame [sourceAddress=0/0, destinationAddress=31259/0, profile=0000, cluster=0002, addressMode=DEVICE, radius=31, apsSecurity=false, apsCounter=1B, payload=00 1B 7A] NodeDescriptorRequest [0/0 -> 31259/0, cluster=0002, TID=1B, nwkAddrOfInterest=31259] -#ZigBeeApsFrame [sourceAddress=31259/0, destinationAddress=0/0, profile=0000, cluster=8002, addressMode=DEVICE, radius=0, apsSecurity=false, apsCounter=00, payload=00 00 1B 7A 01 40 8E AA BB 40 00 00 00 00 00 00 03] -#NodeDescriptorResponse [31259/0 -> 0/0, cluster=8002, TID=NULL, status=SUCCESS, nwkAddrOfInterest=31259, nodeDescriptor=NodeDescriptor [apsFlags=0, bufferSize=64, complexDescriptorAvailable=false, manufacturerCode=48042, logicalType=ROUTER, serverCapabilities=[], incomingTransferSize=0, outgoingTransferSize=0, userDescriptorAvailable=false, frequencyBands=[FREQ_2400_MHZ], macCapabilities=[FULL_FUNCTION_DEVICE, RECEIVER_ON_WHEN_IDLE, MAINS_POWER], extendedEndpointListAvailable=true, extendedSimpleDescriptorListAvailable=true, stackCompliance=0]] +#ZigBeeApsFrame [sourceAddress=0/0, destinationAddress=0/0, profile=0000, cluster=8002, addressMode=DEVICE, radius=0, apsSecurity=false, apsCounter=00, payload=00 00 1B 7A 01 40 8E AA BB 40 00 00 00 00 00 00 03] +#NodeDescriptorResponse [0/0 -> 0/0, cluster=8002, TID=NULL, status=SUCCESS, nwkAddrOfInterest=31259, nodeDescriptor=NodeDescriptor [apsFlags=0, bufferSize=64, complexDescriptorAvailable=false, manufacturerCode=48042, logicalType=ROUTER, serverCapabilities=[], incomingTransferSize=0, outgoingTransferSize=0, userDescriptorAvailable=false, frequencyBands=[FREQ_2400_MHZ], macCapabilities=[FULL_FUNCTION_DEVICE, RECEIVER_ON_WHEN_IDLE, MAINS_POWER], extendedEndpointListAvailable=true, extendedSimpleDescriptorListAvailable=true, stackCompliance=0]] ZigBeeApsFrame [sourceAddress=0/0, destinationAddress=31259/0, profile=0000, cluster=0005, addressMode=DEVICE, radius=31, apsSecurity=false, apsCounter=1D, payload=00 1B 7A] ActiveEndpointsRequest [0/0 -> 31259/0, cluster=0005, TID=1D, nwkAddrOfInterest=31259] -#ZigBeeApsFrame [sourceAddress=31259/0, destinationAddress=0/0, profile=0000, cluster=8002, addressMode=DEVICE, radius=0, apsSecurity=false, apsCounter=00, payload=00 00 1B 7A 01 03] -#ActiveEndpointsResponse [31259/0 -> 0/0, cluster=8005, TID=NULL, status=SUCCESS, nwkAddrOfInterest=31259, activeEpList=[3]] +#ZigBeeApsFrame [sourceAddress=0/0, destinationAddress=0/0, profile=0000, cluster=8002, addressMode=DEVICE, radius=0, apsSecurity=false, apsCounter=00, payload=00 00 1B 7A 01 03] +#ActiveEndpointsResponse [0/0 -> 0/0, cluster=8005, TID=NULL, status=SUCCESS, nwkAddrOfInterest=31259, activeEpList=[3]] ZigBeeApsFrame [sourceAddress=0/0, destinationAddress=31259/0, profile=0000, cluster=0004, addressMode=DEVICE, radius=31, apsSecurity=false, apsCounter=1E, payload=00 1B 7A 03] SimpleDescriptorRequest [0/0 -> 31259/0, cluster=0004, TID=1E, nwkAddrOfInterest=31259, endpoint=3] -ZigBeeApsFrame [sourceAddress=31259/0, destinationAddress=0/0, profile=0000, cluster=8004, addressMode=DEVICE, radius=0, apsSecurity=false, apsCounter=00, payload=00 00 1B 7A 1C 03 5E C0 10 02 02 09 00 10 00 00 03 00 04 00 05 00 06 00 08 00 00 03 0F FC 01 19 00] -SimpleDescriptorResponse [31259/0 -> 0/0, cluster=8004, TID=NULL, status=SUCCESS, nwkAddrOfInterest=31259, length=28, simpleDescriptor=SimpleDescriptor [endpoint=3, profileId=C05E, deviceId=528, deviceVersion=2, inputClusterList=[4096, 0, 3, 4, 5, 6, 8, 768, 64527], outputClusterList=[25]]] +ZigBeeApsFrame [sourceAddress=0/0, destinationAddress=0/0, profile=0000, cluster=8004, addressMode=DEVICE, radius=0, apsSecurity=false, apsCounter=00, payload=00 00 1B 7A 1C 03 5E C0 10 02 02 09 00 10 00 00 03 00 04 00 05 00 06 00 08 00 00 03 0F FC 01 19 00] +SimpleDescriptorResponse [0/0 -> 0/0, cluster=8004, TID=NULL, status=SUCCESS, nwkAddrOfInterest=31259, length=28, simpleDescriptor=SimpleDescriptor [endpoint=3, profileId=C05E, deviceId=528, deviceVersion=2, inputClusterList=[4096, 0, 3, 4, 5, 6, 8, 768, 64527], outputClusterList=[25]]] ZigBeeApsFrame [sourceAddress=0/0, destinationAddress=65535/0, profile=0000, cluster=0000, addressMode=DEVICE, radius=31, apsSecurity=false, apsCounter=1F, payload=00 43 1D A5 00 AA 3E B0 7C 00 00] NetworkAddressRequest [0/0 -> 65535/0, cluster=0000, TID=1F, ieeeAddr=7CB03EAA00A51D43, requestType=0, startIndex=0] -#ZigBeeApsFrame [sourceAddress=31259/0, destinationAddress=0/0, profile=0000, cluster=8000, addressMode=DEVICE, radius=0, apsSecurity=false, apsCounter=00, payload=00 00 43 1D A5 00 AA 3E B0 7C 1B 7A] -#NetworkAddressResponse [31259/0 -> 0/0, cluster=8000, TID=NULL, status=SUCCESS, ieeeAddrRemoteDev=7CB03EAA00A51D43, nwkAddrRemoteDev=31259, startIndex=null, nwkAddrAssocDevList=[]] +#ZigBeeApsFrame [sourceAddress=0/0, destinationAddress=0/0, profile=0000, cluster=8000, addressMode=DEVICE, radius=0, apsSecurity=false, apsCounter=00, payload=00 00 43 1D A5 00 AA 3E B0 7C 1B 7A] +#NetworkAddressResponse [0/0 -> 0/0, cluster=8000, TID=NULL, status=SUCCESS, ieeeAddrRemoteDev=7CB03EAA00A51D43, nwkAddrRemoteDev=31259, startIndex=null, nwkAddrAssocDevList=[]] ZigBeeApsFrame [sourceAddress=0/0, destinationAddress=37410/0, profile=0000, cluster=0021, addressMode=DEVICE, radius=31, sequence=44, payload=00 D1 A0 00 01 00 97 6D 28 01 04 0B 03 49 58 D2 0E 00 6F 0D 00 01] BindRequest [0/0 -> 37410/0, cluster=0021, TID=2C, srcAddress=286D97000100A0D1, srcEndpoint=1, bindCluster=2820, dstAddrMode=3, dstAddress=000D6F000ED25849, dstEndpoint=1] -ZigBeeApsFrame [sourceAddress=37410/0, destinationAddress=0/0, profile=0000, cluster=8021, addressMode=DEVICE, radius=0, sequence=0, payload=00 00] -BindResponse [37410/0 -> 0/0, cluster=8021, TID=NULL, status=SUCCESS] +ZigBeeApsFrame [sourceAddress=0/0, destinationAddress=0/0, profile=0000, cluster=8021, addressMode=DEVICE, radius=0, sequence=0, payload=00 00] +BindResponse [0/0 -> 0/0, cluster=8021, TID=NULL, status=SUCCESS] ZigBeeApsFrame [sourceAddress=0/0, destinationAddress=37410/0, profile=0000, cluster=0033, addressMode=DEVICE, radius=31, sequence=60, payload=00 00] ManagementBindRequest [0/0 -> 37410/0, cluster=0033, TID=3C, startIndex=0] -#ZigBeeApsFrame [sourceAddress=37410/0, destinationAddress=0/0, profile=0000, cluster=8033, addressMode=DEVICE, radius=0, sequence=0, payload=00 00 02 00 02 D1 A0 00 01 00 97 6D 28 01 04 0B 03 49 58 D2 0E 00 6F 0D 00 01 D1 A0 00 01 00 97 6D 28 01 08 00 03 49 58 D2 0E 00 6F 0D 00 01] -#ManagementBindResponse [37410/0 -> 0/0, cluster=8033, TID=NULL, status=SUCCESS, bindingTableEntries=2, startIndex=0, bindingTableList=[BindingTable [srcAddr=286D97000100A0D1/1, dstAddr=000D6F000ED25849/1, clusterId=2820], BindingTable [srcAddr=286D97000100A0D1/1, dstAddr=000D6F000ED25849/1, clusterId=8]]] +#ZigBeeApsFrame [sourceAddress=0/0, destinationAddress=0/0, profile=0000, cluster=8033, addressMode=DEVICE, radius=0, sequence=0, payload=00 00 02 00 02 D1 A0 00 01 00 97 6D 28 01 04 0B 03 49 58 D2 0E 00 6F 0D 00 01 D1 A0 00 01 00 97 6D 28 01 08 00 03 49 58 D2 0E 00 6F 0D 00 01] +#ManagementBindResponse [0/0 -> 0/0, cluster=8033, TID=NULL, status=SUCCESS, bindingTableEntries=2, startIndex=0, bindingTableList=[BindingTable [srcAddr=286D97000100A0D1/1, dstAddr=000D6F000ED25849/1, clusterId=2820], BindingTable [srcAddr=286D97000100A0D1/1, dstAddr=000D6F000ED25849/1, clusterId=8]]] -ZigBeeApsFrame [sourceAddress=6254/0, destinationAddress=0/0, profile=0000, cluster=0006, addressMode=DEVICE, radius=31, apsSecurity=false, apsCounter=03, payload=00 00 00 09 01 01 00 08 01 00 08] -MatchDescriptorRequest [6254/0 -> 0/0, cluster=0006, TID=03, nwkAddrOfInterest=0, profileId=265, inClusterList=[2048], outClusterList=[2048]] +ZigBeeApsFrame [sourceAddress=0/0, destinationAddress=0/0, profile=0000, cluster=0006, addressMode=DEVICE, radius=31, apsSecurity=false, apsCounter=03, payload=00 00 00 09 01 01 00 08 01 00 08] +MatchDescriptorRequest [0/0 -> 0/0, cluster=0006, TID=03, nwkAddrOfInterest=0, profileId=265, inClusterList=[2048], outClusterList=[2048]] ZigBeeApsFrame [sourceAddress=0/0, destinationAddress=6254/0, profile=0000, cluster=8006, addressMode=null, radius=0, apsSecurity=false, apsCounter=57, payload=00 00 00 00 03 01 02 03] MatchDescriptorResponse [0/0 -> 6254/0, cluster=8006, TID=NULL, status=SUCCESS, nwkAddrOfInterest=0, matchList=[1, 2, 3]]