Python Plugin Domoticz-Enigma2

Python and python framework
djksage
Posts: 5
Joined: Sunday 31 January 2016 16:23
Target OS: NAS (Synology & others)
Domoticz version:
Contact:

Re: Python Plugin Domoticz-Enigma2

Post by djksage » Sunday 02 December 2018 1:24

NoProfesor wrote:
Monday 26 November 2018 23:49
is in pathOfPackages = '/home/pi/.local/lib/python3.5/site-packages'

what is wrong?

LOG:

Code: Select all

 2018-11-26 22:37:39.662 Error: (Enigma2) failed to load 'plugin.py', Python Path used was '/home/pi/domoticz/plugins/Domoticz-Enigma2/:/usr/lib/python35.zip:/usr/lib/python3.5:/usr/lib/python3.5/plat-arm-linux-gnueabihf:/usr/lib/python3.5/lib-dynload'.
2018-11-26 22:37:39.662 Error: (VUplus) Module Import failed, exception: 'ImportError'
2018-11-26 22:37:39.662 Error: (VUplus) Module Import failed: ' Name: xmltodict'
2018-11-26 22:37:39.662 Error: (VUplus) Error Line details not available.
2018-11-26 22:38:40.667 Error: (Enigma2) failed to load 'plugin.py', Python Path used was '/home/pi/domoticz/plugins/Domoticz-Enigma2/:/usr/lib/python35.zip:/usr/lib/python3.5:/usr/lib/python3.5/plat-arm-linux-gnueabihf:/usr/lib/python3.5/lib-dynload'.
2018-11-26 22:38:40.667 Error: (VUplus) Module Import failed, exception: 'ImportError'
2018-11-26 22:38:40.667 Error: (VUplus) Module Import failed: ' Name: xmltodict'
2018-11-26 22:38:40.667 Error: (VUplus) Error Line details not available.
2018-11-26 22:40:01.038 Error: VUplus hardware (8) thread seems to have ended unexpectedly
2018-11-26 22:40:30.043 Error: VUplus hardware (8) thread seems to have ended unexpectedly 
Hello, i have exactly same problem

Code: Select all

 2018-12-02 00:08:13.209 Error: (Enigma2) failed to load 'plugin.py', Python Path used was '/home/pi/domoticz/plugins/Domoticz-Enigma2/:/usr/lib/python35.zip:/usr/lib/python3.5:/usr/lib/python3.5/plat-arm-linux-gnueabihf:/usr/lib/python3.5/lib-dynload'.
2018-12-02 00:08:13.209 Error: (VU+ Salon) Module Import failed, exception: 'ImportError'
2018-12-02 00:08:13.209 Error: (VU+ Salon) Module Import failed: ' Name: xmltodict'
2018-12-02 00:08:13.209 Error: (VU+ Salon) Error Line details not available. 
do you find a solution?

thanks

NoProfesor
Posts: 15
Joined: Wednesday 10 October 2018 21:46
Target OS: -
Domoticz version:
Contact:

Re: Python Plugin Domoticz-Enigma2

Post by NoProfesor » Sunday 09 December 2018 15:20

Plugin is not working,

I have simple script for checking engma2 status

Code: Select all


#!/bin/bash

	curl http://192.168.0.xxe/web/powerstate > /home/pi/domoticz/scripts/enigma2/powerstate_enigma2_living3.xml
	enigma2LivingStatus=`xmlstarlet sel -t -m '//e2instandby' -v . -n </home/pi/domoticz/scripts/enigma2/powerstate_enigma2_living3.xml`

	if [ $enigma2LivingStatus = "true" ]
	then
	curl 'http://192.168.0.xxr:8080/json.htm?type=command&param=switchlight&idx=13&switchcmd=Off'
    		echo "$enigma2LivingStatus"
    		echo enigma2 Living is in standby

	elif [ $enigma2LivingStatus = "false" ]
	then
	curl 'http://192.168.0.xxr:8080/json.htm?type=command&param=switchlight&idx=13&switchcmd=On'
    		echo "$enigma2LivingStatus"
    		echo enigma2 Living is not in standby

	else
	curl 'http://192.168.0.xxr:8080/json.htm?type=command&param=switchlight&idx=13&switchcmd=Off'
    		echo "$enigma2LivingStatus"
    		echo enigma2 Living is in standby
    		echo enigma2 Living not found

	fi

and file


Code: Select all

<?xml version="1.0" encoding="UTF-8"?>
<e2powerstate>
	<e2instandby>
true	</e2instandby>
</e2powerstate>

Does anyone know how to run this script in domoticz to check status for 10 seconds?

Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest