tgorgdotcom / locast2plex

A very simple script to connect locast to Plex's live tv/dvr feature.
MIT License
231 stars 43 forks source link

Any way to 'favorite' or remove channels from the lineup? #143

Open eqpaisley opened 3 years ago

eqpaisley commented 3 years ago

Love this script and have it working well (with Jellyfin). But (in New York at least) Locast sends LOADS of channels from religious stuff to home shopping to digital stations I have no interest in that clutter up my interface. Is there a way to remove channels or FAVORITE channels?

tgorgdotcom commented 3 years ago

Hmmmm. I would have thought Jellyfin had some kind of way to disable channels, like Plex, but I guess not? It's definitely something we can consider. Is anyone else interested in this feature?

eqpaisley commented 3 years ago

Hmmmm. I would have thought Jellyfin had some kind of way to disable channels, like Plex, but I guess not? It's definitely something we can consider. Is anyone else interested in this feature?

It might have this ability with a regular HDHR tuner (not sure) but I have to add the locast2plex tuner via the loopback IP. Ty for considering and (again) thanks for this great script.

charlyc11 commented 3 years ago

That would be a great feature. Thanks

eqpaisley commented 3 years ago

When I navigate to:

http://127.0.0.1:6077/lineup.xml

I see the channel line up. Is this XML file editable? Could I do the work of removing the channels I don't want right here? Or will the locast2plex tuner repopulate/rewrite this file based on what's coming in from Locast?

tgorgdotcom commented 3 years ago

@eqpaisley Unfortunately no. Your assumption is correct -- every so often we regenerate the XML. Also the m3u file is auto generated. I would probably need to add a config setting to skip certain channels.

eqpaisley commented 3 years ago

@eqpaisley Unfortunately no. Your assumption is correct -- every so often we regenerate the XML. Also the m3u file is auto generated. I would probably need to add a config setting to skip certain channels.

A config would be an enhancement and a little convenience but the script works beautifully without. Kind of comes down to how much of a hassle it is to add and how much time you've got. Regardless, I'm appreciative of the work you've already done. Thanks!

deathbybandaid commented 3 years ago

I recently added a page to the fHDHR web interface for managing channels.

I added the ability to remap the channel numbers, change the names and callsigns as well as disable individual channels.

image

@tgorgdotcom I'd suggest you look at using a basic sqlite database to store per-channel settings in

deathbybandaid commented 3 years ago

@tgorgdotcom I'm also looking at some hdhomerun forums and they have an api endpoint that I think we are already partially using already:

Screenshot_20201128-171004_Firefox

deathbybandaid commented 3 years ago

Also copy-pasting from another internet location

There is another URL that can be used to set a channel as a favorite: method: POST http://deviceip:80/lineup.post?favorite=value where value = +4.1 (to set favorite) x4.1 (to disable) -4.1 (to unset favorite)

Once this is done, a channel lineup JSON can include a "Favorite" field: [ { "GuideNumber": "4.1", "GuideName": "WCMH-DT", "HD": 1, "Favorite": 1, "URL": "http://192.168.1.111:5004/auto/v4.1" }, { "GuideNumber": "4.2", "GuideName": "MeTV", "URL": "http://192.168.1.111:5004/auto/v4.2" }, ... ]

If it has been disabled, it will not appear in lineup.json. However, it will appear in /lineup.json?show=found with a new property "Enabled": 0

so I believe that

ip:port/lineup.post?favorite= +,-,x channel_number

would be the proper syntax for an api call

aram535 commented 3 years ago

Just found your repo, this is fantastic. Came here to add this an enhancement request. If you accept PRs, I can help.

deathbybandaid commented 3 years ago

@aram535 this is a feature built into fHDHR since November. Until Locast2Plex starts using a database and a web interface, channel management will be incredibly difficult.

fHDHR recently went under some heavy changes to convert it into a plugin system, allowing more flexibility. fHDHR also is not dependant on ffmpeg (for all but 2 plugins). If you need advanced channel management, that would be the way to go.

https://github.com/fHDHR/fHDHR

tgorgdotcom commented 3 years ago

fHDHR is definitely an option, but I do gladly accept pull requests too :)

kingstonwa commented 3 years ago

I have locast2plex installed on my Qnap as a container, how to I check which version that is running/installed of locast2plex?