name: Dehumidifier
products:
  - id: ifasqsxbghku3bwk
    manufacturer: Aktobis
    model: WDH-310EKW
  - id: ifbnzf2j2rwr0upp
    manufacturer: Aktobis
    model: WDH-930EEW
entities:
  - entity: humidifier
    class: dehumidifier
    dps:
      - id: 1
        name: switch
        type: boolean
        mapping:
          - dps_val: false
          - dps_val: true
      - id: 3
        name: humidity
        type: integer
        range:
          min: 30
          max: 70
        mapping:
          - step: 5
      - id: 6
        name: current_humidity
        type: integer
  - entity: fan
    dps:
      - id: 1
        type: boolean
        name: switch
      - id: 4
        type: string
        name: speed
        mapping:
          - dps_val: low
            value: 50
          - dps_val: high
            value: 100
  - entity: sensor
    class: temperature
    dps:
      - id: 7
        type: integer
        name: sensor
        unit: C
        class: measurement
  - entity: binary_sensor
    category: diagnostic
    class: problem
    dps:
      - id: 19
        type: bitfield
        name: sensor
        mapping:
          - dps_val: 0
            value: false
          - value: true
      - id: 19
        name: description
        type: bitfield
        # E2 might be a compressor fault.
        mapping:
          - dps_val: 0
            value: OK
          - dps_val: 1
            value: "E1 Temperature Sensor Fault"
          - dps_val: 2
            value: "E2 Copper Tube Sensor Fault"
          - dps_val: 3
            value: "E3 Humidity Sensor Fault"
          - dps_val: 5
            value: "E5 MCU Communication Failure"
      - id: 19
        type: bitfield
        name: fault_code
  - entity: binary_sensor
    translation_key: tank_full
    category: diagnostic
    dps:
      - id: 101
        type: boolean
        name: sensor
  - entity: binary_sensor
    translation_key: defrost
    category: diagnostic
    dps:
      - id: 102
        type: boolean
        name: sensor
  - entity: select
    translation_key: timer
    category: config
    dps:
      - id: 17
        type: string
        name: option
        mapping:
          - dps_val: cancel
            value: cancel
          - dps_val: 1h
            value: 1h
          - dps_val: 2h
            value: 2h
          - dps_val: 3h
            value: 3h
          - dps_val: 4h
            value: 4h
          - dps_val: 5h
            value: 5h
          - dps_val: 6h
            value: 6h
          - dps_val: 7h
            value: 7h
          - dps_val: 8h
            value: 8h
          - dps_val: 9h
            value: 9h
          - dps_val: 10h
            value: 10h
          - dps_val: 11h
            value: 11h
          - dps_val: 12h
            value: 12h
          - dps_val: 13h
            value: 13h
          - dps_val: 14h
            value: 14h
          - dps_val: 15h
            value: 15h
          - dps_val: 16h
            value: 16h
          - dps_val: 17h
            value: 17h
          - dps_val: 18h
            value: 18h
          - dps_val: 19h
            value: 19h
          - dps_val: 20h
            value: 20h
          - dps_val: 21h
            value: 21h
          - dps_val: 22h
            value: 22h
          - dps_val: 23h
            value: 23h
          - dps_val: 24h
            value: 24h
