Jump to content

New project: locast2dvr


wouterdebie

Recommended Posts

When I was testing this I was changing the DMA quite a lot so maybe that did in fact trigger a cut off. I suppose if you are just using one DMA all the time it won't be changing. This kind of thing would be cool if you moved from Phila to LA but wanted to watch your home town sports teams.

Link to comment
Share on other sites

wouterdebie

I'm in New Orleans, but there's no locast available here yet. Most Saints games are broadcast on the other regions, so this is ideal for me.

I also noticed that your dma only gets updated when you actually stream from a different dma, not anything else. Of all the calls to locast, only retrieving the actual stream url requires to add dma information. After that it's unauthenticated requests to CDNs.

Link to comment
Share on other sites

10 hours ago, wouterdebie said:

I'm in New Orleans, but there's no locast available here yet. Most Saints games are broadcast on the other regions, so this is ideal for me.

I also noticed that your dma only gets updated when you actually stream from a different dma, not anything else. Of all the calls to locast, only retrieving the actual stream url requires to add dma information. After that it's unauthenticated requests to CDNs.

Well you have about 8 months to get this setup to watch the Saints. :)

That good info on the under workings of when/how it does the check.

Link to comment
Share on other sites

all4dom

Is this hard to setup? I'm interested in setting up since I can get locast in my area. I pay for a small streaming package from spectrum & would live to cancel that.....hell I would love to cancel spectrum cable also but that's not until 5g comes. In my area I'm too far to get OTA.

Link to comment
Share on other sites

wouterdebie

Using and installing locast2dvr is pretty straight forward:

  • `pip install locast2dvr`
  • modify the config file
  • run `locast2dvr --config config_file`
  • Add locast2dvr to emby both as a tuner and epg.
Link to comment
Share on other sites

mlcarson

It's nice that locast2dvr can grab an EPG from locast but with Emby, I think you're better using the Emby guide data from the city's OTA source unless a channel is missing.   With Plex or Jellyfin, I'd use the guide data locast2dvr. 

Link to comment
Share on other sites

wouterdebie
9 minutes ago, mlcarson said:

It's nice that locast2dvr can grab an EPG from locast but with Emby, I think you're better using the Emby guide data from the city's OTA source unless a channel is missing.   With Plex or Jellyfin, I'd use the guide data locast2dvr. 

Why is that? I started out with picking the OTA source, but it didn't work well. Channel mappings are somewhat difficult sometimes. Locast provides most of the data necessary afaik, so why not use it?

Link to comment
Share on other sites

Because Emby guide data is rich and full.  Besides just the GUIDE page things like program page really benefit from it.
Also upcoming in Emby Server 4.6 is the ability to switch logos based on these as well for both light and dark icons that work in any theme.  Here is how logos look on the CHANNEL page.

image.png

image.png

Lots of little reason why using Emby guide data in the US will likely be better.
PS what you see above isn't in the beta yet but is coming in the next beta.

Edited by cayars
Link to comment
Share on other sites

3 hours ago, wouterdebie said:

Why is that? I started out with picking the OTA source, but it didn't work well. Channel mappings are somewhat difficult sometimes. Locast provides most of the data necessary afaik, so why not use it?

Why can't you use the locast guide data? Is it xmltv format? You should have no trouble using it if that's what you want.

Link to comment
Share on other sites

They can surely use it but it doesn't compare to Emby Guide data.

It's not just about what you see in the guide itself but how Emby consumes and uses this data in searches or even the Program tab.

The built in data is much more extensive in use so given a choice, use the Emby Guide data. :)

Link to comment
Share on other sites

Sorry I misread that as user saying the locast data wasn't working with Emby. Yes you're right. It should work fine, but Emby Guide data will likely be better.

Link to comment
Share on other sites

emveepee

