Nope, must be invoked remotely. It is possible. I’m just thinking that this is requested every 10 seconds by default, and maybe it is not a good idea.
Did anyone faced the box lagging ?
Nope, must be invoked remotely. It is possible. I’m just thinking that this is requested every 10 seconds by default, and maybe it is not a good idea.
Did anyone faced the box lagging ?
@cinzas thank you so much enigma addon.
I would like to use my default bouquet . This was automatically created by Open-VIX and maintains the channel numbers for freesat here in the UK. So my bouquet contains lots of blanks in the list as well as bouquet markers . So the source list from the HA media player is a huge list of mainly blank entries . Is it possible to ignore a blank entry in the bouquet. See the following from the OpenWebif bouquet editor
100 blank entries then
and so on
Ok, pull request has been done and code as passed all tests.
As I wrote we can grab screenshot easily:
http://192.168.1.99/grab?format=jpg
Lag? I think no problem. We can easily stream anything from our boxes, without any problem, then grabbing screenshot every xx minutes should not make any problem.
Ok, let me see if the pull request is accepted,
Then we can have a entry in the config display=picon or display=screenshot.
And based on the choice it will show what the user wants (picon by default).
Not difficult to implement, will try that later.
Hi guys
It’s done. I just released a new version of the platform.
There is a new variable that can be added to the configuration
picon = picon
or
picon = screenshot
Default is to grab from picon.
If defined picon=screenshot
will grab a new screenshot when channel is changed.
Had to investigate a little bit, becase using grab?format=jpg will work only when loading. Because the request is always the same, the image won’t be refresh by HA.
I decided to grab screenshot with a width of 720, png format and added the channel reference as a parameter (which is ignored by enigma).
With this implementation it is working as desired (i guess)
I will update my pull request accordingly
Thanks
Great work.
Did you consider my suggestion aka. “mixed mode”?
If picon not available (we must somehow check this) show screenshot.
Sorry didn’t see that
It’s a good idea, have to look at the code to see that possibility
Trying to push the pull request, they are asking to create a component instead of a platform in the media_player.
It will force me to learn python hehehe
This is the best way to learn a lot.
Hi @cinzas with last commit I cannot change anymore to another channel via service_call, I get Unsupported media type
error in log
EDIT: I tried with “channel” in content_media_type and there’s the magic
Hi @danichispa, yes this is possible to be happening because I’ve made a small modification in the code.
Give me some days, i’m currently changing all the code to see if I can make a enigma component that will have 2 platfroms (media_player and notify) for integration in the HA.
If I mange to do that I will solve that problem at the same time, if not I will revert the change I’ve made in the custom component.
Sorry, was editing while you were answering, It works setting “media_content_type” to “channel”.
Yeap, that was the change I made but didn’t test. I have to change the readme.
Think it makes more sense also
Hi
I’ve made big changes in the component. Please take a look at the readme
Now we have a new component (enigma), that can have multiple devices (see configuration).
The media_player platform will be created automatically.
For the notify platform you sill need to create them separately.
Everything is working fine on my HA configuration.
Check the README at github
Cool, I’ll check this ASAP.
Hello from Spain. This is the first time I write on this community.
I’ve have a problem to make this works. My receiver has openwebif 0.4.7. I follow the tutorial but never shows in dashboard of my HA. This is that I type:
enigma:
devices:
- host: my ip
port: 80
name: vu
timeout: 20
username: root
password: my password
Before to reboot the service, I try to verify the configuration, but I haven’t got answer, its ever “thinking”
Sorry for my English.
Thanks for your help!.
Hola Jaime
Did you copy all the files into the directory custom_components?
enigma.py in the root of the custom_components directory, and also the notify and media_player folders.
The config seems fine (are you indenting correctly?).
Also restart HA and check the log file for errors.
If needed send it to me for checking.
Espero que ayude, gracias
Hi,
I’vent custom_components, I’ve this configuration:
/config/configuration.yaml, sensors.yaml,etc
/usr/src/apps/homeassistant/components/(here all components .py, media_player and notify directories).
I copied the files correctly, only the file into custom_components directory because I only have components directory, but it’s there.
I have HA in a docker’s container on a Synology NAS.
Where’s log’s file?.
Hi
I never used ha on a docker, but from what i read on the configuration the approach is the same.
Look into https://developers.home-assistant.io/docs/en/creating_component_loading.html
You have defined a config directory when installing the image. Inside that directory create the custom_components directory and copy all the files from my github inside that directory, and then restart HA.
The log file is inside that config directory (How to improve Logging with HA in Docker Container?)
Hi,
Made that you say, and same error. Log out:
2018-11-28 18:16:11 INFO (MainThread) [homeassistant.loader] Loaded hassio from homeassistant.components.hassio
2018-11-28 18:16:11 INFO (MainThread) [homeassistant.components.updater] Submitted analytics to Home Assistant servers. Information submitted includes {‘arch’: ‘x86_64’, ‘dev’: False, ‘docker’: True, ‘os_name’: ‘Linux’, ‘python_version’: ‘3.6.7’, ‘timezone’: ‘Europe/Madrid’, ‘version’: ‘0.82.1’, ‘virtualenv’: False, ‘hassio’: False, ‘distribution’: ‘debian’, ‘os_version’: ‘9’, ‘huuid’: ‘52d1a530d3da473dbbbcb7bde0e84c9c’}
2018-11-28 18:16:11 ERROR (MainThread) [homeassistant.components.updater] Got unexpected response: None
2018-11-28 18:25:44 INFO (MainThread) [homeassistant.components.http.view] Serving /api/websocket to 192.168.1.214 (auth: False)
2018-11-28 18:25:44 INFO (MainThread) [homeassistant.components.http.view] Serving /auth/token to 192.168.1.214 (auth: False)
2018-11-28 18:25:46 INFO (MainThread) [homeassistant.components.http.view] Serving /api/config/core/check_config to 192.168.1.214 (auth: True)
2018-11-28 18:25:46 ERROR (MainThread) [aiohttp.server] Error handling request
Traceback (most recent call last):
File “/usr/local/lib/python3.6/site-packages/aiohttp/web_protocol.py”, line 390, in start
resp = await self._request_handler(request)
File “/usr/local/lib/python3.6/site-packages/aiohttp/web_app.py”, line 366, in _handle
resp = await handler(request)
File “/usr/local/lib/python3.6/site-packages/aiohttp/web_middlewares.py”, line 106, in impl
return await handler(request)
File “/usr/src/app/homeassistant/components/http/static.py”, line 66, in staticresource_middleware
return await handler(request)
File “/usr/src/app/homeassistant/components/http/real_ip.py”, line 34, in real_ip_middleware
return await handler(request)
File “/usr/src/app/homeassistant/components/http/ban.py”, line 66, in ban_middleware
return await handler(request)
File “/usr/src/app/homeassistant/components/http/auth.py”, line 97, in auth_middleware
return await handler(request)
File “/usr/src/app/homeassistant/components/http/real_ip.py”, line 34, in real_ip_middleware
return await handler(request)
File “/usr/src/app/homeassistant/components/http/ban.py”, line 66, in ban_middleware
return await handler(request)
File “/usr/src/app/homeassistant/components/http/auth.py”, line 97, in auth_middleware
return await handler(request)
File “/usr/src/app/homeassistant/components/http/view.py”, line 113, in handle
result = await result
File “/usr/src/app/homeassistant/components/config/core.py”, line 21, in post
errors = await async_check_ha_config_file(request.app[‘hass’])
File “/usr/src/app/homeassistant/config.py”, line 796, in async_check_ha_config_file
check_ha_config_file, hass)
File “/usr/local/lib/python3.6/concurrent/futures/thread.py”, line 56, in run
result = self.fn(*self.args, **self.kwargs)
File “/usr/src/app/homeassistant/scripts/check_config.py”, line 340, in check_ha_config_file
component = loader.get_component(hass, domain)
File “/usr/src/app/homeassistant/loader.py”, line 92, in get_component
module = importlib.import_module(path)
File “/usr/local/lib/python3.6/importlib/init.py”, line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File “<frozen importlib._bootstrap>”, line 994, in _gcd_import
File “<frozen importlib._bootstrap>”, line 971, in _find_and_load
File “<frozen importlib._bootstrap>”, line 955, in _find_and_load_unlocked
File “<frozen importlib._bootstrap>”, line 665, in _load_unlocked
File “<frozen importlib._bootstrap_external>”, line 674, in exec_module
File “<frozen importlib._bootstrap_external>”, line 781, in get_code
File “<frozen importlib._bootstrap_external>”, line 741, in source_to_code
File “<frozen importlib._bootstrap>”, line 219, in _call_with_frames_removed
File “/config/custom_components/enigma.py”, line 7
<!DOCTYPE html>
^
SyntaxError: invalid syntax
2018-11-28 18:25:48 ERROR (MainThread) [homeassistant.core] Error executing service <ServiceCall homeassistant.restart (c:e4284f59d2294449ad45d54641010349)>
Traceback (most recent call last):
File “/usr/src/app/homeassistant/core.py”, line 1177, in _event_to_service_call
await service_handler.func(service_call)
File “/usr/src/app/homeassistant/components/init.py”, line 129, in async_handle_core_service
errors = await conf_util.async_check_ha_config_file(hass)
File “/usr/src/app/homeassistant/config.py”, line 796, in async_check_ha_config_file
check_ha_config_file, hass)
File “/usr/local/lib/python3.6/concurrent/futures/thread.py”, line 56, in run
result = self.fn(*self.args, **self.kwargs)
File “/usr/src/app/homeassistant/scripts/check_config.py”, line 340, in check_ha_config_file
component = loader.get_component(hass, domain)
File “/usr/src/app/homeassistant/loader.py”, line 92, in get_component
module = importlib.import_module(path)
File “/usr/local/lib/python3.6/importlib/init.py”, line 126, in import_module
return _bootstrap._gcd_import(name[level:], package, level)
File “<frozen importlib._bootstrap>”, line 994, in _gcd_import
File “<frozen importlib._bootstrap>”, line 971, in _find_and_load
File “<frozen importlib._bootstrap>”, line 955, in _find_and_load_unlocked
File “<frozen importlib._bootstrap>”, line 665, in _load_unlocked
File “<frozen importlib._bootstrap_external>”, line 674, in exec_module
File “<frozen importlib._bootstrap_external>”, line 781, in get_code
File “<frozen importlib._bootstrap_external>”, line 741, in source_to_code
File “<frozen importlib._bootstrap>”, line 219, in _call_with_frames_removed
File “/config/custom_components/enigma.py”, line 7
<!DOCTYPE html>
^
SyntaxError: invalid syntax
2018-11-28 18:25:54 INFO (MainThread) [homeassistant.components.http.view] Serving /states to 192.168.1.214 (auth: False)
2018-11-28 18:25:54 INFO (MainThread) [homeassistant.components.http.view] Serving /api/websocket to 192.168.1.214 (auth: False)
What do you think?.