PDA

View Full Version : [ABM-DVB-S/S2] Channel Number Hack plus HD Swap



danm14
26-07-16, 15:25
Hi,

I'm using the Sky UK London Custom region, and the channel number hack in CustomMix.xml file. Is there any way to get the channel number hack to name the channels as "101 - BBC One HD, 102 - BBC Two HD, 103 - ITV HD etc" instead of "115 - BBC One HD, 141 - BBC Two HD, 178 - ITV HD etc".

I've tried swapping with the normal swap in the provider file; swapping by inserting and removing in CustomMix and swapping by changing CustomLCN, but the channel number hack still shows the original channel numbers (115, 141, 178 etc instead of 101, 102, 103 etc)

Thanks

Huevos
26-07-16, 15:36
You need to switch off swap and do it in the CustomMix file.

I'll post how in a while.

danm14
26-07-16, 15:40
I've tried
<insert provider="sat_282_sky_uk" source="115" target="101"></insert> and <delete target="115"></delete> etc
but that doesn't work, the channels do swap but the numbers are still wrong, is this what you're saying I should do, or is it something different?

Huevos
26-07-16, 20:12
Put the .pyo files in /usr/lib/enigma2/python/Plugins/SystemPlugins/AutoBouquetsMaker/scanner

Put the .xml in /usr/lib/enigma2/python/Plugins/SystemPlugins/AutoBouquetsMaker/custom

Swap channels = yes

@dsayers, see if this works with your Sky/VM mix.

danm14
26-07-16, 20:43
Yes, this works perfectly, thanks Huevos!
If I want to delete the SD versions of these channels (have 115 blank instead of being BBC One SD etc) is it just a matter of <delete>ing these in CustomMix.xml?

Also, I assume I'll have to keep replacing the pyo files every time there's an update for ABM - is there any way to stop the files from being replaced during update?

Huevos
26-07-16, 21:24
I assume I'll have to keep replacing the pyo files every time there's an update for ABM - is there any way to stop the files from being replaced during update?No you wont have to keep updating the .pyo files.


If I want to delete the SD versions of these channels (have 115 blank instead of being BBC One SD etc) is it just a matter of <delete>ing these in CustomMix.xml?No it is not that simple. The logic of swap is both ends of the swap exist and the promoted channel is HD.

If you want to go down that path you need to forget using swap and create your own.

danm14
26-07-16, 21:51
No you wont have to keep updating the .pyo files.

No it is not that simple. The logic of swap is both ends of the swap exist and the promoted channel is HD.

If you want to go down that path you need to forget using swap and create your own.

Where would you start in doing that? Is it possible to remove a channel from, say, channel 101, and replace it with another channel?

Huevos
26-07-16, 21:59
So BBC One HD is at 101 and 115 is empty?

danm14
26-07-16, 22:02
Exactly, and so the channel number hack calls it "101 BBC One HD" and not "115 BBC One HD".

simono5
26-07-16, 22:23
Can anyone pull together a guide on how to set this up please?

danm14
26-07-16, 22:36
I'll happily make a stab at it - I just need to find a way to remove a given channel from a channel number, and put it on another channel number.
It's possible to blacklist "a channel number" or "a channel" - ie remove whatever channel is on 101, or remove BBC One HD from wherever it is.

If I blacklist "101", I can't put BBC One HD there, because no matter what channel is on 101, it's deleted.
If I blacklist "BBC One HD", I can't put it on 101, because no matter where BBC One HD is, it's deleted.

I can't do anything on the Virgin side, simono5, as I have no access to cable.

Huevos
26-07-16, 23:09
Try this.


<custommix>
<hacks>
<![CDATA[

if "swapchannels" in providers[section_identifier] and len(providers[section_identifier]["swapchannels"]) > 0 and "preferred_order" in providers[section_identifier]["swapchannels"][0]:
for swaprule in providers[section_identifier]["swapchannels"][0]["preferred_order"]:
if swaprule[0] in services[section_identifier]["video"] and swaprule[1] in services[section_identifier]["video"] and services[section_identifier]["video"][swaprule[1]]["service_type"] >= 17:
customised["video"][swaprule[0]] = customised["video"][swaprule[1]]
customised["video"][swaprule[0]]["number"] = swaprule[0]
del customised["video"][swaprule[1]]

for service in sorted(customised["video"].keys()):
if service in range(1,1000):
if "interactive_name" in customised["video"][service]:
customised["video"][service]["interactive_name"] = str(customised["video"][service]["number"]) + " - " + customised["video"][service]["interactive_name"]
else:
customised["video"][service]["interactive_name"] = str(customised["video"][service]["number"]) + " - " + customised["video"][service]["service_name"]

]]>

