Vu+ Integration

I would appreciate integration of vu+ linux media player (see http://www.vuplus.de/)

Thanks!

This can be done with the Webinterface API for Enigma2 receivers. This will also work for all Enigma2 based receivers such as Dreambox, Golden Interstar, VU+,…

You mean like this?

1 Like

Hi guys,

Is anyone working or already been able to implement enigma2.

like this yes!

Feel free to test.
Add the file to: /home/homeassistant/.homeassistant/custom_components/media_player/
enigma.py

Add this to your config file:
media_player:

  • platform: enigma
    host: 192.168.xxx.xxx <- IP of your SAT
    port: 23
    username: xxxxxxx <- user name to telnet
    password: yyyyyyy <- password to telnet

thanks, i have installed it, but there is an error.

[Errorlog]
17-01-23 17:28:18 custom_components.media_player.enigma: PO ZADANI HESLA:
17-01-23 17:28:18 custom_components.media_player.enigma: HODNOTA PWSTATE: head: invalid option – β€˜1’
17-01-23 17:28:19 custom_components.media_player.enigma: PO ZADANI PWSTATE: BusyBox v1.23.2 (2016-03-25 16:32:47 CET) multi-call binary.
17-01-23 17:28:19 custom_components.media_player.enigma: HODNOTA NAME: head: invalid option – β€˜1’
17-01-23 17:28:19 custom_components.media_player.enigma: PO ZADANI MODEL: BusyBox v1.23.2 (2016-03-25 16:32:47 CET) multi-call binary.
17-01-23 17:28:19 custom_components.media_player.enigma: HODNOTA SOURCE: head: invalid option – β€˜1’
17-01-23 17:28:20 custom_components.media_player.enigma: PO ZADANI SOURCE: BusyBox v1.23.2 (2016-03-25 16:32:47 CET) multi-call binary.
17-01-23 17:28:20 custom_components.media_player.enigma: HODNOTA REFERENCE: head: invalid option – β€˜1’
17-01-23 17:28:20 custom_components.media_player.enigma: PO ZADANI REFERENCE: BusyBox v1.23.2 (2016-03-25 16:32:47 CET) multi-call binary.
17-01-23 17:28:20 custom_components.media_player.enigma: HODNOTA EVENT TITLE: head: invalid option – β€˜1’
17-01-23 17:28:21 custom_components.media_player.enigma: PO ZADANI EVENTTITLE: BusyBox v1.23.2 (2016-03-25 16:32:47 CET) multi-call binary.
17-01-23 17:28:21 homeassistant.components.media_player: Error while setting up platform enigma
File β€œ/home/pi/.homeassistant/custom_components/media_player/enigma.py”, line 74, in setup_platform
if enigma.update():
File β€œ/home/pi/.homeassistant/custom_components/media_player/enigma.py”, line 230, in update

and why did you use telnet?
webrequests can be done locally or?
wget -q -O - http://< ip_from_satbox >/web/powerstate | awk -F β€˜[<>]’ β€˜/e2instandby/{print $3}’ | head -1’

greets,
muggle

What’s model of Enigma2 SAT do you have?
As I can see, it is using BusyBox v1.23.2 and maybe thats the problem.
Try to login with telnet and use this command:
wget -q -O - http://127.0.0.1/web/powerstate | awk -F β€˜[<>]’ β€˜/e2instandby/{print $3}’

VU+ SoloΒ²
root@vusolo2:~# wget -q -O - http://127.0.0.1/web/powerstate | awk -F β€˜[<>]’ β€˜/e2instandby/’ | head

true

root@vusolo2:~# wget -q -O - http://127.0.0.1/web/powerstate | awk -F β€˜[<>]’ β€˜/e2instandby/{print $3}’

empty output

P.S. I’m not python guru. :frowning: If you can help with local web-request, feel free to modify the file.

1 Like

try this: wget -q -O - http://127.0.0.1/web/powerstate | awk -F β€˜[<>]’ β€˜/e2instandby/’ | tail

root@vusolo2:~# wget -q -O - http://127.0.0.1/web/powerstate | awk -F β€˜[<>]’ β€˜/e2instandby/’ | tail
< e2instandby >
true < /e2instandby >

i’m also not a python guru :wink:

what have to be the value of this request? so i can test it myself

This: wget -q -O - http://127.0.0.1/web/powerstate
will give the full XML of powerstate
You need to parse the: true (if enigma is in standby, or false if not)

All the other command vice-versa.

Post please the full XML

<?xml version="1.0" encoding="UTF-8"?>

< e2powerstate>
< e2instandby>
true < /e2instandby>
< /e2powerstate>

wget -q -O - http://127.0.0.1/web/powerstate | awk -F β€˜[<>]’ β€˜/e2instandby/{print $1}’ >> Result:
empty line
true

with:
wget -q -O - http://127.0.0.1/web/powerstate | awk -F β€˜[<>]’ β€˜/e2instandby/{print $1}’ | tail -n 1
true

so i thing, thats the correct line

YES, or this:
wget -q -O - http://127.0.0.1/web/powerstate | awk -F β€˜[<>]’ β€˜//e2instandby/{print $1}’

i will change all the lines and give it a new try :slight_smile:

Check all the full XML and correct awk. Good luck :smiley:

now its starting and the media_player card is shown.

_CMD_PWSTATE = β€œwget -q -O - http://127.0.0.1/web/powerstate | awk -F β€˜[<>]’ β€˜//e2instandby/{print $1}’”
_CMD_Q_MODEL = β€œwget -q -O - http://127.0.0.1/web/about | awk -F β€˜[<>]’ β€˜//e2model/{print $3}’”
_CMD_Q_SOURCE = β€œwget -q -O - http://127.0.0.1/web/subservices | awk -F β€˜[<>]’ β€˜//e2servicename/{print $3}’”
_CMD_Q_SERVICEREFERENCE = β€œwget -q -O - http://127.0.0.1/web/subservices | awk -F β€˜[<>]’ β€˜//e2servicereference/{print $3}’”
_CMD_Q_EVENTTITLE_BEGIN = β€œwget -q -O - http://127.0.0.1/web/epgservicenow?sRef=”
_CMD_Q_EVENTTITLE_END = " | awk -F β€˜[<>]’ β€˜//e2eventtitle/{print $3}’"
_CMD_Q_VOLUME = β€œwget -q -O - http://127.0.0.1/web/vol | awk -F β€˜[<>]’ β€˜//e2current/{print $3}’”
_CMD_Q_MUTE = β€œwget -q -O - http://127.0.0.1/web/vol | awk -F β€˜[<>]’ β€˜//e2ismuted/{print $3}’”
_CMD_C_VOLUME = β€˜wget -q -O - http://127.0.0.1/web/vol?set=set’
_CMD_C_MUTE = β€˜wget -q -O - http://127.0.0.1/web/vol?set=mute’
_CMD_C_POWEROFF = β€˜wget -q -O - http://127.0.0.1/web/powerstate?newstate=5’
_CMD_C_POWERON = β€˜wget -q -O - http://127.0.0.1/web/powerstate?newstate=4’

thank you very much for sharing :slight_smile: