timer-bar-card icon indicating copy to clipboard operation
timer-bar-card copied to clipboard

Bar not showing

Open vaderag opened this issue 1 year ago • 3 comments

Describe the bug I've tried to follow the documentation but can't seem to get the bar showing - this is most likely user error but I don't really know where else to go for help! I think this should be simple as I don't need to pull specific attributes etc

Your card configuration


type: custom:timer-bar-card
entity: sensor.p1s_01p00a380200353_remaining_time
duration:
  units: minutes
bar_width: 60%

mushroom:
  color: green
...

image image

Debug information State: 369 (state mode = idle) Mode: idle (explicit; guess mode produces N/A) Duration: second Time remaining: Counter: Attr: {"unit_of_measurement":"min","device_class":"duration","friendly_name":"P1S_01P00A380200353 Remaining time"}

vaderag avatar Nov 20 '24 13:11 vaderag

Sorry I haven't been as responsive in the issue tracker as I've usually been.

This use case does require a bit of configuration. Really the only simple thing to configure are timers, which have the status of the timer as the state and the time remaining as an attribute. Yours instead as the time remaining as a state.

Something like this should work:


type: custom:timer-bar-card
entity: sensor.p1s_01p00a380200353_remaining_time
duration:
  fixed: 07:00:00 # TODO: Set this to how long your timer is
remain_time:
  state: true # Configures time remaining from state
  units: minutes
guess_mode: true # Guesses the timer status from time remaining
bar_width: 60%

mushroom:
  color: green
...

If the timer duration is variable, you'll need another entity with more information about the timer to configure the card. The card doesn't have access to Home Assistant's history, so it can't figure out the initial duration before the timer started counting down.

rianadon avatar Jan 13 '25 05:01 rianadon

Sorry I haven't been as responsive in the issue tracker as I've usually been.

This use case does require a bit of configuration. Really the only simple thing to configure are timers, which have the status of the timer as the state and the time remaining as an attribute. Yours instead as the time remaining as a state.

Something like this should work:

type: custom:timer-bar-card entity: sensor.p1s_01p00a380200353_remaining_time duration: fixed: 07:00:00 # TODO: Set this to how long your timer is remain_time: state: true # Configures time remaining from state units: minutes guess_mode: true # Guesses the timer status from time remaining bar_width: 60%

mushroom: color: green ... If the timer duration is variable, you'll need another entity with more information about the timer to configure the card. The card doesn't have access to Home Assistant's history, so it can't figure out the initial duration before the timer started counting down.

Thanks for your response...

I just tried the above, and sadly still doesn't seem to work This is the output Image

(and just for clarity posting my code below:

type: custom:timer-bar-card
entity: sensor.p1s_01p00a380200353_remaining_time
duration:
  fixed: "5:00:00"
remain_time:
  state: true
  units: minutes
guess_mode: true
bar_width: 60%
mushroom:
  color: green

vaderag avatar Jan 20 '25 10:01 vaderag

I am having the same issue. I cannot get the bar's to render.

ProjectInkfish avatar Aug 09 '25 03:08 ProjectInkfish