Using media player attributes, you can automate the muting of intrusive advertisements.
This works well for long form video content like YouTube playing on a Google Nest Hub, Chromecast, or Chromecast with Google TV, and audio content like Spotify playing on Google Home/Nest speakers.
Hi, are you still using this automation in any way?
I use YoutubeTV with Google Chromecast w/ Google TV and would love a way to automate muting of commercials. I’ve tried using your automation but I can’t get it to trigger when a commercial starts.
I’m super new to home automation. Is there a way to debug the different states or parameters the chromecast is in to try and understand how to identify when a commercial is playing?
Hi. Yes indeed, I am using a more complex version of this idea. I’ll say a few things, but you may have to do some research to fill in the gaps if you are more new to HA:
Make sure you have Advanced Mode toggled on in your username settings
Developer Tools → States is the best way to debug the states for your GC w GTV
Traces is the best way to debug an automation
As far as trigger for this automation, my current trigger is:
I also recommend using a condition that filters out previews in the selection menu:
condition: not
conditions:
- condition: state
entity_id: media_player.living_room_tv
attribute: media_title
state: ""
enabled: true
This works best for long form video content (longer than 153 seconds), but notably the short form video content (i.e. shorts) is muted as well. Also long form advertising is not muted automatically.
I’ve updated my original post to reflect some changes you may find useful.