Locast uses TMS too Only one week but as xmltv goes it is very rich

  <programme start="20210113000000 +0000" stop="20210113003000 +0000" channel="32619.locast.org">
    <title>The Big Bang Theory</title>
    <sub-title>The Parking Spot Escalation</sub-title>
    <desc>Sheldon and Wolowitz's fight over a parking spot at the university impacts the whole gang.</desc>
    <credits>
      <director>Peter Chakos</director>
      <actor>Johnny Galecki</actor>
      <actor>Jim Parsons</actor>
      <actor>Kaley Cuoco</actor>
    </credits>
    <date>20121129</date>
    <category>Sitcom</category>
    <icon src="https://fans.tmsimg.com/assets/p9264952_b_v5_aa.jpg"/>
    <episode-num system="xmltv_ns">5.8.</episode-num>
    <episode-num system="dd_progid">EP009311820125</episode-num>
    <previously-shown start="20121129"/>
    <rating system="VCHIP">
      <value>TV14</value>
    </rating>
  </programme>

Martin

Link to comment
Share on other sites

11 minutes ago, emveepee said:

Locast uses TMS too Only one week but as xmltv goes it is very rich

  <programme start="20210113000000 +0000" stop="20210113003000 +0000" channel="32619.locast.org">
    <title>The Big Bang Theory</title>
    <sub-title>The Parking Spot Escalation</sub-title>
    <desc>Sheldon and Wolowitz's fight over a parking spot at the university impacts the whole gang.</desc>
    <credits>
      <director>Peter Chakos</director>
      <actor>Johnny Galecki</actor>
      <actor>Jim Parsons</actor>
      <actor>Kaley Cuoco</actor>
    </credits>
    <date>20121129</date>
    <category>Sitcom</category>
    <icon src="https://fans.tmsimg.com/assets/p9264952_b_v5_aa.jpg"/>
    <episode-num system="xmltv_ns">5.8.</episode-num>
    <episode-num system="dd_progid">EP009311820125</episode-num>
    <previously-shown start="20121129"/>
    <rating system="VCHIP">
      <value>TV14</value>
    </rating>
  </programme>

Martin

Yea that looks pretty good.

Link to comment
Share on other sites

wouterdebie
46 minutes ago, emveepee said:

Locast uses TMS too Only one week but as xmltv goes it is very rich

  <programme start="20210113000000 +0000" stop="20210113003000 +0000" channel="32619.locast.org">
    <title>The Big Bang Theory</title>
    <sub-title>The Parking Spot Escalation</sub-title>
    <desc>Sheldon and Wolowitz's fight over a parking spot at the university impacts the whole gang.</desc>
    <credits>
      <director>Peter Chakos</director>
      <actor>Johnny Galecki</actor>
      <actor>Jim Parsons</actor>
      <actor>Kaley Cuoco</actor>
    </credits>
    <date>20121129</date>
    <category>Sitcom</category>
    <icon src="https://fans.tmsimg.com/assets/p9264952_b_v5_aa.jpg"/>
    <episode-num system="xmltv_ns">5.8.</episode-num>
    <episode-num system="dd_progid">EP009311820125</episode-num>
    <previously-shown start="20121129"/>
    <rating system="VCHIP">
      <value>TV14</value>
    </rating>
  </programme>

Martin

Where do you get that xmltv from?

Link to comment
Share on other sites

emveepee

I create it with my addon for another PVR (direct play no HDHR emulation needed).  I suspect if Locast isn't shutdown, Locast could  all but kill off ATSC tuners for the normal user who doesn't care about 5:1 audio or highest quality video.   I read they have 2 million subscribers right now.  Everything pre transcoded to h264/aac makes it perfect for home situations.  

I do fell that developers who actively support breaking the geo-fence do everyone more harm then good especially with the Locast plan to roll out US-wide.

Martin

Link to comment
Share on other sites

mlcarson
4 hours ago, emveepee said:

I create it with my addon for another PVR (direct play no HDHR emulation needed).  I suspect if Locast isn't shutdown, Locast could  all but kill off ATSC tuners for the normal user who doesn't care about 5:1 audio or highest quality video.   I read they have 2 million subscribers right now.  Everything pre transcoded to h264/aac makes it perfect for home situations.  

I do fell that developers who actively support breaking the geo-fence do everyone more harm then good especially with the Locast plan to roll out US-wide.

Martin

