AppleTV Plugin: discussion

User avatar
kw123
Posts: 8705
Joined: Sun May 12, 2013 4:44 pm
Location: Dallas, TX
Contact:

AppleTV Plugin: discussion

Post by kw123 »

changes in V 0.1.2@ 2021-03-26
==================
1. first version -- his is an alpha version
will scan for apple tv devices every xx minutes
will read play status of ided apple tv devices ever xx secs
Configure in config:
- path to python3
- time for scan and read sequences
In device edit the IP number can be over written
In menu a manual scan for new devices can be initated


=== you need to install
1. install x-code
xcode-select —install

2. install python3 (do not use home-brew) if you don't have it on your mac
go to https://www.python.org/downloads/release/python-392/
and download the 64 bit installer and install (all point and click)

3.and download /install pyatv
pip3 install pyatv


download at: https://www.indigodomo.com/pluginstore/248/


new function additions to be added:
1. send commands to apple tv
A) simple pause/ play
B) play certain music / video
C) add cursor movement

2. streamline code

this is build on top of
PYATV. It is maintained by postlund
see: https://github.com/postlund/pyatv


Karl
Woetjes
Posts: 117
Joined: Mon Apr 04, 2016 6:44 am
Location: Belgium

Re: AppleTV Plugin: discussion

Post by Woetjes »

Awesome, thanks for another plugin Karl. Will check it out very soon!
Londonmark
Posts: 573
Joined: Wed Feb 29, 2012 12:57 pm

Re: AppleTV Plugin: discussion

Post by Londonmark »

Tried it out yesterday. Worked perfectly. Many thanks Karl - great work.

Then - completely unrelated - my internal hard drive failed this morning. Five year old iMac with a fusion drive. It’s now with Apple to be fixed but I have no Indigo server (I know, I know). I walk into dark rooms and they stay dark. Siri doesn’t do anything. Alexa is lost. It’s very disconcerting. /grumble over.

Hopefully in a week or so I’ll be able to play some more with this plugin.
User avatar
kw123
Posts: 8705
Joined: Sun May 12, 2013 4:44 pm
Location: Dallas, TX
Contact:

Re: AppleTV Plugin: discussion

Post by kw123 »

This how the apocalypse looks like !!


Sent from my iPhone using Tapatalk
User avatar
Korey
Posts: 888
Joined: Wed Jun 04, 2008 11:47 am
Location: Henderson, NV
Contact:

Re: AppleTV Plugin: discussion

Post by Korey »

Working great here Karl!

Thanks a million for all your great Plugins! :D :D
--
Korey
User avatar
durosity
Posts: 4810
Joined: Thu May 10, 2012 3:21 pm
Location: Newcastle Upon Tyne, Ye Ol' England.

Re: AppleTV Plugin: discussion

Post by durosity »

Very cool plugin! Out of interest would it be plausible to expand this to be able to control/read status of HomePods?


Sent from my iPhone using Tapatalk Pro
Computer says no.
User avatar
kw123
Posts: 8705
Joined: Sun May 12, 2013 4:44 pm
Location: Dallas, TX
Contact:

Re: AppleTV Plugin: discussion

Post by kw123 »

I don’t have one.

Don’t know what opsys runs in it and if there is an http interface.


Sent from my iPhone using Tapatalk
User avatar
FlyingDiver
Posts: 7830
Joined: Sat Jun 07, 2014 10:36 am
Location: Southwest Florida, USA

Re: AppleTV Plugin: discussion

Post by FlyingDiver »

Code: Select all

jkeenan@Kraken ~ % which python3
/usr/bin/python3

Code: Select all

   appleTV                         path To python3                /usr/local/bin/python3
   appleTV                         check for new devices every    1440 minutes
   appleTV Warning                  /usr/local/bin/python3  is not present on this mac, see logfile on how to install python3
There is no Python3 in /usr/local/bin.
joe (aka FlyingDiver)
my plugins: http://forums.indigodomo.com/viewforum.php?f=177
User avatar
kw123
Posts: 8705
Joined: Sun May 12, 2013 4:44 pm
Location: Dallas, TX
Contact:

Re: AppleTV Plugin: discussion

Post by kw123 »

Check plugin/menu/help


Sent from my iPhone using Tapatalk
User avatar
FlyingDiver
Posts: 7830
Joined: Sat Jun 07, 2014 10:36 am
Location: Southwest Florida, USA

Re: AppleTV Plugin: discussion

Post by FlyingDiver »

And trying to bring up the plugin config dialog gives me:

Code: Select all


   Error (client)                  timeout waiting for plugin response from com.karlwachs.appleTV for request UiGetValues1
   Error (client)                  timeout waiting for plugin response from com.karlwachs.appleTV for request CallPluginFunc
   Error (client)                  runConfigDialog() caught exception: NSInvalidArgumentException -- *** -[__NSPlaceholderDictionary initWithObjects:forKeys:count:]: attempt to insert nil object from objects[0]
  
joe (aka FlyingDiver)
my plugins: http://forums.indigodomo.com/viewforum.php?f=177
User avatar
kw123
Posts: 8705
Joined: Sun May 12, 2013 4:44 pm
Location: Dallas, TX
Contact:

Re: AppleTV Plugin: discussion

Post by kw123 »

please check v 1.0.10

plugin went to sleep in startup when python3 path is wrong - when still in startup indigo does not allow to start config

now it will wait in runConcurrentThread() until a valid path is entered in config for python3

Karl
User avatar
FlyingDiver
Posts: 7830
Joined: Sat Jun 07, 2014 10:36 am
Location: Southwest Florida, USA

Re: AppleTV Plugin: discussion

Post by FlyingDiver »

Well, I can set the Python path now, but I can't get the plugin to do anything else useful.
joe (aka FlyingDiver)
my plugins: http://forums.indigodomo.com/viewforum.php?f=177
User avatar
kw123
Posts: 8705
Joined: Sun May 12, 2013 4:44 pm
Location: Dallas, TX
Contact:

Re: AppleTV Plugin: discussion

Post by kw123 »

Can you switch on debug

Then manually scan for new Apple TV devices ( plugin/ menu .. )

Check the plugin.log file.


Sent from my iPhone using Tapatalk
User avatar
FlyingDiver
Posts: 7830
Joined: Sat Jun 07, 2014 10:36 am
Location: Southwest Florida, USA

Re: AppleTV Plugin: discussion

Post by FlyingDiver »

Now getting:

Code: Select all

   appleTV Error                   in Line 927 has error=u'192.168.111.160'
   appleTV Error                   ip:192.168.111.160 data:{u'192.168.111.160': {u'name': u'Great Room', u'AIRPLAYPort': 7000, u'MAC': u'40:CB:C0:C1:7F:4A', u'deep_sleep': False, u'model': u'4K tvOS 14.5', u'identifier': u'B4DCA433-FDBF-44ED-A301-7275CBC378AC', u'MRPPort': 49154}}
joe (aka FlyingDiver)
my plugins: http://forums.indigodomo.com/viewforum.php?f=177
User avatar
kw123
Posts: 8705
Joined: Sun May 12, 2013 4:44 pm
Location: Dallas, TX
Contact:

Re: AppleTV Plugin: discussion

Post by kw123 »

Can you restart the Apple TV ?
They sometimes hang.


Sent from my iPhone using Tapatalk
Post Reply

Return to “AppleTV Plugin”