name: Parkside PLGS2012A1 charger
products:
  - id: h6pglenun37dzsgo
primary_entity:
  entity: switch
  icon: "mdi:ev-station"
  dps:
    - id: 1
      type: boolean
      name: switch
      optional: true
    - id: 2
      type: string
      name: model
    - id: 11
      type: bitfield
      name: fault_code
secondary_entities:
  - entity: number
    name: Charge current
    icon: "mdi:current-dc"
    category: config
    class: current
    dps:
      - id: 3
        type: integer
        name: value
        range:
          min: 0
          max: 30000
        mapping:
          - step: 100
            scale: 1000
        unit: A
  - entity: number
    name: Charge voltage
    icon: "mdi:battery-charging"
    category: config
    class: voltage
    dps:
      - id: 4
        type: integer
        name: value
        range:
          min: 0
          max: 25000
        mapping:
          - scale: 1000
            step: 100
        unit: V
  - entity: switch
    name: Storage
    category: config
    dps:
      - id: 8
        type: boolean
        name: switch
        mapping:
          - dps_val: true
            icon: "mdi:battery-60"
          - dps_val: false
            icon: "mdi:battery"
  - entity: switch
    name: Temperature limiter
    category: config
    icon: "mdi:thermometer-alert"
    dps:
      - id: 9
        type: boolean
        name: switch
  - entity: sensor
    class: battery
    dps:
      - id: 5
        type: integer
        name: sensor
        unit: "%"
  - entity: sensor
    class: temperature
    category: diagnostic
    dps:
      - id: 6
        type: integer
        name: sensor
        unit: C
        class: measurement
  - entity: sensor
    name: Max temperature count
    icon: "mdi:thermometer-plus"
    category: diagnostic
    dps:
      - id: 10
        type: integer
        name: sensor
  - entity: select
    name: Charge type
    icon: "mdi:battery-unknown"
    category: config
    dps:
      - id: 7
        type: string
        name: option
        mapping:
          - dps_val: ECO
            value: Eco
          - dps_val: quick
            value: Performance
          - dps_val: standard
            value: Balanced
          - dps_val: individual
            value: Expert
  - entity: sensor
    name: Max current
    class: current
    category: diagnostic
    dps:
      - id: 101
        type: integer
        name: sensor
        unit: A
        mapping:
          - scale: 1000
  - entity: sensor
    translation_key: time_remaining
    class: duration
    dps:
      - id: 102
        type: integer
        name: sensor
        unit: min
  - entity: binary_sensor
    name: Almost charged
    icon: "mdi:battery-charging-90"
    category: diagnostic
    dps:
      - id: 103
        type: boolean
        name: sensor
  - entity: binary_sensor
    name: Fully charged
    icon: "mdi:battery-charging-100"
    category: diagnostic
    dps:
      - id: 104
        type: boolean
        name: sensor
  - entity: binary_sensor
    class: problem
    category: diagnostic
    dps:
      - id: 11
        type: bitfield
        name: sensor
        mapping:
          - dps_val: 0
            value: false
          - value: true
