• 1
  • 2(current)
  • 3
  • 4
  • 5
  • 47
[RELEASE] Norwegian NRK Web-TV (Video) Plugin
Great news ! thanks you both mr grumpy and victor !
If i only could do python coding i would help Wink

Hope progress is going along !
I've spent some time coding on this plugin now, and it should work as specified by spiff. I re-organized the structure a bit, and added different views and a search function. I've also added some icons to make it look slicker, but some of them should absolutely be replaced with some that will fit better.
I'll try to fix bugs as they appear, and I'll try to write some error handling into it when I have some spare time.
I also hope we hear some good news from spiff soon, as it is a bit more enjoyable coding on something that works :p


This version is not testet properly since I only have a old laptop with a bad 3d card, running on windows atm. I'm far from happy with it, but I guess it should work better than earlier version.

i got pissed at libmms this weekend as it worked on one puter of mine, not another one for no apparent (this being the key word i suspect) reason. your changed plugin should make it a bit easier to be me though so soon.
Okay have tested it. Seems like it throws me errors when i try to enter
any categories. The only category that i could enter was : HTML-katalog
but unable to actually play any content under there.

I bellive the following snippet shows atleast some warning:
20:39:33 T:2546228112 M:1676472320  NOTICE:   File "/home/xbmc/.xbmc/plugins/video/nrk media browser/default.py", line 42, in ?
20:39:33 T:2546228112 M:1676472320  NOTICE: from NRK_API import xbmcplugin_program as plugin
20:39:33 T:2546228112 M:1676472320  NOTICE:   File "/home/xbmc/.xbmc/plugins/video/nrk media browser/NRK_API/xbmcplugin_program.py", line 29, in ?
20:39:33 T:2546228112 M:1676472320  NOTICE: from webtv import WebTV
20:39:33 T:2546228112 M:1676472320  NOTICE:   File "/home/xbmc/.xbmc/plugins/video/nrk media browser/NRK_API/webtv.py", line 44, in ?
20:39:33 T:2546228112 M:1676472320  NOTICE: class WebTV:
20:39:33 T:2546228112 M:1676472320  NOTICE:   File "/home/xbmc/.xbmc/plugins/video/nrk media browser/NRK_API/webtv.py", line 60, in WebTV
20:39:33 T:2546228112 M:1676472320  NOTICE: settings = {
20:39:33 T:2546228112 M:1676472320  NOTICE: IndexError
20:39:33 T:2546228112 M:1676472320  NOTICE: :
20:39:33 T:2546228112 M:1676472320  NOTICE: tuple index out of range
20:39:33 T:2546228112 M:1676472320   ERROR: Scriptresult: Error

More complete log:

gonna try latest xbmc build and see if anything changes...
That's odd. It's seems like a typo in settings file. It might be stupid mistake that's been corrected in http://prosjektet.net/xbmc/plugins/nrkplugin2_00002.7z who works for me. It also contains some test with feedparser from nrk beta.
Otherwise I'll take a look at it as soon as I can

You can't play the videos at 'icanal' folder in the html directory either?
I can't get it to play the videos hostet at pd.nrk, but icanals videos works great. I'm not sure how their system are set up, but it seems like icanal are used as some sort of bandwith balancing as the playlist videos "randomly" are redirected there and then works.
Gonna try the new link when i get home from work.
And i didnt try the ones from icanal but gonna try that also.

I realy hope that we can get a stable working nrk plugin since
that was something i used alot back in the days when EnderW had his
old nrk script Smile
Same thing happens... no catagorys is possible to enter.

The NRK Beta streams however i can enter and also stream content Smile

So it's almost there ! Smile

Debug Log snippet:
i have delivered on my promise in r21735. only linux for now, but i'm sure the other platforms will follow soonish
Spiff would this say that the script now works if i upgrade to r21735 ?

Thank you so much for doing that job - !
i didn't try the actual plugin (was too tired), but the hand-extracted url (as i gave instructions and victor said he had followed) definitely played
Newest 7z-file has a bug either in webtv.py or in settings.xml. ViktorV would know where to fix it. My current workaround is below, but that only gets you through to browsing shows. Currently I don't get the shows to play, I just end with an empty directory.

Boxhead: From your log, it seems that you ran into this one.
diff --git a/NRK_API/webtv.py b/NRK_API/webtv.py
index ad01b0a..c06272f 100644
--- a/NRK_API/webtv.py
+++ b/NRK_API/webtv.py
@@ -77,11 +77,11 @@ class WebTV:
-                        )[int(xbmcplugin.getSetting("connection_speed"))],
+                        )[2],
             'cache_time': (
                         ConnectionManager.cache_never_expire, 1, 2, 12, 24,
-                        )[int(xbmcplugin.getSetting("cache_time"))]
+                        )[1]
     print int(xbmcplugin.getSetting("connection_speed"))
Extra note: Delete the *.pyo files from the 7z-archive, I think I also got into problems with these (they had some paths in them stemming from ViktorV's machine). They will be recompiled upon running the plugin.
Berlend i removed all the *.pyo files i could find but still the same for me

Fresh debug log:
PointOfView Nvidia ION Atom 330 - TRANSCEND 2GB DDR2 DIMM 800MHz - G.SKILL 64GB SSD 2.5
Open Elec Beta4 1.95.4
XBMC Online Manual - HOW-TO post about a problem in a useful manner - Create/View Bug Report
Setup/Fix correct resolution on XBMC/Ubuntu - Usefull linux terminal commands

I got some of the shows working by editing xbmcplugin_program.py

--- C:\Users\frode\Documents\xbmc\plugins\nrk media browser\NRK_API\xbmcplugin_program.py    ma jul 13 15:38:28 2009
+++ C:\Users\frode\Documents\xbmc\plugins\nrk media browser\NRK_API\xbmcplugin_program_frodes.py    sø jul 19 22:20:03 2009
@@ -432,7 +432,7 @@
     def _handle_show_clip_index(self, parent):
-        self.item = MediaObj(key=parent)
+        self.item = nrk.MediaObj(key=parent)
         return WebTV.PLAYABLE
     # - EOM -
@@ -702,8 +702,16 @@
                     path = item.url
+            li.setProperty('IsPlayable', item.is_playable())
+            ok = True
+            mediawindow = xwin.MediaWindow(int(sys.argv[1]))
+            item.listitem = li
+            ok = mediawindow.add(item)
+            mediawindow.end(ok)
+            #li.setInfo( type="Video", infoLabels={ "Title": item.title})
             #xbmc.Player().play(item.url, li)
-            xbmcplugin.setResolvedUrl(int(sys.argv[1]), ok, li)
+            #xbmcplugin.setResolvedUrl(int(sys.argv[1]), ok, li)

I'm not quite sure what the problem was. It seems to work properly after removing some entries in settings.xml.


I've tested this on my xbox and my windows build. xbox works properly where it should, windows really doesn't play anything, but plugin seems to work.
Just ignore the podcast section of the plugin. May be disabled in settings (I forgot)

It's still wip, but I have startet to implement some errorhandling that should create a better experience and a more stable plugin. It also remains some work against the xbmc api. Infolabels, sortmethods, context menus ++
  • 1
  • 2(current)
  • 3
  • 4
  • 5
  • 47

Logout Mark Read Team Forum Stats Members Help
[RELEASE] Norwegian NRK Web-TV (Video) Plugin9
This forum uses Lukasz Tkacz MyBB addons.