Even if they deploy nationwide, people are still going to want different DMA's since all DMA's are not created equal.   My DMA sucks but the adjacent one which includes LA is very rich in channels.   That's the TV industry though.   Protect the local stations at all cost and screw the consumers.  If the system worked for the consumer, any network that wasn't offered in the DMA should be available from any other DMA that offered it.   If a local station doesn't like it then provide the network in question and THEN it should be excluded from viewing in any other DMA.   Same arguments were being made by satellite TV providers for a long time but nothing obviously changed. 

Link to comment
Share on other sites

That's very true but what people want and what they are entitled to aren't always the same thing. :)

 

Link to comment
Share on other sites

32 minutes ago, cayars said:

That's very true but what people want and what they are entitled to aren't always the same thing. :)

 

I like that...

There is no such thing as a free lunch. Someone in some way is subsidize that free lunch. Live TV channels are allowed to protect their properties and assets when allowing consumption. This is called fair market. It is sustainable because there is revenue derived from those subscribers on premium tiers beyond what normal subscribers are paying. The DRM channels need that to protect the cable company from stealing from them as much as the cable company has to watch for you stealing from them. Those DRM channels are costing someone an arm and a leg to produce and pay for that content. Pay-per-View with some major fighters in the ring demands that high price. The fighters demand ridiculous pay checks consumers pay ridiculous PPV prices. Actors demand ridiculous salaries consumers will have to pay the price when watching. It is fair because you are only entitled to what you can pay. If it were any other way the model would not be sustainable.

Edited by speechles
  • Like 1
Link to comment
Share on other sites

mlcarson
6 hours ago, speechles said:

I like that...

There is no such thing as a free lunch. Someone in some way is subsidize that free lunch. Live TV channels are allowed to protect their properties and assets when allowing consumption. This is called fair market. It is sustainable because there is revenue derived from those subscribers on premium tiers beyond what normal subscribers are paying. The DRM channels need that to protect the cable company from stealing from them as much as the cable company has to watch for you stealing from them. Those DRM channels are costing someone an arm and a leg to produce and pay for that content. Pay-per-View with some major fighters in the ring demands that high price. The fighters demand ridiculous pay checks consumers pay ridiculous PPV prices. Actors demand ridiculous salaries consumers will have to pay the price when watching. It is fair because you are only entitled to what you can pay. If it were any other way the model would not be sustainable.

A free market is a fair market. If customers don't have the option of purchasing something that others do based on where they live, a black market will be created to fulfil the demand.   Or at the very least the controls designed to enforce the blockade will be circumvented.    What's the justification for denying access to purchase a service that simply isn't offered in a DMA?   It's easy to understand why an ABC from one DMA doesn't want to compete against an ABC from a different DMA but if ABC isn't offered by anybody in that DMA then nobody's right of exclusivity is being violated by allowing the purchase from where it is available.  The point is even harder to grasp when you realize that the channels in question are being broadcast OTA so are free where offered.  This was especially hard to stomach in the early days of HDTV where Canada was allowed to rebroadcast the USA broadcast networks nationwide in HD but it was illegal for American satellite providers to do the same.  It was also illegal for USA citizens within the Canadian satellite footprint to receive these channels; there's a bit of irony there in that the original transmissions were OTA and the satellite signal is also OTA.   I'm surprised lawsuits never happened to prevent antenna users from pointing their aerials at a neighboring DMA. 

Link to comment
Share on other sites

I'm going to play devils advocate to that but probably more like the devil himself. :)

There is nothing fair about a  free market.  It's all about supply and demand or price based on demand done in a legal manner.  A black market is by nature an illegal market.

A person selling the last 10 hot item Christmas toys at 10x price they acquired legally and own is part of a free market but there is nothing "fair" about the price.  A person selling 10 hot item Christmas toys at 10x that are stolen and not owned legally by them is black market and illegal with consequences if caught (buyer and seller).  So what you endorse with black market sales of stolen services is no different then a local thief robbing your house because what you have isn't fair to them so it's justified.

No one should be required to put up 10 foot walls or build a compound around their house to protect their possessions from theft.  The same goes for broadcast networks and DMA where the broadcasts are free ONLY because they sell advertising in those area or receive community funding.  When a company such as Locast is trying to abide by the same DMA as the broadcast signal it's for both the broadcaster and their protection.

