Kodi Community Forum
Release "iPlayer WWW" add-on - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33)
+--- Forum: Add-on Support (https://forum.kodi.tv/forumdisplay.php?fid=27)
+---- Forum: Video Add-ons (https://forum.kodi.tv/forumdisplay.php?fid=154)
+---- Thread: Release "iPlayer WWW" add-on (/showthread.php?tid=353349)



RE: New plugin "iPlayer WWW" - irn|bru - 2016-06-25

(2016-06-25, 08:34)primaeval Wrote: ...I think we need a separate bitrate setting for the red button streams.

I just wanted to chip in with something because the red button has been a bit 'silly' for me recently. I initially noticed that the higher feeds weren't working and like others, had to choose a lesser quality. Just for my own peace of mind, I decided to check via the BBC app on my iPad and pulled an m3u8 from there. The best quality available was the same as I had to choose in this add-on (1.7Mbps). I just thought to myself, "OK, they've pulled the higer feeds for the red button, no biggie". But, I still wasn't convinced and wanted to double check -- my OCD kicking in -- so I grabbed an f4m link to test (http://a.files.bbci.co.uk/media/live/manifesto/audio_video/webcast/hds/uk/pc/llnw/sport_stream_10.f4m) and opened it up to check. The feeds available were:

Code:
<manifest xmlns="http://ns.adobe.com/f4m/2.0">
<dvrInfo windowDuration="-1"/>
<media href="http://ve-hds-uk-live.bbcfmt.vo.llnwd.net/pool_41/live/uk/sport_stream_10/sport_stream_10.isml/sport_stream_10-pa2=48000-video=281000.f4m" bitrate="352"/>
<media href="http://ve-hds-uk-live.bbcfmt.vo.llnwd.net/pool_41/live/uk/sport_stream_10/sport_stream_10.isml/sport_stream_10-pa3=96000-video=437000.f4m" bitrate="544"/>
<media href="http://ve-hds-uk-live.bbcfmt.vo.llnwd.net/pool_41/live/uk/sport_stream_10/sport_stream_10.isml/sport_stream_10-pa3=96000-video=827000.f4m" bitrate="942"/>
<media href="http://ve-hds-uk-live.bbcfmt.vo.llnwd.net/pool_41/live/uk/sport_stream_10/sport_stream_10.isml/sport_stream_10-pa3=96000-video=1604000.f4m" bitrate="1700"/>
<media href="http://ve-hds-uk-live.bbcfmt.vo.llnwd.net/pool_41/live/uk/sport_stream_10/sport_stream_10.isml/sport_stream_10-pa3=96000-video=2812000.f4m" bitrate="2908"/>
<media href="http://ve-hds-uk-live.bbcfmt.vo.llnwd.net/pool_41/live/uk/sport_stream_10/sport_stream_10.isml/sport_stream_10-pa3=96000-video=5070000.f4m" bitrate="5166"/>
</manifest>

I realised that '5166' is 720p 50fps and wondered why it wasn't getting used? Maybe the data was still in the f4m file but they had turned off the feed. Had to check, obviously. So, grabbed the link for that and chucked it into an .strm file for use with f4mtester:
Code:
#EXTINF:0,50fps Glasto Test
plugin://plugin.video.f4mTester/?url=http://ve-hds-uk-live.bbcfmt.vo.llnwd.net/pool_41/live/uk/sport_stream_10/sport_stream_10.isml/sport_stream_10-pa3=96000-video=5070000.f4m

Does it work? YES, it does!!! Weird...

So, my question is, why does it not work in this add-on when choosing the 5.2Mbps feed? Has something changed/broken? I tried to understand it but I haven't a clue. primaeval... it's up to you now Big Grin

EDIT:
I see in the error log in Kodi that the add-on pulls an m3u8 file to play but, knowing that those higher feeds aren't available as m3u8, that's where the error is.


RE: New plugin "iPlayer WWW" - primaeval - 2016-06-25

(2016-06-25, 17:59)irn|bru Wrote:
(2016-06-25, 08:34)primaeval Wrote: ...I think we need a separate bitrate setting for the red button streams.

I just wanted to chip in with something because the red button has been a bit 'silly' for me recently. I initially noticed that the higher feeds weren't working and like others, had to choose a lesser quality. Just for my own peace of mind, I decided to check via the BBC app on my iPad and pulled an m3u8 from there. The best quality available was the same as I had to choose in this add-on (1.7Mbps). I just thought to myself, "OK, they've pulled the higer feeds for the red button, no biggie". But, I still wasn't convinced and wanted to double check -- my OCD kicking in -- so I grabbed an f4m link to test (http://a.files.bbci.co.uk/media/live/manifesto/audio_video/webcast/hds/uk/pc/llnw/sport_stream_10.f4m) and opened it up to check. The feeds available were:

Code:
<manifest xmlns="http://ns.adobe.com/f4m/2.0">
<dvrInfo windowDuration="-1"/>
<media href="http://ve-hds-uk-live.bbcfmt.vo.llnwd.net/pool_41/live/uk/sport_stream_10/sport_stream_10.isml/sport_stream_10-pa2=48000-video=281000.f4m" bitrate="352"/>
<media href="http://ve-hds-uk-live.bbcfmt.vo.llnwd.net/pool_41/live/uk/sport_stream_10/sport_stream_10.isml/sport_stream_10-pa3=96000-video=437000.f4m" bitrate="544"/>
<media href="http://ve-hds-uk-live.bbcfmt.vo.llnwd.net/pool_41/live/uk/sport_stream_10/sport_stream_10.isml/sport_stream_10-pa3=96000-video=827000.f4m" bitrate="942"/>
<media href="http://ve-hds-uk-live.bbcfmt.vo.llnwd.net/pool_41/live/uk/sport_stream_10/sport_stream_10.isml/sport_stream_10-pa3=96000-video=1604000.f4m" bitrate="1700"/>
<media href="http://ve-hds-uk-live.bbcfmt.vo.llnwd.net/pool_41/live/uk/sport_stream_10/sport_stream_10.isml/sport_stream_10-pa3=96000-video=2812000.f4m" bitrate="2908"/>
<media href="http://ve-hds-uk-live.bbcfmt.vo.llnwd.net/pool_41/live/uk/sport_stream_10/sport_stream_10.isml/sport_stream_10-pa3=96000-video=5070000.f4m" bitrate="5166"/>
</manifest>

I realised that '5166' is 720p 50fps and wondered why it wasn't getting used? Maybe the data was still in the f4m file but they had turned off the feed. Had to check, obviously. So, grabbed the link for that and chucked it into an .strm file for use with f4mtester:
Code:
#EXTINF:0,50fps Glasto Test
plugin://plugin.video.f4mTester/?url=http://ve-hds-uk-live.bbcfmt.vo.llnwd.net/pool_41/live/uk/sport_stream_10/sport_stream_10.isml/sport_stream_10-pa3=96000-video=5070000.f4m

Does it work? YES, it does!!! Weird...

So, my question is, why does it not work in this add-on when choosing the 5.2Mbps feed? Has something changed/broken? I tried to understand it but I haven't a clue. primaeval... it's up to you now Big Grin

I get the same result as you. I can't see anything in the addon code that would limit the streams above 1.7Mbps. I think it might be something f4mTester is bypassing that helps. Perhaps the source providers are limiting connections due to the season: football, olympics, glastonbury. I'll keep testing and I hope you could too.

My test version a couple of posts ago would help anyone that wants to watch Glastonbury today and still keep the Highest bitrates for the normal channels.


RE: New plugin "iPlayer WWW" - irn|bru - 2016-06-25

(2016-06-25, 18:34)primaeval Wrote: I get the same result as you. I can't see anything in the addon code that would limit the streams above 1.7Mbps. I think it might be something f4mTester is bypassing that helps. Perhaps the source providers are limiting connections due to the season: football, olympics, glastonbury. I'll keep testing and I hope you could too.

My test version a couple of posts ago would help anyone that wants to watch Glastonbury today and still keep the Highest bitrates for the normal channels.

I just updated my post Smile
I see in the error log in Kodi that the add-on pulls an m3u8 file (or adds the m3u8 extension) to play but, knowing that those higher feeds aren't available as m3u8, that's where the error is. I don't know why they have pulled the higher feeds in m3u8 format but it may be because their app only goes to 1.7Mbps so they don't need the other two higher m3u8's. Is there any way that this add-on can utilise f4mtester/livestreamer to play the red button feeds?


RE: New plugin "iPlayer WWW" - primaeval - 2016-06-25

(2016-06-25, 18:42)irn|bru Wrote:
(2016-06-25, 18:34)primaeval Wrote: I get the same result as you. I can't see anything in the addon code that would limit the streams above 1.7Mbps. I think it might be something f4mTester is bypassing that helps. Perhaps the source providers are limiting connections due to the season: football, olympics, glastonbury. I'll keep testing and I hope you could too.

My test version a couple of posts ago would help anyone that wants to watch Glastonbury today and still keep the Highest bitrates for the normal channels.

I just updated my post Smile
I see in the error log in Kodi that the add-on pulls an m3u8 file (or adds the m3u8 extension) to play but, knowing that those higher feeds aren't available as m3u8, that's where the error is. I don't know why they have pulled the higher feeds in m3u8 format but it may be because their app only goes to 1.7Mbps so they don't need the other two higher m3u8's. Is there any way that this add-on can utilise f4mtester/livestreamer to play the red button feeds?

The higher bitrate m3u8 files definitely exist and contain the correct ts links inside but they just don't play.
eg
Code:
http://ve-hds-uk-live.edgesuite.net/pool_14/live/uk/sport_stream_04/sport_stream_04.isml/sport_stream_04-pa3%3d96000-video%3d5070000.m3u8
contains
Code:
#EXTM3U
#EXT-X-VERSION:2
## Created with Unified Streaming Platform(version=1.7.9)
#EXT-X-MEDIA-SEQUENCE:183358311
#EXT-X-TARGETDURATION:8
#USP-X-TIMESTAMP-MAP:MPEGTS=7869650144,LOCAL=2016-06-25T14:54:44Z
#EXT-X-PROGRAM-DATE-TIME:2016-06-25T14:54:44Z
#EXTINF:8, no desc
sport_stream_04-pa3=96000-video=5070000-183358311.ts
#EXTINF:8, no desc
sport_stream_04-pa3=96000-video=5070000-183358312.ts
#EXTINF:8, no desc
sport_stream_04-pa3=96000-video=5070000-183358313.ts
#EXTINF:8, no desc
...
I don't know if f4mtester is classed as a dodgy addon by team kodi.
I have only used livestreamer as a standalone program. How does it work in Kodi?


RE: New plugin "iPlayer WWW" - irn|bru - 2016-06-25

(2016-06-25, 19:00)primaeval Wrote: The higher bitrate m3u8 files definitely exist and contain the correct ts links inside but they just don't play.
Yea apologies, I should have clarified that they DO exist but just don't work... that's what I meant. I had been testing those higher m3u8's with Livestreamer on the laptop, with VLC using the console and also in Kodi via an strm file. I thought it might have even been a User Agent problem but even changing that made no difference. The .ts segments still don't get loaded so that's why I kinda thought that the details of the feeds are still there but the feed itself is turned off. Not entirely sure if that's how it works but it kinda makes sense to me.

(2016-06-25, 19:00)primaeval Wrote: I don't know if f4mtester is classed as a dodgy addon by team kodi.
I have only used livestreamer as a standalone program. How does it work in Kodi?
Ah, I never thought of it not being allowed... good point. As for Livestreamer in Kodi, I'm not sure how it works in terms of it being used in the coding side of things, to be honest. Then again, I'm not entirely sure it's even able to play the links we need. That comes down to f4mtester, I THINK.


RE: New plugin "iPlayer WWW" - irn|bru - 2016-06-25

Apologies for the double post but I've got the 50pfs m3u8 now working for the feeds. You need to change the pa part to 1 instead of 3 4 instead and the audio needs to be 128000. Old non-working URL is:
Code:
http://ve-hds-uk-live.bbcfmt.vo.llnwd.net/pool_41/live/uk/sport_stream_10/sport_stream_10.isml/sport_stream_10-pa3=24000-video=5070000.m3u8
New working file is:
Code:
http://ve-hds-uk-live.bbcfmt.vo.llnwd.net/pool_41/live/uk/sport_stream_10/sport_stream_10.isml/sport_stream_10-pa4=128000-video=5070000.m3u8
Fingers crossed this change can be implemented in the add-on when it tries to grab a higher quality stream?

EDITED FOR CLARITY


RE: New plugin "iPlayer WWW" - primaeval - 2016-06-25

(2016-06-25, 19:56)irn|bru Wrote: Apologies for the double post but I've got the 50pfs m3u8 now working for the feeds. You need to change the pa part to 1 instead of 3. Old non-working URL is:
Code:
http://ve-hds-uk-live.bbcfmt.vo.llnwd.net/pool_41/live/uk/sport_stream_10/sport_stream_10.isml/sport_stream_10-pa3=24000-video=5070000.m3u8
New working file is:
Code:
http://ve-hds-uk-live.bbcfmt.vo.llnwd.net/pool_41/live/uk/sport_stream_10/sport_stream_10.isml/sport_stream_10-pa1=24000-video=5070000.m3u8
Fingers crossed this change can be implemented in the add-on when it tries to grab a higher quality stream?

Excellent! That works. How did you find it?

The code that needs changing is just to add one line:
https://github.com/primaeval/plugin.video.iplayerwww/commit/35e11c94e038683f3fd4daa12c5b82482a03b019

I've made a new test release:
https://github.com/primaeval/plugin.video.iplayerwww/archive/2.3.2p2.zip
which is in my beta repo:
https://github.com/primaeval/repository.primaeval/raw/master/zips/repository.primaeval/repository.primaeval-0.0.1.zip

I suppose we don't really need a seperate Red Button bitrate now.

Thanks. Smile


RE: New plugin "iPlayer WWW" - irn|bru - 2016-06-25

(2016-06-25, 20:20)primaeval Wrote: Excellent!...
Wait a min... are you getting audio from the feeds? Unless I'm going crazy, I had audio now don't have any. Maybe it's not a fix yet. Damn. Will keep testing and leave a feed running to see if it comes back or if I really am going crazy.

By the way, I found the feed by looking at the links that do work against the links that don't. Noticed the change in the URL and decided to see if it works with the HQ ones.

Quick Edit: I know what's wrong. The 24000 bit needs the matching audio bitrate. Will find it in a sec. (unless you have it already. just needs a figure for an HQ feed that does work)

EDIT 2:
OK, the pa part has to be 4 and the audio 128000. So it's pa4=128000 I must have had a different audio feed in my m3u8 when testing. Sorry. This link is definitely working as planned:
Code:
http://ve-hds-uk-live.bbcfmt.vo.llnwd.net/pool_41/live/uk/sport_stream_10/sport_stream_10.isml/sport_stream_10-pa4=128000-video=5070000.m3u8



RE: New plugin "iPlayer WWW" - primaeval - 2016-06-25

(2016-06-25, 20:43)irn|bru Wrote:
(2016-06-25, 20:20)primaeval Wrote: Excellent!...
Wait a min... are you getting audio from the feeds? Unless I'm going crazy, I had audio now don't have any. Maybe it's not a fix yet. Damn. Will keep testing and leave a feed running to see if it comes back or if I really am going crazy.

By the way, I found the feed by looking at the links that do work against the links that don't. Noticed the change in the URL and decided to see if it works with the HQ ones.

Quick Edit: I know what's wrong. The 24000 bit needs the matching audio bitrate. Will find it in a sec. (unless you have it already. just needs a figure for an HQ feed that does work)

EDIT 2:
OK, the pa part has to be 4 and the audio 128000. So it's pa4=128000 I must have had a different audio feed in my m3u8 when testing. Sorry. This link is definitely working as planned:
Code:
http://ve-hds-uk-live.bbcfmt.vo.llnwd.net/pool_41/live/uk/sport_stream_10/sport_stream_10.isml/sport_stream_10-pa4=128000-video=5070000.m3u8

That seems to work. There's some nice saxophone on that channel right now. Smile


RE: New plugin "iPlayer WWW" - irn|bru - 2016-06-25

(2016-06-25, 21:02)primaeval Wrote: That seems to work. There's some nice saxophone on that channel right now. Smile

I'm glad you have it working too. I honestly thought I was going crazy! I have your beta repo installed by the way. That's when I noticed there was no sound when I tried it. Big Grin Happy it's fixed because it has been annoying me as I couldn't get those m3u8's to work.

EDIT:
Just to let you know that the pa change is only for the 2908 and 5166kbps feeds. I no longer have audio on the lower bitrate feeds so I'm guessing you changed the pa part for ALL red button feeds? Just wanted to clarify.


RE: New plugin "iPlayer WWW" - primaeval - 2016-06-25

(2016-06-25, 21:07)irn|bru Wrote:
(2016-06-25, 21:02)primaeval Wrote: That seems to work. There's some nice saxophone on that channel right now. Smile

I'm glad you have it working too. I honestly thought I was going crazy! I have your beta repo installed by the way. That's when I noticed there was no sound when I tried it. Big Grin Happy it's fixed because it has been annoying me as I couldn't get those m3u8's to work.

I was testing it without my headphones on so I didn't notice it either. doh Smile

I've been looking for an epg for the Red Button streams if you come across them. The first one comes up with in my "TV Listings" addon from tvguide.co.uk but the others are empty. Its a long way behind the "TV Listings (xmltv)" in terms of functionality but has that Red Button 1 schedule built in.


RE: New plugin "iPlayer WWW" - irn|bru - 2016-06-25

(2016-06-25, 21:13)primaeval Wrote: I was testing it without my headphones on so I didn't notice it either. doh Smile

I've been looking for an epg for the Red Button streams if you come across them. The first one comes up with in my "TV Listings" addon from tvguide.co.uk but the others are empty. Its a long way behind the "TV Listings (xmltv)" in terms of functionality but has that Red Button 1 schedule built in.
Oops...

I haven't seen one but I'll be sure to give you a shout if I do. By the way, did you see the edit in my previous post about the pa part change and that its only for the 5.2 and 2.9Mbps feeds? I no longer have audio for the lesser quality feeds so I'm guessing you changed the part for all of them?


RE: New plugin "iPlayer WWW" - primaeval - 2016-06-25

I did a regex on the whole pattern so it doesn't touch the lower bitrates.
There's a new version 2.3.2p3 in the repo now which works on all the streams for me now.
We still need to find the manifest for the m3u8 files so that it can pick the right ones without having to do this fix, if it exists.


RE: New plugin "iPlayer WWW" - irn|bru - 2016-06-25

(2016-06-25, 21:25)primaeval Wrote: I did a regex on the whole pattern so it doesn't touch the lower bitrates.
There's a new version 2.3.2p3 in the repo now which works on all the streams for me now.
We still need to find the manifest for the m3u8 files so that it can pick the right ones without having to do this fix, if it exists.
Cool, yeah I noticed the update and it too works for me so thank you. In regards to the manifest, does this help any:
Code:
2.9Mbps - http://ve-hds-uk-live.bbcfmt.vo.llnwd.net/pool_11/live/uk/sport_stream_01/sport_stream_01.isml/sport_stream_01-pa4=128000-video=2812000.f4m
5.2Mbps - http://ve-hds-uk-live.bbcfmt.vo.llnwd.net/pool_11/live/uk/sport_stream_01/sport_stream_01.isml/sport_stream_01-pa4=128000-video=5070000.f4m
Is that what you mean? Those don't appear in the main manifest file though:
Code:
http://a.files.bbci.co.uk/media/live/manifesto/audio_video/webcast/hds/uk/pc/llnw/sport_stream_01.f4m
...just the links that don't work without the pa fix.

Maybe we should tell the BBC they need to update their main manifest file!


RE: New plugin "iPlayer WWW" - primaeval - 2016-06-25

(2016-06-25, 21:42)irn|bru Wrote:
(2016-06-25, 21:25)primaeval Wrote: I did a regex on the whole pattern so it doesn't touch the lower bitrates.
There's a new version 2.3.2p3 in the repo now which works on all the streams for me now.
We still need to find the manifest for the m3u8 files so that it can pick the right ones without having to do this fix, if it exists.
Cool, yeah I noticed the update and it too works for me so thank you. In regards to the manifest, does this help any:
Code:
2.9Mbps - http://ve-hds-uk-live.bbcfmt.vo.llnwd.net/pool_11/live/uk/sport_stream_01/sport_stream_01.isml/sport_stream_01-pa4=128000-video=2812000.f4m
5.2Mbps - http://ve-hds-uk-live.bbcfmt.vo.llnwd.net/pool_11/live/uk/sport_stream_01/sport_stream_01.isml/sport_stream_01-pa4=128000-video=5070000.f4m
Is that what you mean? Those don't appear in the main manifest file though:
Code:
http://a.files.bbci.co.uk/media/live/manifesto/audio_video/webcast/hds/uk/pc/llnw/sport_stream_01.f4m
...just the links that don't work without the pa fix.

Maybe we should tell the BBC they need to update their main manifest file!

In the code we read the f4m manifesto and cheat by converting the f4m links to m3u8 links. It used to work, until this week.
Here is a little script that runs through all the possible ways of getting the streams that we know of. There isn't one that finds the Red Button streams directly but that is what we are looking for. Our Glastonbury holy grail. Wink
https://gist.github.com/primaeval/276a3965194a8ee167a6