New here and found this thread trying to fix my problem so bumping it - hope that’s OK.
So, there’s a few posts about Apple TV “randomly” turning on, however my problem is more similar to this thread which describes the jumping in the UI. My issue is not another device like to original post update and I do not have a problem where it’s only displaying “No title”. Everything seems to be working, except I can’t keep my TV off.
I can live with the jumping in the UI, however, since I’m using CEC (and would like to keep doing that) every time I shut down my Apple TV (and thus the TV), the Apple TV and TV will start again within 1 - 5 minutes.
Even if I were to remove the CEC (which I tried), the Apple TV will still start up and that means that the Apple TV would be on (not in stand-by) 24/7 which I would like to avoid. Since I’m running Home Assistant on an always-on Raspbery Pi the polling will be made 24/7.
I’ve read about the “start_off” parameter, disabling of Apple TV discovery (my Apple TVs is added manually) etcetera but nothing really resolves my issue. So after reading this post I understood that the “start_off” is the same thing as turning the Apple TV off in the UI (no polling will be made), right? Since the jumping won’t occur in this state, nor does the TV start - this kind of resolves my issue. However I have automations setup in Home Assistant which tweaks my lights depending on states of the Apple TV so I don’t want it switched off while actually on. This is my configuration:
discovery:
ignore:
- apple_tv
apple_tv:
- host: 10.10.1.17
login_id: 00000000-xxxx-xxxx-xxxx-xxxxxxxxxxxx
name: "Apple TV Living room"
start_off: true
Since the TV I’m using is a Sony Bravia I was able to connect my TV to Home Assistant. Now what I’ve done is that I’ve added the following automations:
- action:
- alias: Turn on Apple TV
data:
entity_id: remote.apple_tv_living_room
service: remote.turn_on
trigger:
- entity_id: media_player.sony_bravia_tv
from: 'off'
platform: state
to: 'on'
- action:
- alias: Turn off Apple TV
data:
entity_id: remote.apple_tv_living_room
service: remote.turn_off
trigger:
- entity_id: media_player.sony_bravia_tv
from: 'on'
platform: state
to: 'off'
Speaking of that, is there a way to not add the remotes for every Apple TV? I can’t really see the usage of the remote since all I can do with it is to toggle the Apple TV on or off which can also be done via media_player.apple_tv.
This makes sure that whenever the TV is not on, the Apple TV in HA will be off and vice versa.
- Is this really the intended way to setup an Apple TV 4?
- Is there a way to avoid the Apple TV from always starting when HA is on?
- If I turn off CEC - should the Apple TV be on 24/7 anyway?
This issue is only present on Apple TV 4 and not with Apple TV 3.
Setup
Raspberry Pi 1 (Model B)
Linux hassbian 4.9.35+ (although I had to install pyatv/atvremote manually anyway)
HA 0.51.1
Python 3.4.2
Combined with homebridge-homeassistant
Edit
Ok, it seems like the bouncing UI might be related to this, only larger jumps. Since that’s a known bug I guess my only problem is that I cannot keep my Apple TV/TV turend off.