hello,
is it also possible to switch channels with this cool script??
This works, thank you!! On smartphone there is only one problem: you can’t see the full list, rather a small part is visible… is it possible to show more than 1-2 programs?? or maybe left and right arrow for zapping programs??
For those who get the authentication error. You will get this error if you did not activate the authentication in OpenWebIf.
Just change the line:
self.handle_base_auth()
to:
if self._password != DEFAULT_PASSWORD:
self.handle_base_auth()
Hi,
I have a problem with this…
I’ve made /home/homeasistant/.homeasistant/custom_components/media_player directory
I’ve pasted there enigma.py
changed:
DEFAULT_NAME = 'Enigma2 Satelite'
DEFAULT_PORT = 80
DEFAULT_TIMEOUT = None
DEFAULT_USERNAME = 'root'
DEFAULT_PASSWORD = 'password'
to
DEFAULT_NAME = ‘Enigma2 Satelite’
DEFAULT_PORT = 80
DEFAULT_TIMEOUT = None
DEFAULT_USERNAME = ‘root’
DEFAULT_PASSWORD = ‘My_root_passwrd’
added to configuration.yaml:
media_player:
- platform: enigma
host: My_tuner_ip
port: 23
username: root
password: My_root_password
and the problem is the HA is not starting ?!
Please help…
Thanks.
Works perfect, but I need to change:
bouquets_xml = self.request_call(’/web/bouquets’)
to
bouquets_xml = self.request_call(’/web/getservices’)
I’ve notice same thing…
Thank You @KavajNaruj for Your great work and if it’s possible please fix that…
Or maybe it’s on HA side ?
Hi there,
I tried to make KavajNaruj/homeassistant-enigma-player (08ec239) work.
Sadly I got this error:
2017-06-14 13:06:51 ERROR (MainThread) [homeassistant.components.media_player] Error while setting up platform enigma
Traceback (most recent call last):
File "/usr/local/lib/python3.4/dist-packages/homeassistant/helpers/entity_component.py", line 150, in _async_setup_platform
entity_platform.async_schedule_add_entities, discovery_info
File "/home/pi/.homeassistant/custom_components/media_player/enigma.py", line 52, in async_setup_platform
config.get(CONF_TIMEOUT))
File "/home/pi/.homeassistant/custom_components/media_player/enigma.py", line 77, in __init__
self.load_sources()
File "/home/pi/.homeassistant/custom_components/media_player/enigma.py", line 90, in load_sources
reference = urllib.parse.quote_plus(self.get_bouquet_reference())
File "/usr/lib/python3.4/urllib/parse.py", line 710, in quote_plus
string = quote(string, safe + space, encoding, errors)
File "/usr/lib/python3.4/urllib/parse.py", line 694, in quote
return quote_from_bytes(string, safe)
File "/usr/lib/python3.4/urllib/parse.py", line 719, in quote_from_bytes
raise TypeError("quote_from_bytes() expected bytes")
TypeError: quote_from_bytes() expected bytes
My config says following
media_player:
- platform: enigma
host: 192.168.178.61
My HA version is 0.46.1
I also tried it with username
and password
.
I can open my VU+ web with just the IP, I don’t have any credentials on internal requests.
Any ideas?
I tried setting this up last night with the same python file from @KavajNaruj but I was getting a differnt error Bad Request 400 at the end of the trace. I had already worked on a “switch” which enabled me to turn the box on and off as a basic switch using the command line function but would like to get the media component working as well
- platform: command_line
switches:
skybox:
command_on: "/usr/bin/curl -X GET http://192.168.0.2/web/powerstate?newstate=4"
command_off: "/usr/bin/curl -X GET http://192.168.0.2/web/powerstate?newstate=5"
command_state: "/usr/bin/curl -X GET http://192.168.0.2/web/powerstate"
value_template: >
{% if 'false' in value %}
true
{% else %}
false
{% endif %}
friendly_name: Sky
Hi, I finaly find some time to play with homeassistant and upgrade from 0.42 to 0.51 and I found my custom component broken. But fix is alredy on github! So could you please try it? @Craig86 @akentner @Borys_MB
Thanks @MrUart232 I dont now that authentication is not required.
To @hoary I have exactly same problem on smartphone, but it is a homeassistant issue.
To @cypo.sk web/bouquets return only favorites chanels and web/getservices return all, maybe I should to put some flag to configuration…
Working fine (and connecting without any issues)
Just be clear for anyone following the thread, use the latest code in the github link above, create a file and paste the code.
/custom_components/media_player/enigma.py
Then edit your configuration with
- platform: enigma
host: 192.168.0.XX
@KavajNaruj working good, only issue is under “Sources” I’m only seeing about 10/15 channels, the rest appears as whitespace
Has this channels special characters? And if yes, witch ones?
same issue here, but a full blank sources
error log:
2017-08-30 11:48:42 ERROR (MainThread) [homeassistant.helpers.entity] Update for media_player.zero fails
Traceback (most recent call last):
File “/srv/homeassistant/lib/python3.4/site-packages/homeassistant/helpers/entity.py”, line 225, in async_update_ha_state
yield from self.hass.async_add_job(self.update)
File “/usr/lib/python3.4/asyncio/futures.py”, line 388, in iter
yield self # This tells Task to wait for completion.
File “/usr/lib/python3.4/asyncio/tasks.py”, line 286, in _wakeup
value = future.result()
File “/usr/lib/python3.4/asyncio/futures.py”, line 277, in result
raise self._exception
File “/usr/lib/python3.4/concurrent/futures/thread.py”, line 54, in run
result = self.fn(*self.args, **self.kwargs)
File “/srv/homeassistant/lib/python3.4/site-packages/homeassistant/util/init.py”, line 306, in wrapper
result = method(*args, **kwargs)
File “/home/homeassistant/.homeassistant/custom_components/media_player/enigma.py”, line 123, in update
powerstate_xml = self.request_call(‘/web/powerstate’)
File “/home/homeassistant/.homeassistant/custom_components/media_player/enigma.py”, line 115, in request_call
return urllib.request.urlopen(uri, timeout=10).read().decode(‘UTF8’)
File “/usr/lib/python3.4/urllib/request.py”, line 153, in urlopen
return opener.open(url, data, timeout)
File “/usr/lib/python3.4/urllib/request.py”, line 455, in open
response = self._open(req, data)
File “/usr/lib/python3.4/urllib/request.py”, line 473, in _open
‘_open’, req)
File “/usr/lib/python3.4/urllib/request.py”, line 433, in _call_chain
result = func(*args)
File “/usr/lib/python3.4/urllib/request.py”, line 1202, in http_open
return self.do_open(http.client.HTTPConnection, req)
File “/usr/lib/python3.4/urllib/request.py”, line 1177, in do_open
r = h.getresponse()
File “/usr/lib/python3.4/http/client.py”, line 1172, in getresponse
response.begin()
File “/usr/lib/python3.4/http/client.py”, line 351, in begin
version, status, reason = self._read_status()
File “/usr/lib/python3.4/http/client.py”, line 313, in _read_status
line = str(self.fp.readline(_MAXLINE + 1), “iso-8859-1”)
File “/usr/lib/python3.4/socket.py”, line 371, in readinto
return self._sock.recv_into(b)
socket.timeout: timed out
No just standard channel names, some further down may have things like “ITV+1” but shouldn’t have anything other than space and +
I’m using the channel lis of Hans available here:
http://www.detransponder.nl/wp-content/uploads/2017/08/e2_hanssettings_9e_13e_19e_23e_28e_AND_rotating.zip
edit: i’m using a vuplus zero
Hi,
is this better, because i have openwebif on my vu+solo2 ?
thanks
by
kikan
NOT WORKING
tested with v.0.52.1
log file
2017-09-08 00:03:03 ERROR (MainThread) [homeassistant.components.media_player] Error while setting up platform enigma
Traceback (most recent call last):
File “/usr/lib/python3.6/site-packages/homeassistant/helpers/entity_component.py”, line 164, in _async_setup_platform
SLOW_SETUP_MAX_WAIT, loop=self.hass.loop)
File “/usr/lib/python3.6/asyncio/tasks.py”, line 352, in wait_for
return fut.result()
File “/usr/lib/python3.6/asyncio/futures.py”, line 244, in result
raise self._exception
File “/usr/lib/python3.6/asyncio/tasks.py”, line 179, in _step
result = coro.send(None)
File “/usr/lib/python3.6/asyncio/coroutines.py”, line 210, in coro
res = func(*args, **kw)
File “/config/custom_components/media_player/enigma.py”, line 53, in async_setup_platform
config.get(CONF_TIMEOUT))
File “/config/custom_components/media_player/enigma.py”, line 79, in init
self.load_sources()
File “/config/custom_components/media_player/enigma.py”, line 92, in load_sources
reference = urllib.parse.quote_plus(self.get_bouquet_reference())
File “/config/custom_components/media_player/enigma.py”, line 108, in get_bouquet_reference
soup = BeautifulSoup(bouquets_xml, ‘html.parser’)
File “/usr/lib/python3.6/site-packages/bs4/init.py”, line 192, in init
elif len(markup) <= 256 and (
TypeError: object of type ‘bool’ has no len()
i’m having some trouble with this too.
I can confirm that the component is working with “BlackHole” Firmware, but i’m not a big fan of that one.
I have it on one of my receivers, and it’s working NP.
But now i’ve installed “VTi” Firmware instead on my bedroom box, and i’m not able to control it anymore.
Log says:
2017-09-10 18:26:03 INFO (MainThread) [homeassistant.components.media_player] Setting up media_player.enigma
2017-09-10 18:26:04 ERROR (MainThread) [homeassistant.components.media_player] Error while setting up platform enigma
Traceback (most recent call last):
File “/usr/src/app/homeassistant/helpers/entity_component.py”, line 164, in _async_setup_platform
SLOW_SETUP_MAX_WAIT, loop=self.hass.loop)
File “/usr/local/lib/python3.6/asyncio/tasks.py”, line 358, in wait_for
return fut.result()
File “/usr/local/lib/python3.6/asyncio/futures.py”, line 245, in result
raise self._exception
File “/usr/local/lib/python3.6/asyncio/tasks.py”, line 180, in _step
result = coro.send(None)
File “/usr/local/lib/python3.6/asyncio/coroutines.py”, line 210, in coro
res = func(*args, **kw)
File “/config/custom_components/media_player/enigma.py”, line 53, in async_setup_platform
config.get(CONF_TIMEOUT))
File “/config/custom_components/media_player/enigma.py”, line 79, in init
self.load_sources()
File “/config/custom_components/media_player/enigma.py”, line 92, in load_sources
reference = urllib.parse.quote_plus(self.get_bouquet_reference())
File “/config/custom_components/media_player/enigma.py”, line 108, in get_bouquet_reference
soup = BeautifulSoup(bouquets_xml, ‘html.parser’)
File “/config/deps/lib/python3.6/site-packages/bs4/init.py”, line 192, in init
elif len(markup) <= 256 and (
Can anyone with the brains and the skills firgure out what’s causing this? And maybe help a m8 out to figure out how i can use my beloved VTi firmware instead of being locked to a firmware i dont like to get the features…
To get the VTi firmware, you’ll be able to download it from here https://www.vuplus-support.org/ after signing up and/or in.
BlackHole (wich is working for this component) can be downlaoded from here: http://www.sat-universe.com/
I really hope someone can help out here
EDIT: I’ve also just tried flashing the OpenVIX firmware. This works too: http://www.openvix.co.uk
i Change in enigma.py on line 106 the api Funktion off openweb to this
bouquets_xml = self.request_call(’/web/getallservices’)