</hacks>
</custommix>

danm14
26-07-16, 23:18
Exactly what I wanted, Huevos! I owe you a pint or two some day!

Huevos
26-07-16, 23:44
Can anyone pull together a guide on how to set this up please?
A guide on setting what up? Please be specific.

dsayers
26-07-16, 23:55
Put the .pyo files in /usr/lib/enigma2/python/Plugins/SystemPlugins/AutoBouquetsMaker/scanner

Put the .xml in /usr/lib/enigma2/python/Plugins/SystemPlugins/AutoBouquetsMaker/custom

Swap channels = yes

@dsayers, see if this works with your Sky/VM mix.

Thanks I'll try after work or over the weekend

dsayers
27-07-16, 06:53
its worked for the sky channels but the vm channels are still showing the vm channel numbers not sky that i want

49091
and some of the sky sd channels are wrong ie gold is correct 110 and universal is wrong 204
49092

dsayers
27-07-16, 07:06
here is my custommix.xml and debuglog
49093

Huevos
27-07-16, 10:30
Ok. Problem is nothing to do with swap. I'll post a solution later.

simono5
27-07-16, 11:20
A guide on setting what up? Please be specific.

Apologies, I've interpreted this post as a way of adding channel numbers into the EPG? If correct I'd appreciate a 'how to' guide on how I can set this up on my Solo2.

Thanks

dsayers
27-07-16, 14:36
Apologies, I've interpreted this post as a way of adding channel numbers into the EPG? If correct I'd appreciate a 'how to' guide on how I can set this up on my Solo2.

Thanks

Look at post 4

danm14
27-07-16, 16:11
Try this.


<custommix>
<hacks>
<=!=[=C=D=A=T=A=[

if "swapchannels" in providers[section_identifier] and len(providers[section_identifier]["swapchannels"]) > 0 and "preferred_order" in providers[section_identifier]["swapchannels"][0]:
for swaprule in providers[section_identifier]["swapchannels"][0]["preferred_order"]:
if swaprule[0] in services[section_identifier]["video"] and swaprule[1] in services[section_identifier]["video"] and services[section_identifier]["video"][swaprule[1]]["service_type"] >= 17:
customised["video"][swaprule[0]] = customised["video"][swaprule[1]]
customised["video"][swaprule[0]]["number"] = swaprule[0]
del customised["video"][swaprule[1]]

for service in sorted(customised["video"].keys()):
if service in range(1,1000):
if "interactive_name" in customised["video"][service]:
customised["video"][service]["interactive_name"] = str(customised["video"][service]["number"]) + " - " + customised["video"][service]["interactive_name"]
else:
customised["video"][service]["interactive_name"] = str(customised["video"][service]["number"]) + " - " + customised["video"][service]["service_name"]

]=]=>

</hacks>
</custommix>

Is it possible to add exceptions to this, for example if I want to keep BBC One SD for local news, but still have BBC One HD on 101?

dsayers
27-07-16, 16:42
Sorry miss read post

simono5
27-07-16, 17:39
This works great. I have a main custom bouquet but these don't include the channel numbers. Is this possible?

Huevos
27-07-16, 19:18
Is it possible to add exceptions to this, for example if I want to keep BBC One SD for local news, but still have BBC One HD on 101?Yes, just swap the pair using inserts.

Huevos
27-07-16, 19:26
its worked for the sky channels but the vm channels are still showing the vm channel numbers not sky that i want Try this...

dsayers
27-07-16, 20:28
Thanks I'll will in the morning after work

simono5
27-07-16, 23:20
This works great. I have a main custom bouquet but these don't include the channel numbers. Is this possible?

Recreating the bouquet using DreamBoxEdit has sorted this.

dsayers
28-07-16, 06:23
Try this...

That works great thank you.

dsayers
29-07-16, 08:59
No you wont have to keep updating the .pyo files.



have you uploaded the py files to github? im thinking of upgrading now i can get past v4.1.010 using channel numbers and noticed you've edited the same py files in the zipfile to github

Huevos
29-07-16, 17:19
Yes, .py files pushed. Will be in next build.