Installing Plugin won't work

Python and python framework

Moderator: leecollings

Post Reply
robinvd
Posts: 8
Joined: Wednesday 13 January 2021 0:06
Target OS: Raspberry Pi / ODroid
Domoticz version: 2021.1
Location: NL
Contact:

Installing Plugin won't work

Post by robinvd »

Hello,

Im trying to add my Qlima AC to Domoticz, there is a Plugin that should can do that. I tried multiple times & multiple ways to install the plugin. I did the following:

Code: Select all

login to Raspberry
cd domoticz/plugins
git clone https://github.com/mac-zhou/midea-msmart.git
cd midea-msmart
git clone https://github.com/awalsum/Qlima.git
sudo reboot
the files are present on the filesystem, and I changed the rights with

Code: Select all

chmod +x plugin.py
What am I doing wrong? In the Hardware list there is no Midea or Qlima device.

I'm using Version: 2021.1, on a raspberry PI Model 3B
pipiche
Posts: 1977
Joined: Monday 02 April 2018 20:33
Target OS: Raspberry Pi / ODroid
Domoticz version: beta
Location: France
Contact:

Re: Installing Plugin won't work

Post by pipiche »

make sure that you have python-dev installed
Zigbee for Domoticz plugin / RPI3B+ / Electrolama ZZH-P / 45 devices

If the plugin provides you value, you can support me with a donation Paypal.

Wiki is available here.

Zigbee for Domoticz FAQ
User avatar
waltervl
Posts: 5149
Joined: Monday 28 January 2019 18:48
Target OS: Linux
Domoticz version: 2024.7
Location: NL
Contact:

Re: Installing Plugin won't work

Post by waltervl »

Also follow the troubleshooting instructions for Python plugins https://www.domoticz.com/wiki/Using_Pyt ... leshooting

Is it the first plugin you are trying to install?

I have the same plugin working so I can confirm it works.
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
robinvd
Posts: 8
Joined: Wednesday 13 January 2021 0:06
Target OS: Raspberry Pi / ODroid
Domoticz version: 2021.1
Location: NL
Contact:

Re: Installing Plugin won't work

Post by robinvd »

I now can add the AC via Hardware, but it's not showing up at Devices. The Log is saying this:

Code: Select all

2021-06-16 19:57:15.396 Airco hardware started.
2021-06-16 19:57:15.350 Status: Airco: (Airco) Stop directive received.
2021-06-16 19:57:15.350 Status: Airco: (Airco) Stopping threads.
2021-06-16 19:57:15.350 Status: Airco: (Airco) Exiting work loop.
2021-06-16 19:57:15.350 Status: Airco: (Airco) Stopping python interpreter.
2021-06-16 19:57:15.396 Status: Airco: (Airco) Stopped.
2021-06-16 19:57:15.396 Status: Airco: (Airco) Entering work loop.
2021-06-16 19:57:15.396 Status: Airco: (Airco) Started.
2021-06-16 19:57:15.731 Error: Airco: (Qlima) failed to load 'plugin.py', Python Path used was '/home/pi/domoticz/plugins/Qlima/:/usr/lib/python37.zip:/usr/lib/python3.7:/usr/lib/python3.7/lib-dynload:/usr/local/lib/python3.7/dist-packages:/usr/lib/python3/dist-packages:/usr/lib/python3.7/dist-packages'.
2021-06-16 19:57:15.731 Error: Airco: (Airco) Module Import failed, exception: 'ModuleNotFoundError'
2021-06-16 19:57:15.731 Error: Airco: (Airco) Module Import failed: ' Name: Crypto.Util.Padding'
2021-06-16 19:57:15.731 Error: Airco: (Airco) Error Line details not available.
2021-06-16 19:57:16.365 Airco hardware started.
2021-06-16 19:57:16.305 Status: Airco: (Airco) Stop directive received.
2021-06-16 19:57:16.305 Status: Airco: (Airco) Stopping threads.
2021-06-16 19:57:16.305 Status: Airco: (Airco) Exiting work loop.
2021-06-16 19:57:16.305 Status: Airco: (Airco) Stopping python interpreter.
2021-06-16 19:57:16.364 Status: Airco: (Airco) Stopped.
2021-06-16 19:57:16.365 Status: Airco: (Airco) Entering work loop.
2021-06-16 19:57:16.365 Status: Airco: (Airco) Started.
2021-06-16 19:57:16.612 Error: Airco: (Qlima) failed to load 'plugin.py', Python Path used was '/home/pi/domoticz/plugins/Qlima/:/usr/lib/python37.zip:/usr/lib/python3.7:/usr/lib/python3.7/lib-dynload:/usr/local/lib/python3.7/dist-packages:/usr/lib/python3/dist-packages:/usr/lib/python3.7/dist-packages'.
2021-06-16 19:57:16.613 Error: Airco: (Airco) Module Import failed, exception: 'ModuleNotFoundError'
2021-06-16 19:57:16.613 Error: Airco: (Airco) Module Import failed: ' Name: Crypto.Util.Padding'
2021-06-16 19:57:16.613 Error: Airco: (Airco) Error Line details not available.
Thorgal789
Posts: 815
Joined: Wednesday 15 August 2018 14:38
Target OS: -
Domoticz version:
Contact:

