#How to display the count for the number of times the door is been opened

1 messages · Page 1 of 1 (latest)

restive quarry
#

Hello people - How can I show the number of times a door is been opened in the dashboard?

severe hatchBOT
misty hare
#

You can use that to create an entity that gives you that value, and then display that entity

restive quarry
#

Let me try.

restive quarry
#

so, this is my config

- platform: history_stats
  type: count
  name: MDOpenCount
  entity_id: binary_sensor.md_door
  state: on
  start: "{{ now().replace(hour=0).replace(minute=0).replace(second=0) }}"
  end: "{{ now() }}"

The counts stays at 0 what am I missing here?

#

Is there a way to check if the door "on" and "off" is recorded in history_stats?

misty hare
#

Do you have the new sensor.mdopencount entity?

restive quarry
#

Yes.

#

It's not incrementing.

misty hare
restive quarry
#

Sure. Thanks for your help.

lavish oasis
#

I think it might need to be state: "on"

#

IIRC on is one of those special yaml keywords that's actually a boolean

restive quarry
#

Damn.

#

Thanks @lavish oasis - it worked.