@@ -358,6 +358,9 @@ public static BaseCluster getCluster(long clusterId) {
358
358
if (clusterId == ContentAppObserver.ID) {
359
359
return new ContentAppObserver();
360
360
}
361
+ if (clusterId == ElectricalMeasurement.ID) {
362
+ return new ElectricalMeasurement();
363
+ }
361
364
if (clusterId == UnitTesting.ID) {
362
365
return new UnitTesting();
363
366
}
@@ -15893,6 +15896,253 @@ public long getCommandID(String name) throws IllegalArgumentException {
15893
15896
return Command.valueOf(name).getID();
15894
15897
}
15895
15898
}
15899
+ public static class ElectricalMeasurement implements BaseCluster {
15900
+ public static final long ID = 2820L;
15901
+ public long getID() {
15902
+ return ID;
15903
+ }
15904
+
15905
+ public enum Attribute {
15906
+ MeasurementType(0L),
15907
+ DcVoltage(256L),
15908
+ DcVoltageMin(257L),
15909
+ DcVoltageMax(258L),
15910
+ DcCurrent(259L),
15911
+ DcCurrentMin(260L),
15912
+ DcCurrentMax(261L),
15913
+ DcPower(262L),
15914
+ DcPowerMin(263L),
15915
+ DcPowerMax(264L),
15916
+ DcVoltageMultiplier(512L),
15917
+ DcVoltageDivisor(513L),
15918
+ DcCurrentMultiplier(514L),
15919
+ DcCurrentDivisor(515L),
15920
+ DcPowerMultiplier(516L),
15921
+ DcPowerDivisor(517L),
15922
+ AcFrequency(768L),
15923
+ AcFrequencyMin(769L),
15924
+ AcFrequencyMax(770L),
15925
+ NeutralCurrent(771L),
15926
+ TotalActivePower(772L),
15927
+ TotalReactivePower(773L),
15928
+ TotalApparentPower(774L),
15929
+ Measured1stHarmonicCurrent(775L),
15930
+ Measured3rdHarmonicCurrent(776L),
15931
+ Measured5thHarmonicCurrent(777L),
15932
+ Measured7thHarmonicCurrent(778L),
15933
+ Measured9thHarmonicCurrent(779L),
15934
+ Measured11thHarmonicCurrent(780L),
15935
+ MeasuredPhase1stHarmonicCurrent(781L),
15936
+ MeasuredPhase3rdHarmonicCurrent(782L),
15937
+ MeasuredPhase5thHarmonicCurrent(783L),
15938
+ MeasuredPhase7thHarmonicCurrent(784L),
15939
+ MeasuredPhase9thHarmonicCurrent(785L),
15940
+ MeasuredPhase11thHarmonicCurrent(786L),
15941
+ AcFrequencyMultiplier(1024L),
15942
+ AcFrequencyDivisor(1025L),
15943
+ PowerMultiplier(1026L),
15944
+ PowerDivisor(1027L),
15945
+ HarmonicCurrentMultiplier(1028L),
15946
+ PhaseHarmonicCurrentMultiplier(1029L),
15947
+ InstantaneousVoltage(1280L),
15948
+ InstantaneousLineCurrent(1281L),
15949
+ InstantaneousActiveCurrent(1282L),
15950
+ InstantaneousReactiveCurrent(1283L),
15951
+ InstantaneousPower(1284L),
15952
+ RmsVoltage(1285L),
15953
+ RmsVoltageMin(1286L),
15954
+ RmsVoltageMax(1287L),
15955
+ RmsCurrent(1288L),
15956
+ RmsCurrentMin(1289L),
15957
+ RmsCurrentMax(1290L),
15958
+ ActivePower(1291L),
15959
+ ActivePowerMin(1292L),
15960
+ ActivePowerMax(1293L),
15961
+ ReactivePower(1294L),
15962
+ ApparentPower(1295L),
15963
+ PowerFactor(1296L),
15964
+ AverageRmsVoltageMeasurementPeriod(1297L),
15965
+ AverageRmsUnderVoltageCounter(1299L),
15966
+ RmsExtremeOverVoltagePeriod(1300L),
15967
+ RmsExtremeUnderVoltagePeriod(1301L),
15968
+ RmsVoltageSagPeriod(1302L),
15969
+ RmsVoltageSwellPeriod(1303L),
15970
+ AcVoltageMultiplier(1536L),
15971
+ AcVoltageDivisor(1537L),
15972
+ AcCurrentMultiplier(1538L),
15973
+ AcCurrentDivisor(1539L),
15974
+ AcPowerMultiplier(1540L),
15975
+ AcPowerDivisor(1541L),
15976
+ OverloadAlarmsMask(1792L),
15977
+ VoltageOverload(1793L),
15978
+ CurrentOverload(1794L),
15979
+ AcOverloadAlarmsMask(2048L),
15980
+ AcVoltageOverload(2049L),
15981
+ AcCurrentOverload(2050L),
15982
+ AcActivePowerOverload(2051L),
15983
+ AcReactivePowerOverload(2052L),
15984
+ AverageRmsOverVoltage(2053L),
15985
+ AverageRmsUnderVoltage(2054L),
15986
+ RmsExtremeOverVoltage(2055L),
15987
+ RmsExtremeUnderVoltage(2056L),
15988
+ RmsVoltageSag(2057L),
15989
+ RmsVoltageSwell(2058L),
15990
+ LineCurrentPhaseB(2305L),
15991
+ ActiveCurrentPhaseB(2306L),
15992
+ ReactiveCurrentPhaseB(2307L),
15993
+ RmsVoltagePhaseB(2309L),
15994
+ RmsVoltageMinPhaseB(2310L),
15995
+ RmsVoltageMaxPhaseB(2311L),
15996
+ RmsCurrentPhaseB(2312L),
15997
+ RmsCurrentMinPhaseB(2313L),
15998
+ RmsCurrentMaxPhaseB(2314L),
15999
+ ActivePowerPhaseB(2315L),
16000
+ ActivePowerMinPhaseB(2316L),
16001
+ ActivePowerMaxPhaseB(2317L),
16002
+ ReactivePowerPhaseB(2318L),
16003
+ ApparentPowerPhaseB(2319L),
16004
+ PowerFactorPhaseB(2320L),
16005
+ AverageRmsVoltageMeasurementPeriodPhaseB(2321L),
16006
+ AverageRmsOverVoltageCounterPhaseB(2322L),
16007
+ AverageRmsUnderVoltageCounterPhaseB(2323L),
16008
+ RmsExtremeOverVoltagePeriodPhaseB(2324L),
16009
+ RmsExtremeUnderVoltagePeriodPhaseB(2325L),
16010
+ RmsVoltageSagPeriodPhaseB(2326L),
16011
+ RmsVoltageSwellPeriodPhaseB(2327L),
16012
+ LineCurrentPhaseC(2561L),
16013
+ ActiveCurrentPhaseC(2562L),
16014
+ ReactiveCurrentPhaseC(2563L),
16015
+ RmsVoltagePhaseC(2565L),
16016
+ RmsVoltageMinPhaseC(2566L),
16017
+ RmsVoltageMaxPhaseC(2567L),
16018
+ RmsCurrentPhaseC(2568L),
16019
+ RmsCurrentMinPhaseC(2569L),
16020
+ RmsCurrentMaxPhaseC(2570L),
16021
+ ActivePowerPhaseC(2571L),
16022
+ ActivePowerMinPhaseC(2572L),
16023
+ ActivePowerMaxPhaseC(2573L),
16024
+ ReactivePowerPhaseC(2574L),
16025
+ ApparentPowerPhaseC(2575L),
16026
+ PowerFactorPhaseC(2576L),
16027
+ AverageRmsVoltageMeasurementPeriodPhaseC(2577L),
16028
+ AverageRmsOverVoltageCounterPhaseC(2578L),
16029
+ AverageRmsUnderVoltageCounterPhaseC(2579L),
16030
+ RmsExtremeOverVoltagePeriodPhaseC(2580L),
16031
+ RmsExtremeUnderVoltagePeriodPhaseC(2581L),
16032
+ RmsVoltageSagPeriodPhaseC(2582L),
16033
+ RmsVoltageSwellPeriodPhaseC(2583L),
16034
+ GeneratedCommandList(65528L),
16035
+ AcceptedCommandList(65529L),
16036
+ EventList(65530L),
16037
+ AttributeList(65531L),
16038
+ FeatureMap(65532L),
16039
+ ClusterRevision(65533L),;
16040
+ private final long id;
16041
+ Attribute(long id) {
16042
+ this.id = id;
16043
+ }
16044
+
16045
+ public long getID() {
16046
+ return id;
16047
+ }
16048
+
16049
+ public static Attribute value(long id) throws NoSuchFieldError {
16050
+ for (Attribute attribute : Attribute.values()) {
16051
+ if (attribute.getID() == id) {
16052
+ return attribute;
16053
+ }
16054
+ }
16055
+ throw new NoSuchFieldError();
16056
+ }
16057
+ }
16058
+
16059
+ public enum Event {;
16060
+ private final long id;
16061
+ Event(long id) {
16062
+ this.id = id;
16063
+ }
16064
+
16065
+ public long getID() {
16066
+ return id;
16067
+ }
16068
+
16069
+ public static Event value(long id) throws NoSuchFieldError {
16070
+ for (Event event : Event.values()) {
16071
+ if (event.getID() == id) {
16072
+ return event;
16073
+ }
16074
+ }
16075
+ throw new NoSuchFieldError();
16076
+ }
16077
+ }
16078
+
16079
+ public enum Command {
16080
+ GetProfileInfoCommand(0L),
16081
+ GetMeasurementProfileCommand(1L),;
16082
+ private final long id;
16083
+ Command(long id) {
16084
+ this.id = id;
16085
+ }
16086
+
16087
+ public long getID() {
16088
+ return id;
16089
+ }
16090
+
16091
+ public static Command value(long id) throws NoSuchFieldError {
16092
+ for (Command command : Command.values()) {
16093
+ if (command.getID() == id) {
16094
+ return command;
16095
+ }
16096
+ }
16097
+ throw new NoSuchFieldError();
16098
+ }
16099
+ }public enum GetMeasurementProfileCommandCommandField {AttributeId(0),StartTime(1),NumberOfIntervals(2),;
16100
+ private final int id;
16101
+ GetMeasurementProfileCommandCommandField(int id) {
16102
+ this.id = id;
16103
+ }
16104
+
16105
+ public int getID() {
16106
+ return id;
16107
+ }
16108
+ public static GetMeasurementProfileCommandCommandField value(int id) throws NoSuchFieldError {
16109
+ for (GetMeasurementProfileCommandCommandField field : GetMeasurementProfileCommandCommandField.values()) {
16110
+ if (field.getID() == id) {
16111
+ return field;
16112
+ }
16113
+ }
16114
+ throw new NoSuchFieldError();
16115
+ }
16116
+ }@Override
16117
+ public String getAttributeName(long id) throws NoSuchFieldError {
16118
+ return Attribute.value(id).toString();
16119
+ }
16120
+
16121
+ @Override
16122
+ public String getEventName(long id) throws NoSuchFieldError {
16123
+ return Event.value(id).toString();
16124
+ }
16125
+
16126
+ @Override
16127
+ public String getCommandName(long id) throws NoSuchFieldError {
16128
+ return Command.value(id).toString();
16129
+ }
16130
+
16131
+ @Override
16132
+ public long getAttributeID(String name) throws IllegalArgumentException {
16133
+ return Attribute.valueOf(name).getID();
16134
+ }
16135
+
16136
+ @Override
16137
+ public long getEventID(String name) throws IllegalArgumentException {
16138
+ return Event.valueOf(name).getID();
16139
+ }
16140
+
16141
+ @Override
16142
+ public long getCommandID(String name) throws IllegalArgumentException {
16143
+ return Command.valueOf(name).getID();
16144
+ }
16145
+ }
15896
16146
public static class UnitTesting implements BaseCluster {
15897
16147
public static final long ID = 4294048773L;
15898
16148
public long getID() {
0 commit comments