Open chrisaljoudi opened 2 years ago
You need to pair AirPlay
and provide credentials for it to work. The power state is pretty unstable as there is no true power state reported by the Apple TV, it's just something try to derive. But if you provide me with some logs I can take a look. Basically put the device in a state where you expect it to be in a certain power state, but the wrong one is reported. Then run atvremote
with the --debug
flag.
I am having the exact same problem, just using atvremote directly after pairing and with credentials all correct (it will turn the ATV on and off), but always reports paower_state as OFF.
Here's the output with dubug when the ATV is ON (and always reports as being OFF):-
atvremote --debug -i CCD2815BB67C --airplay-credentials `cat ~/.homebridge/ATV/BYXone/airplay.cred` --companion-credentials `cat ~/.homebridge/ATV/BYXone/companion.cred` power_state
2022-07-19 16:50:00 DEBUG [pyatv.scripts]: Running with pyatv 0.10.2
2022-07-19 16:50:00 DEBUG [pyatv.support.net]: Binding on *:5353
2022-07-19 16:50:00 DEBUG [pyatv.support.net]: Binding on 127.0.0.1:0
2022-07-19 16:50:00 DEBUG [pyatv.support.net]: Binding on xxx.xxx.3.3:0
2022-07-19 16:50:00 DEBUG [pyatv.support.net]: Binding on xxx.xxx.3.10:0
2022-07-19 16:50:00 DEBUG [pyatv.support.net]: Binding on xxx.xxx.3.123:0
2022-07-19 16:50:00 DEBUG [pyatv.support.net]: Binding on xxx.xxx.3.53:0
2022-07-19 16:50:00 DEBUG [pyatv.core.scan]: Auto-discovered BYXone at xxx.xxx.33.151:49152 via Protocol.Companion ({'rpmac': '1', 'rphn': 'c08d186da929', 'rpfl': '0xB6782', 'rpha': '86926767511b', 'rpmd': 'AppleTV6,2', 'rpvr': '350.2', 'rpad': '5d35696f3eae', 'rphi': '478eb21e3e97', 'rpba': 'CB:81:DF:C6:D3:3A', 'rpmrtid': 'C7969DC0-2B1D-426E-8946-5E03DB5F2B91'})
2022-07-19 16:50:00 DEBUG [pyatv.core.scan]: Auto-discovered BYXone at xxx.xxx.33.151:7000 via Protocol.AirPlay ({'acl': '0', 'btaddr': 'CC:D2:81:65:A8:79', 'deviceid': 'CC:D2:81:5B:B6:7C', 'fex': '1d9/St5fFbwI', 'features': '0x4A7FDFD5,0xBC155FDE', 'flags': '0x644', 'gid': 'B1C44532-2E92-4689-B812-00F7A5C569B2', 'igl': '1', 'gcgl': '1', 'model': 'AppleTV6,2', 'protovers': '1.1', 'pi': 'da554ed7-314e-4edf-a53a-5a6ba12ca2fc', 'psi': 'C7969DC0-2B1D-426E-8946-5E03DB5F2B91', 'pk': '7d785854aa3cff64de5f0d5b8b9e835bbb45706f03a596a4c27db2e6e59087ff', 'srcvers': '615.12.1', 'osvers': '15.5.1', 'vv': '2'})
2022-07-19 16:50:00 DEBUG [pyatv.core.scan]: Auto-discovered CCD2815BB67C@BYXone at xxx.xxx.33.151:7000 via Protocol.RAOP ({'cn': '0,1,2,3', 'da': 'true', 'et': '0,3,5', 'ft': '0x4A7FDFD5,0xBC155FDE', 'sf': '0x644', 'md': '0,1,2', 'am': 'AppleTV6,2', 'pk': '7d785854aa3cff64de5f0d5b8b9e835bbb45706f03a596a4c27db2e6e59087ff', 'tp': 'UDP', 'vn': '65537', 'vs': '615.12.1', 'ov': '15.5.1', 'vv': '2'})
2022-07-19 16:50:00 INFO [pyatv.scripts.atvremote]: Auto-discovered BYXone at xxx.xxx.33.151
2022-07-19 16:50:00 DEBUG [pyatv.core.facade]: Adding handler for protocol Protocol.AirPlay
2022-07-19 16:50:00 DEBUG [pyatv.protocols.airplay]: Remote control channel is supported
2022-07-19 16:50:00 DEBUG [pyatv.core.facade]: Adding handler for protocol Protocol.MRP
2022-07-19 16:50:00 DEBUG [pyatv.core.facade]: Adding handler for protocol Protocol.Companion
2022-07-19 16:50:00 DEBUG [pyatv.core.facade]: Adding handler for protocol Protocol.MRP
2022-07-19 16:50:00 DEBUG [pyatv.core.facade]: Adding handler for protocol Protocol.RAOP
2022-07-19 16:50:00 DEBUG [pyatv.core.facade]: Connecting to protocol: Protocol.AirPlay
2022-07-19 16:50:00 DEBUG [pyatv.core.facade]: Connected to protocol: Protocol.AirPlay
2022-07-19 16:50:00 DEBUG [pyatv.core.facade]: Connecting to protocol: Protocol.MRP
2022-07-19 16:50:00 DEBUG [pyatv.protocols.airplay.remote_control]: Setting up remote control connection to xxx.xxx.33.151:7000
2022-07-19 16:50:00 DEBUG [pyatv.support.http]: Connected to xxx.xxx.33.151
2022-07-19 16:50:00 DEBUG [pyatv.protocols.airplay.auth]: Setting up new AirPlay Pair-Verify procedure with type AuthenticationType.HAP
2022-07-19 16:50:00 DEBUG [pyatv.support.http]: Sending HTTP/1.1 message: b'POST /pair-verify HTTP/1.1\r\nContent-Length: 37\r\nUser-Agent: AirPlay/320.20\r\nConnection: keep-alive\r\nX-Apple-HKP: 3\r\nContent-Type: application/octet-stream\r\n\r\n\x06\x01\x01\x03 ^\xcc\x88&_\xb2\x14\x92"{\xe2\xbf"\x03@\x8925-\xec\x13R\xf9v\x04\xf1\x96\xf0\xa3\x99\xb3x'
2022-07-19 16:50:00 DEBUG [pyatv.support.http]: Received: b"HTTP/1.1 200 OK\r\nDate: Tue, 19 Jul 2022 15:50:00 GMT\r\nContent-Length: 159\r\nContent-Type: application/octet-stream\r\nServer: AirTunes/615.12.1\r\n\r\n\x05x\xcb9\xb5\x0feEA[\xabi\xeb\x0b\\\xaa_\x82M\xc6\xc6\xc6\x190\xd7$\xb1\xc5\xa08P\x07?e\xbclg\x9c\xd7\x06\xfd\x06\xb3c\x96\x01\x1a,\xd6\xc1\xab\x9c(\xd1\xb7\xd5\xc2\xb0\xf2\xec+\xc3l\xf3\x9b\xee\xe2L\x1eB\x11'\x11X!\x0fs\xc0\xcd\xdaw\xcf\x8bT\xde\xe3-%\x02\xb3\xf7\xdc\x0ev\x1f\xdaD\xbb%Ql\x8d\x88\xcd\x1c\xcd#L\xbc\xc6\xdd)Y2~\xce\x97(\x86F.E\x06\x01\x02\x03 UO\xebwf\xe7\xf8\xa0\xbb$\x92@\xcb\xac\xf8\xed~\xe3\x96\x89]Da\xe0\xaeg\xb0\x7f\xb0\x11\x8bP"
2022-07-19 16:50:00 DEBUG [pyatv.support.http]: Got HTTP response: HttpResponse(protocol='HTTP', version='1.1', code=200, message='OK', headers={'date': 'Tue, 19 Jul 2022 15:50:00 GMT', 'content-length': '159', 'content-type': 'application/octet-stream', 'server': 'AirTunes/615.12.1'}, body=b"\x05x\xcb9\xb5\x0feEA[\xabi\xeb\x0b\\\xaa_\x82M\xc6\xc6\xc6\x190\xd7$\xb1\xc5\xa08P\x07?e\xbclg\x9c\xd7\x06\xfd\x06\xb3c\x96\x01\x1a,\xd6\xc1\xab\x9c(\xd1\xb7\xd5\xc2\xb0\xf2\xec+\xc3l\xf3\x9b\xee\xe2L\x1eB\x11'\x11X!\x0fs\xc0\xcd\xdaw\xcf\x8bT\xde\xe3-%\x02\xb3\xf7\xdc\x0ev\x1f\xdaD\xbb%Ql\x8d\x88\xcd\x1c\xcd#L\xbc\xc6\xdd)Y2~\xce\x97(\x86F.E\x06\x01\x02\x03 UO\xebwf\xe7\xf8\xa0\xbb$\x92@\xcb\xac\xf8\xed~\xe3\x96\x89]Da\xe0\xaeg\xb0\x7f\xb0\x11\x8bP"):
2022-07-19 16:50:00 DEBUG [pyatv.protocols.airplay.auth.hap]: Device (Encrypted=cb39b50f6545415bab69eb0b5caa5f824dc6c6c61930d724b1c5a03850073f65bc6c679cd706fd06b36396011a2cd6c1ab9c28d1b7d5c2b0f2ec2bc36cf39beee24c1e4211271158210f73c0cdda77cf8b54dee32d2502b3f7dc0e761fda44bb25516c8d88cd1ccd234cbcc6dd2959327ece972886462e45, Public=31d5b6b945ff78e30a2c33f5935653a9cd14047074860ea769959d2fd9732c43)
2022-07-19 16:50:00 DEBUG [pyatv.support.http]: Sending HTTP/1.1 message: b"POST /pair-verify HTTP/1.1\r\nContent-Length: 125\r\nUser-Agent: AirPlay/320.20\r\nConnection: keep-alive\r\nX-Apple-HKP: 3\r\nContent-Type: application/octet-stream\r\n\r\n\x06\x01\x03\x05x\xfd\xce\xc9\x82\x84\xc8G\xf2U\x16\x90\xd4\xcc\x92N\x98\xfcR?\x0b\t@\xdf\xac\x16<\x9d\xf1\xc0\xa6\xed$\x08Z7\x1e\x93U\xf0\xf9l\n\x05\x00^\x1f\xa2\x95\xf7g\xc7\xf9v\x0e\xf9\x0c\x87\x9f\xce\x9a\x0fz<'+8\x02\x18O%\x03\x9e \xfe\x01\xc1a\xc55\x7f\x8c\xf0`s\xa0\xe8\xf9\x7f\x01L.W\xecR~x?\xecd\x1c\x02\x7fL\\|\x80}ky%\xd4\xa0\r\xf3T\x96\x84\xa1\xcb5"
2022-07-19 16:50:00 DEBUG [pyatv.support.http]: Received: b'HTTP/1.1 200 OK\r\nDate: Tue, 19 Jul 2022 15:50:00 GMT\r\nContent-Length: 3\r\nContent-Type: application/octet-stream\r\nServer: AirTunes/615.12.1\r\n\r\n\x06\x01\x04'
2022-07-19 16:50:00 DEBUG [pyatv.support.http]: Got HTTP response: HttpResponse(protocol='HTTP', version='1.1', code=200, message='OK', headers={'date': 'Tue, 19 Jul 2022 15:50:00 GMT', 'content-length': '3', 'content-type': 'application/octet-stream', 'server': 'AirTunes/615.12.1'}, body=b'\x06\x01\x04'):
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_srp]: Keys (Input=fb2bdf293447c64e4757819d3600149b84dae73dd7f70102c925c2b99bd44a99, Output=dc748a6fd3d00ccd0424a78f4f1b9740926a4b764434a673ac984e563cc8a676)
2022-07-19 16:50:00 DEBUG [pyatv.support.http]: Sending RTSP/1.0 message: b'SETUP rtsp://xxx.xxx.3.3/2580456882 RTSP/1.0\r\nUser-Agent: AirPlay/540.31\r\nContent-Length: 367\r\nCSeq: 0\r\nDACP-ID: E9F10EE3F7030D38\r\nActive-Remote: 2001727944\r\nClient-Instance: E9F10EE3F7030D38\r\nContent-Type: application/x-apple-binary-plist\r\n\r\nbplist00\xdb\x01\x02\x03\x04\x05\x06\x07\x08\t\n\x0b\x0c\r\x0e\x0f\x10\x11\x12\x13\x14\x15\x16XdeviceID_\x10\x13isRemoteControlOnlyZmacAddressUmodelTname^osBuildVersionVosNameYosVersion[sessionUUID]sourceVersion^timingProtocol_\x10\x11FF:EE:DD:CC:BB:AA\t_\x10\x11AA:BB:CC:DD:EE:FFZiPhone10,6UpyatvU18G82YiPhone OSV14.7.1_\x10$A4EF543D-F5F6-4E64-8570-B3DD9516FB07V550.10TNone\x00\x08\x00\x1f\x00(\x00>\x00I\x00O\x00T\x00c\x00j\x00t\x00\x80\x00\x8e\x00\x9d\x00\xb1\x00\xb2\x00\xc6\x00\xd1\x00\xd7\x00\xdd\x00\xe7\x00\xee\x01\x15\x01\x1c\x00\x00\x00\x00\x00\x00\x02\x01\x00\x00\x00\x00\x00\x00\x00\x17\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01!'
2022-07-19 16:50:00 DEBUG [pyatv.support.http]: Received: b'RTSP/1.0 200 OK\r\nDate: Tue, 19 Jul 2022 15:50:00 GMT\r\nContent-Length: 59\r\nContent-Type: application/x-apple-binary-plist\r\nServer: AirTunes/615.12.1\r\nCSeq: 0\r\n\r\nbplist00\xd1\x01\x02YeventPort\x11\xc0^\x08\x0b\x15\x00\x00\x00\x00\x00\x00\x01\x01\x00\x00\x00\x00\x00\x00\x00\x03\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x18'
2022-07-19 16:50:00 DEBUG [pyatv.support.http]: Got RTSP response: HttpResponse(protocol='RTSP', version='1.0', code=200, message='OK', headers={'date': 'Tue, 19 Jul 2022 15:50:00 GMT', 'content-length': '59', 'content-type': 'application/x-apple-binary-plist', 'server': 'AirTunes/615.12.1', 'cseq': '0'}, body=b'bplist00\xd1\x01\x02YeventPort\x11\xc0^\x08\x0b\x15\x00\x00\x00\x00\x00\x00\x01\x01\x00\x00\x00\x00\x00\x00\x00\x03\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x18'):
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_srp]: Keys (Input=40541440f69a43643d19f0fe351b0328100c47ebea16c017fdde3163600ea555, Output=126d004dd8d26875e4ca94c65e009ce98830d269a0e4f3bc168ba281664cff05)
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_channel]: Connected to xxx.xxx.33.151:49246
2022-07-19 16:50:00 DEBUG [pyatv.support.http]: Sending RTSP/1.0 message: b'RECORD rtsp://xxx.xxx.3.3/2580456882 RTSP/1.0\r\nUser-Agent: AirPlay/540.31\r\nCSeq: 1\r\nDACP-ID: E9F10EE3F7030D38\r\nActive-Remote: 2001727944\r\nClient-Instance: E9F10EE3F7030D38\r\n\r\n'
2022-07-19 16:50:00 DEBUG [pyatv.support.http]: Received: b'RTSP/1.0 200 OK\r\nDate: Tue, 19 Jul 2022 15:50:00 GMT\r\nContent-Length: 0\r\nAudio-Latency: 0\r\nServer: AirTunes/615.12.1\r\nCSeq: 1\r\n\r\n'
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_channel]: Received data (Data=0004faa52fe1060bad73b3167f679d19ed679738d1841fd68d0ebda217fc33e774d74bc29fbe64e39c47bb058071e34421522273042ce866d6762746bab13525e4d65e3063a204bb7616f410aa581cdd3b2bced18260f386382983e3f6d8b7fd073c07b15b80aaac4661b8fc82fa859929f4669ba40e3137eda0a32558e49307c8af7abf168e6f45f98e4ff6abe90b2b7ce3882e01e8490036c7f6637556286297809b0940e6575fc21d7de176a828527a5f486497b674b0fa709f66bab49e61897a021c958ea5ce9e3fb791d5efd7d12a3745d6b7d0c5e8e846e7eae549b07668635efaf42fbf950eaa0c5a14cf2ea647a5a28ed7eaa55d0d0088d142fbb...)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.airplay.channels]: Got message on event channel: HttpRequest(method='POST', path='/command', protocol='RTSP', version='1.0', headers={'cseq': '0', 'content-length': '1385', 'content-type': 'application/x-apple-binary-plist'}, body=b'bplist00\xd2\x01\x02\x03\x04TtypeUvalueZupdateInfo\xdf\x10\x18\x05\x06\x07\x08\t\n\x0b\x0c\r\x0e\x0f\x10\x11\x12\x13\x14\x15\x16\x17\x18\x19\x1a\x1b\x1c\x1d\x1e\x1f&\'#)*+,-.&0123;#=>?@ASpsiRvv_\x10\x14playbackCapabilities_\x10\x15canRecordScreenStream[statusFlags_\x10\x18keepAliveSendStatsAsBodyTname_\x10\x0fprotocolVersion_\x10\x11volumeControlType]senderAddressXdeviceIDRpi^screenDemoMode]initialVolumeZfeaturesExZtxtAirPlay_\x10\x10supportedFormats]sourceVersion_\x10\x16hasUDPMirroringSupportUmodelRpkZmacAddress_\x10\x15receiverHDRCapabilityXfeatures_\x10$C7969DC0-2B1D-426E-8946-5E03DB5F2B91\x10\x02\xd3 !"###_\x10\x15supportsInterstitials_\x10\x15supportsFPSSecureStop_\x10\x1dsupportsUIForAudioOnlyContent\t\t\t\x08\x11\x06D\tVBYXoneS1.1\x10\x04^xxx.xxx.3.3:64160_\x10\x11CC:D2:81:5B:B6:7C_\x10$da554ed7-314e-4edf-a53a-5a6ba12ca2fc\x08#\x00\x00\x00\x00\x00\x00\x00\x00\\1d9/St5fFbwIO\x11\x01\x84\x05acl=0\x18btaddr=CC:D2:81:65:A8:79\x1adeviceid=CC:D2:81:5B:B6:7C\x10fex=1d9/St5fFbwI\x1efeatures=0x4A7FDFD5,0xBC155FDE\x0bflags=0x644(gid=B1C44532-2E92-4689-B812-00F7A5C569B2\x05igl=1\x06gcgl=1\x10model=AppleTV6,2\rprotovers=1.1\'pi=da554ed7-314e-4edf-a53a-5a6ba12ca2fc(psi=C7969DC0-2B1D-426E-8946-5E03DB5F2B91Cpk=7d785854aa3cff64de5f0d5b8b9e835bbb45706f03a596a4c27db2e6e59087ff\x10srcvers=615.12.1\rosvers=15.5.1\x04vv=2\xd44567899:_\x10\x15lowLatencyAudioStream\\screenStream[audioStream\\bufferStream\x10\x00\x12\x01D\x08\x00\x12\x00\xe0\x00\x00X615.12.1\tZAppleTV6,2O\x10 }xXT\xaa<\xffd\xde_\r[\x8b\x9e\x83[\xbbEpo\x03\xa5\x96\xa4\xc2}\xb2\xe6\xe5\x90\x87\xff_\x10\x11CC:D2:81:5B:B6:7CT4k30\x13\xbc\x15_\xdeJ\x7f\xdf\xd5\x00\x08\x00\r\x00\x12\x00\x18\x00#\x00V\x00Z\x00]\x00t\x00\x8c\x00\x98\x00\xb3\x00\xb8\x00\xca\x00\xde\x00\xec\x00\xf5\x00\xf8\x01\x07\x01\x15\x01 \x01+\x01>\x01L\x01e\x01k\x01n\x01y\x01\x91\x01\x9a\x01\xc1\x01\xc3\x01\xca\x01\xe2\x01\xfa\x02\x1a\x02\x1b\x02\x1c\x02\x1d\x02\x1e\x02!\x02"\x02)\x02-\x02/\x02>\x02R\x02y\x02z\x02\x83\x02\x90\x04\x18\x04!\x049\x04F\x04R\x04_\x04a\x04f\x04k\x04t\x04u\x04\x80\x04\xa3\x04\xb7\x04\xbc\x00\x00\x00\x00\x00\x00\x02\x01\x00\x00\x00\x00\x00\x00\x00B\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x04\xc5')
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_channel]: Sending data (Encrypted=4f000c49992302797f359a44a1cb36edcc4d90c82823b23dab28bd4856ed38dfe02cd608c39e163d93c4cdebf81d7389ba78ed0c2b453ad33e62a96f57c0dce075215f2dab21af57b9ca8c179a536acea519d9b72a4c73e9b07484a638c1e4e9b2)
2022-07-19 16:50:00 DEBUG [pyatv.support.http]: Got RTSP response: HttpResponse(protocol='RTSP', version='1.0', code=200, message='OK', headers={'date': 'Tue, 19 Jul 2022 15:50:00 GMT', 'content-length': '0', 'audio-latency': '0', 'server': 'AirTunes/615.12.1', 'cseq': '1'}, body=''):
2022-07-19 16:50:00 DEBUG [pyatv.support.http]: Sending RTSP/1.0 message: b'SETUP rtsp://xxx.xxx.3.3/2580456882 RTSP/1.0\r\nUser-Agent: AirPlay/540.31\r\nContent-Length: 324\r\nCSeq: 2\r\nDACP-ID: E9F10EE3F7030D38\r\nActive-Remote: 2001727944\r\nClient-Instance: E9F10EE3F7030D38\r\nContent-Type: application/x-apple-binary-plist\r\n\r\nbplist00\xd1\x01\x02Wstreams\xa1\x03\xd7\x04\x05\x06\x07\x08\t\n\x0b\x0c\r\x0e\x0f\x10\x11YchannelID^clientTypeUUIDZclientUUID[controlTypeTseedTtype_\x10\x14wantsDedicatedSocket_\x10$F9973799-90F3-4E22-B339-575B7D37FC39_\x10$1910A70F-DBC0-4242-AF95-115DB30604E1_\x10$C339ACBC-D2E8-4B05-8F74-D5907D72A835\x10\x02\x14\x00\x00\x00\x00\x00\x00\x00\x00\xec\xde\xa1\xefY-f\x8d\x10\x82\t\x00\x08\x00\x0b\x00\x13\x00\x15\x00$\x00.\x00=\x00H\x00T\x00Y\x00^\x00u\x00\x9c\x00\xc3\x00\xea\x00\xec\x00\xfd\x00\xff\x00\x00\x00\x00\x00\x00\x02\x01\x00\x00\x00\x00\x00\x00\x00\x12\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x01\x00'
2022-07-19 16:50:00 DEBUG [pyatv.support.http]: Received: b'RTSP/1.0 200 OK\r\nDate: Tue, 19 Jul 2022 15:50:00 GMT\r\nContent-Length: 100\r\nContent-Type: application/x-apple-binary-plist\r\nServer: AirTunes/615.12.1\r\nCSeq: 2\r\n\r\nbplist00\xd1\x01\x02Wstreams\xa1\x03\xd3\x04\x05\x06\x07\x08\tTtypeXstreamIDXdataPort\x10\x82\x10\x01\x11\xc0_\x08\x0b\x13\x15\x1c!*357\x00\x00\x00\x00\x00\x00\x01\x01\x00\x00\x00\x00\x00\x00\x00\n\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00:'
2022-07-19 16:50:00 DEBUG [pyatv.support.http]: Got RTSP response: HttpResponse(protocol='RTSP', version='1.0', code=200, message='OK', headers={'date': 'Tue, 19 Jul 2022 15:50:00 GMT', 'content-length': '100', 'content-type': 'application/x-apple-binary-plist', 'server': 'AirTunes/615.12.1', 'cseq': '2'}, body=b'bplist00\xd1\x01\x02Wstreams\xa1\x03\xd3\x04\x05\x06\x07\x08\tTtypeXstreamIDXdataPort\x10\x82\x10\x01\x11\xc0_\x08\x0b\x13\x15\x1c!*357\x00\x00\x00\x00\x00\x00\x01\x01\x00\x00\x00\x00\x00\x00\x00\n\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00:'):
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_srp]: Keys (Input=0b2f988caeba1ad8ff794142b9097a7092d2de108709cc640b0f12d2cb88eefa, Output=c2a3bb3e5dae893e0ec0e2032ac63ad67e68851e78d016c529ff69b7ade659cf)
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_channel]: Connected to xxx.xxx.33.151:49247
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_channel]: Sending data (Encrypted=3c01adb3219b9e6a21e28034a9ba9be1e8c88ba54d7031d5ff7739f814b831a81d6de15d6b5fd8c8ec9b0f60823255aa4e0b5dd9ab0344fff57c0078d31421c857cd7a8bd47510ad1eb8029ec425844b9094066689eda4d9a100dd24edae835499b73bfd978b4df4df3d4af7ec5a811656500f910a0343e491b5c850963038c2bcd401dea9610f9f17b46ed5bc68102675985f972815ddd6cf726ee8cf332f13e1b3e45d6537dcad0b3eae69d697fdde7d9a8833981853d4a1155db8142567348e771cd8dfe10f303e7e9af2842c3844e9a075560809df4f4ba669260a195121ac81d040065cf5efdceb84bfc71368b31bafc9000a4d69a0a20c85b9a3b66...)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.airplay.mrp_connection]: >> Send: Protobuf: type: DEVICE_INFO_MESSAGE
identifier: "BC12D359-3AD9-4CCD-AB93-CED4E1FC446E"
errorCode: NoError
[deviceInfoMessage] {
uniqueIdentifier: "bbb78370-15e8-4ed6-93eb-9c2098ed0b5b"
name: "pyatv"
localizedModelName: "iPhone"
systemBuildVersion: "18A393"
applicationBundleIdentifier: "com.apple.TVRemote"
applicationBundleVersion: "344.28"
protocolVersion: 1
lastSupportedMessageType: 108
supportsSystemPairing: true
allowsPairing: true
systemMediaApplication: "com.apple.TVMusic"
supportsACL: true
supportsSharedQueue: true
supportsExtendedMotion: true
sharedQueueVersion: 2
deviceClass: iPhone
logicalDeviceCount: 1
}
uniqueIdentifier: "B16DEE9B-76D2-4035-B9F5-8F53447D5E62"
2022-07-19 16:50:00 DEBUG [pyatv.core.protocol]: Starting heartbeat loop (AirPlay:xxx.xxx.33.151)
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_channel]: Received data (Data=20007dc118af9e04dde7fcc825d75ff3c65b0149ac3f54f52f0990ff899f9d0339cdebcb3354dd7af1829274e16a2516f5492a00c61337c8c2879a195ba034169dbb8e7bb9970a955e32d1a031d38dc989c29fac08c8435cbb14b3783c73f5711149673e3f6628f84ff4e1d76538)
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_channel]: Received data (Data=20009f8cdc6afff151fbdaf392284a550cf9b20de17da170b225e47e5f8e4eb2a05f6165e4d6741186eb0b7a2c03e86ea96d4b0213493605144a5f09989f5c53aba6c2a9d4ac002e5d2990f17bcabacbc82bd3b4d9d85d246da4fefaab1873d8bc2940298cacde20c9b90a030b9aa343ccc3876d5032738012f20675f9cf0d64b63cc47e2aa526af5c01e0c17165c7af2fba6959846d4331b8b5c5a5d1f18bf3b6a09ceb630bed9d188d01ee29be7be8f6a09e473651bf47840ab812698ef9b9b7febb75b94148129b7b24a97479ae8a625a1e384b4cc5e7cd7e5507d7ff3d8fb95ddd92255e5d4c5045105c3da7d0150003bc94dc62c1decfc5cd80e50f7...)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.airplay.mrp_connection]: << Receive: Protobuf: type: DEVICE_INFO_MESSAGE
identifier: "BC12D359-3AD9-4CCD-AB93-CED4E1FC446E"
[deviceInfoMessage] {
uniqueIdentifier: "C7969DC0-2B1D-426E-8946-5E03DB5F2B91"
name: "BYXone"
localizedModelName: "Apple\302\240TV"
systemBuildVersion: "19L580"
applicationBundleIdentifier: "com.apple.mediaremoted"
protocolVersion: 1
lastSupportedMessageType: 123
supportsSystemPairing: true
allowsPairing: true
systemMediaApplication: "com.apple.TVMusic"
supportsACL: true
supportsSharedQueue: true
supportsExtendedMotion: true
sharedQueueVersion: 3
deviceUID: "C7969DC0-2B1D-426E-8946-5E03DB5F2B91"
managedConfigDeviceID: "cc:d2:81:5b:b6:7c"
deviceClass: AppleTV
logicalDeviceCount: 0
isProxyGroupPlayer: true
groupUID: "B1C44532-2E92-4689-B812-00F7A5C569B2"
isGroupLeader: true
isAirplayActive: false
systemPodcastApplication: "com.apple.podcasts"
senderDefaultGroupUID: "B1C44532-2E92-4689-B812-00F7A5C569B2"
airplayReceivers: "TVAirPlay"
clusterType: 0
isClusterAware: true
modelID: "AppleTV6,2"
supportsMultiplayer: false
routingContextID: "577E1BCA-2D9B-41C2-A8F8-C515CE8072D4"
airPlayGroupID: "B1C44532-2E92-4689-B812-00F7A5C569B2"
systemBooksApplication: "com.apple.TVBooks"
}
uniqueIdentifier: "05D4EB64-5475-4538-8C43-BB9E5BDA9DAD"
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_channel]: Sending data (Encrypted=200082ddb75bd0b2ca2bcd228507552bea23cb0818749128a3672d35d231275f8fe673bda1f8d6d12e15dc816053d6b76d92)
2022-07-19 16:50:00 DEBUG [pyatv.core.protocol]: Dispatching message with type 15 to <bound method MrpPower._update_power_state of <pyatv.protocols.mrp.MrpPower object at 0x10450b1c0>>
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_channel]: Sending data (Encrypted=9300138c83c01ead56a2462558efce03f87c9c61927222a2e7b32325b5938016eda98af4892fda3b282bd7c6966ef97cf5a131f4ad796f23cbecf0d1b2cebbc0318e150aed3fd2700e22d0fc401247414a8e1b172450fca4a57162f0d95b07d994ef0d811d1989b574761ca2b08a674bdbb24f181e199be6dcd4fe427b1c85f4edf80b561765c566637a32628c20b21854b7b9b2474bf1bae5c58129dae28c5e6ee65e14df)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.airplay.mrp_connection]: >> Send: Protobuf: type: SET_CONNECTION_STATE_MESSAGE
errorCode: NoError
[setConnectionStateMessage] {
state: Connected
}
uniqueIdentifier: "5E75B918-B053-4D33-A51E-5C0C60D3C177"
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_channel]: Sending data (Encrypted=c100b9dbabaed593bdc90c4e7e0f5bb2e6b1a09cf13d0dbed8166ac4559a41fea5ddaab81df31d75a55b4edd151b8dc98f33f1b54b2951cfa83cfd0af55bbd138bb8b41eee93b62e3d17c9b5ccdcd9e4664338b407bdb7d8ad7e7b630b6404aae09ed8ee9254d5dd79df9418043994505562dad4ebedaf79afea91e803466da9b852a57c4f1bb3d8b3bb080491acc38d3e39f8a5e8b0e4e27dd34f1038881b6447c898d87efd2249a43d34ca8866388622e3f9dbff528e8003ec712e4130c14d3057f76284e85c735d20de58158ab8008e8730)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.airplay.mrp_connection]: >> Send: Protobuf: type: CLIENT_UPDATES_CONFIG_MESSAGE
identifier: "AE0DDFDF-2607-4228-8709-4883D14DA595"
errorCode: NoError
[clientUpdatesConfigMessage] {
artworkUpdates: true
nowPlayingUpdates: false
volumeUpdates: true
keyboardUpdates: true
outputDeviceUpdates: true
}
uniqueIdentifier: "6FC90A39-63C0-4250-BEF5-A7890BEC7B4C"
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_channel]: Received data (Data=2000229591ae5677a9cc43744f05c88e307d8534b2ba6266062b72bcd72d4d95a8e08d9364563694e7bc4f546b6f4a707a412a00e5a2c150d8183ff826adf4629039f50bbc2976eebe09b5bdcc2ca07c3fcc8bc74637a3ac0faf2c5be19db886a600aa02ca6d9815ff51dc22b4ff)
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_channel]: Received data (Data=2000220a1b4cc6afb626bf1cf58eacff9cf78cd214c608971f0f080477131fe74e97db3fde10dd75aa64878dbbb36ba4d7fc)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.airplay.channels]: Not enough data on data channel (has 32, expects 74)
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_channel]: Received data (Data=2a00749d7ffeda1ae96c1e70fae2cc20a39bfff51e23b6eaec764373e2a8952b17b98d6ebf3f62519eac72ea0933b727c750ad1b247d1ace1c28828b)
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_channel]: Received data (Data=20007935104c5e8f477489450c5555469831766e8491bdd1e622fcdac26f6206863d51351098bea9433ef0823d55b745fbcf)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.airplay.channels]: Not enough data on data channel (has 32, expects 145)
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_channel]: Received data (Data=710060854bbd037fb70e1f4d5f8d9edf0a76fce854d573b0ed8f56c47b1f78122d50b92cb6945445644edccea931e5ec1585baaa598669020bee1139dbaac2ed776af7d590cdfd979b0763a0a0e4bc0824b3f79084daf178f120c3842b1af1e6cec87f2cdc344aaf502b84a3ea2829de23ffbcf91fee811963baa8b4e4ad5087032894)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.airplay.mrp_connection]: << Receive: Protobuf: type: SET_HILITE_MODE_MESSAGE
[setHiliteModeMessage] {
hiliteMode: 1
}
uniqueIdentifier: "DAEE3DF3-F9F9-4F76-84E7-DFD7D7B66401"
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_channel]: Sending data (Encrypted=2000c90a73e0d4a649f56cd66ad1bef3fcc9c19cdec1dbee56d016d1fc0d72ca3f52532af3dc604720d18ec0f5cb3e0ddc8c)
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_channel]: Received data (Data=2000c8c7f85fe7a29479a041ded904c3358f02807371064f89d6c15daa20431b30398e6a1400d09bcd302d116a845d5b90b11a05cbac2fabdca2e91b3bd33a5ffd301d1c026ba9a36b73a30bfe08ae6c2a0ee0caadb16bd80173d995c1f35106a83a05bef51f6c5fd3e8764ceaa5fce073b6ec17023495894899109faf2722919099d3714c23398e96e71b066ed7dd4b8c875ba1d8f9a26197c717781cadd7ca1d9657e53725c2df0efd4ad1098b8c2282a1bd694914aeec22af4645b70ac4029be2e13b3eebfbbf6fe3eb4569dcf8e3906eedd7e5fd6a9f7eeba1f40fee79e7cb721280fd475b96dbc6e30d0ba8c185983f7c324432d1b0204e0fb199249...)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.airplay.mrp_connection]: << Receive: Protobuf: type: UPDATE_OUTPUT_DEVICE_MESSAGE
[updateOutputDeviceMessage] {
}
uniqueIdentifier: "B45530A7-B08B-45BB-BECD-64F6A8DC3861"
2022-07-19 16:50:00 DEBUG [pyatv.protocols.airplay.mrp_connection]: << Receive: Protobuf: type: SET_DEFAULT_SUPPORTED_COMMANDS_MESSAGE
[setDefaultSupportedCommandsMessage] {
supportedCommands {
supportedCommands {
command: Play
enabled: true
}
supportedCommands {
command: PrepareForSetQueue
enabled: true
}
supportedCommands {
command: SetPlaybackQueue
enabled: true
supportedPlaybackQueueTypes: 7
supportedPlaybackQueueTypes: 3
supportedPlaybackQueueTypes: 6
supportedPlaybackQueueTypes: 2
supportedPlaybackQueueTypes: 5
supportedPlaybackQueueTypes: 1
supportedPlaybackQueueTypes: 8
supportedCustomQueueIdentifiers: "com.apple.music.playbackqueue.radio"
supportedCustomQueueIdentifiers: "com.apple.music.playbackqueue.tracklist"
supportedCustomQueueIdentifiers: "com.apple.MediaPlaybackCore.playbackContextArchive-v1.opack"
supportedCustomQueueIdentifiers: "com.apple.mediaplayer.playbackcontext"
}
supportedCommands {
command: SetPlaybackSession
}
supportedCommands {
command: PreloadedPlaybackSession
}
}
displayID: "com.apple.TVMusic"
playbackQueueCapabilities {
}
playerPath {
client {
bundleIdentifier: "com.apple.TVMusic"
}
}
}
uniqueIdentifier: "13E202DF-1B4B-4005-BBC5-C5E3C32AC4DE"
2022-07-19 16:50:00 DEBUG [pyatv.core.protocol]: Dispatching message with type 72 to <bound method PlayerStateManager._handle_set_default_supported_commands of <pyatv.protocols.mrp.player_state.PlayerStateManager object at 0x10450b250>>
2022-07-19 16:50:00 DEBUG [pyatv.protocols.airplay.mrp_connection]: << Receive: Protobuf: type: SET_DEFAULT_SUPPORTED_COMMANDS_MESSAGE
[setDefaultSupportedCommandsMessage] {
supportedCommands {
supportedCommands {
command: Play
enabled: true
}
supportedCommands {
command: SetPlaybackQueue
enabled: true
supportedPlaybackQueueTypes: 3
supportedPlaybackQueueTypes: 6
supportedPlaybackQueueTypes: 2
supportedPlaybackQueueTypes: 5
supportedPlaybackQueueTypes: 1
}
supportedCommands {
command: SetPlaybackSession
enabled: true
supportedPlaybackSessionTypes: "com.apple.podcasts.MTPlaybackQueueController.GenericQueue"
currentPlaybackSessionTypes: "com.apple.podcasts.MTPlaybackQueueController.GenericQueue"
}
}
displayID: "com.apple.podcasts"
playbackQueueCapabilities {
}
playerPath {
client {
bundleIdentifier: "com.apple.podcasts"
}
}
}
uniqueIdentifier: "DE4490A3-C341-41C2-BBEB-6589A47BAFAE"
2022-07-19 16:50:00 DEBUG [pyatv.core.protocol]: Dispatching message with type 72 to <bound method PlayerStateManager._handle_set_default_supported_commands of <pyatv.protocols.mrp.player_state.PlayerStateManager object at 0x10450b250>>
2022-07-19 16:50:00 DEBUG [pyatv.protocols.airplay.mrp_connection]: << Receive: Protobuf: type: ORIGIN_CLIENT_PROPERTIES_MESSAGE
uniqueIdentifier: "1C9974F9-AA34-4453-8D82-B93788AFDB34"
[originClientPropertiesMessage] {
lastPlayingTimestamp: 679938359.9782909
}
2022-07-19 16:50:00 DEBUG [pyatv.protocols.airplay.mrp_connection]: << Receive: Protobuf: type: UPDATE_CLIENT_MESSAGE
[updateClientMessage] {
client {
processIdentifier: 154
bundleIdentifier: "com.apple.TVAirPlay"
processUserIdentifier: 501
displayName: "AirPlay"
}
}
uniqueIdentifier: "C87B160B-4581-4960-A723-F218CBC3EA4A"
2022-07-19 16:50:00 DEBUG [pyatv.core.protocol]: Dispatching message with type 55 to <bound method PlayerStateManager._handle_update_client of <pyatv.protocols.mrp.player_state.PlayerStateManager object at 0x10450b250>>
2022-07-19 16:50:00 DEBUG [pyatv.protocols.airplay.mrp_connection]: << Receive: Protobuf: type: SET_STATE_MESSAGE
[setStateMessage] {
supportedCommands {
supportedCommands {
command: Play
enabled: true
}
supportedCommands {
command: Pause
enabled: true
}
supportedCommands {
command: TogglePlayPause
enabled: true
}
supportedCommands {
command: Stop
enabled: true
}
supportedCommands {
command: NextTrack
enabled: true
}
supportedCommands {
command: PreviousTrack
enabled: true
}
supportedCommands {
command: BeginFastForward
enabled: true
}
supportedCommands {
command: EndFastForward
enabled: true
}
supportedCommands {
command: BeginRewind
enabled: true
}
supportedCommands {
command: EndRewind
enabled: true
}
supportedCommands {
command: AdvanceRepeatMode
enabled: true
}
supportedCommands {
command: AdvanceShuffleMode
enabled: true
}
supportedCommands {
command: SeekToPlaybackPosition
enabled: true
}
}
displayName: "AirPlay"
playbackState: Paused
playbackQueueCapabilities {
}
playerPath {
origin {
displayName: "BYXone"
identifier: 1280262988
}
client {
processIdentifier: 154
bundleIdentifier: "com.apple.TVAirPlay"
}
player {
identifier: "MediaRemote-DefaultPlayer"
displayName: "Default Player"
6: 0
}
}
playbackStateTimestamp: 679933810.818278
}
uniqueIdentifier: "050DA1F3-439D-4F70-B05F-B5F15F3A93BB"
2022-07-19 16:50:00 DEBUG [pyatv.core.protocol]: Dispatching message with type 4 to <bound method PlayerStateManager._handle_set_state of <pyatv.protocols.mrp.player_state.PlayerStateManager object at 0x10450b250>>
2022-07-19 16:50:00 DEBUG [pyatv.protocols.airplay.mrp_connection]: << Receive: Protobuf: type: PLAYER_CLIENT_PROPERTIES_MESSAGE
uniqueIdentifier: "AF987EEE-9EA7-48C5-A3C4-5C131487B06C"
[playerClientPropertiesMessage] {
playerPath {
origin {
displayName: "BYXone"
identifier: 1280262988
5: 1
}
client {
processIdentifier: 154
bundleIdentifier: "com.apple.TVAirPlay"
processUserIdentifier: 501
displayName: "AirPlay"
}
player {
identifier: "MediaRemote-DefaultPlayer"
displayName: "Default Player"
6: 0
}
}
lastPlayingTimestamp: -63114076800.0
}
2022-07-19 16:50:00 DEBUG [pyatv.protocols.airplay.mrp_connection]: << Receive: Protobuf: type: UNKNOWN_MESSAGE
identifier: "AE0DDFDF-2607-4228-8709-4883D14DA595"
uniqueIdentifier: "EEA11EBD-4E18-4474-9414-159CBC6FFC68"
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_channel]: Sending data (Encrypted=2000af5834a628306a3da6137a194d55cb436d5d58b0728d890bfbcd6b162b7d9135730a64a50ce6dd2d9522d44b3934270d)
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_channel]: Sending data (Encrypted=b400ad107f16b80033e3c556e009e6565a48c18081367ffd2ac124cd99e03105cd63773fca32995488c29f2670eca6be3cb08a3aec0bc58ade0c1b87e0e0f5210cbf4108373b700d96ce82c315346239ff1504692aae8ad3798faa088946eaa950f3f92cadfa22b43a9b35911a058d902e7d5c8eb1e0d2dd543e3edfa0ba5052ee23ece397750d1d13d505f75738c41fca3082abb9f9a25f90bae07cf8571e2aa6aad83af6478b4985680fc453048c97a141b0d9f24774a881af35a6270c762e0ed9b71d8cb9)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.airplay.mrp_connection]: >> Send: Protobuf: type: GET_KEYBOARD_SESSION_MESSAGE
identifier: "75C80FEA-2513-4DC1-9BDB-DAFADDDF8002"
errorCode: NoError
uniqueIdentifier: "793B5F2B-5487-4BB3-B4A5-C15B6367FE10"
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_channel]: Received data (Data=2000f1cd888a6989a5b18c66548a5121f83002479e1ae2ddc42392a6d47535822444c8901ff8490ef20255102bf86b6b38e62a002bf8fdd4c1990fe00f6116f2b1649bace3f13e48c582743e5b1a307d032b729736f17e2d6e8f107e68aaa236b1993e967294d326d6c18f37492b)
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_channel]: Received data (Data=20003ed3f7041a713b280830f457bbe530466249615cfbb243daf4b92ca7096284e4df9c7315ce00b5852e8bdc484c4adbeba9005dbc43fbaca22154ee33081c086758d35dc30bb56729f793a29c0c0d0a61d74d8c7a58bd8dd8cff19c0cb446755d9f6e072d6d04955e6d5b2a8598d82a9099ac0c108fe6ca5343927a58c9f29e6d6785387ac782b657dd34a833bf892856f9eb10daca9000afdd01618abee9a26a34709d5e1e2e1ed5c35dad43937ab7c305673c4cf30af07994c1e4de2333b19017c6ed153d01e7cfce9bbaa91401a74f90a2a189c87b3a3ed8a82c75e29ea3ef260cc4298b7d55ead3878d)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.airplay.mrp_connection]: << Receive: Protobuf: type: KEYBOARD_MESSAGE
identifier: "75C80FEA-2513-4DC1-9BDB-DAFADDDF8002"
[keyboardMessage] {
state: Unknown
attributes {
inputTraits {
autocapitalizationType: None
keyboardType: Default
returnKeyType: Default
enablesReturnKeyAutomatically: false
secureTextEntry: false
validTextRangeLocation: 0
validTextRangeLength: 0
}
}
}
uniqueIdentifier: "73FB01A3-85B7-4653-8275-799E3938D529"
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_channel]: Sending data (Encrypted=2000ecd6a43ade3484eec216070ed5cbf2063e831b8ce12bf7e981ce793616a77c043eb1683c9db2a8a45d9b991b08195b9f)
2022-07-19 16:50:00 DEBUG [pyatv.core.facade]: Connected to protocol: Protocol.MRP
2022-07-19 16:50:00 DEBUG [pyatv.core.facade]: Connecting to protocol: Protocol.Companion
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.api]: Connect to Companion from API
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.connection]: Connected to companion device xxx.xxx.33.151:49152
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.protocol]: Companion credentials: 31d5b6b945ff78e30a2c33f5935653a9cd14047074860ea769959d2fd9732c43:8d5415e6a84444c76d8661af021bee0ede7d4303ffbb86134b4ac7dcef455fc5:43373936394443302d324231442d343236452d383934362d354530334442354632423931:35656164663733622d386138332d343131312d626465632d373030616232636262323965
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.protocol]: Exchange OPACK: {'_pd': b'\x06\x01\x01\x03 v\xb2\x85\x91\xadD\n\x9aR\xc2\xbb\xd3\xf4#_n\x96\x06.[P\x18gg\xdf\xb7\xb82K\xd3ES', '_auTy': 4}
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.protocol]: Send OPACK: {'_pd': b'\x06\x01\x01\x03 v\xb2\x85\x91\xadD\n\x9aR\xc2\xbb\xd3\xf4#_n\x96\x06.[P\x18gg\xdf\xb7\xb82K\xd3ES', '_auTy': 4, '_x': 60089}
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.connection]: >> Send data (Data=e3435f70649125060101032076b28591ad440a9a52c2bbd3f4235f6e96062e5b50186767dfb7b8324bd34553455f617554790c425f7831b9ea, FrameType=05)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.connection]: Received data (Data=060000a6e1435f7064919f0578ab6deb7c5ffc57f56ad861ef4e4afe3127c9544eb1b032d5698af7abc9b5c329ab4a32b7eb7ea57ebd85685aee82e2c38d4aa3f6f1ae243e276056e8e6bf62b86cbcdee893a4cb5da6d954e27abe7678a1c0fabc5683c6d26abaadbcd814540a94434f500b4d4c006d97a785a2ba968d07617983467fb739060102032059128ec9ebad30ac37a08a717f0747fb87c87e86ba8f9138fe88f03b4239d027)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.protocol]: Received frame FrameType.PV_Next: b"\xe1C_pd\x91\x9f\x05x\xabm\xeb|_\xfcW\xf5j\xd8a\xefNJ\xfe1'\xc9TN\xb1\xb02\xd5i\x8a\xf7\xab\xc9\xb5\xc3)\xabJ2\xb7\xeb~\xa5~\xbd\x85hZ\xee\x82\xe2\xc3\x8dJ\xa3\xf6\xf1\xae$>'`V\xe8\xe6\xbfb\xb8l\xbc\xde\xe8\x93\xa4\xcb]\xa6\xd9T\xe2z\xbevx\xa1\xc0\xfa\xbcV\x83\xc6\xd2j\xba\xad\xbc\xd8\x14T\n\x94COP\x0bML\x00m\x97\xa7\x85\xa2\xba\x96\x8d\x07ay\x83F\x7f\xb79\x06\x01\x02\x03 Y\x12\x8e\xc9\xeb\xad0\xac7\xa0\x8aq\x7f\x07G\xfb\x87\xc8~\x86\xba\x8f\x918\xfe\x88\xf0;B9\xd0'"
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.protocol]: Process incoming auth frame (FrameType.PV_Next): {'_pd': b"\x05x\xabm\xeb|_\xfcW\xf5j\xd8a\xefNJ\xfe1'\xc9TN\xb1\xb02\xd5i\x8a\xf7\xab\xc9\xb5\xc3)\xabJ2\xb7\xeb~\xa5~\xbd\x85hZ\xee\x82\xe2\xc3\x8dJ\xa3\xf6\xf1\xae$>'`V\xe8\xe6\xbfb\xb8l\xbc\xde\xe8\x93\xa4\xcb]\xa6\xd9T\xe2z\xbevx\xa1\xc0\xfa\xbcV\x83\xc6\xd2j\xba\xad\xbc\xd8\x14T\n\x94COP\x0bML\x00m\x97\xa7\x85\xa2\xba\x96\x8d\x07ay\x83F\x7f\xb79\x06\x01\x02\x03 Y\x12\x8e\xc9\xeb\xad0\xac7\xa0\x8aq\x7f\x07G\xfb\x87\xc8~\x86\xba\x8f\x918\xfe\x88\xf0;B9\xd0'"}
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.auth]: Device (Encrypted=ab6deb7c5ffc57f56ad861ef4e4afe3127c9544eb1b032d5698af7abc9b5c329ab4a32b7eb7ea57ebd85685aee82e2c38d4aa3f6f1ae243e276056e8e6bf62b86cbcdee893a4cb5da6d954e27abe7678a1c0fabc5683c6d26abaadbcd814540a94434f500b4d4c006d97a785a2ba968d07617983467fb739, Public=31d5b6b945ff78e30a2c33f5935653a9cd14047074860ea769959d2fd9732c43)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.protocol]: Exchange OPACK: {'_pd': b'\x06\x01\x03\x05x\x15\xe15\x88\xfa\x8d<\xba\x9b\xa6\xef\xc1\xe5\xb5\xec!\xcc\xa2\xbc\xcd\xcdv\x0f\xf7\x15\xfaX\xc4\x033[\x7f\xa7t\x89@(;\x7f\xb2\x83(L6\xfa\xe2\xeee\'\xd0"o\xc6\xd9\xf3t[\xe8\x1e3\xef\xaf\xa3\r\xdf\x93\xaeu\xa0\xf3\xaa\xee\x01\xea\x96\xb6|\xbaLR=\x9a\xe0R\x1e&\x9ai\x98\xb4\xcaAC\xe4R\xd4\xee\xd8\xd5\xe0 \xec\xab\xa1\xefZ4,R\x85wvK(\xad\xf1\r&Hj'}
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.protocol]: Send OPACK: {'_pd': b'\x06\x01\x03\x05x\x15\xe15\x88\xfa\x8d<\xba\x9b\xa6\xef\xc1\xe5\xb5\xec!\xcc\xa2\xbc\xcd\xcdv\x0f\xf7\x15\xfaX\xc4\x033[\x7f\xa7t\x89@(;\x7f\xb2\x83(L6\xfa\xe2\xeee\'\xd0"o\xc6\xd9\xf3t[\xe8\x1e3\xef\xaf\xa3\r\xdf\x93\xaeu\xa0\xf3\xaa\xee\x01\xea\x96\xb6|\xbaLR=\x9a\xe0R\x1e&\x9ai\x98\xb4\xcaAC\xe4R\xd4\xee\xd8\xd5\xe0 \xec\xab\xa1\xefZ4,R\x85wvK(\xad\xf1\r&Hj', '_x': 60090}
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.connection]: >> Send data (Data=e2435f7064917d060103057815e13588fa8d3cba9ba6efc1e5b5ec21cca2bccdcd760ff715fa58c403335b7fa7748940283b7fb283284c36fae2ee6527d0226fc6d9f3745be81e33efafa30ddf93ae75a0f3aaee01ea96b67cba4c523d9ae0521e269a6998b4ca4143e452d4eed8d5e020ecaba1ef5a342c528577764b28adf10d26486a425f7831baea, FrameType=06)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.connection]: Received data (Data=06000009e1435f706473060104)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.protocol]: Received frame FrameType.PV_Next: b'\xe1C_pds\x06\x01\x04'
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.protocol]: Process incoming auth frame (FrameType.PV_Next): {'_pd': b'\x06\x01\x04'}
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_srp]: Keys (Input=1b27e1deead3ee8f4fbf17d45828a08b6783098d8f9b1a89e65d174b3ea20bf5, Output=56acf6ea3f7623525c31135378c1b10498f73b2b9a9a403b9efe002ddd37bcf4)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.api]: Sending system information
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.protocol]: Exchange OPACK: {'_i': '_systemInfo', '_t': 2, '_c': {'_bf': 0, '_cf': 512, '_clFl': 128, '_i': 'cafecafecafe', '_idsID': b'5eadf73b-8a83-4111-bdec-700ab2cbb29e', '_pubID': 'aa:bb:cc:dd:ee:ff', '_sf': 256, '_sv': '170.18', 'model': 'iPhone14,3', 'name': 'pyatv'}, '_x': 60091}
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.protocol]: Send OPACK: {'_i': '_systemInfo', '_t': 2, '_c': {'_bf': 0, '_cf': 512, '_clFl': 128, '_i': 'cafecafecafe', '_idsID': b'5eadf73b-8a83-4111-bdec-700ab2cbb29e', '_pubID': 'aa:bb:cc:dd:ee:ff', '_sf': 256, '_sv': '170.18', 'model': 'iPhone14,3', 'name': 'pyatv'}, '_x': 60091}
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.connection]: >> Send data (Data=e4425f694b5f73797374656d496e666f425f740a425f63ea435f626608435f6366310002455f636c466c3080a04c636166656361666563616665465f6964734944912435656164663733622d386138332d343131312d626465632d373030616232636262323965465f70756249445161613a62623a63633a64643a65653a6666435f7366310001435f7376463137302e3138456d6f64656c4a6950686f6e6531342c33446e616d65457079617476425f7831bbea, FrameType=08)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.connection]: >> Send (Encrypted=c6ac30dbcc38936286b4ebaa4f6dbbb18f97b448b2fb237a3554c7c4017fb2069c0f182fb0be88fe51666a89b1dd0dbe0b4c6e978a9659d5a8331215091ba564e62c786114153443b45a05ae304b90c8cddbfb57e555c462e5994203663e2d572660a719e7cde06913d49dd3f5da4319038905f4a593ce31f8ec6496545a0e9928655a5e2e0bf11249fbb03dbc971f6e92961ead82bb8f7950c70eb102c6f272822cb59c8543e597e1552cafc816541114021d68d63d5804bccdafc06fe20fad5bc55a6d, Header=080000c4)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.connection]: Received data (Data=080015b58e72baf99d2d7838d6814ebcbe204985e5067df43b00196afbbeba6cf3c2f4a7395c3e93be6b600bccba8fcddc401cd3916ee57a7be43ec3a6728710060a20c550db6d431b7bebd0c42ef5c26237d2277a2b1d0398369b3b30a8fce787303400e16649565f4eea79734a0c0028abb096d9da82fddbee72cbf36eb6250212a37602ae21c2983485cdfc9a644b2c62df70b46b7b81ab5c287c0511c2cfb146b1ddf076b9d3ff3ad38299d20491f8a0db74de67490d2eb81814854521d3a19d71d70ee1c253a239cb27d2569da371e7ab1b4da21b2438fca809fdb4ff22167680198287c39a657b2a84bef4b9ee18836ad1c229aea8aab31fc165f5d...)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.protocol]: Received frame FrameType.E_OPACK: b'\xe3B_c\xefE_msSt\tE_msRo\x0bC_lP2\x00\xc0\x00\x00E_hkID\x05\xe4\xeb\x8f\xb7q\xf4SE\x84e\x8e\x06,[r\x14F_pubIDQCB:81:DF:C6:D3:3AC_cf1\x00\x02D_stA\xdaa,com.apple.callservicesd.CompanionLinkManagerXcom.apple.SeymourSessionZcom.apple.tvremoteservices\\com.apple.biomesyncd.rapportXcom.apple.home.messagingUcom.apple.siri.wakeup\xb1Scom.apple.LiveAudioWcom.apple.coreduet.syncQcom.apple.SeymourC_svE350.2E_mrIDa$C7969DC0-2B1D-426E-8946-5E03DB5F2B91DnameFBYXoneF_hkUID\xd1\x05\xeb\xb5\xa5\xbd&-W3\x93Y\x93\x85\xbbq\xa5\x89I_siriInfo\xe8HpeerData\xe8SassistantIdentifiera$31C77E57-1041-4212-A52E-88756849433FLbuildVersionF19L580KproductTypeJAppleTV6,2TsharedUserIdentifiera$93EC7DE0-4C74-4F01-823D-E379D5404A0BQhomeAccessoryInfo\xebHroomName\xba\xbfa0X-HM://A/AC=95292EB4-2D8A-5D48-B660-0D9631FC0DD5LmanufacturerJApple Inc.RschemaCategoryType)a$hasActiveThirdPartyMusicSubscription\x02EmodelHMQD22B/AIisSpeaker\x02WloggingUniqueIdentifier\x05(\xe4\xf0.\xd8T\x07N\x0c3\xbd\xf1\r\xbfo{PuniqueIdentifier\xa6LcategoryTypea$F6D2A2AC-3A6E-4E6F-8196-678ABE909D8E\xb9\xbaJaceVersionH12.4-19ERuserInterfaceIdiomDZEUSVuserAssignedDeviceName\xbaRdeviceCapabilities\xe1SvoiceTriggerEnabled\tTdeviceCapabilitiesV2\xd4\x92#\x03bplist00\xd4\x01\x02\x03\x04\x05\x06\x07\nX$versionY$archiverT$topX$objects\x12\x00\x01\x86\xa0_\x10\x0fNSKeyedArchiver\xd1\x08\tTroot\x80\x01\xab\x0b\x0c\x11\x19\x1a\x1f &*.2U$null\xd2\r\x0e\x0f\x10_\x10 SVDVoiceTriggerCapabilityBackingV$class\x80\x02\x80\n\xd4\x12\x0e\x13\x14\x15\x16\x17\x18_\x103primitivesMap_VoiceTriggerCapability::supportStatusSkey]primitiveKeys\x80\x07\x80\t\x80\x03\x80\x04_\x10\x16VoiceTriggerCapability\xd2\x1b\x0e\x1c\x1eZNS.objects\xa1\x1d\x80\x05\x80\x06_\x10%VoiceTriggerCapability::supportStatus\xd2!"#$Z$classnameX$classesWNSArray\xa2#%XNSObject\xd2\'\x0e()]supportStatus\x10\x02\x80\x08\xd2!"+,_\x10\x1dSVDBooleanCapabilityPrimitive\xa2-%_\x10\x1dSVDBooleanCapabilityPrimitive\xd2!"/0_\x102SiriVirtualDeviceResolution.VoiceTriggerCapability\xa21%_\x102SiriVirtualDeviceResolution.VoiceTriggerCapability\xd2!"34_\x10\x19SVDVoiceTriggerCapability\xa356%_\x10\x19SVDVoiceTriggerCapability]SVDCapability\x00\x08\x00\x11\x00\x1a\x00$\x00)\x002\x007\x00I\x00L\x00Q\x00S\x00_\x00e\x00j\x00\x8d\x00\x94\x00\x96\x00\x98\x00\xa1\x00\xd7\x00\xdb\x00\xe9\x00\xeb\x00\xed\x00\xef\x00\xf1\x01\n\x01\x0f\x01\x1a\x01\x1c\x01\x1e\x01 \x01H\x01M\x01X\x01a\x01i\x01l\x01u\x01z\x01\x88\x01\x8a\x01\x8c\x01\x91\x01\xb1\x01\xb4\x01\xd4\x01\xd9\x02\x0e\x02\x11\x02F\x02K\x02g\x02k\x02\x87\x00\x00\x00\x00\x00\x00\x02\x01\x00\x00\x00\x00\x00\x00\x007\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x95\x92\x0b\x03bplist00\xd4\x01\x02\x03\x04\x05\x06\x07\nX$versionY$archiverT$topX$objects\x12\x00\x01\x86\xa0_\x10\x0fNSKeyedArchiver\xd1\x08\tTroot\x80\x01\xab\x0b\x0c\x11\x19\x1a\x1f &*.2U$null\xd2\r\x0e\x0f\x10_\x10\x1dSVDAppLaunchCapabilityBackingV$class\x80\x02\x80\n\xd4\x0e\x12\x13\x14\x15\x16\x17\x18Skey_\x100primitivesMap_AppLaunchCapability::supportStatus]primitiveKeys\x80\t\x80\x03\x80\x07\x80\x04_\x10\x13AppLaunchCapability\xd2\x1b\x0e\x1c\x1eZNS.objects\xa1\x1d\x80\x05\x80\x06_\x10"AppLaunchCapability::supportStatus\xd2!"#$Z$classnameX$classesWNSArray\xa2#%XNSObject\xd2\'\x0e()]supportStatus\x10\x01\x80\x08\xd2!"+,_\x10\x1dSVDBooleanCapabilityPrimitive\xa2-%_\x10\x1dSVDBooleanCapabilityPrimitive\xd2!"/0_\x10/SiriVirtualDeviceResolution.AppLaunchCapability\xa21%_\x10/SiriVirtualDeviceResolution.AppLaunchCapability\xd2!"34_\x10\x16SVDAppLaunchCapability\xa356%_\x10\x16SVDAppLaunchCapability]SVDCapability\x00\x08\x00\x11\x00\x1a\x00$\x00)\x002\x007\x00I\x00L\x00Q\x00S\x00_\x00e\x00j\x00\x8a\x00\x91\x00\x93\x00\x95\x00\x9e\x00\xa2\x00\xd5\x00\xe3\x00\xe5\x00\xe7\x00\xe9\x00\xeb\x01\x01\x01\x06\x01\x11\x01\x13\x01\x15\x01\x17\x01<\x01A\x01L\x01U\x01]\x01`\x01i\x01n\x01|\x01~\x01\x80\x01\x85\x01\xa5\x01\xa8\x01\xc8\x01\xcd\x01\xff\x02\x02\x024\x029\x02R\x02V\x02o\x00\x00\x00\x00\x00\x00\x02\x01\x00\x00\x00\x00\x00\x00\x007\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02}\x92+\x03bplist00\xd4\x01\x02\x03\x04\x05\x06\x07\nX$versionY$archiverT$topX$objects\x12\x00\x01\x86\xa0_\x10\x0fNSKeyedArchiver\xd1\x08\tTroot\x80\x01\xab\x0b\x0c\x11\x19\x1a\x1f &*.2U$null\xd2\r\x0e\x0f\x10_\x10!SVDVideoPlaybackCapabilityBackingV$class\x80\x02\x80\n\xd4\x0e\x12\x13\x14\x15\x16\x17\x18Skey_\x104primitivesMap_VideoPlaybackCapability::supportStatus]primitiveKeys\x80\t\x80\x03\x80\x07\x80\x04_\x10\x17VideoPlaybackCapability\xd2\x1b\x0e\x1c\x1eZNS.objects\xa1\x1d\x80\x05\x80\x06_\x10&VideoPlaybackCapability::supportStatus\xd2!"#$Z$classnameX$classesWNSArray\xa2#%XNSObject\xd2\'\x0e()]supportStatus\x10\x01\x80\x08\xd2!"+,_\x10\x1dSVDBooleanCapabilityPrimitive\xa2-%_\x10\x1dSVDBooleanCapabilityPrimitive\xd2!"/0_\x103SiriVirtualDeviceResolution.VideoPlaybackCapability\xa21%_\x103SiriVirtualDeviceResolution.VideoPlaybackCapability\xd2!"34_\x10\x1aSVDVideoPlaybackCapability\xa356%_\x10\x1aSVDVideoPlaybackCapability]SVDCapability\x00\x08\x00\x11\x00\x1a\x00$\x00)\x002\x007\x00I\x00L\x00Q\x00S\x00_\x00e\x00j\x00\x8e\x00\x95\x00\x97\x00\x99\x00\xa2\x00\xa6\x00\xdd\x00\xeb\x00\xed\x00\xef\x00\xf1\x00\xf3\x01\r\x01\x12\x01\x1d\x01\x1f\x01!\x01#\x01L\x01Q\x01\\\x01e\x01m\x01p\x01y\x01~\x01\x8c\x01\x8e\x01\x90\x01\x95\x01\xb5\x01\xb8\x01\xd8\x01\xdd\x02\x13\x02\x16\x02L\x02Q\x02n\x02r\x02\x8f\x00\x00\x00\x00\x00\x00\x02\x01\x00\x00\x00\x00\x00\x00\x007\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x9d\x923\x03bplist00\xd4\x01\x02\x03\x04\x05\x06\x07\nX$versionY$archiverT$topX$objects\x12\x00\x01\x86\xa0_\x10\x0fNSKeyedArchiver\xd1\x08\tTroot\x80\x01\xab\x0b\x0c\x11\x19\x1a\x1f &*.2U$null\xd2\r\x0e\x0f\x10_\x10"SVDSeymourRoutingCapabilityBackingV$class\x80\x02\x80\n\xd4\x12\x0e\x13\x14\x15\x16\x17\x18_\x105primitivesMap_SeymourRoutingCapability::supportStatusSkey]primitiveKeys\x80\x07\x80\t\x80\x03\x80\x04_\x10\x18SeymourRoutingCapability\xd2\x1b\x0e\x1c\x1eZNS.objects\xa1\x1d\x80\x05\x80\x06_\x10\'SeymourRoutingCapability::supportStatus\xd2!"#$Z$classnameX$classesWNSArray\xa2#%XNSObject\xd2\'\x0e()]supportStatus\x10\x01\x80\x08\xd2!"+,_\x10\x1dSVDBooleanCapabilityPrimitive\xa2-%_\x10\x1dSVDBooleanCapabilityPrimitive\xd2!"/0_\x104SiriVirtualDeviceResolution.SeymourRoutingCapability\xa21%_\x104SiriVirtualDeviceResolution.SeymourRoutingCapability\xd2!"34_\x10\x1bSVDSeymourRoutingCapability\xa356%_\x10\x1bSVDSeymourRoutingCapability]SVDCapability\x00\x08\x00\x11\x00\x1a\x00$\x00)\x002\x007\x00I\x00L\x00Q\x00S\x00_\x00e\x00j\x00\x8f\x00\x96\x00\x98\x00\x9a\x00\xa3\x00\xdb\x00\xdf\x00\xed\x00\xef\x00\xf1\x00\xf3\x00\xf5\x01\x10\x01\x15\x01 \x01"\x01$\x01&\x01P\x01U\x01`\x01i\x01q\x01t\x01}\x01\x82\x01\x90\x01\x92\x01\x94\x01\x99\x01\xb9\x01\xbc\x01\xdc\x01\xe1\x02\x18\x02\x1b\x02R\x02W\x02u\x02y\x02\x97\x00\x00\x00\x00\x00\x00\x02\x01\x00\x00\x00\x00\x00\x00\x007\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\xa5a&audio-session-coordination.system-info\xe4ZmediaRemoteGroupIdentifiera$B1C44532-2E92-4689-B812-00F7A5C569B2OhomeKitRoomName\xbaZmediaRemoteRouteIdentifier\xb8UisSupportedAndEnabled\x02OstationaryScore5]{\xe1AKisCollector\x02XcollectorElectionVersion5\x00\x00\x80?RsharedDataProtoBuf\x924\x03\x08\x01"$C23EFF62-5C36-4999-BDC6-0FE73579CAA8*\x05en-GB2$31C77E57-1041-4212-A52E-88756849433F:\x19https://guzzoni.apple.comH\x00R$93EC7DE0-4C74-4F01-823D-E379D5404A0Bb\x02\x10\x00j\x11\n\x05en-GB\x10\x01\x1a\x06arthurp\x01x\x00\x82\x01EAssistant(Apple TV/AppleTV6,2; Apple TVOS/15.5.1/19L580) Ace/12.4-19E\x88\x01\x00\x9a\x01\x07Celsius\xa2\x01$6F2309C5-1F8F-4AC7-9845-F0FC59CDD0FE\xaa\x01$B907E06A-32F6-4643-810F-F0F0D6266B7D\xb2\x01\x0b143444-2,33\xba\x01$C7969DC0-2B1D-426E-8946-5E03DB5F2B91\xca\x01\xec\x01AmpvhNuNAXm9H5ZhfnAWyqt9teCMkFXa_l2RthLxSyW4L1H34WjcT4-htYW7Wjabj4MWv77SfRFZSyiZUWj--xVZK_QwjBxyuAGzettE4YJXqBfT9ljqlq_xN9x9LHXzR_M5iPItiv7790tOrff1MLeiSkcz65blHwzq0dqVkxY7AwZ5H9MfBGM9ZTYfIyne_YDHkCUNVlXP_E4jMbZ0SsfDVMsXoq435aDlu9ovkJRK\xd0\x01\x01\xda\x01\x06BYXone\xe2\x01\x9e\x01\n\r\n\x06caller\x12\x03wlk\n\x0f\n\x06locale\x12\x05en-GB\n)\n\x05utscf\x12 OjAAAAEAAAAAAAMAEAAAAAwADQAOABAA\n\n\n\x03pfm\x12\x03atv\n\x0c\n\x02sf\x12\x06143444\n\x07\n\x01v\x12\x0258\n.\n\x04utsk\x12&332bbbb965cf6aa9::::::b1926c57d97c6ead\xea\x01\x08OptedOutG_idsCIDa$4325884b-7080-4e39-bcee-9ad5b495538dB_iL68936638382dF_accIDUfern.house@icloud.comE_clFl1\x80\x00C_bf1\x80\x07\xc1.\xc1$I_roomName\xbaF_mRtID\xb8F_idsIDa$BB6EBEC1-057A-4942-83A3-CCC84CA5FA19C_sf2\x00\x00\x01\x00C_dCGunknown\x03B_t\x0bB_x1\xbb\xea'
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.protocol]: Process incoming OPACK frame (FrameType.E_OPACK): {'_c': {'_msSt': 1, '_msRo': 3, '_lP': 49152, '_hkID': UUID('e4eb8fb7-71f4-5345-8465-8e062c5b7214'), '_pubID': 'CB:81:DF:C6:D3:3A', '_cf': 512, '_stA': ['com.apple.callservicesd.CompanionLinkManager', 'com.apple.SeymourSession', 'com.apple.tvremoteservices', 'com.apple.biomesyncd.rapport', 'com.apple.home.messaging', 'com.apple.siri.wakeup', 'com.apple.siri.wakeup', 'com.apple.LiveAudio', 'com.apple.coreduet.sync', 'com.apple.Seymour'], '_sv': '350.2', '_mrID': 'C7969DC0-2B1D-426E-8946-5E03DB5F2B91', 'name': 'BYXone', '_hkUID': [UUID('ebb5a5bd-262d-5733-9359-9385bb71a589')], '_siriInfo': {'peerData': {'assistantIdentifier': '31C77E57-1041-4212-A52E-88756849433F', 'buildVersion': '19L580', 'productType': 'AppleTV6,2', 'sharedUserIdentifier': '93EC7DE0-4C74-4F01-823D-E379D5404A0B', 'homeAccessoryInfo': {'roomName': 'BYXone', 'assistantIdentifier': 'X-HM://A/AC=95292EB4-2D8A-5D48-B660-0D9631FC0DD5', 'manufacturer': 'Apple Inc.', 'schemaCategoryType': 33, 'hasActiveThirdPartyMusicSubscription': False, 'model': 'MQD22B/A', 'isSpeaker': False, 'loggingUniqueIdentifier': UUID('28e4f02e-d854-074e-0c33-bdf10dbf6f7b'), 'uniqueIdentifier': UUID('e4eb8fb7-71f4-5345-8465-8e062c5b7214'), 'categoryType': 'F6D2A2AC-3A6E-4E6F-8196-678ABE909D8E', 'name': 'BYXone'}, 'aceVersion': '12.4-19E', 'userInterfaceIdiom': 'ZEUS', 'userAssignedDeviceName': 'BYXone'}, 'deviceCapabilities': {'voiceTriggerEnabled': 1}, 'deviceCapabilitiesV2': [b'bplist00\xd4\x01\x02\x03\x04\x05\x06\x07\nX$versionY$archiverT$topX$objects\x12\x00\x01\x86\xa0_\x10\x0fNSKeyedArchiver\xd1\x08\tTroot\x80\x01\xab\x0b\x0c\x11\x19\x1a\x1f &*.2U$null\xd2\r\x0e\x0f\x10_\x10 SVDVoiceTriggerCapabilityBackingV$class\x80\x02\x80\n\xd4\x12\x0e\x13\x14\x15\x16\x17\x18_\x103primitivesMap_VoiceTriggerCapability::supportStatusSkey]primitiveKeys\x80\x07\x80\t\x80\x03\x80\x04_\x10\x16VoiceTriggerCapability\xd2\x1b\x0e\x1c\x1eZNS.objects\xa1\x1d\x80\x05\x80\x06_\x10%VoiceTriggerCapability::supportStatus\xd2!"#$Z$classnameX$classesWNSArray\xa2#%XNSObject\xd2\'\x0e()]supportStatus\x10\x02\x80\x08\xd2!"+,_\x10\x1dSVDBooleanCapabilityPrimitive\xa2-%_\x10\x1dSVDBooleanCapabilityPrimitive\xd2!"/0_\x102SiriVirtualDeviceResolution.VoiceTriggerCapability\xa21%_\x102SiriVirtualDeviceResolution.VoiceTriggerCapability\xd2!"34_\x10\x19SVDVoiceTriggerCapability\xa356%_\x10\x19SVDVoiceTriggerCapability]SVDCapability\x00\x08\x00\x11\x00\x1a\x00$\x00)\x002\x007\x00I\x00L\x00Q\x00S\x00_\x00e\x00j\x00\x8d\x00\x94\x00\x96\x00\x98\x00\xa1\x00\xd7\x00\xdb\x00\xe9\x00\xeb\x00\xed\x00\xef\x00\xf1\x01\n\x01\x0f\x01\x1a\x01\x1c\x01\x1e\x01 \x01H\x01M\x01X\x01a\x01i\x01l\x01u\x01z\x01\x88\x01\x8a\x01\x8c\x01\x91\x01\xb1\x01\xb4\x01\xd4\x01\xd9\x02\x0e\x02\x11\x02F\x02K\x02g\x02k\x02\x87\x00\x00\x00\x00\x00\x00\x02\x01\x00\x00\x00\x00\x00\x00\x007\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x95', b'bplist00\xd4\x01\x02\x03\x04\x05\x06\x07\nX$versionY$archiverT$topX$objects\x12\x00\x01\x86\xa0_\x10\x0fNSKeyedArchiver\xd1\x08\tTroot\x80\x01\xab\x0b\x0c\x11\x19\x1a\x1f &*.2U$null\xd2\r\x0e\x0f\x10_\x10\x1dSVDAppLaunchCapabilityBackingV$class\x80\x02\x80\n\xd4\x0e\x12\x13\x14\x15\x16\x17\x18Skey_\x100primitivesMap_AppLaunchCapability::supportStatus]primitiveKeys\x80\t\x80\x03\x80\x07\x80\x04_\x10\x13AppLaunchCapability\xd2\x1b\x0e\x1c\x1eZNS.objects\xa1\x1d\x80\x05\x80\x06_\x10"AppLaunchCapability::supportStatus\xd2!"#$Z$classnameX$classesWNSArray\xa2#%XNSObject\xd2\'\x0e()]supportStatus\x10\x01\x80\x08\xd2!"+,_\x10\x1dSVDBooleanCapabilityPrimitive\xa2-%_\x10\x1dSVDBooleanCapabilityPrimitive\xd2!"/0_\x10/SiriVirtualDeviceResolution.AppLaunchCapability\xa21%_\x10/SiriVirtualDeviceResolution.AppLaunchCapability\xd2!"34_\x10\x16SVDAppLaunchCapability\xa356%_\x10\x16SVDAppLaunchCapability]SVDCapability\x00\x08\x00\x11\x00\x1a\x00$\x00)\x002\x007\x00I\x00L\x00Q\x00S\x00_\x00e\x00j\x00\x8a\x00\x91\x00\x93\x00\x95\x00\x9e\x00\xa2\x00\xd5\x00\xe3\x00\xe5\x00\xe7\x00\xe9\x00\xeb\x01\x01\x01\x06\x01\x11\x01\x13\x01\x15\x01\x17\x01<\x01A\x01L\x01U\x01]\x01`\x01i\x01n\x01|\x01~\x01\x80\x01\x85\x01\xa5\x01\xa8\x01\xc8\x01\xcd\x01\xff\x02\x02\x024\x029\x02R\x02V\x02o\x00\x00\x00\x00\x00\x00\x02\x01\x00\x00\x00\x00\x00\x00\x007\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02}', b'bplist00\xd4\x01\x02\x03\x04\x05\x06\x07\nX$versionY$archiverT$topX$objects\x12\x00\x01\x86\xa0_\x10\x0fNSKeyedArchiver\xd1\x08\tTroot\x80\x01\xab\x0b\x0c\x11\x19\x1a\x1f &*.2U$null\xd2\r\x0e\x0f\x10_\x10!SVDVideoPlaybackCapabilityBackingV$class\x80\x02\x80\n\xd4\x0e\x12\x13\x14\x15\x16\x17\x18Skey_\x104primitivesMap_VideoPlaybackCapability::supportStatus]primitiveKeys\x80\t\x80\x03\x80\x07\x80\x04_\x10\x17VideoPlaybackCapability\xd2\x1b\x0e\x1c\x1eZNS.objects\xa1\x1d\x80\x05\x80\x06_\x10&VideoPlaybackCapability::supportStatus\xd2!"#$Z$classnameX$classesWNSArray\xa2#%XNSObject\xd2\'\x0e()]supportStatus\x10\x01\x80\x08\xd2!"+,_\x10\x1dSVDBooleanCapabilityPrimitive\xa2-%_\x10\x1dSVDBooleanCapabilityPrimitive\xd2!"/0_\x103SiriVirtualDeviceResolution.VideoPlaybackCapability\xa21%_\x103SiriVirtualDeviceResolution.VideoPlaybackCapability\xd2!"34_\x10\x1aSVDVideoPlaybackCapability\xa356%_\x10\x1aSVDVideoPlaybackCapability]SVDCapability\x00\x08\x00\x11\x00\x1a\x00$\x00)\x002\x007\x00I\x00L\x00Q\x00S\x00_\x00e\x00j\x00\x8e\x00\x95\x00\x97\x00\x99\x00\xa2\x00\xa6\x00\xdd\x00\xeb\x00\xed\x00\xef\x00\xf1\x00\xf3\x01\r\x01\x12\x01\x1d\x01\x1f\x01!\x01#\x01L\x01Q\x01\\\x01e\x01m\x01p\x01y\x01~\x01\x8c\x01\x8e\x01\x90\x01\x95\x01\xb5\x01\xb8\x01\xd8\x01\xdd\x02\x13\x02\x16\x02L\x02Q\x02n\x02r\x02\x8f\x00\x00\x00\x00\x00\x00\x02\x01\x00\x00\x00\x00\x00\x00\x007\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\x9d', b'bplist00\xd4\x01\x02\x03\x04\x05\x06\x07\nX$versionY$archiverT$topX$objects\x12\x00\x01\x86\xa0_\x10\x0fNSKeyedArchiver\xd1\x08\tTroot\x80\x01\xab\x0b\x0c\x11\x19\x1a\x1f &*.2U$null\xd2\r\x0e\x0f\x10_\x10"SVDSeymourRoutingCapabilityBackingV$class\x80\x02\x80\n\xd4\x12\x0e\x13\x14\x15\x16\x17\x18_\x105primitivesMap_SeymourRoutingCapability::supportStatusSkey]primitiveKeys\x80\x07\x80\t\x80\x03\x80\x04_\x10\x18SeymourRoutingCapability\xd2\x1b\x0e\x1c\x1eZNS.objects\xa1\x1d\x80\x05\x80\x06_\x10\'SeymourRoutingCapability::supportStatus\xd2!"#$Z$classnameX$classesWNSArray\xa2#%XNSObject\xd2\'\x0e()]supportStatus\x10\x01\x80\x08\xd2!"+,_\x10\x1dSVDBooleanCapabilityPrimitive\xa2-%_\x10\x1dSVDBooleanCapabilityPrimitive\xd2!"/0_\x104SiriVirtualDeviceResolution.SeymourRoutingCapability\xa21%_\x104SiriVirtualDeviceResolution.SeymourRoutingCapability\xd2!"34_\x10\x1bSVDSeymourRoutingCapability\xa356%_\x10\x1bSVDSeymourRoutingCapability]SVDCapability\x00\x08\x00\x11\x00\x1a\x00$\x00)\x002\x007\x00I\x00L\x00Q\x00S\x00_\x00e\x00j\x00\x8f\x00\x96\x00\x98\x00\x9a\x00\xa3\x00\xdb\x00\xdf\x00\xed\x00\xef\x00\xf1\x00\xf3\x00\xf5\x01\x10\x01\x15\x01 \x01"\x01$\x01&\x01P\x01U\x01`\x01i\x01q\x01t\x01}\x01\x82\x01\x90\x01\x92\x01\x94\x01\x99\x01\xb9\x01\xbc\x01\xdc\x01\xe1\x02\x18\x02\x1b\x02R\x02W\x02u\x02y\x02\x97\x00\x00\x00\x00\x00\x00\x02\x01\x00\x00\x00\x00\x00\x00\x007\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x00\x02\xa5'], 'audio-session-coordination.system-info': {'mediaRemoteGroupIdentifier': 'B1C44532-2E92-4689-B812-00F7A5C569B2', 'homeKitRoomName': 'BYXone', 'mediaRemoteRouteIdentifier': 'C7969DC0-2B1D-426E-8946-5E03DB5F2B91', 'isSupportedAndEnabled': False}, 'stationaryScore': 28.18523597717285, 'isCollector': False, 'collectorElectionVersion': 1.0, 'sharedDataProtoBuf': b'\x08\x01"$C23EFF62-5C36-4999-BDC6-0FE73579CAA8*\x05en-GB2$31C77E57-1041-4212-A52E-88756849433F:\x19https://guzzoni.apple.comH\x00R$93EC7DE0-4C74-4F01-823D-E379D5404A0Bb\x02\x10\x00j\x11\n\x05en-GB\x10\x01\x1a\x06arthurp\x01x\x00\x82\x01EAssistant(Apple TV/AppleTV6,2; Apple TVOS/15.5.1/19L580) Ace/12.4-19E\x88\x01\x00\x9a\x01\x07Celsius\xa2\x01$6F2309C5-1F8F-4AC7-9845-F0FC59CDD0FE\xaa\x01$B907E06A-32F6-4643-810F-F0F0D6266B7D\xb2\x01\x0b143444-2,33\xba\x01$C7969DC0-2B1D-426E-8946-5E03DB5F2B91\xca\x01\xec\x01AmpvhNuNAXm9H5ZhfnAWyqt9teCMkFXa_l2RthLxSyW4L1H34WjcT4-htYW7Wjabj4MWv77SfRFZSyiZUWj--xVZK_QwjBxyuAGzettE4YJXqBfT9ljqlq_xN9x9LHXzR_M5iPItiv7790tOrff1MLeiSkcz65blHwzq0dqVkxY7AwZ5H9MfBGM9ZTYfIyne_YDHkCUNVlXP_E4jMbZ0SsfDVMsXoq435aDlu9ovkJRK\xd0\x01\x01\xda\x01\x06BYXone\xe2\x01\x9e\x01\n\r\n\x06caller\x12\x03wlk\n\x0f\n\x06locale\x12\x05en-GB\n)\n\x05utscf\x12 OjAAAAEAAAAAAAMAEAAAAAwADQAOABAA\n\n\n\x03pfm\x12\x03atv\n\x0c\n\x02sf\x12\x06143444\n\x07\n\x01v\x12\x0258\n.\n\x04utsk\x12&332bbbb965cf6aa9::::::b1926c57d97c6ead\xea\x01\x08OptedOut'}, '_idsCID': '4325884b-7080-4e39-bcee-9ad5b495538d', '_i': '68936638382d', '_accID': 'fern.house@icloud.com', '_clFl': 128, '_bf': 1920, 'model': 'AppleTV6,2', '_roomName': 'BYXone', '_mRtID': 'C7969DC0-2B1D-426E-8946-5E03DB5F2B91', '_idsID': 'BB6EBEC1-057A-4942-83A3-CCC84CA5FA19', '_sf': 65536, '_dC': 'unknown'}, '_t': 3, '_x': 60091}
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.protocol]: Exchange OPACK: {'_i': '_sessionStart', '_t': 2, '_c': {'_srvT': 'com.apple.tvremoteservices', '_sid': 3998384767}, '_x': 60092}
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.protocol]: Send OPACK: {'_i': '_sessionStart', '_t': 2, '_c': {'_srvT': 'com.apple.tvremoteservices', '_sid': 3998384767}, '_x': 60092}
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.connection]: >> Send data (Data=e4425f694d5f73657373696f6e5374617274425f740a425f63e2455f737276545a636f6d2e6170706c652e747672656d6f74657365727669636573445f736964327f8252ee425f7831bcea, FrameType=08)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.connection]: >> Send (Encrypted=76086a7410eb6747f5c55781e512fdcd624606ba56721be9e4d668ac9e3913d7a5a594889035887388471a1cd4bea2be91781ea8626a12971643a1f2665501e222b3df1e79f569fed389426bf8137dea86068d8dae37c06d094173, Header=0800005b)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.connection]: Received data (Data=0800002938436434908d8eea121f2cccb71039d0672283ffdf9b806466c0a5f592db58d4d9f0c37d3e28c06e5e)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.protocol]: Received frame FrameType.E_OPACK: b'\xe3B_c\xe1D_sid2\xdf\xe2|"B_t\x0bB_x1\xbc\xea'
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.protocol]: Process incoming OPACK frame (FrameType.E_OPACK): {'_c': {'_sid': 578609887}, '_t': 3, '_x': 60092}
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.api]: Started session with SID 0x227CE2DFEE52827F
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.protocol]: Send OPACK: {'_i': '_interest', '_t': 1, '_c': {'_regEvents': ['_iMC']}, '_x': 60093}
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.connection]: >> Send data (Data=e4425f69495f696e746572657374425f7409425f63e14a5f7265674576656e7473d1445f694d43425f7831bdea, FrameType=08)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.connection]: >> Send (Encrypted=31af0375828c94060ebdb5906877a2b5ce9429f8182fa42ba5955f444b6a8abac3f74904b388c682ffb84f913bab7ba2cd6042e5f3d66505220ae8ca26, Header=0800003d)
2022-07-19 16:50:00 DEBUG [pyatv.core.facade]: Connected to protocol: Protocol.Companion
2022-07-19 16:50:00 DEBUG [pyatv.core.facade]: Protocol Protocol.MRP already set up, ignoring
2022-07-19 16:50:00 DEBUG [pyatv.core.facade]: Connecting to protocol: Protocol.RAOP
2022-07-19 16:50:00 DEBUG [pyatv.core.facade]: Connected to protocol: Protocol.RAOP
PowerState.Off
2022-07-19 16:50:00 DEBUG [pyatv.protocols.airplay.mrp_connection]: Closing connection
2022-07-19 16:50:00 DEBUG [pyatv.scripts.atvremote]: Waiting for 2 remaining tasks
2022-07-19 16:50:00 DEBUG [pyatv.protocols.airplay.mrp_connection]: Disconnected from device: None
2022-07-19 16:50:00 DEBUG [pyatv.scripts.atvremote]: Connection was closed properly
2022-07-19 16:50:00 DEBUG [pyatv.core.protocol]: Stopping heartbeat loop at 1 (AirPlay:xxx.xxx.33.151)
2022-07-19 16:50:00 DEBUG [pyatv.support.http]: Connection closed
2022-07-19 16:50:00 DEBUG [pyatv.auth.hap_channel]: Connection was lost to remote
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.protocol]: Send OPACK: {'_i': '_interest', '_t': 1, '_c': {'_deregEvents': ['_iMC']}, '_x': 60094}
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.connection]: >> Send data (Data=e4425f69495f696e746572657374425f7409425f63e14c5f64657265674576656e7473d1445f694d43425f7831beea, FrameType=08)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.connection]: >> Send (Encrypted=68cdeb34e541aa70d44723581010980942f7ff706cdee75f3cfa803334b356e791bd7f03ab0244cb84c48d4b2bb40c4e48dcdf58f8cf9dad7408be64385368, Header=0800003f)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.protocol]: Exchange OPACK: {'_i': '_sessionStop', '_t': 2, '_c': {'_srvT': 'com.apple.tvremoteservices', '_sid': 2485110545805640319}, '_x': 60095}
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.protocol]: Send OPACK: {'_i': '_sessionStop', '_t': 2, '_c': {'_srvT': 'com.apple.tvremoteservices', '_sid': 2485110545805640319}, '_x': 60095}
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.connection]: >> Send data (Data=e4425f694c5f73657373696f6e53746f70425f740a425f63e2455f737276545a636f6d2e6170706c652e747672656d6f74657365727669636573445f736964337f8252eedfe27c22425f7831bfea, FrameType=08)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.connection]: >> Send (Encrypted=a452900f41f8c52704a8fb818fdb4c664c454d53ef6b8d76d611c18ac880f365561b42b8e5a8980b0eba22050487129e8e4bcefe5b95249ee7289dedc674b74c84244bc31eafcffb3fe539d5dc7b975e38952b46dd36b66bce37355bafc6, Header=0800005e)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.connection]: Received data (Data=0800004e80c8c64ed5172cf95db2c2e9183d6361f3e22a917a29ebd48215e7eaf0beab83c43807dbbd237708a04d6fa132496637f407fcb878e3e6470d9559cf6b6f31c0bdedbb71fc648aac3305f47a8462)
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.protocol]: Received frame FrameType.E_OPACK: b'\xe6B_x1\xbf\xeaC_emQSession not foundC_ec1\xb9\xe5C_edMRPErrorDomainB_c\xe0B_t\x0b'
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.protocol]: Process incoming OPACK frame (FrameType.E_OPACK): {'_x': 60095, '_em': 'Session not found', '_ec': 58809, '_ed': 'RPErrorDomain', '_c': {}, '_t': 3}
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.api]: Ignoring error during disconnect: Command failed: Session not found
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.connection]: Closing connection
2022-07-19 16:50:00 DEBUG [pyatv.protocols.companion.connection]: Connection lost to remote device: None
Been trying this some more and discovered that an ATV playing in the next room (wife is watching it) is reporting PowerState.On.
So (using atvremote) I started the ATV I'm testing in my study. Still reporting PowerState.Off
I wondered if it requires something to be actually playing, so I started playing something in the AppleTV+ app, but even with that actually playing and responding correctly to the 'playing' command, 'power_state' still returns PowerState.Off.
So now a double puzzle. Why does power_state work on one ATV and not the other? Both ATV4s, same model.
I will have to study the logs a bit more, will do that when I'm in front of a computer.
Is one of them (the one not reporting) using homepods as speakers?
Is one using the Disney app? If you "pause it wrong" in Disney it'll never report power off when you turn it "off".
If you've been playing music on the apple tv, it'll usually not report power off when it's "off".
What else? I think those are the weird conditions I have that never report power off state.
This is a shame as my main requirement is to be able to trigger a HomeKit Automation when the Apple TV is turned off. Homebridge is in the middle of this, but it seems to be impossible to reliably determine the power state of the Apple TV. It frustrates (and angers) me no end that Apple (in their infinite wisdom) have not made the ATV HomeKit 'compatible', despite being a HomeKit hub. Just doesn't make sense to me.
I agree in many ways. It's ridiculous that apple doesn't have a decent way to determine if a device is on or off. The power_state
attribute will never be truly reliable until they add a way to determine that.
I can't find it right now but there was someone a while ago who put a light sensor on the front of the Apple TV to sense that little white indicator if it's on or off... That's a pretty annoying surefire way to know...
PS: I agree with the comments as well. I check with every iOS update whether there are Home App automations using Apple TV state as a trigger.
Yeah, that is certainly one way of doing it. Not very viable in a general sense though 😉
I can't find it right now but there was someone a while ago who put a light sensor on the front of the Apple TV to sense that little white indicator if it's on or off... That's a pretty ~annoying~ surefire way to know...
@crxporter: I do that thing with the light. It works not that great, because every time you press a button on the remote the light goes dark. So it works great for power on, not so great for power off... Another thing is that the AppleTV is really trying to be too smart and turns sometimes on on its own. Its so annoying. I just wish they would provide a real interface for controlling the power.
Any updates for tvOS 16?
Just a concept: try to use a power sensor to determine whether an ATV is power on. I am going to do this with my TV and ATV. It's a bit complex but I think this way will be more effective.
Thats actually how I solved this
A lot has changed as apple has added a state concept to the Companion protocol. I added support for it in 0.13.0. Please upgrade to latest pyatv, make sure you pair Companion and then retry again. Hopefully it works better.
Describe the bug
Initially, I noticed that none of my Apple TVs in Home Assistant were correctly reflecting their power state anymore. Even when something was actively playing on the Apple TV, the entity would show as having an
off
state.Looking more deeply into it, I decided to try this more directly using
atvremote
command from this package. Upon doing so, an exception is thrown claimingpower_state
is not supported by the Apple TV.I tested this with both the latest Apple TV 4K as well as a first-generation Apple TV 4K.
Error log
How to reproduce the bug?
Try getting power state using
atvremote power_state
.What is expected behavior?
Power state should be returned for the Apple TV.
Operating System
macOS
Python
3.9
pyatv
0.10.2
Device
Apple TV 4K tvOS 15.5.1
Additional context
I understand this might be a separate issue from the fact currently playing media isn't reflected either in Home Assistant for example, but power state not working at all seemed like the more fundamental issue (with the media player being reported as
off
and the exception being thrown here).