What component are you using to read that feed? I may set that up so I have a sensor which matches your configuration so I can test any changes I make.
Iām sorry, but Iām using iantrichās feedparser. Can it be a problem for you?
I have tried to create a ālast motionā feed with my motion sensors and the below code however it doesnāt seem to be updating correctly. For example I can look in the dev-states and see that the kitchen motion sensor was triggered 6 hours ago, yet it isnāt in the home feed cardā¦ any ideas? (there are a number of motion sensors that should all be showing activity around 6 hours ago, but there is nothing showing for that time period)
- type: 'custom:home-feed-card'
title: Last Motion
id_filter: ^nothing.*
max_item_count: 10
entities:
- entity: binary_sensor.ensuite_multisensor_motion
include_history: true
exclude_duplicates: false
exclude_states:
- "off"
- entity: binary_sensor.garage_multisensor_sensor
include_history: true
exclude_duplicates: false
exclude_states:
- "off"
- entity: binary_sensor.gym_multisensor_sensor
include_history: true
exclude_duplicates: false
exclude_states:
- "off"
- entity: binary_sensor.kitchen_multi_sensor_sensor
include_history: true
exclude_duplicates: false
exclude_states:
- "off"
- entity: binary_sensor.lounge_multisensor_sensor
include_history: true
exclude_duplicates: false
exclude_states:
- "off"
- entity: binary_sensor.motion_sensor_158d0001ad43db
include_history: true
exclude_duplicates: false
exclude_states:
- "off"
- entity: binary_sensor.pantry_motion_sensor
include_history: true
exclude_duplicates: false
exclude_states:
- "off"
- entity: binary_sensor.paradox_z14_main_shed_pir
include_history: true
exclude_duplicates: false
exclude_states:
- "off"
- entity: binary_sensor.paradox_z15_garden_shed_pir
include_history: true
exclude_duplicates: false
exclude_states:
- "off"
- entity: binary_sensor.paradox_z4_lounge_pir
include_history: true
exclude_duplicates: false
exclude_states:
- "off"
- entity: binary_sensor.paradox_z5_living_pir
include_history: true
exclude_duplicates: false
exclude_states:
- "off"
- entity: binary_sensor.passage_multi_sensor_sensor
include_history: true
exclude_duplicates: false
exclude_states:
- "off"
Iāve just deployed a new Beta release (0.3.4b1). You will need to use the āShow betaā option in the settings for this card in HACS to see this. This should fix your issue by sorting the items from entities in descending order of their timestamps before applying max_items.
I did notice that, to get timestamps from feedparser which parsed correctly in my card, I had to set the date_format option in feedparse to ā%Y-%m-%dā like this:
- platform: feedparser
name: wikiquote
feed_url: https://it.wikiquote.org/w/api.php?action=featuredfeed&feed=qotd
date_format: '%Y-%m-%d'
So, if you still have problems when updating to this version, you may need to do that.
The option exclude_duplicates is wrong. It should be remove_repeats. The default value for this option is true so, since you are excluding the off state with the exclude_states option (which is applied before the remove_repeats option), all but the earliest occurrence of motion for a sensor over the last 24 hours are being excluded.
oooooo YES!
Thanks so much. It works as well as I expected !!
the image (which I will try to remove) is distorted, will it be the caches of my browser? ā¦ anyway ā¦ thank you very much!
before the beta version
beta versione
There was an issue in 0.3.4b1 due to a a fix I had added to stop images being cut off in the feed. This was setting the width to 100% but unfortunately this also caused images smaller than the width of the feed being stretched. I have just released 0.3.4b2, which now set the maximum width rather than the width, which should work for both cases.
will you share the code of your card? Italian here and iād like to have something similarā¦
Thanks, iāll take a look at itā¦
I removed all of the exclude_duplicates: false
code but it is still not showing the latest motion activityā¦
Did you just remove the exclude_duplicates: false
or did you replace it with remove_repeats: false
? Each entity would need to look like this (using the first one as an example) if you want all the events to appear:
- entity: binary_sensor.ensuite_multisensor_motion
include_history: true
remove_repeats: false
exclude_states:
- "off"
I followed your instructions but i today i get this:
Why the news is about 11 november? And the ANSA news are not listed?
Is the link clickable or i have only the number of news?
I checked the sensor and about hassio help it says 0, while wikiquote shows me only the first of 10 and itās the oldest articleā¦
Are you using the Beta version? That fixes an issue with multi-value entities, where max_items would pick the earliest rather than the latest items from the entity.
Yes, fixed, thanks!
- Follow Stevenās instructions install beta 0.3.4b1
- The administrator has changed hosts, we still donāt know what happened
- You read Stevenās guide? In the package I entered
max_items: 1
- Try this (with the beta version at point 1)
- type: custom:home-feed-card
title: "\U0001F4F0 ANSA"
show_empty: false
entities:
- entity: sensor.news_ansa
multiple_items: true
list_attribute: entries
content_template: >-
[{{title}}]({{link}})
I hope to help you
edit I see nowā¦OK you solved :D**
Thanks, that fixed it
Iām sorry if I missed this somewhere above.
Is there a way to force the sensors to be listed in order?
And is there a way to hide the time stamp and icons?
Also I tried to apply style: to both the top level and each entity but was unsuccessful.
Iām using this to display NFL standings I scrape using Siri Shortcuts on my iPhone.
I canāt get the card to show up. Can somebody help debugging?
I manually added the card in my lovelace-custom folder and linked it in ui-lovelace.yaml
- url: /local/lovelace-custom/lovelace-home-feed-card/lovelace-home-feed-card.js
type: js
Then added this to ui-lovelace.yaml and restarted Home Assistant
- title: 'test'
cards:
- type: custom:home-feed-card
title: test
show_empty: true
entities:
- sensor.smokedetector_overview_alarmstatus
home-assistant.log doensāt mention anything.
No red box with errors. Just nothing.
Thanks,
Jelle