name: Pet feeder
products:
  - id: qf3dg2jlcvtacxpk
    manufacturer: MolyPet
    model: F02W
entities:
  - entity: text
    translation_key: meal_plan
    category: config
    hidden: true
    dps:
      - id: 1
        type: base64
        optional: true
        name: value
  - entity: button
    name: Quick feed
    icon: "mdi:paw"
    dps:
      - id: 2
        type: boolean
        optional: true
        name: button
  - entity: number
    translation_key: manual_feed
    category: config
    dps:
      - id: 3
        type: integer
        optional: true
        persist: false
        name: value
        unit: portions
        range:
          min: 1
          max: 50
  - entity: sensor
    translation_key: status
    class: enum
    category: diagnostic
    dps:
      - id: 4
        type: string
        name: sensor
        mapping:
          - dps_val: standby
            value: standby
          - dps_val: feeding
            value: feeding
          - dps_val: done
            value: feeding_complete
  - entity: switch
    name: Slow feed
    icon: "mdi:snail"
    category: config
    dps:
      - id: 6
        type: boolean
        name: switch
  - entity: binary_sensor
    class: problem
    category: diagnostic
    dps:
      - id: 14
        type: bitfield
        name: sensor
        mapping:
          - dps_val: 0
            value: false
          - value: true
      - id: 14
        type: bitfield
        name: fault_code
  - entity: sensor
    name: Last feed
    icon: "mdi:history"
    category: diagnostic
    dps:
      - id: 15
        type: integer
        name: sensor
        unit: portions
        class: measurement
  - entity: number
    name: Slow release interval
    class: duration
    category: config
    dps:
      - id: 18
        type: integer
        name: value
        unit: min
        range:
          min: 0
          max: 10
      - id: 6
        type: boolean
        name: available
  - entity: light
    translation_key: indicator
    category: config
    dps:
      - id: 19
        type: boolean
        name: switch
  - entity: switch
    name: Voice playback
    category: config
    dps:
      - id: 101
        type: boolean
        name: switch
  - entity: sensor
    class: battery
    category: diagnostic
    dps:
      - id: 102
        type: string
        name: sensor
        unit: "%"
        class: measurement
        mapping:
          - dps_val: "0"
            value: 0
            hidden: true
          - dps_val: "2"
            value: 20
            hidden: true
          - dps_val: "3"
            value: 30
            hidden: true
          - dps_val: "4"
            value: 40
            hidden: true
          - dps_val: "5"
            value: 50
            hidden: true
          - dps_val: "6"
            value: 60
            hidden: true
          - dps_val: "7"
            value: 70
            hidden: true
          - dps_val: "8"
            value: 80
            hidden: true
          - dps_val: "9"
            value: 90
            hidden: true
          - dps_val: "10"
            value: 100
            hidden: true
          - value: null
            hidden: true
  - entity: button
    class: restart
    category: config
    dps:
      - id: 103
        type: boolean
        optional: true
        name: button
