Hello Guest, if you are reading this it means you have not registered yet. Please take a second, Click here to register, and in a few simple steps you will be able to enjoy our community and use our OpenViX support section.
Results 1 to 2 of 2

Thread: ABM Hacks Examples by Huevos

  1. #1

    Title
    Forum Supporter
    Donated Member
    Join Date
    Jan 2015
    Location
    Stafford
    Posts
    846
    Thanks
    202
    Thanked 170 Times in 151 Posts

    ABM Hacks Examples by Huevos

    Two hacks posted - ITV Regions and Timeshift when upzipped have the same name - sat_282_sky_uk_CustomMix.xml so when placed in /usr/lib/enigma2/python/Plugins/SystemPlugins/AutoBouquetsMaker/custom as instructed one overwrites the other. Or have I mis-understood (as usual)
    VU+ Solo2 HDD Harmony 650 remote
    Mutant HD51 4K
    VU+ Zero
    Edision OS MINI

  2. #2
    Huevos's Avatar
    Title
    Administrator
    Join Date
    Jun 2010
    Location
    38.5N, 0.5W
    Posts
    13,632
    Thanks
    2,007
    Thanked 4,956 Times in 3,276 Posts
    They are just examples. So each file only does one thing. To use both you would have to combine them in one file. The order you combine them will dictate the order of the bouquets.

    Something like this.
    Code:
    <custommix>
    	<hacks>
    <![CDATA[
    
    # Make ITV regions bouquet
    
    ITVs = []
    ITVsPlusOne = []
    rest = []
    last_section = max(sections.keys())
    last_section_name = sections[last_section]
    
    for service in sorted(services["sat_282_sky_uk"]["video"].keys()):
    	if service in range(last_section, 1450) or service in [103, 133, 178]:
    		# ITV regions
    		if 'interactive_name' in services["sat_282_sky_uk"]["video"][service] and (service in [103,178] or (service in range(last_section, 1450) and '+1' not in services["sat_282_sky_uk"]["video"][service]["interactive_name"] and ('ITV' in services["sat_282_sky_uk"]["video"][service]["interactive_name"] or 'STV' in services["sat_282_sky_uk"]["video"][service]["interactive_name"] or 'UTV' in services["sat_282_sky_uk"]["video"][service]["interactive_name"]))):
    			ITVs.append(services["sat_282_sky_uk"]["video"][service])
    			
    		# ITV +1 regions
    		elif 'interactive_name' in services["sat_282_sky_uk"]["video"][service] and (service in [133] or (service in range(last_section, 1450) and '+1' in services["sat_282_sky_uk"]["video"][service]["interactive_name"] and ('ITV' in services["sat_282_sky_uk"]["video"][service]["interactive_name"] or 'STV' in services["sat_282_sky_uk"]["video"][service]["interactive_name"] or 'UTV' in services["sat_282_sky_uk"]["video"][service]["interactive_name"]))):
    			ITVsPlusOne.append(services["sat_282_sky_uk"]["video"][service])
    		
    		else:
    			rest.append(services["sat_282_sky_uk"]["video"][service])
    
    i = last_section
    sections[i] = "ITV Regions"
    
    sort_list = []
    for x in ITVs:
    	sort_list.append((x, re.sub('^(?![a-z])', 'zzzzz', x['interactive_name'].lower())))
    sort_list = sorted(sort_list, key=lambda listItem: listItem[1])
    for service in sort_list:
    	customised["video"][i] = service[0]
    	i += 1
    			
    sort_list = []
    for x in ITVsPlusOne:
    	sort_list.append((x, re.sub('^(?![a-z])', 'zzzzz', x['interactive_name'].lower())))
    sort_list = sorted(sort_list, key=lambda listItem: listItem[1])
    for service in sort_list:
    	customised["video"][i] = service[0]
    	i += 1
    		
    sections[i] = last_section_name	
    sort_list = []
    for x in rest:
    	sort_list.append((x, re.sub('^(?![a-z])', 'zzzzz', x['service_name'].lower())))
    sort_list = sorted(sort_list, key=lambda listItem: listItem[1])
    for service in sort_list:
    	customised["video"][i] = service[0]
    	i += 1
    	
    ############################################################################################
    
    # make a timeshift bouquet
    
    timeshift = []
    rest = []
    last_section = max(sections.keys())
    last_section_name = sections[last_section]
    
    for service in sorted(services["sat_282_sky_uk"]["video"].keys()):
    	if service in range(last_section, 1450):
    		rest.append(services["sat_282_sky_uk"]["video"][service])
    	elif service < 1000 and ("+1" in services["sat_282_sky_uk"]["video"][service]["service_name"] or "+2" in services["sat_282_sky_uk"]["video"][service]["service_name"]):
    		timeshift.append(services["sat_282_sky_uk"]["video"][service])
    		
    i = last_section
    sections[i] = "Timeshift"
    
    sort_list = []
    for x in timeshift:
    	sort_list.append((x, re.sub('^(?![a-z])', 'zzzzz', x['service_name'].lower())))
    sort_list = sorted(sort_list, key=lambda listItem: listItem[1])
    for service in sort_list:
    	customised["video"][i] = service[0]
    	i += 1
    
    sections[i] = last_section_name	
    sort_list = []
    for x in rest:
    	sort_list.append((x, re.sub('^(?![a-z])', 'zzzzz', x['service_name'].lower())))
    sort_list = sorted(sort_list, key=lambda listItem: listItem[1])
    for service in sort_list:
    	customised["video"][i] = service[0]
    	i += 1
    			
    ]]>
    	</hacks>
    </custommix>
    Help keep OpenViX servers online.Please donate!

  3. The Following User Says Thank You to Huevos For This Useful Post:

    Willmoore (09-08-15)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
This website uses cookies
We use cookies to store session information to facilitate remembering your login information, to allow you to save website preferences, to personalise content and ads, to provide social media features and to analyse our traffic. We also share information about your use of our site with our social media, advertising and analytics partners.