text in bold is the solution to my original error, other text is a new problem.
The cause of the original error was the password used for the enigma box. I am using a new enigma box that’s only a few weeks old and so I hadn’t changed the default password for the root account from literally “password”. SSH on to the enigma box and a quick “passwd” command to change the password to anything other than “password”, change the config in HA, restart, and the enigma media player controls appear as expected with no errors in the log.
Changing the enigma box root password back to “password” and it all fails again! So something in the code is not dealing with specifically defining the password as “password”!
Now it’s up and running I have discovered a problem with the picon display in HA. Your custom component is attempting to load a picon (the card briefly slides down as if it is about to display the picon but then slides back up) and it seems to keep trying.
Looking at enigma.py and trying to understand the python (which I am now learning from your custom component! ) the important code seems to be lines 178 to 194.
The call on line 179 gives:
<e2servicelist>
<e2service>
<e2servicereference>1:0:19:4484:4085:233A:EEEE0000:0:0:0:</e2servicereference>
<e2servicename>BBC ONE HD</e2servicename>
</e2service>
</e2servicelist>
and the call made on line 187 returns:
<e2eventlist>
<e2event>
<e2eventid>47224</e2eventid>
<e2eventstart>1520503200</e2eventstart>
<e2eventduration>3600</e2eventduration>
<e2eventcurrenttime>1520503977</e2eventcurrenttime>
<e2eventtitle>Homes Under the Hammer</e2eventtitle>
<e2eventdescription>
A small garden with planning permission in Canterbury in Kent, a flat in London's Crystal Palace and a bungalow in the village of Branthwaite in Cumbria are sold at auction. [HD] [S]
</e2eventdescription>
<e2eventdescriptionextended/>
<e2eventservicereference>1:0:19:4484:4085:233A:EEEE0000:0:0:0:</e2eventservicereference>
<e2eventservicename>BBC ONE HD</e2eventservicename>
</e2event>
</e2eventlist>
The picon_url built on line 191 uses the e2servicereference value resulting in a URL of:
http://192.168.1.44/picon/1_0_19_4484_4085_233A_EEEE0000_0_0_0.png
(including the username and password of course)
That URL returns a 404 no such resource error.
However on my system the correct picon for this channel should be:
http://192.168.1.44/picon/bbconehd.png
which is the e2servicename with the whitespace removed and converted to lowercase. This method works for all the channels to determine the correct png filename.
This may be because I am using terrestrial DVB-T2 tuners, or it could be a UK thing, I’m not sure exactly how it works as I am fairly new to enigma2 receivers so don’t understand the system properly yet.
Fantastic work so far and great to have basic control of the receiver from HA! Let me know if I can help any more with this picon issue supplying more info or testing code - very happy to help get this working fully!
[EDIT] Can I also put in a feature request to define which bouquet to use instead of it being the first bouquet it finds? Thanks!