/**
 * @license
 * Copyright 2022-2026 Matter.js Authors
 * SPDX-License-Identifier: Apache-2.0
 */
import { MatterDefinition } from "../MatterDefinition.js";
import {
  ClusterElement as Cluster,
  AttributeElement as Attribute,
  FieldElement as Field,
  EventElement as Event,
  DatatypeElement as Datatype
} from "../../elements/index.js";
const PumpConfigurationAndControl = Cluster(
  { name: "PumpConfigurationAndControl", id: 512, classification: "application" },
  Attribute({ name: "ClusterRevision", id: 65533, type: "ClusterRevision", default: 4 }),
  Attribute(
    { name: "FeatureMap", id: 65532, type: "FeatureMap" },
    Field({ name: "PRSCONST", conformance: "O.a+", constraint: "0", title: "ConstantPressure" }),
    Field({ name: "PRSCOMP", conformance: "O.a+", constraint: "1", title: "CompensatedPressure" }),
    Field({ name: "FLW", conformance: "O.a+", constraint: "2", title: "ConstantFlow" }),
    Field({ name: "SPD", conformance: "O.a+", constraint: "3", title: "ConstantSpeed" }),
    Field({ name: "TEMP", conformance: "O.a+", constraint: "4", title: "ConstantTemperature" }),
    Field({ name: "AUTO", conformance: "O", constraint: "5", title: "Automatic" }),
    Field({ name: "LOCAL", conformance: "O", constraint: "6", title: "LocalOperation" })
  ),
  Attribute(
    { name: "MaxPressure", id: 0, type: "int16", access: "R V", conformance: "M", default: null, quality: "X F" }
  ),
  Attribute(
    { name: "MaxSpeed", id: 1, type: "uint16", access: "R V", conformance: "M", default: null, quality: "X F" }
  ),
  Attribute({ name: "MaxFlow", id: 2, type: "uint16", access: "R V", conformance: "M", default: null, quality: "X F" }),
  Attribute({
    name: "MinConstPressure",
    id: 3,
    type: "int16",
    access: "R V",
    conformance: "PRSCONST, [AUTO]",
    default: null,
    quality: "X F"
  }),
  Attribute({
    name: "MaxConstPressure",
    id: 4,
    type: "int16",
    access: "R V",
    conformance: "PRSCONST, [AUTO]",
    default: null,
    quality: "X F"
  }),
  Attribute({
    name: "MinCompPressure",
    id: 5,
    type: "int16",
    access: "R V",
    conformance: "PRSCOMP, [AUTO]",
    default: null,
    quality: "X F"
  }),
  Attribute({
    name: "MaxCompPressure",
    id: 6,
    type: "int16",
    access: "R V",
    conformance: "PRSCOMP, [AUTO]",
    default: null,
    quality: "X F"
  }),
  Attribute({
    name: "MinConstSpeed",
    id: 7,
    type: "uint16",
    access: "R V",
    conformance: "SPD, [AUTO]",
    default: null,
    quality: "X F"
  }),
  Attribute({
    name: "MaxConstSpeed",
    id: 8,
    type: "uint16",
    access: "R V",
    conformance: "SPD, [AUTO]",
    default: null,
    quality: "X F"
  }),
  Attribute({
    name: "MinConstFlow",
    id: 9,
    type: "uint16",
    access: "R V",
    conformance: "FLW, [AUTO]",
    default: null,
    quality: "X F"
  }),
  Attribute({
    name: "MaxConstFlow",
    id: 10,
    type: "uint16",
    access: "R V",
    conformance: "FLW, [AUTO]",
    default: null,
    quality: "X F"
  }),
  Attribute({
    name: "MinConstTemp",
    id: 11,
    type: "int16",
    access: "R V",
    conformance: "TEMP, [AUTO]",
    constraint: "min -27315",
    default: null,
    quality: "X F"
  }),
  Attribute({
    name: "MaxConstTemp",
    id: 12,
    type: "int16",
    access: "R V",
    conformance: "TEMP, [AUTO]",
    constraint: "min -27315",
    default: null,
    quality: "X F"
  }),
  Attribute({
    name: "PumpStatus",
    id: 16,
    type: "PumpStatusBitmap",
    access: "R V",
    conformance: "O",
    constraint: "desc",
    default: 0,
    quality: "P"
  }),
  Attribute({
    name: "EffectiveOperationMode",
    id: 17,
    type: "OperationModeEnum",
    access: "R V",
    conformance: "M",
    constraint: "desc",
    quality: "N"
  }),
  Attribute({
    name: "EffectiveControlMode",
    id: 18,
    type: "ControlModeEnum",
    access: "R V",
    conformance: "M",
    constraint: "desc",
    quality: "N"
  }),
  Attribute(
    { name: "Capacity", id: 19, type: "int16", access: "R V", conformance: "M", default: null, quality: "X P" }
  ),
  Attribute({ name: "Speed", id: 20, type: "uint16", access: "R V", conformance: "O", default: null, quality: "X" }),
  Attribute({
    name: "LifetimeRunningHours",
    id: 21,
    type: "uint24",
    access: "RW VM",
    conformance: "O",
    default: 0,
    quality: "X N"
  }),
  Attribute({ name: "Power", id: 22, type: "uint24", access: "R V", conformance: "O", default: null, quality: "X" }),
  Attribute({
    name: "LifetimeEnergyConsumed",
    id: 23,
    type: "uint32",
    access: "RW VM",
    conformance: "O",
    default: 0,
    quality: "X N"
  }),
  Attribute({
    name: "OperationMode",
    id: 32,
    type: "OperationModeEnum",
    access: "RW VM",
    conformance: "M",
    constraint: "desc",
    default: 0,
    quality: "N"
  }),
  Attribute({
    name: "ControlMode",
    id: 33,
    type: "ControlModeEnum",
    access: "RW VM",
    conformance: "O",
    constraint: "desc",
    default: 0,
    quality: "N"
  }),
  Attribute({ name: "AlarmMask", id: 34, type: "uint16", conformance: "D" }),
  Event({ name: "SupplyVoltageLow", id: 0, access: "V", conformance: "O", priority: "info" }),
  Event({ name: "SupplyVoltageHigh", id: 1, access: "V", conformance: "O", priority: "info" }),
  Event({ name: "PowerMissingPhase", id: 2, access: "V", conformance: "O", priority: "info" }),
  Event({ name: "SystemPressureLow", id: 3, access: "V", conformance: "O", priority: "info" }),
  Event({ name: "SystemPressureHigh", id: 4, access: "V", conformance: "O", priority: "info" }),
  Event({ name: "DryRunning", id: 5, access: "V", conformance: "O", priority: "critical" }),
  Event({ name: "MotorTemperatureHigh", id: 6, access: "V", conformance: "O", priority: "info" }),
  Event({ name: "PumpMotorFatalFailure", id: 7, access: "V", conformance: "O", priority: "critical" }),
  Event({ name: "ElectronicTemperatureHigh", id: 8, access: "V", conformance: "O", priority: "info" }),
  Event({ name: "PumpBlocked", id: 9, access: "V", conformance: "O", priority: "critical" }),
  Event({ name: "SensorFailure", id: 10, access: "V", conformance: "O", priority: "info" }),
  Event({ name: "ElectronicNonFatalFailure", id: 11, access: "V", conformance: "O", priority: "info" }),
  Event({ name: "ElectronicFatalFailure", id: 12, access: "V", conformance: "O", priority: "critical" }),
  Event({ name: "GeneralFault", id: 13, access: "V", conformance: "O", priority: "info" }),
  Event({ name: "Leakage", id: 14, access: "V", conformance: "O", priority: "info" }),
  Event({ name: "AirDetection", id: 15, access: "V", conformance: "O", priority: "info" }),
  Event({ name: "TurbineOperation", id: 16, access: "V", conformance: "O", priority: "info" }),
  Datatype(
    { name: "PumpStatusBitmap", type: "map16" },
    Field({ name: "DeviceFault", constraint: "0" }),
    Field({ name: "SupplyFault", constraint: "1" }),
    Field({ name: "SpeedLow", constraint: "2" }),
    Field({ name: "SpeedHigh", constraint: "3" }),
    Field({ name: "LocalOverride", constraint: "4" }),
    Field({ name: "Running", constraint: "5" }),
    Field({ name: "RemotePressure", constraint: "6" }),
    Field({ name: "RemoteFlow", constraint: "7" }),
    Field({ name: "RemoteTemperature", constraint: "8" })
  ),
  Datatype(
    { name: "OperationModeEnum", type: "enum8" },
    Field({ name: "Normal", id: 0, conformance: "M" }),
    Field({ name: "Minimum", id: 1, conformance: "SPD" }),
    Field({ name: "Maximum", id: 2, conformance: "SPD" }),
    Field({ name: "Local", id: 3, conformance: "LOCAL" })
  ),
  Datatype(
    { name: "ControlModeEnum", type: "enum8" },
    Field({ name: "ConstantSpeed", id: 0, conformance: "SPD" }),
    Field({ name: "ConstantPressure", id: 1, conformance: "PRSCONST" }),
    Field({ name: "ProportionalPressure", id: 2, conformance: "PRSCOMP" }),
    Field({ name: "ConstantFlow", id: 3, conformance: "FLW" }),
    Field({ name: "ConstantTemperature", id: 5, conformance: "TEMP" }),
    Field({ name: "Automatic", id: 7, conformance: "AUTO" })
  )
);
MatterDefinition.children.push(PumpConfigurationAndControl);
export {
  PumpConfigurationAndControl
};
//# sourceMappingURL=pump-configuration-and-control.element.js.map