Re: Installing Plugin won't work

Post by Thorgal789 »

Try with

Code: Select all

pip3 install pycryptodome
robinvd
Posts: 8
Joined: Wednesday 13 January 2021 0:06
Target OS: Raspberry Pi / ODroid
Domoticz version: 2021.1
Location: NL
Contact:

Re: Installing Plugin won't work

Post by robinvd »

First thank you for helping me.
I tried it, but still it doesn't work. Now the log file is showing this:

Code: Select all

2021-06-17 22:28:19.156 AC Woonkamer hardware started.
2021-06-17 22:28:19.112 Status: AC Woonkamer: (AC Woonkamer) Stop directive received.
2021-06-17 22:28:19.112 Status: AC Woonkamer: (AC Woonkamer) Stopping threads.
2021-06-17 22:28:19.112 Status: AC Woonkamer: (AC Woonkamer) Exiting work loop.
2021-06-17 22:28:19.113 Status: AC Woonkamer: (AC Woonkamer) Stopping python interpreter.
2021-06-17 22:28:19.155 Status: AC Woonkamer: (AC Woonkamer) Stopped.
2021-06-17 22:28:19.156 Status: AC Woonkamer: (AC Woonkamer) Entering work loop.
2021-06-17 22:28:19.156 Status: AC Woonkamer: (AC Woonkamer) Started.
2021-06-17 22:28:19.334 Error: AC Woonkamer: (Qlima) failed to load 'plugin.py', Python Path used was '/home/pi/domoticz/plugins/Qlima/:/usr/lib/python37.zip:/usr/lib/python3.7:/usr/lib/python3.7/lib-dynload:/usr/local/lib/python3.7/dist-packages:/usr/lib/python3/dist-packages:/usr/lib/python3.7/dist-packages'.
2021-06-17 22:28:19.334 Error: AC Woonkamer: (AC Woonkamer) Module Import failed, exception: 'ModuleNotFoundError'
2021-06-17 22:28:19.334 Error: AC Woonkamer: (AC Woonkamer) Module Import failed: ' Name: msmart'
2021-06-17 22:28:19.334 Error: AC Woonkamer: (AC Woonkamer) Error Line details not available.
User avatar
waltervl
Posts: 5149
Joined: Monday 28 January 2019 18:48
Target OS: Linux
Domoticz version: 2024.7
Location: NL
Contact:

Re: Installing Plugin won't work

Post by waltervl »

There should be an msmart folder with Python files in your Qlima plugin folder.
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
robinvd
Posts: 8
Joined: Wednesday 13 January 2021 0:06
Target OS: Raspberry Pi / ODroid
Domoticz version: 2021.1
Location: NL
Contact:

Re: Installing Plugin won't work

Post by robinvd »

Hello, it now works and the device is shown in de devices menu. I now have another problem I think.. My Qlima SC5248 is not supported says the Midea-discover command.. Thanks for the help, if there is a way I can get it to work..it would be nice.
User avatar
waltervl
Posts: 5149
Joined: Monday 28 January 2019 18:48
Target OS: Linux
Domoticz version: 2024.7
Location: NL
Contact:

Re: Installing Plugin won't work

Post by waltervl »

