Homelab, Linux, JS & ABAP (~˘▾˘)~
 

[Home Assistant] Person card with step counter

I recently enhanced the person cards on my dashboard to display some mobile phone sensor data (check here). In addition, I now also added the daily steps by using the Steps sensor of my mobile phone in combination with a utility helper sensor, which counts the daily steps, as the mobile Steps sensor is an increasing counter without daily reset. This is how it looks now:

To include the daily steps, you first have to enable the Steps sensor in the Home Assistant Companion App on your mobile phone.

Next, create a utility sensor which uses the Steps sensor as Input and daily resets the counted steps.

The utility sensor history should look like this after a few days:

Now we can add the utility sensor to the dashboard. As I’m using the vertical-stack-in-card, I simply had to add a new horizontal-stack to the person card to get a new line, and include a mushroom-chips-card which displays the steps.

  - type: horizontal-stack
    cards:
      - type: custom:mushroom-chips-card
        alignment: center
        card_mod:
          style: |
            ha-card {
                --chip-font-size: 0.32em;
                --chip-icon-size: 0.5em;
                --chip-border-width: 0;
                --chip-box-shadow: none;
                --chip-background: none;
                --chip-border: none;
                --chip-spacing: none;
                --chip-font-weight: bold;
            }
        chips:
          - type: template
            entity: sensor.daily_steps_mi8
            content: "{{ states('sensor.daily_steps_mi8')}} steps today"
            tap_action:
              action: more-info

I noticed, that the Steps sensor sometimes does not count steps, and it helps to have some separate steps counter app running on the phone like Paseo.

One comment

  1. Pingback: [Home Assistant] Person card – nocin.eu

Leave a Reply

Your email address will not be published. Required fields are marked *