Look at this line
SCAN_INTERVAL = timedelta(minutes=10)
Thanks for this, i am using it with my local Fuel Watch to get the fuel prices in my area
I am new too using RSS feeds like this but on my way to work this morning i was checking the website for fuel prices and thought âi wonder if i can just put this in to homeassistantâ and sure enough you have solved my problem
If anybody was wondering how to find what things they can add under inclusions just open your RSS feed in a web browser and look for the things in â<>â like etc
I thought that might help as i was wondering the same thing at first
Thanks again
Thanks! Would you be cool with updating the Readme on the repo with a PR with some details on what you think is the easiest way to find inclusions?
can you show your sensor setup for this ?
Lee from WA
@krakupkiwi, I would like to know how you did this too
Do you have an account with fuelwatch, using a third party supply or are you using a public login?
edit: do you usse an RSS call something like: https://www.fuelwatch.wa.gov.au/fuelwatch/fuelWatchRSS?Product=1&Suburb=Duncraig
sharing your config would be very helpful!
Phil from WA.
So this is what it looks like, there was some info on their site about how to format the url but mine looks like this
âhttp://www.fuelwatch.wa.gov.au/fuelwatch/fuelWatchRSS?Product=1&Suburb=Duncraigâ
where product-1 is for unleaded fuel and the suburb closest to where i live
########################
# Fuel Watch RSS #
########################
sensor fuelwatch:
- platform: feedparser
name: Fuel Watch WA
feed_url: âhttp://www.fuelwatch.wa.gov.au/fuelwatch/fuelWatchRSS?Product=1&Suburb=Duncraigâ
date_format: â%a, %b %d %I:%M %pâ
inclusions:
- title
- description
- price
- link
- item
- brand
- date
- trading-name
- location
- address
exclusions:
- language
i keep getting this error: ERROR (Thread-6) [homeassistant.util.yaml] YAML file /home/homeassistant/.homeassistant/ui-lovelace.yaml contains duplicate key âtitleâ. Check lines 0 and 348.
- badges: []
cards:
- type: custom:list-card
entity: sensor.nieuws
title: Nieuws GVA
columns:
- title: Link
type: image
add_link: link
field: links
- title: Title
field: title
- title: Summary
field: summary
title: Nieuws
also mine doesnt display pictures either.
I would like to have a limit in the sensor configuration to be able to show the latest news event only.
Iâm currently using another custom component which does that but itâs limited to 1 specific hardcoded site.
https://github.com/thibmaek/custom-components/issues/13#issuecomment-484475957
I want to be able to to have such config to get this card using the âcustom:useful-markdown-cardâ which provides a lot of flexibility, see details in the above github
You should be able to already do that using the zeroth index in the list
I donât understand what you mean by âzeroth indexâ.
The sensor has no attributes ie. plus and I think there is something wrong with the config as I dont get the picture and other elements
This is my config
- platform: feedparser
name: HLN
feed_url: 'https://www.hln.be/nieuws/rss.xml'
date_format: '%a, %b %d %I:%M %p'
inclusions:
- title
- id
- summary
- updated
- media
this is the output
what I would like to see is something like this with attributes that are usable:
Iâm not a dev, just trying to understand the capabilities of your component and provide some feedback for more improvement.
I canât test right now, but you should be able to do something like this
[sensor.hln.attributes[0].title]
in the useful-markdown-card
Tried does not work, I assume because of missing attributes in the sensor or not support by useful-markdown-card.
Attributes is a list as you see in your screenshot
this is what I get as error when used in the custom markdown card
[[ Template matching failed: sensor.hln.attributes[0].title ]]
That might be a limitation of the card. Feedparser is actually broken for me right now due to an upstream issue in Python 3.7 and havenât taken the time to downgrade to 3.6, so canât play around with this, unfortunately.
However, what should work for sure is my config-template-card and the regular markdown-card. Youâd do something like this:
type: 'custom:config-template-card'
variables:
- states['sensor.hln'].attributes[0]
entities:
- sensor.hln
card:
type: markdown
content: "${vars[0].title}"
Great job with both the sensor and the card. I would really like to use this for managing my favorite podcasts in home assistant. I am thinking of using the sensor against the rss-feed for the podcast, which contains all the info required, including the url to the media. Furthermore it would then be really cool if I could just click the row with the podcast I want to hear, and it would play on one of my media players configured in home assistant.
Have you considered implementing functionality for triggering hass services when one of the rows are clicked? I can imagine quite a few use cases where that would enable some cool features.
Regards
Henrik
Thanks for the suggestion iantrich. I have actually had a look at the podcast-card, which looks very nice. My understanding is that the podcastcard is limited to gPodder? Quite a few of the podcasts I am interested in are not available on gPodder.
Do you have any plans for supporting other sources for the podcast-card in the future?
Only other one that Iâm aware that is open is Plex that I hope to eventually add once I find the time.