Apple TV remote integration: Airplay button?

Hi all,
On my Apple TV remote I have a button that after a long press, shows available airplay devices.
That way, all outgoing audio from the Apple TV is being streamed to airplay. Is there a way to get HA to do this action?

If you ask why: I would like to use this strategy as a workaround. My audio receiver has airplay, but no other ways of receiving audio streams. My goal is to send a stream via Plex using HA to my Apple TV. Who in turn will stream it to the Audio receiver using airplay.

Support for that is not implemented in Home Assistant, no. It is supported by pyatv so it could be implemented though.

Thank you for your answer.
I imagine this implementation will require some work.
In the meantime, I’d like to explore the options of using pyatv to experiment with this option.
Which pyatv command would allow for airplay? Is it the “home hold” command?
Thanks in advance

Yeah, not much code but needs to be done. You should probably use atvremote ... home=2. You have the different meanings of that number here: pyatv/const.py at c6c77918ea763f89f78f98a28203a0b5d4e03bff · postlund/pyatv · GitHub

Thank you!

1 Like