It supports the SK102 Wifi Stick and not the SK-103.....
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
robinvd
Posts: 8
Joined: Wednesday 13 January 2021 0:06
Target OS: Raspberry Pi / ODroid
Domoticz version: 2021.1
Location: NL
Contact:

Re: Installing Plugin won't work

Post by robinvd »

Do you know if I can change the wifi stick on the airco? it's just a usb dongle.. but will it work?
User avatar
waltervl
Posts: 5149
Joined: Monday 28 January 2019 18:48
Target OS: Linux
Domoticz version: 2024.7
Location: NL
Contact:

Re: Installing Plugin won't work

Post by waltervl »

It should work see https://domoticz.com/forum/viewtopic.ph ... a&start=80
But they are hard to get I believe.
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
antoniojgc
Posts: 4
Joined: Friday 19 May 2023 13:38
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Installing Plugin won't work

Post by antoniojgc »

¿Cual era el problema que tenias?
A mi me pasa lo mismo y aun no lo he podido solucionar
User avatar
waltervl
Posts: 5149
Joined: Monday 28 January 2019 18:48
Target OS: Linux
Domoticz version: 2024.7
Location: NL
Contact:

Re: Installing Plugin won't work

Post by waltervl »

antoniojgc wrote: Friday 19 May 2023 14:50 ¿Cual era el problema que tenias?
A mi me pasa lo mismo y aun no lo he podido solucionar
English please....
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
antoniojgc
Posts: 4
Joined: Friday 19 May 2023 13:38
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Installing Plugin won't work

Post by antoniojgc »

What was the problem you had?
The same thing happens to me and I haven't been able to solve it yet.
User avatar
waltervl
Posts: 5149
Joined: Monday 28 January 2019 18:48
Target OS: Linux
Domoticz version: 2024.7
Location: NL
Contact:

Re: Installing Plugin won't work

Post by waltervl »

What same problem do you have? The crypto module not found?
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
antoniojgc
Posts: 4
Joined: Friday 19 May 2023 13:38
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Installing Plugin won't work

Post by antoniojgc »

I have installed the qlima plugin, but it doesn't show me any devices in the device list. It gives me the error:
2023-05-19 18:57:33354 Error: aire: (Qlima) failed to load 'plugin*py', Python Path used was '/home/pi/domoticz/plugins/Qlima/:/usr/lib/python39*zip:/usr/lib/python3*9:/usr/lib/python3*9/lib-dynload:/usr/local/lib/python3*9/dist-packages:/usr/lib/python3/dist-packages:/usr/lib/python3*9/dist-packages'.
2023-05-19 18:57:33356 Error: aire: Traceback (most recent call last):
2023-05-19 18:57:33356 Error: aire: File "/home/pi/domoticz/plugins/Qlima/plugin*py", line 42, in <module>
2023-05-19 18:57:33356 Error: aire: from msmart*device import air_conditioning_device as ac
2023-05-19 18:57:33356 Error: aire: ImportError: cannot import name 'air_conditioning_device' from 'msmart*device' (/home/pi/domoticz/plugins/Qlima/msmart/device/__init__*py)
antoniojgc
Posts: 4
Joined: Friday 19 May 2023 13:38
Target OS: Raspberry Pi / ODroid
Domoticz version:
Contact:

Re: Installing Plugin won't work

Post by antoniojgc »

Note: I have changed some points, because it would not let me send the post with the original text.
User avatar
waltervl
Posts: 5149
Joined: Monday 28 January 2019 18:48
Target OS: Linux
Domoticz version: 2024.7
Location: NL
Contact:

Re: Installing Plugin won't work

Post by waltervl »

Seems that python msmart module has been changed and is not compatible with the plugin code anymore. Did you check the GitHub repository of the plugin? Perhaps there are similar issues...
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
User avatar
waltervl
Posts: 5149
Joined: Monday 28 January 2019 18:48
Target OS: Linux
Domoticz version: 2024.7
Location: NL
Contact:

Re: Installing Plugin won't work

Post by waltervl »

There are also various version of this plugin, check topic viewtopic.php?p=293590
Domoticz running on Udoo X86 (on Ubuntu)
Devices/plugins: ZigbeeforDomoticz (with Xiaomi, Ikea, Tuya devices), Nefit Easy, Midea Airco, Omnik Solar, Goodwe Solar
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest