shift / script.kodi.ambimote

This is a addon for Kodi which allows you to turn a Pimoroni Mote Host and Sticks into a alternative Ambilight.
GNU General Public License v2.0
3 stars 1 forks source link

Issues when running on Kodi 17 #1

Open PaulWebster opened 6 years ago

PaulWebster commented 6 years ago

I have not tried this addon on Kodi 16 (so I do not know for sure that I had set things up correctly) ... however, it does not run on Kodi 17 without some changes.

I started hacking things but was not getting a callback when the video started playing so I decided to check with you first.

First issue appears to be that the setting of useLegacyApi to False might need to be moved up above the call to PlayerMonitor because PlayerMonitor is using it. (useLegacyApi as False means Kodi 17+). I do not know what the calling order is in the Kodi Python so not sure if the code at the very top is called before main but I guess it is ... in which case perhaps the setting of useLegacyApi should be up at the top just after the line capture = xbmc.RenderCapture()

I think that the line if capture.getCaptureState() == xbmc.CAPTURE_STATE_DONE: also needs protecting with a check to useLegacyApi because it is not in Kodi 17 either.

I made those changes (and added in some code as an alternative for when useLegacyApi is False) but I could not get things to work (I put some print statements in the area where onPlayBackStarted is actioned and got nothing). I expect that I can do some more diagnostics next week but I do not want to work on it if someone else already has a solution.

shift commented 6 years ago

PR's welcome to fix the Kodi 17 issues. AFAIK no one is working on this.

PaulWebster commented 6 years ago

Thanks for the reply. I experimented with a different route today and now have the Pimoroni Mote sticks working. If it does not work out after some soak testing then I’ll come back and try to get things going here.

FYI I am now using a Python implementation of an OPC (Open Pixel Control) to Pimoroni Unicorn LED matrix that I have adapted to drive the Mote sticks. Benefit being that as an OPC Server it is supported by Hyperion and a few other things.