bsharper / atv-desktop-remote

A simple app to allow you to control an Apple TV from your desktop
MIT License
228 stars 14 forks source link

Manual IP address #16

Open Clarky65 opened 8 months ago

Clarky65 commented 8 months ago

I would love to use this in an environment where I have a lot of Apple TVs. Education space. It polls so quickly it's hard to find the right unit before it refreshes.

It would be great if I could just put in a manual IP address and connect to the unit that way.

bsharper commented 8 months ago

Interesting, so when you are trying to pair with a specific Apple TV you're seeing the list of pairing candidates refresh? I think it should be sending out a scan request, then getting a list of devices and showing them in the dropdown. It shouldn't be polling. But it's possible there's a bug.

Try this. Open the window then press Cmd+Option+I (macOS) or Ctrl+Shift+I (Windows) and it should open up the developer tools. Then click "pair another remote." You should see some messages like

received: Buffer(36)
sendMessage: {cmd:scan, data:}
received: Buffer(411)
Results: ...

You can leave out anything after "Results:" which would be specific to your devices. I'm curious if the server is sending back multiple scan results or if the UI is refreshing for some other reason.

Clarky65 commented 8 months ago

https://github.com/bsharper/atv-desktop-remote/assets/158229575/c712cb06-bb69-4283-b704-2b0561e84907

Here is a video of how it seems to be continuously refreshing.

Clarky65 commented 8 months ago
Screenshot 2024-01-31 at 2 58 20 PM

Looks like it's throwing a "closed abnormally" in the console...

bsharper commented 8 months ago

Interesting, thanks for sharing. It seems like communication between the front-end and the library that communicates with Apple TVs keeps failing, which is causing it to loop for you. You can try deleting the configuration directory for this program (%APPDATA%/ATV Remote on Windows, ~/Library/Application Support/ATV Remote on macOS). Make sure to only delete the ATV Remote directory, and to close the program before deleting it.

This will require the program to set back up the next time it is started (takes a few minutes), but some people have had their issues solved by trying this.