Development of Tunein radio streaming plugin

Looking to see if the work already done on the tunein.com website for media portal and other media streaming systems (see http://tunein.com/partners/tv/) can be tweaked to create a plugin for the plex world.



Tunein has many radio stations that shoutcast doesnt cover for my and many others interests.



Any help would be apprecaited.



I will still down soon enough and try to learn the code (not a natural at it, but have looked at this type of stuff in a past life without kids, the house and other projects taking up my valuable time).



Thanks to all those out there working to better Plex, love it.



Cheers

Daniel.



That's a fantastic idea. I use TuneIn on my phone, and it'd be neat to have it in Plex as well.

Looking at that link, it looks like there's a CE-HTML app at http://ce.radiotime.com/. You should be able to scrape that for the relevant data. And if you don't, maybe I will. :)

I’m not sure if you’ve seen, but I had a stab a while back at putting together a Tune-In plugin:

http://forums.plexapp.com/index.php/topic/29146-new-plug-in-tune-in



The problem was that Tune-in refused me official access to their API as they did not want to allow Plex to be a platform for their service. Annoying, right?!?

Thanks for the update on your earlier work. I can understand tunein’s protection of IP for the iOS side, however it would seem ideal to look to have the service accessable and setup as a part of plex on the general mac/pc world interfaces.



It would appear from your other post on this, that there has been some progress however more recently a few challenges that are indicating the plug in isnt working. Is that correct? I have grab the tunein bundle linked in the post (i assume this is the most upto date one) and will test tonight.



Cheers

Daniel.

so is it working or not?


The working TuneIn plugin is here https://github.com/solvek/TuneIn.bundle

@Solvek2 said:
The working TuneIn plugin is here GitHub - solvek/TuneIn.bundle: Play TuneIn stations with Plex Media Server

I’ve been waiting for this for a LONG time. Thank you, Solvek2. You may want to post this on the Channels thread. I’m positive that there are many others that would like to use this channel.

Hello,

Is there some reason why this plugin will not work in the standalone Plex Home Theater (PHT) software on Windows 10? I did try it in the Windows 10 AppStore app and it does indeed work there but will not play any stations while using the standalone Plex Home Theater that is installed on the same computer as the server. Both are the current versions just installed yesterday. The plugin used within the web application looks great, nice job!

One or both of these errors are what show up when a station is clicked while using the Home Theater program:

  1. Unable to play media. Please check that this file exists and the necessary drive is mounted.
  2. Playback failed. One or more items failed to play.

Also, the username will not save when typed into the preferences box.

Any help would be greatly appreciated.

Regards,
Glenn

@ghudson58@hotmail.com the plugin has been updated and is now working. Just update the bundle file :slight_smile:

Hi,
I just installed tunein.bundle (download from github February 6, 2016).
It’s looking very nice, but I see the errors (1. and 2.) from above in Home Theater.
Wasn’t that what you fixed, colonelhati?
Regards,
Birger

Hello,

when I start to play a radio station it does’nt work. I get the following errors in com.plexapp.system.log:

