hacs_waveshare_ups_hat icon indicating copy to clipboard operation
hacs_waveshare_ups_hat copied to clipboard

can't see attributes in card

Open confuserated opened this issue 2 years ago • 1 comments

Hi,

Happy that I can see my UPS Hat B on RPi 4 but I can't see any of the attributes.

I've followed the instructions I can see but although I can create a card with the template sensors from the entity attributes, they all show up as unknown, except for a the main UPS entity and a binary sensor which shows as "waveshare_ups_hat_online" and I can't see where I added that...

Am I missing a step?

here's my configuration.yaml entry:

sensor:

  • platform: waveshare_ups_hat name: UPS
    unique_id: waveshare_ups

template:

  • sensor:
    • name: UPS Capacity state: "{{ state_attr('sensor.waveshare_ups_hat', 'capacity' )}}" unit_of_measurement: '%' icon: mdi:battery-unknown
    • name: UPS PSU Voltage state: "{{ state_attr('sensor.waveshare_ups_hat', 'psu_voltage' )}}" unit_of_measurement: 'V' icon: mdi:lightning-bolt
    • name: UPS Load Voltage state: "{{ state_attr('sensor.waveshare_ups_hat', 'load_voltage' )}}" unit_of_measurement: 'V' icon: mdi:lightning-bolt
    • name: UPS Current state: "{{ state_attr('sensor.waveshare_ups_hat', 'current' )}}" unit_of_measurement: 'mA' icon: mdi:current-dc
    • name: UPS Power state: "{{ state_attr('sensor.waveshare_ups_hat', 'power' )}}" unit_of_measurement: 'W' icon: mdi:power-plug
    • name: UPS Power Calculated state: "{{ state_attr('sensor.waveshare_ups_hat', 'power_calculated' )}}" unit_of_measurement: 'W' icon: mdi:power-plug
    • name: UPS Charging state: "{{ state_attr('sensor.waveshare_ups_hat', 'charging' )}}" unit_of_measurement: '' icon: mdi:battery-charging
    • name: UPS Online state: "{{ state_attr('sensor.waveshare_ups_hat', 'online' )}}" unit_of_measurement: '' icon: mdi:battery-charging-100
    • name: UPS Low Battery state: "{{ state_attr('sensor.waveshare_ups_hat', 'low_battery' )}}" unit_of_measurement: '' icon: mdi:battery-low

binary_sensor:

  • platform: waveshare_ups_hat

confuserated avatar Feb 12 '23 15:02 confuserated