name: Thermostat
products:
  - id: qgmh0aak7xcmrlf3
    name: Plikc Neve X RFW
  - id: 5kwgvcaqzzkzrftu
    name: Plikc Neve X W
primary_entity:
  entity: climate
  translation_key: thermostat
  dps:
    - id: 1
      type: boolean
      name: hvac_mode
      mapping:
        - dps_val: false
          value: "off"
        - dps_val: true
          value: heat_cool
    - id: 2
      type: string
      name: preset_mode
      mapping:
        - dps_val: auto
          value: program
        - dps_val: manual
          value: manual
        - dps_val: temporary
          value: temp_override
          hidden: true
        - dps_val: holiday
          value: away
          constraint: holiday_duration
          conditions:
            - dps_val: 0
              value: "Set holiday length!"
              hidden: true
    - id: 3
      type: string
      name: hvac_action
      mapping:
        - dps_val: heat
          value: heating
        - dps_val: cold
          value: cooling
        - dps_val: "off"
          constraint: hvac_mode
          conditions:
            - dps_val: true
              value: idle
            - dps_val: false
              value: "off"
    - id: 16
      type: integer
      name: temperature
      unit: C
      range:
        min: 50
        max: 350
      mapping:
        - scale: 10
          constraint: preset_mode
          conditions:
            - dps_val: holiday
              value_redirect: holiday_temp_set
    - id: 24
      type: integer
      name: current_temperature
      mapping:
        - scale: 10
    - id: 32
      type: integer
      name: holiday_temp_set
      optional: true
      hidden: true
      range:
        min: 50
        max: 350
      mapping:
        - scale: 10
    - id: 33
      type: integer
      name: holiday_duration
      hidden: true
secondary_entities:
  - entity: number
    name: Temperature calibration
    category: config
    icon: "mdi:thermometer-check"
    dps:
      - id: 27
        type: integer
        name: value
        unit: °
        range:
          min: -30
          max: 30
        mapping:
          - scale: 10
            step: 5
  - entity: number
    name: Holiday length
    category: config
    icon: "mdi:calendar-range"
    dps:
      - id: 33
        type: integer
        name: value
        unit: d
        range:
          min: 0
          max: 99
  - entity: button
    translation_key: factory_reset
    category: config
    dps:
      - id: 39
        type: boolean
        name: button
        optional: true
  - entity: lock
    translation_key: child_lock
    category: config
    dps:
      - id: 40
        type: boolean
        name: lock
        optional: true
        mapping:
          - dps_val: null
            value: false
  - entity: sensor
    translation_key: time_remaining
    class: duration
    category: diagnostic
    dps:
      - id: 42
        type: integer
        name: sensor
        unit: min
  - entity: binary_sensor
    class: problem
    category: diagnostic
    dps:
      - id: 45
        type: bitfield
        optional: true
        name: sensor
        mapping:
          - dps_val: 0
            value: false
          - dps_val: null
            value: false
          - value: true