2016-05-27 10:27:42,051 (1418) : DEBUG (runtime:88) - Sending packed state data (99 bytes)
2016-05-27 10:27:42,052 (1418) : DEBUG (runtime:924) - Response: [500] 4168 bytes
2016-05-27 10:27:42,188 (1034) : DEBUG (runtime:717) - Handling request GET /system/services/url/lookup?url=http%3A%2F%2Fopml.radiotime.com%2FTune.ashx%3Fid%3Ds24973%26partnerId%3DRadioTime%26username%3Dmail4700
2016-05-27 10:27:42,191 (1034) : DEBUG (runtime:814) - Found route matching /system/services/url/lookup
2016-05-27 10:27:42,191 (1034) : DEBUG (services:23) - Looking up URL ‘http://opml.radiotime.com/Tune.ashx?id=s24973&partnerId=RadioTime&username=mail4700
2016-05-27 10:27:42,193 (1034) : DEBUG (services:616) - Found a service matching ‘http://opml.radiotime.com/Tune.ashx?id=s24973&partnerId=RadioTime&username=mail4700’ - TuneIn (com.plexapp.plugins.tunein)
2016-05-27 10:27:42,196 (1034) : DEBUG (services:616) - Found a service matching ‘http://opml.radiotime.com/Tune.ashx?id=s24973&partnerId=RadioTime&username=mail4700’ - TuneIn (com.plexapp.plugins.tunein)
2016-05-27 10:27:42,207 (1034) : DEBUG (logkit:13) - Requesting metadata for url: http://opml.radiotime.com/Tune.ashx?id=s24973&partnerId=RadioTime&username=mail4700
2016-05-27 10:27:42,207 (1034) : DEBUG (networking:166) - Requesting ‘http://tunein.com/radio/-s24973/
2016-05-27 10:27:43,154 (1034) : DEBUG (services:30) - TAG: Object
2016-05-27 10:27:43,157 (1034) : DEBUG (services:616) - Found a service matching ‘http://opml.radiotime.com/Tune.ashx?id=s24973&partnerId=RadioTime&username=mail4700’ - TuneIn (com.plexapp.plugins.tunein)
2016-05-27 10:27:43,163 (1034) : DEBUG (runtime:88) - Sending packed state data (99 bytes)
2016-05-27 10:27:43,164 (1034) : DEBUG (runtime:924) - Response: [200] MediaContainer, 1424 bytes
2016-05-27 10:27:43,219 (14a8) : DEBUG (runtime:717) - Handling request GET /:/plugins/com.plexapp.system/serviceFunction/url/com.plexapp.plugins.tunein/TuneIn/PlayTrack?args=Y2VyZWFsMQoxCnR1cGxlCjAKcjAK&kwargs=Y2VyZWFsMQoxCmRpY3QKMQpzODMKaHR0cDovL29wbWwucmFkaW90aW1lLmNvbS9UdW5lLmFzaHg%40aWQ9czI0OTczJnBhcnRuZXJJZD1SYWRpb1RpbWUmdXNlcm5hbWU9bWFpbDQ3MDBzMwp1cmxyMAo_
2016-05-27 10:27:43,221 (14a8) : DEBUG (runtime:814) - Found route matching /:/plugins/com.plexapp.system/serviceFunction/url/com.plexapp.plugins.tunein/TuneIn/PlayTrack
2016-05-27 10:27:43,224 (14a8) : DEBUG (networking:166) - Requesting ‘http://tunein.com/radio/-s24973/
2016-05-27 10:27:44,173 (14a8) : DEBUG (networking:166) - Requesting ‘http://stream.radiotime.com/listen.stream?streamIds=46790376,46790377,46790378,46790379&rti=dihyG20zJUdWSR0mE0hEXU0oRE1EGhk9UlVDF0xXJlhEExZ7awECDFEDI3QQRlZgDwcVC1VFRGtHEAlzGBkKEgIWX3RqGAVABUEGUlpZYAM%3D~~~
2016-05-27 10:27:44,530 (14a8) : WARNING (data:179) - Error decoding with simplejson, using demjson instead (this will cause a performance hit) - Extra data: line 1 column 10 - line 1 column 1094 (char 9 - 1093)
2016-05-27 10:27:44,532 (14a8) : CRITICAL (core:574) - Exception when calling function ‘PlayTrack’ (most recent call last):
File “C:\Program Files (x86)\Plex\Plex Media Server\Resources\Plug-ins-7be11e1\Framework.bundle\Contents\Resources\Versions\2\Python\Framework\code\sandbox.py”, line 294, in call_named_function
result = f(*args, **kwargs)
File “C:\Users\Administrator\AppData\Local\Plex Media Server\Plug-ins\TuneIn.bundle\Contents\Services\URL\TuneIn\ServiceCode.pys”, line 61, in PlayTrack
for stream in station.loadStreams():
File “C:\Users\Administrator\AppData\Local\Plex Media Server\Plug-ins\TuneIn.bundle\Contents\Services\URL\TuneIn\ServiceCode.pys”, line 165, in loadStreams
return JSON.ObjectFromString(text)[‘Streams’]
File “C:\Program Files (x86)\Plex\Plex Media Server\Resources\Plug-ins-7be11e1\Framework.bundle\Contents\Resources\Versions\2\Python\Framework\api\parsekit.py”, line 97, in ObjectFromString
return self._core.data.json.from_string(string, encoding)
File “C:\Program Files (x86)\Plex\Plex Media Server\Resources\Plug-ins-7be11e1\Framework.bundle\Contents\Resources\Versions\2\Python\Framework\components\data.py”, line 180, in from_string
return demjson.decode(jsonstring, encoding)
File “C:\Program Files (x86)\Plex\Plex Media Server\Resources\Plug-ins-7be11e1\Framework.bundle\Contents\Resources\Platforms\Shared\Libraries\demjson.py”, line 2135, in decode
obj = j.decode( unitxt )
File “C:\Program Files (x86)\Plex\Plex Media Server\Resources\Plug-ins-7be11e1\Framework.bundle\Contents\Resources\Platforms\Shared\Libraries\demjson.py”, line 1713, in decode
raise JSONDecodeError(‘unexpected or extra text’,txt[i:])
JSONDecodeError: (‘unexpected or extra text’, u’: [{“StreamId”:46790376,“Reliability”:62,“Bandwidth”:128,“HasPlaylist”:false,“MediaType”: “MP3”,“Url”: “http://regiocast.hoerradar.de/deltaradio128?sABC=5748018r%230%2322n2r4sq4o2q4017rnoq21968o00n724%23gharva&amsparams=playerid:tunein;skey:1464336782","Type”: “Live”},{“StreamId”:46790377,“Reliability”:95,“Bandwidth”:192,“HasPlaylist”:false,“MediaType”: “MP3”,“Url”: “http://regiocast.hoerradar.de/deltaradio-live-mp3-hq?sABC=5748018r%230%238o143s258r9r78946rprr1p98son02p8%23gharva&amsparams=playerid:tunein;skey:1464336782","Type”: “Live”},{“StreamId”:46790378,“Reliability”:99,“Bandwidth”:64,“HasPlaylist”:false,“MediaType”: “AAC”,“Url”: “http://regiocast.hoerradar.de/deltaradio-mobil64?sABC=5748018r%230%238o143s258r9r78946rprr1p98son02p8%23gharva&amsparams=playerid:tunein;skey:1464336782","Type”: “Live”},{“StreamId”:46790379,“Reliability”:61,“Bandwidth”:48,“HasPlaylist”:false,“MediaType”: “AAC”,“Url”: “http://regiocast.hoerradar.de/deltaradio-mobil64?sABC=5748018s%230%238o143s258r9r78946rprr1p98son02p8%23gharva&amsparams=playerid:tunein;skey:1464336783","Type”: “Live”}]’)

2016-05-27 10:27:44,533 (14a8) : CRITICAL (core:574) - Exception (most recent call last):
File “C:\Program Files (x86)\Plex\Plex Media Server\Resources\Plug-ins-7be11e1\Framework.bundle\Contents\Resources\Versions\2\Python\Framework\components\runtime.py”, line 843, in handle_request
result = f(**d)
File “C:\Program Files (x86)\Plex\Plex Media Server\Resources\Plug-ins-7be11e1\Framework.bundle\Contents\Resources\Versions\2\Python\Framework\handlers\services.py”, line 150, in call_service_function
result = self._core.services._call_named_function_in_service(f_name, service, f_args, f_kwargs)
File “C:\Program Files (x86)\Plex\Plex Media Server\Resources\Plug-ins-7be11e1\Framework.bundle\Contents\Resources\Versions\2\Python\Framework\components\services.py”, line 589, in _call_named_function_in_service
return self._call_named_function_in_sandbox(service.sandbox, fname, None, f_args, f_kwargs, allow_deferred, raise_exceptions, f_optional)
File “C:\Program Files (x86)\Plex\Plex Media Server\Resources\Plug-ins-7be11e1\Framework.bundle\Contents\Resources\Versions\2\Python\Framework\components\services.py”, line 573, in _call_named_function_in_sandbox
result = sandbox.call_named_function(fname, allow_deferred=allow_deferred, raise_exceptions=raise_exceptions, args=f_args, kwargs=f_kwargs, mod_name=mod_name, optional_kwargs=f_optional)
File “C:\Program Files (x86)\Plex\Plex Media Server\Resources\Plug-ins-7be11e1\Framework.bundle\Contents\Resources\Versions\2\Python\Framework\code\sandbox.py”, line 294, in call_named_function
result = f(*args, **kwargs)
File “C:\Users\Administrator\AppData\Local\Plex Media Server\Plug-ins\TuneIn.bundle\Contents\Services\URL\TuneIn\ServiceCode.pys”, line 61, in PlayTrack
for stream in station.loadStreams():
File “C:\Users\Administrator\AppData\Local\Plex Media Server\Plug-ins\TuneIn.bundle\Contents\Services\URL\TuneIn\ServiceCode.pys”, line 165, in loadStreams
return JSON.ObjectFromString(text)[‘Streams’]
File “C:\Program Files (x86)\Plex\Plex Media Server\Resources\Plug-ins-7be11e1\Framework.bundle\Contents\Resources\Versions\2\Python\Framework\api\parsekit.py”, line 97, in ObjectFromString
return self._core.data.json.from_string(string, encoding)
File “C:\Program Files (x86)\Plex\Plex Media Server\Resources\Plug-ins-7be11e1\Framework.bundle\Contents\Resources\Versions\2\Python\Framework\components\data.py”, line 180, in from_string
return demjson.decode(jsonstring, encoding)
File “C:\Program Files (x86)\Plex\Plex Media Server\Resources\Plug-ins-7be11e1\Framework.bundle\Contents\Resources\Platforms\Shared\Libraries\demjson.py”, line 2135, in decode
obj = j.decode( unitxt )
File “C:\Program Files (x86)\Plex\Plex Media Server\Resources\Plug-ins-7be11e1\Framework.bundle\Contents\Resources\Platforms\Shared\Libraries\demjson.py”, line 1713, in decode
raise JSONDecodeError(‘unexpected or extra text’,txt[i:])
JSONDecodeError: (‘unexpected or extra text’, u’: [{“StreamId”:46790376,“Reliability”:62,“Bandwidth”:128,“HasPlaylist”:false,“MediaType”: “MP3”,“Url”: “http://regiocast.hoerradar.de/deltaradio128?sABC=5748018r%230%2322n2r4sq4o2q4017rnoq21968o00n724%23gharva&amsparams=playerid:tunein;skey:1464336782","Type”: “Live”},{“StreamId”:46790377,“Reliability”:95,“Bandwidth”:192,“HasPlaylist”:false,“MediaType”: “MP3”,“Url”: “http://regiocast.hoerradar.de/deltaradio-live-mp3-hq?sABC=5748018r%230%238o143s258r9r78946rprr1p98son02p8%23gharva&amsparams=playerid:tunein;skey:1464336782","Type”: “Live”},{“StreamId”:46790378,“Reliability”:99,“Bandwidth”:64,“HasPlaylist”:false,“MediaType”: “AAC”,“Url”: “http://regiocast.hoerradar.de/deltaradio-mobil64?sABC=5748018r%230%238o143s258r9r78946rprr1p98son02p8%23gharva&amsparams=playerid:tunein;skey:1464336782","Type”: “Live”},{“StreamId”:46790379,“Reliability”:61,“Bandwidth”:48,“HasPlaylist”:false,“MediaType”: “AAC”,“Url”: “http://regiocast.hoerradar.de/deltaradio-mobil64?sABC=5748018s%230%238o143s258r9r78946rprr1p98son02p8%23gharva&amsparams=playerid:tunein;skey:1464336783","Type”: “Live”}]’)

pourquoi ai-je besoin d’un plug-in, quand il y a beaucoup de webradio?
(gratuit)

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.