The justification for denying access if you don't live in an area paying for the local service is that you have other methods to acquire the channels legally. That could be a cable or satellite subscription for example where part of your contract price does go back to the channels or networks since you're not in their "free" market.

If you want to watch sports teams in a different market you either pony up money for Sat/Cable subscription with a sports package or have property in that location to legally acquire it.

With the LETTER OF THE LAW out of the way you are correct in many respects.  People will circumvent DMA or sat/cable subscriptions and use illegal tv service they get on the cheap.  Some of this is just pure greed from these companies when $50 of a bill is just rental equipment.  One thing for sure, broadcast TV is slowly changing.  People don't watch conventional TV like they used to. Now people use Netflix, Prime, Hulu and other online giants as their main source of content.  Smart people like ourselves build our own entertainment system.

 

Link to comment
Share on other sites

@wouterdebie

I had to reboot my PC today and locast2DVR is now erroring on startup.

2021-01-29 23:40:55 - INFO - Facilities: Using cached file: C:\Users\username\.locast2dvr\facilities.zip
2021-01-29 23:40:55 - INFO - Facilities: Unzipping facilities...
Can't find FCC DMA for 862, Sacramento

I tried deleting the specified facilities.zip file and the error persisted.

2021-01-29 23:43:19 - INFO - Facilities: Downloading FCC facilities..
2021-01-29 23:43:23 - INFO - Facilities: Cached facilities at C:\Users\username\.locast2dvr\facilities.zip
2021-01-29 23:43:23 - INFO - Facilities: Unzipping facilities...
Can't find FCC DMA for 862, Sacramento

I have tried specifying an override zipdcode as well as an override latitude & longitude.  The error message is the same.

Anything going on with facilities.zip?

By the way, It doesn't matter what zipcode I enter, it always responds "Can't find FCC DMA for 862, Sacramento".

Edited by richt
Additional Info
Link to comment
Share on other sites

I worked on getting Locast2dvr on an old laptop for my Emby server, yesterday and today. Windows 10 and it wasn't a breeze. I have used python a bit before, so that wasn't it, the laptop made everything flaky. I installed  and uninstalled python 4 full times, and had problems with pip  and couldn't get any of it to work ... but then the nth time is the charm ... I could get it working, but I couldn't get it into Emby, using a laptop and not thinking right by the end of the day fighting this thing, I  would have just had to bind the ip to the machine it was on so I could get it to my server. Maybe.

All in all I also updated that laptop to the current version of Win 10 this morning. Once that finished I knew I had something good going to suddenly Windows firewall popped up and asked about the connection, when it hadn't done that at all for hours before in the same day and all day yesterday. 

It wasn't all the great though, in the end I finally got Emby to take my url as a homerun device. But then ffmpeg was throwing errors all over the place, what a nice look at the whole thing, nothing would play or record though, so ... I knew I wanted to use it as an m3u server but it just wasn't working, and after I deleted the homerun server, I tried and tried and tried and finally Emby took it and ran. Nice!

It's working sweet. I have a .bat file to quickly start it, and will make it a service soon probably. 

I have Youtube TV and I hate it. Locast is nice, just the local stuff from around here where I am, and further afield with just a little tweaking. Cool. It looks good in Emby, thanks for working on it.

I'm using Python 3.8 btw

 

Link to comment
Share on other sites

6 hours ago, wouterdebie said:

@richtWhich version are you running? What does your config look like and how are you starting locast2dvr? 

Don't see a version noted, however there is a dist folder "locast2dvr-0.4.16.dist-info".  Just to be sure I'm current I re-ran "pip install locast2dvr" and it shows "Requirement already satisfied" for locast2dvr at 0.4.16.  

My config file is as follows and I swap out override-zipcode and override-location

Quote

username="emailaddress@something.com"
password="Super_Secret!"
uid="NYC"
override-zipcode="11231"

I have attempted to start locast with either "locast2dvr --config c:\test\locastconfig.txt" or "locast2dvr -U email address@something.com -p Super_Secret! -u NYC" and the resilt is the same.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...