Lovelace: Request Logbook Card

I have the need for a Logbook Lovelace card.
What I mean is a card in were you can define entities, event types and/or time frame from which events from the logbook are shown.

So you can list the 5 last motion trigger events, or lamp/devices on/off…
Just in a list.
Anyone know if something like that exists?
I have looked but have seen only the useful markdown card in which you can hardcode a few devices to display their status.

6 Likes

Have you tried to display the /logbook in a lovelace iframe card yet? Not sure if this will work though.

No, my logbook page is very slow when showing all entries, so that’s not a good option.

Have you tried https://github.com/gadgetchnnel/lovelace-home-feed-card

Did anyone find a solution for a logbook card, would be great to have something similar to the home feed card for log book entries that you can control the number of entries to show or even filter out some unwanted events. Thanks.

Came across this post, needing to do the same thing.
Agreed; this would be cool.

Use case: Show me that last few times the front door open/closed…

Hi,

i have develop a logbook card for my own usage.

It is pretty raw now and need to be improve (PR welcome :wink:)

I just published it on github: https://github.com/royto/logbook-card

3 Likes

Sweet! Working great. Thank you
Added your repo to my HACS.
Some notes for your documentation:

  • In your Example: type: ‘custom:logbook-card’

  • Resource entry:
    url: /community_plugin/logbook-card/logbook-card.js
    type: js

1 Like

Thank you for your comment. I’ll take into account your remarks. I have planned to update the repo to be HACS compliant and works on documentation.

Hi @royto, thanks for the work!
It looks great but how can I use it with two different sensors in one card? It would help me see easily which one came first.

Hi @mgim,

Currently, the card only support one entity at a time.

Could you please open an issue on the github ?

One of the most useful additions to my Lovelace UI. Thank you very much!

2 Likes

If I want to see if something has been running today and for how long time, can it be done?
Let say I want to see when the washing machine was running lately and for how long time.
I have a z-wave device that logs current, volt and Watt. But it always on but so I would need some kind of filter, that when washing machine is running the Watt sensor is above 10W, when it its it should set a flag that washing machine is on.

You should look at history stats and template

Thanks, that might work.
I am pretty new to HA so I might need some help.

In template below I tried this but it looks like the sensor stolpar_av_eller_pa is going to be set to on only when the switch is on and above 10
What I want to do is that have a switch always turned on and only set a “flag” or something to like “Light turned on” or “washing machine is running”

  • platform: template
    sensors:
    stolpar_av_eller_pa:
    friendly_name: “Stolpar av eller på”
    value_template: >-
    {% if is_state(‘switch.shelly_shsw_25_c47158_2’, ‘off’) %}
    off
    {% elif state_attr(‘switch.shelly_shsw_25_c47158_2’, ‘kwh’)|float < 10 %}
    standby
    {% elif is_state(‘switch.shelly_shsw_25_c47158_2’, ‘on’) %}
    on
    {% else %}
    failed
    {% endif %}

Found a easy solution !

2 Likes