evandcoleman / node-appletv

A node module for interacting with an Apple TV (4th-generation or later) over the Media Remote Protocol.
https://evandcoleman.github.io/node-appletv/
MIT License
180 stars 48 forks source link

Apple TV paired, but can't send commands #12

Closed denzel1994 closed 4 years ago

denzel1994 commented 6 years ago

Hey everyone,

I got my AppleTV by the paring command appletv pair I also got my credentials and the program shows up as a remote on the AppleTV. However as soon as I try to send a command I get the following:

appletv command play WARNING The program 'node' uses the Apple Bonjour compatibility layer of Avahi. WARNING Please fix your application to use the native API of Avahi! WARNING For more information see http://0pointer.de/avahi-compat?s=libdns_sd&e=node WARNING The program 'node' called 'DNSServiceRegister()' which is not supported (or only supported partially) in the Apple Bonjour compatibility layer of Avahi. WARNING Please fix your application to use the native API of Avahi! WARNING For more information see http://0pointer.de/avahi-compat?s=libdns_sd&e=node&f=DNSServiceRegister Credentials are required. Pair first.

jonentropy commented 6 years ago

You should pass the credentials from the pairing process when calling command. e.g. appletv --credentials '1391A5F5-FE3E-4BC1-B759-95E8B38AC636:39323141373441412d423644442d343435462d393141412d393541324239323142414532:63613438353264352d663862302d343965662d396634632d326435666364656436346361:f11b1ad4f6b3a285ad9937aca437c82ac4460b65ad07e50b746aef6c8b623880:2625a1e11cc4787cd655fd96adb5e5c52afa8b2ed7a83ce78c00067d43b243da' command play