• 1
  • 6
  • 7
  • 8(current)
  • 9
  • 10
Release Random Trailers Screensaver / Script
Hey kz

Back to the remote mapping again - I found a reference to using windowID in the keymap.
Only thing is, I have no idea how to find the window ID of random trailers player?

Also, I have had trouble in the past with keymaps taking effect. Running in 'portable' mode can be one of the problems, and also (from memory) it has to be under keymaps directory.

Here is the wiki reference; http://wiki.xbmc.org/index.php?title=Keymap (find in page 'windowid')
Do you know what that might be for Random Trailers?

thanks
Reply
Python assigns window id's when running an addon so I cannot specify them. it looks like they are assigned in the range of 13000-13099

I ran a test and it looks like the window ID you are looking for is 13001

Please let me know if this works.

Thanks!

PS I put some code in to print out the window id in the xbmc.log file. If you download and install from git you should get the following in your log:

Trailer_Window_id = 13001
-ken Z-
Reply
Version 1.1.13 with rating filtering now available in official XBMC Repo!
-ken Z-
Reply
(2014-03-06, 00:59)kzeleny Wrote: Python assigns window id's when running an addon so I cannot specify them. it looks like they are assigned in the range of 13000-13099

I ran a test and it looks like the window ID you are looking for is 13001

Please let me know if this works.

Thanks!

PS I put some code in to print out the window id in the xbmc.log file. If you download and install from git you should get the following in your log:

Trailer_Window_id = 13001

I tried running a "download ZIP" from your git but it crashes, maybe it's something I'm doing.
Reply
What crashes? And when?
-ken Z-
Reply
(2014-03-06, 03:29)kzeleny Wrote: What crashes? And when?

When I run random trailers from your git it crashes without doing anything.
Similar log items to this:
Code:
18:14:01 T:6212  NOTICE: -->Python Interpreter Initialized<--
18:14:01 T:6212   DEBUG: XBPyThread::Process - The source file to load is C:\Users\Cory\AppData\Roaming\XBMC\addons\screensaver.randomtrailers-master\default.py
18:14:01 T:6212   DEBUG: XBPyThread::Process - Setting the Python path to C:\Users\Cory\AppData\Roaming\XBMC\addons\screensaver.randomtrailers-master;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.demjson\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.protobuf\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\plugin.program.sabnzbd\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.myconnpy\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.beautifulsoup\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.common.plugin.cache\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.gmusicapi\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.coveapi\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.free.cable.database\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.donnie\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.walter\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.playbackengine\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.universal\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.buggalo\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.mechanize\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.xbmcswift2\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.t0mm0.common\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.watchhistory\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.cryptopy\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.chardet\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.simplejson\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.addon.common\lib;C:\Program Files (x86)\XBMC\addons\script.module.pil\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.simple.downloader\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.requests\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.decorator\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.urlresolver\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.mutagen\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.parsedom\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.elementtree\lib;C:\Program Files (x86)\XBMC\addons\script.module.pysqlite\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.validictory\lib;C:\Users\Cory\AppData\Roaming\XBMC\addons\script.module.metahandler\lib;C:\Program Files (x86)\XBMC\system\python\DLLs;C:\Program Files (x86)\XBMC\system\python\Lib;C:\Program Files (x86)\XBMC\python26.zip;C:\Program Files (x86)\XBMC\system\python\lib\plat-win;C:\Program Files (x86)\XBMC\system\python\lib\lib-tk;C:\Program Files (x86)\XBMC;C:\Program Files (x86)\XBMC\system\python;C:\Program Files (x86)\XBMC\system\python\lib\site-packages;
18:14:01 T:6212   DEBUG: XBPyThread::Process - Entering source directory C:\Users\Cory\AppData\Roaming\XBMC\addons\screensaver.randomtrailers-master
18:14:01 T:6212   DEBUG: Instantiating addon using automatically obtained id of "screensaver.randomtrailers" dependent on version 2.1.0 of the xbmc.python api
18:14:01 T:6212   ERROR: EXCEPTION Thrown (PythonToCppException) : -->Python callback/script returned the following error<--
                                             - NOTE: IGNORING THIS CAN LEAD TO MEMORY LEAKS!
                                            Error Type: <type 'exceptions.IndentationError'>
                                            Error Contents: ('expected an indented block', ('C:\\Users\\Cory\\AppData\\Roaming\\XBMC\\addons\\screensaver.randomtrailers-master\\default.py', 564, 25, ''))
                                            IndentationError: ('expected an indented block', ('C:\\Users\\Cory\\AppData\\Roaming\\XBMC\\addons\\screensaver.randomtrailers-master\\default.py', 564, 25, ''))
                                            -->End of Python script error report<--
Reply
some kind of commit error, fixed it should be ok now
-ken Z-
Reply
(2014-03-06, 05:02)kzeleny Wrote: some kind of commit error, fixed it should be ok now

I'm getting different 'invalid syntax' errors now.
Error Type: <type 'exceptions.SyntaxError'>
Error Contents: ('invalid syntax', ('C:\\Users\\Cory\\AppData\\Roaming\\XBMC\\addons\\screensaver.randomtrailers-master\\default.py', 527, 12, 'class def onInit(self):\n'))
SyntaxError: ('invalid syntax', ('C:\\Users\\Cory\\AppData\\Roaming\\XBMC\\addons\\screensaver.randomtrailers-master\\default.py', 527, 12, 'class def onInit(self):\n'))
Reply
Ok if you try again you should get a working copy. Not sure what happened on git so I took a working copy I had and replaced the git version, then reinstalled form git and it worked for me.
-ken Z-
Reply
(2014-03-07, 02:36)kzeleny Wrote: Ok if you try again you should get a working copy. Not sure what happened on git so I took a working copy I had and replaced the git version, then reinstalled form git and it worked for me.

Thank you! It works!!!

Now I can map 0 to the queue command only in the addon player to send to CP.

In case anyone else is interested, this is what I did:

In /users/(user)/Roaming/XBMC/userdata/keymaps

I created keyboard.xml

Inside keyboard.xml I put these lines:

Code:
<keymap>
<window13001>  
  <keyboard>
  <zero>queue</zero>
  </keyboard>
</window13001>
</keymap>

(And btw, windowID in the log matches 13001)
I don't know if the windowid will change sometimes so we will see what the behaviour is. This may have benefits in other places.

Thanks for everything kz!
Reply
It should stay the show's to hear it is working for you!
-ken Z-
Reply
Have you thought about using "MOVIECLIPS Trailers" as your YouTube trailer source. They have a pretty solid track record for uploading the latest HD trailers, just need to figure out how to weed out all the other garbage they are uploading these days.
Reply
It doesn't seem to work as screensaver. screen just goes black.

Edit: Never mind. I just reinstalled it and it works!
Reply
You have to restart xbmc after you enable the screen saver.
-ken Z-
Reply
(2014-03-15, 09:02)Rusti Wrote: Have you thought about using "MOVIECLIPS Trailers" as your YouTube trailer source. They have a pretty solid track record for uploading the latest HD trailers, just need to figure out how to weed out all the other garbage they are uploading these days.

Yes I have looked at it, but their api dosen't provide me with links to the actual trailer file, but only links to their embedded page. I have imporved the tmdb trailers in the latest verison available on my git Repo. v 1.15 I will be pushing that to the official repo in another week or so.

See first post for location do download from git.

Thanks for the Suggestion!
-ken Z-
Reply
  • 1
  • 6
  • 7
  • 8(current)
  • 9
  • 10

Logout Mark Read Team Forum Stats Members Help
Random Trailers Screensaver / Script1