I got inspired by uwut and came up with some scripts dealing with Google Home to handle news, music and information in the morning.
So using pushbullet and Out Loud on my tablet :
#news
news:
sequence:
- service: media_player.turn_on
data:
entity_id: media_player.all
- service: media_player.volume_set
data_template:
entity_id: media_player.all
volume_level: 0.4
- service: notify.push
data_template:
title: Alert
message: 'Hey Google ... swedish news'
#welcome
welcome_home:
sequence:
- service: media_player.turn_on
data:
entity_id: media_player.all
- service: media_player.volume_set
data_template:
entity_id: media_player.all
volume_level: 0.40
- service: notify.push
data_template:
title: Alert
message: >
Hey Google. Play Spotify playlist. {{["happy to be home","songs to sing in the shower.","life is good.","happy hits.","feeling good.","seize the day.","sweet songs for sunny days","lounge soft house"] | random}} on. music.
#play spotify
play_spotify_list:
sequence:
- service: media_player.turn_on
data:
entity_id: media_player.all
- service: media_player.volume_set
data_template:
entity_id: media_player.all
volume_level: 0.30
- service: notify.push
data_template:
title: Alert
message: >
Hey Google. Play Spotify playlist {{states.input_select.spotifylist.state}}. on {{states.input_select.speakers.state}}.
#polleninfo
morning:
sequence:
- service: media_player.turn_on
data:
entity_id: media_player.all
- service: media_player.volume_set
data_template:
entity_id: media_player.all
volume_level: 0.50
- service: notify.push
data_template:
title: Alert
message: >
{% set mymap = { 'i.h':'None','i.u':'No messaurement','L':'Low','L-M':'Low to Medium','M':'Medium','M-H':'Medium to High','H':'High','H+':'Very High'} %}
{% set bjork = 'None' %}
{% set gras = 'None' %}
{% set al = 'None' %}
{% set alm = 'None' %}
{% set bok = 'None' %}
{% set ek = 'None' %}
{% set grabo = 'None' %}
{% set hassel = 'None' %}
{% set salgvide = 'None' %}
{% if states.sensor.pollen_bjork.state in mymap.keys() %}
{% set bjork = mymap[states.sensor.pollen_bjork.state] %}
{% endif %}
{% if states.sensor.pollen_gras.state in mymap.keys() %}
{% set gras = mymap[states.sensor.pollen_gras.state] %}
{% endif %}
{% if states.sensor.pollen_al.state in mymap.keys() %}
{% set al = mymap[states.sensor.pollen_al.state] %}
{% endif %}
{% if states.sensor.pollen_alm.state in mymap.keys() %}
{% set alm = mymap[states.sensor.pollen_alm.state] %}
{% endif %}
{% if states.sensor.pollen_bok.state in mymap.keys() %}
{% set bok = mymap[states.sensor.pollen_bok.state] %}
{% endif %}
{% if states.sensor.pollen_ek.state in mymap.keys() %}
{% set ek = mymap[states.sensor.pollen_ek.state] %}
{% endif %}
{% if states.sensor.pollen_grabo.state in mymap.keys() %}
{% set grabo = mymap[states.sensor.pollen_grabo.state] %}
{% endif %}
{% if states.sensor.pollen_hassel.state in mymap.keys() %}
{% set hassel = mymap[states.sensor.pollen_hassel.state] %}
{% endif %}
{% if states.sensor.pollen_salgvide.state in mymap.keys() %}
{% set salgvide = mymap[states.sensor.pollen_salgvide.state] %}
{% endif %}
{{["Wakey, wakey.","Rise and shine.","Good morning sunshine.","Get your butt out of bed."] | random}} to this awesome {{states.sensor.weekday.state}} ... time is {{states.sensor.time.state}} ... date is {{states.sensor.dates.state}} ... on week {{states.sensor.weekofyear.state}} ... It's currently {{states.sensor.dark_sky_summary.state}} ... Temperature right now is {{states.sensor.medel_temp_ute.state}} degrees ... lowest today will be {{states.sensor.pws_temp_low_1d_c.state}} degrees ... highest today will be {{states.sensor.pws_temp_high_1d_c.state}} degrees ... Temperature feels like {{states.sensor.medel_chill_effect.state}} degrees ... Here is a summary of this day ... {{states ('sensor.dark_sky_hourly_summary') }} ... Status for grass is {{ gras }} ... Status for birch is {{ bjork }} ... Status for alder is {{ al }} ... Status for elm is {{ alm }} ... Status for beech is {{ bok }} ... Status for oak is {{ ek }} ... Status for mugwort is {{ grabo }} ... Status for hazel is {{ hassel }} ... Status for willow is {{ salgvide }} ... {{["Lets rock.","Have a great day.","Its going to be awesome today.","Rock and roll."] | random}} ... ... Hey Google ... swedish news