name: Water valve
products:
  - id: h4ocnm0dpyyem79i
    manufacturer: Neo
    model: NEO-2 NAS-WV02W
entities:
  - entity: valve
    class: water
    dps:
      - id: 1
        type: boolean
        name: valve
  - entity: sensor
    class: volume_flow_rate
    dps:
      - id: 5
        type: integer
        name: sensor
        unit: gal/h
        class: measurement
        mapping:
          - scale: 10
  - entity: sensor
    class: water
    dps:
      - id: 6
        type: integer
        name: sensor
        unit: gal
        class: total_increasing
        mapping:
          - scale: 10
      - id: 125
        type: integer
        name: hourly
  - entity: sensor
    class: temperature
    dps:
      - id: 101
        type: integer
        name: sensor
        unit: F
        class: measurement
        mapping:
          - scale: 10
  - entity: sensor
    class: pressure
    dps:
      - id: 102
        type: integer
        name: sensor
        unit: psi
        class: measurement
        mapping:
          - scale: 10
  - entity: switch
    name: Temperature alarm
    icon: "mdi:thermometer-alert"
    category: config
    dps:
      - id: 110
        type: boolean
        name: switch
  - entity: number
    translation_key: minimum_temperature
    category: config
    class: temperature
    dps:
      - id: 104
        type: integer
        optional: true
        name: value
        unit: F
        range:
          min: 0
          max: 176
      - id: 110
        type: boolean
        name: available
  - entity: number
    translation_key: maximum_temperature
    category: config
    class: temperature
    dps:
      - id: 105
        type: integer
        optional: true
        name: value
        unit: F
        range:
          min: 0
          max: 176
      - id: 110
        type: boolean
        name: available
  - entity: switch
    name: Pressure alarm
    category: config
    icon: "mdi:water-alert"
    dps:
      - id: 111
        type: boolean
        name: switch
  - entity: number
    name: Minimum pressure
    category: config
    class: pressure
    dps:
      - id: 106
        type: integer
        optional: true
        name: value
        unit: psi
        range:
          min: 0
          max: 100
      - id: 111
        type: boolean
        name: available
  - entity: number
    name: Maximum pressure
    category: config
    class: pressure
    dps:
      - id: 107
        type: integer
        optional: true
        name: value
        unit: psi
        range:
          min: 0
          max: 100
      - id: 111
        type: boolean
        name: available
  - entity: button
    name: Leak test
    category: config
    dps:
      - id: 112
        type: string
        optional: true
        name: button
        mapping:
          - dps_val: "1"
            value: true
      - id: 112
        type: string
        optional: true
        name: result
  - entity: select
    translation_key: temperature_unit
    category: config
    dps:
      - id: 114
        type: string
        optional: true
        name: option
        mapping:
          - dps_val: "1"
            value: fahrenheit
          - dps_val: "2"
            value: celsius
  - entity: select
    name: Pressure unit
    category: config
    dps:
      - id: 115
        type: string
        optional: true
        name: option
        mapping:
          - dps_val: "1"
            value: psi
          - dps_val: "2"
            value: kPa
  - entity: select
    name: Volume unit
    category: config
    dps:
      - id: 116
        type: string
        optional: true
        name: option
        mapping:
          - dps_val: "1"
            value: gal
          - dps_val: "2"
            value: m³
  - entity: event
    name: Leak alarm
    dps:
      - id: 118
        type: string
        name: event
        optional: true
        mapping:
          - dps_val: "1"
            value: leaking
          - dps_val: "0"
            value: cleared
  - entity: event
    name: Temperature alarm
    dps:
      - id: 119
        type: string
        name: event
        optional: true
        mapping:
          - dps_val: "0"
            value: cleared
          - dps_val: "1"
            value: low
          - dps_val: "2"
            value: high
          - dps_val: "3"
            value: sensor_fault
  - entity: event
    name: Pressure alarm
    dps:
      - id: 120
        type: string
        name: event
        optional: true
        mapping:
          - dps_val: "0"
            value: cleared
          - dps_val: "1"
            value: low
          - dps_val: "2"
            value: high
          - dps_val: "3"
            value: sensor_fault
  - entity: switch
    name: Flow alarm
    category: config
    dps:
      - id: 123
        type: boolean
        name: switch
  - entity: number
    name: Minimum flow rate
    class: volume_flow_rate
    category: config
    dps:
      - id: 108
        type: integer
        optional: true
        name: value
        unit: gal/h
        range:
          min: 0
          max: 4000
      - id: 123
        type: boolean
        name: available
  - entity: number
    name: Maximum flow rate
    class: volume_flow_rate
    category: config
    dps:
      - id: 109
        type: integer
        optional: true
        name: value
        unit: gal/h
        range:
          min: 0
          max: 4000
      - id: 123
        type: boolean
        name: available
  - entity: event
    name: Flow alarm
    dps:
      - id: 121
        type: string
        name: event
        optional: true
        mapping:
          - dps_val: "0"
            value: cleared
          - dps_val: "1"
            value: high
          - dps_val: "2"
            value: low
          - dps_val: "3"
            value: sensor_fault
  - entity: button
    name: Meter reset
    category: config
    dps:
      - id: 124
        type: boolean
        optional: true
        name: button
