Python Plugin : Broadlink

Python and python framework

Moderator: leecollings

Backlash
Posts: 9
Joined: Sunday 23 August 2020 20:47
Target OS: Raspberry Pi / ODroid
Domoticz version: Latest
Location: Nederland
Contact:

Re: Python Plugin : Broadlink

Post by Backlash »

Can anybody provide me a link to download the broadlink file since https://synnas.publicvm.com:32701/s/gmt22Ad7TyYJGdN is no longer working.
nachorc32
Posts: 3
Joined: Wednesday 27 February 2019 18:18
Target OS: Linux
Domoticz version:
Contact:

Re: Python Plugin : Broadlink

Post by nachorc32 »

This link https://synnas.publicvm.com:32701/s/gmt22Ad7TyYJGdN is not working! If you have a valid link, please post it!
zak45
Posts: 952
Joined: Sunday 22 January 2017 11:37
Target OS: Windows
Domoticz version: V2024.4
Contact:

Re: Python Plugin : Broadlink

Post by zak45 »

in process to rebuild my Nextcloud... so should be available soon.
zak45
Posts: 952
Joined: Sunday 22 January 2017 11:37
Target OS: Windows
Domoticz version: V2024.4
Contact:

Re: Python Plugin : Broadlink

Post by zak45 »

Final Nextcloud config with a valid certificat (LetsEncrypt:)
so, the new link :

https://synnas.publicvm.com:4430/s/Czn9r8G8QwrZ7ji
Backlash
Posts: 9
Joined: Sunday 23 August 2020 20:47
Target OS: Raspberry Pi / ODroid
Domoticz version: Latest
Location: Nederland
Contact:

Re: Python Plugin : Broadlink

Post by Backlash »

Great!

Don't forget to edit setup.py to include the new download path https://synnas.publicvm.com:4430/s/Czn9r8G8QwrZ7ji
rjblake
Posts: 142
Joined: Friday 21 October 2016 9:25
Target OS: NAS (Synology & others)
Domoticz version:
Location: Netherlands
Contact:

Re: Python Plugin : Broadlink

Post by rjblake »

rjblake wrote: Monday 25 January 2021 16:11 Updated my install to Buster, and now it no longer works. I keep getting the following:

Code: Select all

2021-01-25 15:56:02.067 Error: Python Plugin System: (Broadlink) failed to load 'plugin.py', Python Path used was '/home/pi/domoticz/plugins/Broadlink/:/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-01-25 15:56:02.067 Error: Python Plugin System: (BroadlinkRM2-New) Module Import failed, exception: 'AttributeError'
2021-01-25 15:56:02.067 Error: Python Plugin System: (BroadlinkRM2-New) Error Line details not available.
2021-01-25 15:57:08.876 Error: BroadlinkRM2-New hardware (28) thread seems to have ended unexpectedly
I have installed Python3.7 and set as system default, installed all the modules, they show as listed in

Code: Select all

/usr/local/lib/python3.7/dist-packages
.

I'm guessing something is messed up with Python; but I've set Python3.7 as system wide version using

Code: Select all

sudo update-alternatives --config python
If I run the

Code: Select all

./broadlink_discovery.py
from the /home/pi/domoticz/plugins/Broadlink directory, it responds correctly:

Code: Select all

# broadlink_cli --type 0x2787 --host 192.168.178.17 --mac AABBCCDDEEFF
Device file data (to be used with --device @filename in broadlink_cli) : 
0x2787 192.168.178.17 AABBCCDDEEFF
temperature = 22.1
Anyone got any thoughts aside from complete fresh install?
Bump - still not managed to sort this. Guess a full clean install is the only option
Backlash
Posts: 9
Joined: Sunday 23 August 2020 20:47
Target OS: Raspberry Pi / ODroid
Domoticz version: Latest
Location: Nederland
Contact:

Re: Python Plugin : Broadlink

Post by Backlash »

Tried a fresh install, still tons of errors :(
extremeaudio
Posts: 47
Joined: Tuesday 24 November 2020 17:57
Target OS: Linux
Domoticz version:
Contact:

Re: Python Plugin : Broadlink

Post by extremeaudio »

I tried with python setup.py but gives error

Code: Select all

 File "setup.py", line 229
    print("\r>> Bytes downloaded -->" + state + str(leng) + state, end='', flush=True)
and if I do python3 setup.py I get the prompt for domoticz ip and port but after entering the IP address and port correctly (where I can access the domoticz web UI fine) I get "ERROR : Not able to reach Domoticz"

EDIT: My domoticz install also appears to go offline after i issue the abpve command

have to reboot to get it back up
rjblake
Posts: 142
Joined: Friday 21 October 2016 9:25
Target OS: NAS (Synology & others)
Domoticz version:
Location: Netherlands
Contact:

Re: Python Plugin : Broadlink

Post by rjblake »

Backlash wrote: Thursday 28 January 2021 20:48 Tried a fresh install, still tons of errors :(
I did a fresh install on RasPi 4 running Raspbian and mostly ok. Still get the following error and have no idea how to stop this

Code: Select all

2021-01-29 20:10:31.653 Error: (BroadlinkRM2-New) Error to retrieve plugin version from : /home/pi/domoticz/plugins/Broadlink/tst-plugin
2021-01-29 20:10:33.379 Error: (BroadlinkRM2-New) ERR : remote_plugin_ver--Error to retrieve plugin version from : /home/pi/domoticz/plugins/Broadlink/tst-plugin--21
zak45
Posts: 952
Joined: Sunday 22 January 2017 11:37
Target OS: Windows
Domoticz version: V2024.4
Contact:

Re: Python Plugin : Broadlink

Post by zak45 »

rjblake wrote: Saturday 30 January 2021 17:58 I did a fresh install on RasPi 4 running Raspbian and mostly ok. Still get the following error and have no idea how to stop this

Code: Select all

2021-01-29 20:10:31.653 Error: (BroadlinkRM2-New) Error to retrieve plugin version from : /home/pi/domoticz/plugins/Broadlink/tst-plugin
2021-01-29 20:10:33.379 Error: (BroadlinkRM2-New) ERR : remote_plugin_ver--Error to retrieve plugin version from : /home/pi/domoticz/plugins/Broadlink/tst-plugin--21
Download Dombroadlink.py and put it under /home/pi/domoticz/plugins/Broadlink
THBR
Posts: 37
Joined: Saturday 02 November 2019 21:05
Target OS: -
Domoticz version:
Contact:

Re: Python Plugin : Broadlink

Post by THBR »

zak45 wrote: Friday 20 November 2020 16:51
henk99 wrote: Thursday 19 November 2020 23:36 What is going wrong here? As soon as I set the usage to computional, domoticz goes crazy. By the way, this is a brand new install from scratch with Debian 10 (buster) and domoticz 2020.2.
you're right.... same here.
Do not know where the problem is.!!!???

Just remove the device to solve Domoticz reboot until had some times to investigate.
Hi Zak45,

Have you possibly already found a solution (I have exactly the same problem here. I already updated plugin.py and dombroadlink.py without any result)?

Thanks.

Gr. Theo.
rjblake
Posts: 142
Joined: Friday 21 October 2016 9:25
Target OS: NAS (Synology & others)
Domoticz version:
Location: Netherlands
Contact:

Re: Python Plugin : Broadlink

Post by rjblake »

zak45 wrote: Saturday 30 January 2021 19:05
rjblake wrote: Saturday 30 January 2021 17:58 I did a fresh install on RasPi 4 running Raspbian and mostly ok. Still get the following error and have no idea how to stop this

Code: Select all

2021-01-29 20:10:31.653 Error: (BroadlinkRM2-New) Error to retrieve plugin version from : /home/pi/domoticz/plugins/Broadlink/tst-plugin
2021-01-29 20:10:33.379 Error: (BroadlinkRM2-New) ERR : remote_plugin_ver--Error to retrieve plugin version from : /home/pi/domoticz/plugins/Broadlink/tst-plugin--21
Download Dombroadlink.py and put it under /home/pi/domoticz/plugins/Broadlink
I downloaded the latest version and still get the following error:

Code: Select all

2021-02-01 16:53:10.807 Error: (BroadlinkRM2-New) Error to retrieve plugin version from : /home/pi/domoticz/plugins/Broadlink/tst-plugin
extremeaudio
Posts: 47
Joined: Tuesday 24 November 2020 17:57
Target OS: Linux
Domoticz version:
Contact:

Re: Python Plugin : Broadlink

Post by extremeaudio »

Below are the errors I get while installing..

Code: Select all

pi@raspberrypi:~/domoticz/plugins/Broadlink $ python setup.py
*
================================================================================
*
                     Broadlink Plugin Installation
*
================================================================================
*
Python 3.7.3 (default, Jul 25 2020, 13:03:44)
[GCC 8.3.0] on linux
________________________________________
# We need Domoticz Net info
----------------------------------------
ENTER Domoticz IP address (e.g. 192.168.1.45): 192.168.1.153
ENTER Domoticz Port Number (e.g. 8080): 8080
IP/PORT OK
Installation initialized ......
________________________________________
# we retrieve Domoticz language
Request from domoticz to : type=settings
We work with this language : en
On this platform : Linux
________________________________________
# we install necessary modules
----------------------------------------
-*-
 We execute this command : sudo -H python -m pip install setuptools
 We have installed : setuptools
-*-
 We execute this command : sudo -H python -m pip install wheel
 We have installed : wheel
-*-
 We execute this command : sudo -H python -m pip install googletrans
  Could not find a version that satisfies the requirement httpx==0.13.3 (from googletrans) (from versions: )
No matching distribution found for httpx==0.13.3 (from googletrans)
ERROR to start subprocess
1
sudo -H python -m pip install googletrans
b'Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple\nCollecting googletrans\n  Using cached https://files.pythonhosted.org/packages/71/3a/3b19effdd4c03958b90f40fe01c93de6d5280e03843cc5adf6956bfc9512/googletrans-3.0.0.tar.gz\nCollecting httpx==0.13.3 (from googletrans)\n'
 ERROR to install : googletrans
 could be normal if already exist, continue in anyway....
-*-
 We execute this command : sudo -H python -m pip install translate
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-install-MwklDU/lxml/
ERROR to start subprocess
1
sudo -H python -m pip install translate
b'Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple\nCollecting translate\n  Using cached https://files.pythonhosted.org/packages/85/b2/2ea329a07bbc0c7227eef84ca89ffd6895e7ec237d6c0b26574d56103e53/translate-3.5.0-py2.py3-none-any.whl\nRequirement already satisfied: click in /usr/lib/python2.7/dist-packages (from translate) (7.0)\nCollecting tox (from translate)\n  Using cached https://files.pythonhosted.org/packages/8c/8d/c42440af715d4a6952fe3074bb1cb133681014409743a867c6396401234c/tox-3.21.3-py2.py3-none-any.whl\nRequirement already satisfied: requests in /usr/lib/python2.7/dist-packages (from translate) (2.21.0)\nCollecting pre-commit (from translate)\n  Using cached https://files.pythonhosted.org/packages/df/30/22425aa6680370ba06de107e82eb3fc6159f462619b941241e96dd6bd79b/pre_commit-1.21.0-py2.py3-none-any.whl\nCollecting lxml (from translate)\n  Using cached https://files.pythonhosted.org/packages/db/f7/43fecb94d66959c1e23aa53d6161231dca0e93ec500224cf31b3c4073e37/lxml-4.6.2.tar.gz\n    Complete output from command python setup.py egg_info:\n    Building lxml version 4.6.2.\n    Building without Cython.\n    Error: Please make sure the libxml2 and libxslt development packages are installed.\n    \n    ----------------------------------------\n'
 ERROR to install : translate
 could be normal if already exist, continue in anyway....
-*-
 We execute this command : sudo -H python -m pip install requests
 We have installed : requests
-*-
 We execute this command : sudo -H python -m pip install requests_toolbelt
 We have installed : requests_toolbelt
-*-
 We execute this command : sudo -H python -m pip install irgen
  Could not find a version that satisfies the requirement irgen (from versions: )
No matching distribution found for irgen
ERROR to start subprocess
1
sudo -H python -m pip install irgen
b'Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple\nCollecting irgen\n'
 ERROR to install : irgen
 could be normal if already exist, continue in anyway....
________________________________________
# we download plugin files from DropBox (zip format)
----------------------------------------
/usr/lib/python3/dist-packages/urllib3/connectionpool.py:849: InsecureRequestWarning: Unverified HTTPS request is being made. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings
  InsecureRequestWarning)
We download plugin files to: BroadlinkSetup.zip
>> Bytes downloaded -->**1895939**: 100% Done
________________________________________
# we extract necessary plugin files
----------------------------------------
File Name                                             Modified             Size
Broadlink/                                     2021-02-02 15:12:34            0
Broadlink/Dombroadlink.py                      2021-01-27 22:50:10        34987
Broadlink/README.md                            2021-01-21 11:17:02         4350
Broadlink/broadlink_cli.py                     2021-01-04 12:04:46         7840
Broadlink/broadlink_discovery.py               2021-01-04 12:04:46         1452
Broadlink/lng/                                 2021-02-02 15:12:34            0
Broadlink/lng/en_ar.lng                        2021-01-04 12:04:46        21959
Broadlink/lng/en_bg.lng                        2021-01-04 12:04:46        26107
Broadlink/lng/en_bs.lng                        2021-01-04 12:04:46        18895
Broadlink/lng/en_ca.lng                        2021-01-04 12:04:46        19923
Broadlink/lng/en_cs.lng                        2021-01-04 12:04:46        18690
Broadlink/lng/en_da.lng                        2021-01-04 12:04:46        17843
Broadlink/lng/en_de.lng                        2021-01-04 12:04:46        18950
Broadlink/lng/en_el.lng                        2021-01-04 12:04:46        27588
Broadlink/lng/en_en.lng                        2021-01-04 12:04:46        18298
Broadlink/lng/en_es.lng                        2021-01-04 12:04:46        19341
Broadlink/lng/en_et.lng                        2021-01-04 12:04:46        17038
Broadlink/lng/en_fa.lng                        2021-01-04 12:04:46        45771
Broadlink/lng/en_fi.lng                        2021-01-04 12:04:46        17882
Broadlink/lng/en_fr.lng                        2021-01-04 12:04:46        20728
Broadlink/lng/en_fr.lng.tmp                    2021-01-04 12:04:46        19633
Broadlink/lng/en_he.lng                        2021-01-04 12:04:46        20596
Broadlink/lng/en_hu.lng                        2021-01-04 12:04:46        19657
Broadlink/lng/en_is.lng                        2021-01-04 12:04:46        18421
Broadlink/lng/en_it.lng                        2021-01-04 12:04:46        19090
Broadlink/lng/en_lt.lng                        2021-01-04 12:04:46        18217
Broadlink/lng/en_lv.lng                        2021-01-04 12:04:46        18825
Broadlink/lng/en_mk.lng                        2021-01-04 12:04:46        26733
Broadlink/lng/en_nl.lng                        2021-01-04 12:04:46        18492
Broadlink/lng/en_no.lng                        2021-01-04 12:04:46        17974
Broadlink/lng/en_pl.lng                        2021-01-04 12:04:46        18436
Broadlink/lng/en_pt.lng                        2021-01-04 12:04:46        18715
Broadlink/lng/en_ro.lng                        2021-01-04 12:04:46        19152
Broadlink/lng/en_ru.lng                        2021-01-04 12:04:46        24982
Broadlink/lng/en_sk.lng                        2021-01-04 12:04:46        18989
Broadlink/lng/en_sl.lng                        2021-01-04 12:04:46        18562
Broadlink/lng/en_sq.lng                        2021-01-04 12:04:46        18744
Broadlink/lng/en_sr.lng                        2021-01-04 12:04:46        25313
Broadlink/lng/en_sv.lng                        2021-01-04 12:04:46        18022
Broadlink/lng/en_tr.lng                        2021-01-04 12:04:46        18631
Broadlink/lng/en_uk.lng                        2021-01-04 12:04:46        25586
Broadlink/lng/en_zh.lng                        2021-01-04 12:04:46        16863
Broadlink/lng/en_zh_TW.lng                     2021-01-04 12:04:46        60914
Broadlink/plugin.py                            2021-01-08 11:16:38       213722
Broadlink/python-broadlink-master/             2021-02-02 15:12:34            0
Broadlink/python-broadlink-master/.gitignore   2021-01-04 12:04:46            6
Broadlink/python-broadlink-master/LICENSE      2021-01-04 12:04:46         1111
Broadlink/python-broadlink-master/README.md    2021-01-04 12:04:46         2514
Broadlink/python-broadlink-master/broadlink/   2021-02-02 15:12:34            0
Broadlink/python-broadlink-master/broadlink/__init__.py 2021-01-04 12:04:46        39918
Broadlink/python-broadlink-master/broadlink/exceptions.py 2021-01-04 12:04:46         2230
Broadlink/python-broadlink-master/cli/         2021-02-02 15:12:34            0
Broadlink/python-broadlink-master/cli/README.md 2021-01-04 12:04:46         1859
Broadlink/python-broadlink-master/cli/broadlink_cli 2021-01-04 12:04:46         7840
Broadlink/python-broadlink-master/cli/broadlink_discovery 2021-01-04 12:04:46         1452
Broadlink/python-broadlink-master/protocol.md  2021-01-04 12:04:46         6527
Broadlink/python-broadlink-master/requirements.txt 2021-01-04 12:04:46           20
Broadlink/python-broadlink-master/setup.py     2021-01-04 12:04:46          750
Broadlink/scr/                                 2021-02-02 15:12:34            0
Broadlink/scr/dombr.cmd                        2021-01-04 12:04:46           45
Broadlink/scr/dombr.sh                         2020-08-10 14:33:58           21
Broadlink/setup.py                             2021-01-27 22:51:14         9129
Broadlink/web/                                 2021-02-02 15:12:34            0
Broadlink/web/css/                             2021-02-02 15:12:34            0
Broadlink/web/css/ModalDialog.css              2021-01-04 12:04:46         3144
Broadlink/web/css/animations.css               2021-01-04 12:04:46        63164
Broadlink/web/css/button.css                   2021-01-04 12:04:46          600
Broadlink/web/css/listdir.css                  2021-01-04 12:04:46        26535
Broadlink/web/css/manage.css                   2021-01-04 12:04:46         4398
Broadlink/web/css/multi.css                    2021-01-04 12:04:46          359
Broadlink/web/css/website.css                  2021-01-04 12:04:46        12403
Broadlink/web/img/                             2021-02-02 15:12:34            0
Broadlink/web/img/A1.txt                       2021-01-04 12:04:46        20914
Broadlink/web/img/MP1.txt                      2021-01-04 12:04:46        11082
Broadlink/web/img/RM2.txt                      2021-01-04 12:04:46        10858
Broadlink/web/img/RM2M.txt                     2021-01-04 12:04:46        28330
Broadlink/web/img/SP.txt                       2021-01-04 12:04:46        15178
Broadlink/web/img/UNK.txt                      2021-01-04 12:04:46         3858
Broadlink/web/js/                              2021-02-02 15:12:36            0
Broadlink/web/js/RGraph.common.core.js         2021-01-04 12:04:46       119363
Broadlink/web/js/RGraph.common.dynamic.js      2021-01-04 12:04:46        19333
Broadlink/web/js/RGraph.common.tooltips.js     2021-01-04 12:04:46        11590
Broadlink/web/js/RGraph.fuel.js                2021-01-04 12:04:46        13216
Broadlink/web/js/RGraph.gauge.js               2021-01-04 12:04:46        22493
Broadlink/web/js/RGraph.meter.js               2021-01-04 12:04:46        22178
Broadlink/web/js/RGraph.odo.js                 2021-01-04 12:04:46        23141
Broadlink/web/js/RGraph.thermometer.js         2021-01-04 12:04:46        15219
Broadlink/web/js/RGraph.vprogress.js           2021-01-04 12:04:46        22682
Broadlink/web/js/Sortable.min.js               2021-01-04 12:04:46        42997
Broadlink/web/js/dynatree.js                   2021-01-04 12:04:46        45094
Broadlink/web/js/iframeResizer.contentWindow.js 2021-01-04 12:04:46        34362
Broadlink/web/js/iframeResizer.js              2021-01-04 12:04:46        36463
Broadlink/web/js/plugincontroller.js           2021-01-04 12:04:46        68167
Broadlink/web/js/sorttable.js                  2021-01-04 12:04:46        16877
Broadlink/web/js/splitter.js                   2021-01-04 12:04:46         5258
Broadlink/web/js/tablesorter.js                2021-01-04 12:04:46        17188
Extracting all the files now...
-*-
 We execute this command : sudo -H python -m pip install python-broadlink-master/.
 We have installed : python-broadlink-master/.
________________________________________
# We do necessary modifications depend of Platform
----------------------------------------
 put *.py files executable (+x) OK
 put *.sh files executable (+x) OK
________________________________________
Checking installation ....
----------------------------------------
Error importing googletrans
and if i try to add hardware from domoticz, below is the log

Code: Select all

2021-02-02 20:17:51.427 Status: Domoticz V2020.2 (c)2012-2020 GizMoCuz
2021-02-02 20:17:51.429 Status: Build Hash: b63341bc0, Date: 2020-04-26 17:17:55
2021-02-02 20:17:51.430 Status: Startup Path: /home/pi/domoticz/
2021-02-02 20:17:52.363 Active notification Subsystems: fcm, http (2/13)
2021-02-02 20:17:52.411 Starting shared server on: :::6144
2021-02-02 20:17:52.357 Status: PluginSystem: Started, Python version '3.7.3'.
2021-02-02 20:17:52.390 Status: WebServer(HTTP) started on address: :: with port 8080
2021-02-02 20:17:52.408 Status: WebServer(SSL) started on address: :: with port 443
2021-02-02 20:17:52.412 Status: RxQueue: queue worker started...
2021-02-02 20:17:52.411 Status: TCPServer: shared server started...
2021-02-02 20:17:54.421 Status: NotificationSystem: thread started...
2021-02-02 20:17:54.421 Status: EventSystem: reset all events...
2021-02-02 20:17:54.427 Status: EventSystem: reset all device statuses...
2021-02-02 20:17:54.559 Status: Python EventSystem: Initalizing event module.
2021-02-02 20:17:54.560 Status: EventSystem: Started
2021-02-02 20:17:54.560 Status: EventSystem: Queue thread started...
2021-02-02 20:17:54.637 Status: PluginSystem: Entering work loop.
2021-02-02 20:31:16.912 Status: (broadlink) Started.
2021-02-02 20:31:17.601 Error: (Broadlink) failed to load 'plugin.py', Python Path used was '/home/pi/domoticz/plugins/Broadlink/:/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-02-02 20:31:17.601 Error: (broadlink) Module Import failed, exception: 'ModuleNotFoundError'
2021-02-02 20:31:17.601 Error: (broadlink) Module Import failed: ' Name: broadlink'
2021-02-02 20:31:17.601 Error: (broadlink) Error Line details not available.
2021-02-02 20:32:17.177 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:32:31.180 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:32:45.183 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:32:59.186 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:33:13.189 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:33:27.192 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:33:41.195 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:33:55.198 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:34:09.201 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:34:23.204 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:34:37.207 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:34:51.210 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:35:05.226 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:35:19.229 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:35:33.232 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:35:47.235 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:36:01.238 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:36:12.713 Status: (broadlink) Stop directive received.
2021-02-02 20:36:12.713 Status: (broadlink) Stopping threads.
2021-02-02 20:36:12.713 Status: (broadlink) Stopped.
2021-02-02 20:36:12.713 Status: (broadlink) Started.
2021-02-02 20:36:13.219 Error: (Broadlink) failed to load 'plugin.py', Python Path used was '/home/pi/domoticz/plugins/Broadlink/:/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-02-02 20:36:13.219 Error: (broadlink) Module Import failed, exception: 'ModuleNotFoundError'
2021-02-02 20:36:13.219 Error: (broadlink) Module Import failed: ' Name: broadlink'
2021-02-02 20:36:13.219 Error: (broadlink) Error Line details not available.
2021-02-02 20:37:25.254 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:37:39.257 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:37:53.260 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:38:07.263 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:38:21.266 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:38:35.269 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:38:49.272 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:39:03.276 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:39:17.279 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:39:31.282 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:39:45.285 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:39:59.288 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:40:13.304 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:40:27.307 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:40:41.310 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:40:55.313 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:41:09.316 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:41:23.270 Status: Incoming connection from: 192.168.1.153
2021-02-02 20:41:23.319 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:41:37.323 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:41:51.326 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:42:05.330 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:42:19.333 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:42:33.336 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:42:47.340 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:43:01.343 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:43:15.346 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:43:29.349 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:43:43.351 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:43:57.354 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:44:01.411 Status: (broadlink) Stop directive received.
2021-02-02 20:44:01.411 Status: (broadlink) Stopping threads.
2021-02-02 20:44:01.411 Status: (broadlink) Stopped.
2021-02-02 20:44:01.411 Status: (broadlink) Started.
2021-02-02 20:44:02.070 Error: (Broadlink) failed to load 'plugin.py', Python Path used was '/home/pi/domoticz/plugins/Broadlink/:/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-02-02 20:44:02.070 Error: (broadlink) Module Import failed, exception: 'ModuleNotFoundError'
2021-02-02 20:44:02.070 Error: (broadlink) Module Import failed: ' Name: broadlink'
2021-02-02 20:44:02.070 Error: (broadlink) Error Line details not available.
2021-02-02 20:45:07.413 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:45:21.416 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:45:35.419 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:45:49.422 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:46:03.425 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:46:17.429 Error: broadlink hardware (2) thread seems to have ended unexpectedly
rjblake
Posts: 142
Joined: Friday 21 October 2016 9:25
Target OS: NAS (Synology & others)
Domoticz version:
Location: Netherlands
Contact:

Re: Python Plugin : Broadlink

Post by rjblake »

extremeaudio wrote: Tuesday 02 February 2021 16:23 Below are the errors I get while installing..

Code: Select all

pi@raspberrypi:~/domoticz/plugins/Broadlink $ python setup.py
*
================================================================================
*
                     Broadlink Plugin Installation
*
================================================================================
*
Python 3.7.3 (default, Jul 25 2020, 13:03:44)
[GCC 8.3.0] on linux
________________________________________
# We need Domoticz Net info
----------------------------------------
ENTER Domoticz IP address (e.g. 192.168.1.45): 192.168.1.153
ENTER Domoticz Port Number (e.g. 8080): 8080
IP/PORT OK
Installation initialized ......
________________________________________
# we retrieve Domoticz language
Request from domoticz to : type=settings
We work with this language : en
On this platform : Linux
________________________________________
# we install necessary modules
----------------------------------------
-*-
 We execute this command : sudo -H python -m pip install setuptools
 We have installed : setuptools
-*-
 We execute this command : sudo -H python -m pip install wheel
 We have installed : wheel
-*-
 We execute this command : sudo -H python -m pip install googletrans
  Could not find a version that satisfies the requirement httpx==0.13.3 (from googletrans) (from versions: )
No matching distribution found for httpx==0.13.3 (from googletrans)
ERROR to start subprocess
1
sudo -H python -m pip install googletrans
b'Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple\nCollecting googletrans\n  Using cached https://files.pythonhosted.org/packages/71/3a/3b19effdd4c03958b90f40fe01c93de6d5280e03843cc5adf6956bfc9512/googletrans-3.0.0.tar.gz\nCollecting httpx==0.13.3 (from googletrans)\n'
 ERROR to install : googletrans
 could be normal if already exist, continue in anyway....
-*-
 We execute this command : sudo -H python -m pip install translate
Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-install-MwklDU/lxml/
ERROR to start subprocess
1
sudo -H python -m pip install translate
b'Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple\nCollecting translate\n  Using cached https://files.pythonhosted.org/packages/85/b2/2ea329a07bbc0c7227eef84ca89ffd6895e7ec237d6c0b26574d56103e53/translate-3.5.0-py2.py3-none-any.whl\nRequirement already satisfied: click in /usr/lib/python2.7/dist-packages (from translate) (7.0)\nCollecting tox (from translate)\n  Using cached https://files.pythonhosted.org/packages/8c/8d/c42440af715d4a6952fe3074bb1cb133681014409743a867c6396401234c/tox-3.21.3-py2.py3-none-any.whl\nRequirement already satisfied: requests in /usr/lib/python2.7/dist-packages (from translate) (2.21.0)\nCollecting pre-commit (from translate)\n  Using cached https://files.pythonhosted.org/packages/df/30/22425aa6680370ba06de107e82eb3fc6159f462619b941241e96dd6bd79b/pre_commit-1.21.0-py2.py3-none-any.whl\nCollecting lxml (from translate)\n  Using cached https://files.pythonhosted.org/packages/db/f7/43fecb94d66959c1e23aa53d6161231dca0e93ec500224cf31b3c4073e37/lxml-4.6.2.tar.gz\n    Complete output from command python setup.py egg_info:\n    Building lxml version 4.6.2.\n    Building without Cython.\n    Error: Please make sure the libxml2 and libxslt development packages are installed.\n    \n    ----------------------------------------\n'
 ERROR to install : translate
 could be normal if already exist, continue in anyway....
-*-
 We execute this command : sudo -H python -m pip install requests
 We have installed : requests
-*-
 We execute this command : sudo -H python -m pip install requests_toolbelt
 We have installed : requests_toolbelt
-*-
 We execute this command : sudo -H python -m pip install irgen
  Could not find a version that satisfies the requirement irgen (from versions: )
No matching distribution found for irgen
ERROR to start subprocess
1
sudo -H python -m pip install irgen
b'Looking in indexes: https://pypi.org/simple, https://www.piwheels.org/simple\nCollecting irgen\n'
 ERROR to install : irgen
 could be normal if already exist, continue in anyway....
________________________________________
# we download plugin files from DropBox (zip format)
----------------------------------------
/usr/lib/python3/dist-packages/urllib3/connectionpool.py:849: InsecureRequestWarning: Unverified HTTPS request is being made. Adding certificate verification is strongly advised. See: https://urllib3.readthedocs.io/en/latest/advanced-usage.html#ssl-warnings
  InsecureRequestWarning)
We download plugin files to: BroadlinkSetup.zip
>> Bytes downloaded -->**1895939**: 100% Done
________________________________________
# we extract necessary plugin files
----------------------------------------
File Name                                             Modified             Size
Broadlink/                                     2021-02-02 15:12:34            0
Broadlink/Dombroadlink.py                      2021-01-27 22:50:10        34987
Broadlink/README.md                            2021-01-21 11:17:02         4350
Broadlink/broadlink_cli.py                     2021-01-04 12:04:46         7840
Broadlink/broadlink_discovery.py               2021-01-04 12:04:46         1452
Broadlink/lng/                                 2021-02-02 15:12:34            0
Broadlink/lng/en_ar.lng                        2021-01-04 12:04:46        21959
Broadlink/lng/en_bg.lng                        2021-01-04 12:04:46        26107
Broadlink/lng/en_bs.lng                        2021-01-04 12:04:46        18895
Broadlink/lng/en_ca.lng                        2021-01-04 12:04:46        19923
Broadlink/lng/en_cs.lng                        2021-01-04 12:04:46        18690
Broadlink/lng/en_da.lng                        2021-01-04 12:04:46        17843
Broadlink/lng/en_de.lng                        2021-01-04 12:04:46        18950
Broadlink/lng/en_el.lng                        2021-01-04 12:04:46        27588
Broadlink/lng/en_en.lng                        2021-01-04 12:04:46        18298
Broadlink/lng/en_es.lng                        2021-01-04 12:04:46        19341
Broadlink/lng/en_et.lng                        2021-01-04 12:04:46        17038
Broadlink/lng/en_fa.lng                        2021-01-04 12:04:46        45771
Broadlink/lng/en_fi.lng                        2021-01-04 12:04:46        17882
Broadlink/lng/en_fr.lng                        2021-01-04 12:04:46        20728
Broadlink/lng/en_fr.lng.tmp                    2021-01-04 12:04:46        19633
Broadlink/lng/en_he.lng                        2021-01-04 12:04:46        20596
Broadlink/lng/en_hu.lng                        2021-01-04 12:04:46        19657
Broadlink/lng/en_is.lng                        2021-01-04 12:04:46        18421
Broadlink/lng/en_it.lng                        2021-01-04 12:04:46        19090
Broadlink/lng/en_lt.lng                        2021-01-04 12:04:46        18217
Broadlink/lng/en_lv.lng                        2021-01-04 12:04:46        18825
Broadlink/lng/en_mk.lng                        2021-01-04 12:04:46        26733
Broadlink/lng/en_nl.lng                        2021-01-04 12:04:46        18492
Broadlink/lng/en_no.lng                        2021-01-04 12:04:46        17974
Broadlink/lng/en_pl.lng                        2021-01-04 12:04:46        18436
Broadlink/lng/en_pt.lng                        2021-01-04 12:04:46        18715
Broadlink/lng/en_ro.lng                        2021-01-04 12:04:46        19152
Broadlink/lng/en_ru.lng                        2021-01-04 12:04:46        24982
Broadlink/lng/en_sk.lng                        2021-01-04 12:04:46        18989
Broadlink/lng/en_sl.lng                        2021-01-04 12:04:46        18562
Broadlink/lng/en_sq.lng                        2021-01-04 12:04:46        18744
Broadlink/lng/en_sr.lng                        2021-01-04 12:04:46        25313
Broadlink/lng/en_sv.lng                        2021-01-04 12:04:46        18022
Broadlink/lng/en_tr.lng                        2021-01-04 12:04:46        18631
Broadlink/lng/en_uk.lng                        2021-01-04 12:04:46        25586
Broadlink/lng/en_zh.lng                        2021-01-04 12:04:46        16863
Broadlink/lng/en_zh_TW.lng                     2021-01-04 12:04:46        60914
Broadlink/plugin.py                            2021-01-08 11:16:38       213722
Broadlink/python-broadlink-master/             2021-02-02 15:12:34            0
Broadlink/python-broadlink-master/.gitignore   2021-01-04 12:04:46            6
Broadlink/python-broadlink-master/LICENSE      2021-01-04 12:04:46         1111
Broadlink/python-broadlink-master/README.md    2021-01-04 12:04:46         2514
Broadlink/python-broadlink-master/broadlink/   2021-02-02 15:12:34            0
Broadlink/python-broadlink-master/broadlink/__init__.py 2021-01-04 12:04:46        39918
Broadlink/python-broadlink-master/broadlink/exceptions.py 2021-01-04 12:04:46         2230
Broadlink/python-broadlink-master/cli/         2021-02-02 15:12:34            0
Broadlink/python-broadlink-master/cli/README.md 2021-01-04 12:04:46         1859
Broadlink/python-broadlink-master/cli/broadlink_cli 2021-01-04 12:04:46         7840
Broadlink/python-broadlink-master/cli/broadlink_discovery 2021-01-04 12:04:46         1452
Broadlink/python-broadlink-master/protocol.md  2021-01-04 12:04:46         6527
Broadlink/python-broadlink-master/requirements.txt 2021-01-04 12:04:46           20
Broadlink/python-broadlink-master/setup.py     2021-01-04 12:04:46          750
Broadlink/scr/                                 2021-02-02 15:12:34            0
Broadlink/scr/dombr.cmd                        2021-01-04 12:04:46           45
Broadlink/scr/dombr.sh                         2020-08-10 14:33:58           21
Broadlink/setup.py                             2021-01-27 22:51:14         9129
Broadlink/web/                                 2021-02-02 15:12:34            0
Broadlink/web/css/                             2021-02-02 15:12:34            0
Broadlink/web/css/ModalDialog.css              2021-01-04 12:04:46         3144
Broadlink/web/css/animations.css               2021-01-04 12:04:46        63164
Broadlink/web/css/button.css                   2021-01-04 12:04:46          600
Broadlink/web/css/listdir.css                  2021-01-04 12:04:46        26535
Broadlink/web/css/manage.css                   2021-01-04 12:04:46         4398
Broadlink/web/css/multi.css                    2021-01-04 12:04:46          359
Broadlink/web/css/website.css                  2021-01-04 12:04:46        12403
Broadlink/web/img/                             2021-02-02 15:12:34            0
Broadlink/web/img/A1.txt                       2021-01-04 12:04:46        20914
Broadlink/web/img/MP1.txt                      2021-01-04 12:04:46        11082
Broadlink/web/img/RM2.txt                      2021-01-04 12:04:46        10858
Broadlink/web/img/RM2M.txt                     2021-01-04 12:04:46        28330
Broadlink/web/img/SP.txt                       2021-01-04 12:04:46        15178
Broadlink/web/img/UNK.txt                      2021-01-04 12:04:46         3858
Broadlink/web/js/                              2021-02-02 15:12:36            0
Broadlink/web/js/RGraph.common.core.js         2021-01-04 12:04:46       119363
Broadlink/web/js/RGraph.common.dynamic.js      2021-01-04 12:04:46        19333
Broadlink/web/js/RGraph.common.tooltips.js     2021-01-04 12:04:46        11590
Broadlink/web/js/RGraph.fuel.js                2021-01-04 12:04:46        13216
Broadlink/web/js/RGraph.gauge.js               2021-01-04 12:04:46        22493
Broadlink/web/js/RGraph.meter.js               2021-01-04 12:04:46        22178
Broadlink/web/js/RGraph.odo.js                 2021-01-04 12:04:46        23141
Broadlink/web/js/RGraph.thermometer.js         2021-01-04 12:04:46        15219
Broadlink/web/js/RGraph.vprogress.js           2021-01-04 12:04:46        22682
Broadlink/web/js/Sortable.min.js               2021-01-04 12:04:46        42997
Broadlink/web/js/dynatree.js                   2021-01-04 12:04:46        45094
Broadlink/web/js/iframeResizer.contentWindow.js 2021-01-04 12:04:46        34362
Broadlink/web/js/iframeResizer.js              2021-01-04 12:04:46        36463
Broadlink/web/js/plugincontroller.js           2021-01-04 12:04:46        68167
Broadlink/web/js/sorttable.js                  2021-01-04 12:04:46        16877
Broadlink/web/js/splitter.js                   2021-01-04 12:04:46         5258
Broadlink/web/js/tablesorter.js                2021-01-04 12:04:46        17188
Extracting all the files now...
-*-
 We execute this command : sudo -H python -m pip install python-broadlink-master/.
 We have installed : python-broadlink-master/.
________________________________________
# We do necessary modifications depend of Platform
----------------------------------------
 put *.py files executable (+x) OK
 put *.sh files executable (+x) OK
________________________________________
Checking installation ....
----------------------------------------
Error importing googletrans
and if i try to add hardware from domoticz, below is the log

Code: Select all

2021-02-02 20:17:51.427 Status: Domoticz V2020.2 (c)2012-2020 GizMoCuz
2021-02-02 20:17:51.429 Status: Build Hash: b63341bc0, Date: 2020-04-26 17:17:55
2021-02-02 20:17:51.430 Status: Startup Path: /home/pi/domoticz/
2021-02-02 20:17:52.363 Active notification Subsystems: fcm, http (2/13)
2021-02-02 20:17:52.411 Starting shared server on: :::6144
2021-02-02 20:17:52.357 Status: PluginSystem: Started, Python version '3.7.3'.
2021-02-02 20:17:52.390 Status: WebServer(HTTP) started on address: :: with port 8080
2021-02-02 20:17:52.408 Status: WebServer(SSL) started on address: :: with port 443
2021-02-02 20:17:52.412 Status: RxQueue: queue worker started...
2021-02-02 20:17:52.411 Status: TCPServer: shared server started...
2021-02-02 20:17:54.421 Status: NotificationSystem: thread started...
2021-02-02 20:17:54.421 Status: EventSystem: reset all events...
2021-02-02 20:17:54.427 Status: EventSystem: reset all device statuses...
2021-02-02 20:17:54.559 Status: Python EventSystem: Initalizing event module.
2021-02-02 20:17:54.560 Status: EventSystem: Started
2021-02-02 20:17:54.560 Status: EventSystem: Queue thread started...
2021-02-02 20:17:54.637 Status: PluginSystem: Entering work loop.
2021-02-02 20:31:16.912 Status: (broadlink) Started.
2021-02-02 20:31:17.601 Error: (Broadlink) failed to load 'plugin.py', Python Path used was '/home/pi/domoticz/plugins/Broadlink/:/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-02-02 20:31:17.601 Error: (broadlink) Module Import failed, exception: 'ModuleNotFoundError'
2021-02-02 20:31:17.601 Error: (broadlink) Module Import failed: ' Name: broadlink'
2021-02-02 20:31:17.601 Error: (broadlink) Error Line details not available.
2021-02-02 20:32:17.177 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:32:31.180 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:32:45.183 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:32:59.186 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:33:13.189 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:33:27.192 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:33:41.195 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:33:55.198 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:34:09.201 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:34:23.204 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:34:37.207 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:34:51.210 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:35:05.226 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:35:19.229 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:35:33.232 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:35:47.235 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:36:01.238 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:36:12.713 Status: (broadlink) Stop directive received.
2021-02-02 20:36:12.713 Status: (broadlink) Stopping threads.
2021-02-02 20:36:12.713 Status: (broadlink) Stopped.
2021-02-02 20:36:12.713 Status: (broadlink) Started.
2021-02-02 20:36:13.219 Error: (Broadlink) failed to load 'plugin.py', Python Path used was '/home/pi/domoticz/plugins/Broadlink/:/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-02-02 20:36:13.219 Error: (broadlink) Module Import failed, exception: 'ModuleNotFoundError'
2021-02-02 20:36:13.219 Error: (broadlink) Module Import failed: ' Name: broadlink'
2021-02-02 20:36:13.219 Error: (broadlink) Error Line details not available.
2021-02-02 20:37:25.254 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:37:39.257 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:37:53.260 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:38:07.263 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:38:21.266 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:38:35.269 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:38:49.272 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:39:03.276 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:39:17.279 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:39:31.282 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:39:45.285 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:39:59.288 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:40:13.304 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:40:27.307 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:40:41.310 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:40:55.313 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:41:09.316 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:41:23.270 Status: Incoming connection from: 192.168.1.153
2021-02-02 20:41:23.319 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:41:37.323 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:41:51.326 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:42:05.330 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:42:19.333 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:42:33.336 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:42:47.340 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:43:01.343 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:43:15.346 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:43:29.349 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:43:43.351 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:43:57.354 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:44:01.411 Status: (broadlink) Stop directive received.
2021-02-02 20:44:01.411 Status: (broadlink) Stopping threads.
2021-02-02 20:44:01.411 Status: (broadlink) Stopped.
2021-02-02 20:44:01.411 Status: (broadlink) Started.
2021-02-02 20:44:02.070 Error: (Broadlink) failed to load 'plugin.py', Python Path used was '/home/pi/domoticz/plugins/Broadlink/:/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-02-02 20:44:02.070 Error: (broadlink) Module Import failed, exception: 'ModuleNotFoundError'
2021-02-02 20:44:02.070 Error: (broadlink) Module Import failed: ' Name: broadlink'
2021-02-02 20:44:02.070 Error: (broadlink) Error Line details not available.
2021-02-02 20:45:07.413 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:45:21.416 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:45:35.419 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:45:49.422 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:46:03.425 Error: broadlink hardware (2) thread seems to have ended unexpectedly
2021-02-02 20:46:17.429 Error: broadlink hardware (2) thread seems to have ended unexpectedly
From similar problems, I had to do a manual install. As you have an install error, seems you did not satisfy the prerequisites forst. You need to have the following installed ['googletrans', 'translate', 'requests', 'requests_toolbelt'] - you can install these with pip (I did with

Code: Select all

sudo pip install <library>
). As for the next error, guess it isn't installed to start with, so try that first. However, I ran into the same problem as seems Domoticz insists on Python3.7 as the default (and even with it installed as default I have issues when I have alternate versions installed)
extremeaudio
Posts: 47
Joined: Tuesday 24 November 2020 17:57
Target OS: Linux
Domoticz version:
Contact:

Re: Python Plugin : Broadlink

Post by extremeaudio »

Thanks for the help. I now have the device showing up in domoticz.

But I now get the following errors in domoticz log

Code: Select all

2021-02-03 17:35:41.285 Status: Domoticz V2020.2 (c)2012-2020 GizMoCuz
2021-02-03 17:35:41.285 Status: Build Hash: b63341bc0, Date: 2020-04-26 17:17:55
2021-02-03 17:35:41.286 Status: Startup Path: /home/pi/domoticz/
2021-02-03 17:35:42.318 Active notification Subsystems: fcm, http (2/13)
2021-02-03 17:35:42.369 Starting shared server on: :::6144
2021-02-03 17:35:42.306 Status: PluginSystem: Started, Python version '3.7.3'.
2021-02-03 17:35:42.343 Status: WebServer(HTTP) started on address: :: with port 8080
2021-02-03 17:35:42.364 Status: WebServer(SSL) started on address: :: with port 443
2021-02-03 17:35:42.370 Status: RxQueue: queue worker started...
2021-02-03 17:35:42.370 Status: TCPServer: shared server started...
2021-02-03 17:35:44.371 Status: (broadlink) Started.
2021-02-03 17:35:44.371 Status: NotificationSystem: thread started...
2021-02-03 17:35:44.372 Status: EventSystem: reset all events...
2021-02-03 17:35:44.376 Status: EventSystem: reset all device statuses...
2021-02-03 17:35:44.542 Status: PluginSystem: Entering work loop.
2021-02-03 17:35:44.543 Status: Python EventSystem: Initalizing event module.
2021-02-03 17:35:44.544 Status: EventSystem: Started
2021-02-03 17:35:44.544 Status: EventSystem: Queue thread started...
2021-02-03 17:35:48.394 (broadlink) lang file : /home/pi/domoticz/plugins/Broadlink/lng/en_en.lng
2021-02-03 17:35:48.394 (broadlink) Language loaded for : en
2021-02-03 17:35:48.404 (broadlink) Listen on BROWebServer - Port: 9000
2021-02-03 17:35:48.452 (broadlink) Plugin Device count start on : 9
2021-02-03 17:35:48.475 (broadlink) Connecting to: 192.168.1.119 : 24DFA7E86E65
2021-02-03 17:35:48.501 (broadlink) Admin html file created: /home/pi/domoticz/www/templates/Broadlink-RM24M-2.html
2021-02-03 17:35:48.371 Status: (broadlink) Entering work loop.
2021-02-03 17:35:48.372 Status: (broadlink) Initialized version 1.6.3, author 'zak45'
2021-02-03 17:35:48.475 Error: (broadlink) Traceback (most recent call last):
2021-02-03 17:35:48.475 File "/home/pi/domoticz/plugins/Broadlink/plugin.py", line 404, in onStart
2021-02-03 17:35:48.475 with open(devfile, 'w', encoding='utf-8') as fp:
2021-02-03 17:35:48.475 FileNotFoundError: [Errno 2] No such file or directory: '/home/pi/domoticz/plugins/Broadlink/log/2RM24M.txt'
2021-02-03 17:35:48.475
2021-02-03 17:35:48.475 Error: (broadlink) Error to create device file : /home/pi/domoticz/plugins/Broadlink/log/2RM24M.txt
2021-02-03 17:35:48.476 Error: (broadlink) Traceback (most recent call last):
2021-02-03 17:35:48.476 File "/home/pi/domoticz/plugins/Broadlink/plugin.py", line 1823, in read_type
2021-02-03 17:35:48.476 with open(devfile, 'r', encoding='utf-8') as f:
2021-02-03 17:35:48.476 FileNotFoundError: [Errno 2] No such file or directory: '/home/pi/domoticz/plugins/Broadlink/log/2RM24M.txt'
2021-02-03 17:35:48.476
2021-02-03 17:35:48.476 Error: (broadlink) Error to retrieve type from this file : /home/pi/domoticz/plugins/Broadlink/log/2RM24M.txt
2021-02-03 17:35:48.483 Error: (broadlink) Traceback (most recent call last):
2021-02-03 17:35:48.483 File "/home/pi/domoticz/plugins/Broadlink/plugin.py", line 1803, in broadlink_connect
2021-02-03 17:35:48.483 DEVICE.auth()
2021-02-03 17:35:48.483 File "/usr/local/lib/python3.7/dist-packages/broadlink/__init__.py", line 270, in auth
2021-02-03 17:35:48.483 response = self.send_packet(0x65, payload)
2021-02-03 17:35:48.483 File "/usr/local/lib/python3.7/dist-packages/broadlink/__init__.py", line 323, in send_packet
2021-02-03 17:35:48.483 packet[0x25] = self.devtype >> 8
2021-02-03 17:35:48.483 ValueError: byte must be in range(0, 256)
2021-02-03 17:35:48.483
2021-02-03 17:35:48.483 Error: (broadlink) Error to connect to Broadlink device: 192.168.1.119
2021-02-03 17:35:58.406 Error: (broadlink) Traceback (most recent call last):
2021-02-03 17:35:58.406 File "/home/pi/domoticz/plugins/Broadlink/plugin.py", line 1823, in read_type
2021-02-03 17:35:58.406 with open(devfile, 'r', encoding='utf-8') as f:
2021-02-03 17:35:58.406 FileNotFoundError: [Errno 2] No such file or directory: '/home/pi/domoticz/plugins/Broadlink/log/2RM24M.txt'
2021-02-03 17:35:58.406
2021-02-03 17:35:58.407 Error: (broadlink) Error to retrieve type from this file : /home/pi/domoticz/plugins/Broadlink/log/2RM24M.txt
2021-02-03 17:35:58.409 Error: (broadlink) Traceback (most recent call last):
2021-02-03 17:35:58.409 File "/home/pi/domoticz/plugins/Broadlink/plugin.py", line 1803, in broadlink_connect
2021-02-03 17:35:58.409 DEVICE.auth()
2021-02-03 17:35:58.409 File "/usr/local/lib/python3.7/dist-packages/broadlink/__init__.py", line 270, in auth
2021-02-03 17:35:58.409 response = self.send_packet(0x65, payload)
2021-02-03 17:35:58.409 File "/usr/local/lib/python3.7/dist-packages/broadlink/__init__.py", line 323, in send_packet
2021-02-03 17:35:58.409 packet[0x25] = self.devtype >> 8
2021-02-03 17:35:58.409 ValueError: byte must be in range(0, 256)
2021-02-03 17:35:58.409
2021-02-03 17:35:58.409 Error: (broadlink) Error to connect to Broadlink device: 192.168.1.119
2021-02-03 17:38:39.388 (broadlink) onCommand called for Unit 2: Parameter 'Set Level', Level: 20 , Connected : False
2021-02-03 17:38:39.404 (broadlink) Nothing to send
2021-02-03 17:38:39.382 Status: User: Admin initiated a switch command (2/broadlink - IR Commands/Set Level)
2021-02-03 17:38:43.925 (broadlink) onCommand called for Unit 2: Parameter 'Set Level', Level: 20 , Connected : False
2021-02-03 17:38:43.939 (broadlink) Nothing to send
2021-02-03 17:38:43.889 Status: User: Admin initiated a switch command (2/broadlink - IR Commands/Set Level)
2021-02-03 17:38:53.221 (broadlink) onCommand called for Unit 2: Parameter 'Set Level', Level: 10 , Connected : False
2021-02-03 17:38:53.233 (broadlink) Update 1:'Learn IR command' (broadlink - RM24M-Status)
2021-02-03 17:38:53.199 Status: User: Admin initiated a switch command (2/broadlink - IR Commands/Set Level)
2021-02-03 17:39:03.206 (broadlink) onCommand called for Unit 2: Parameter 'Set Level', Level: 20 , Connected : False
2021-02-03 17:39:03.221 (broadlink) Nothing to send
2021-02-03 17:39:03.172 Status: User: Admin initiated a switch command (2/broadlink - IR Commands/Set Level)
2021-02-03 17:39:06.140 (broadlink) onCommand called for Unit 2: Parameter 'Set Level', Level: 40 , Connected : False
2021-02-03 17:39:06.140 (broadlink) Nothing to reset
2021-02-03 17:39:06.153 (broadlink) Update 1:'reset IR/RF' (broadlink - RM24M-Status)
2021-02-03 17:39:06.097 Status: User: Admin initiated a switch command (2/broadlink - IR Commands/Set Level)
2021-02-03 17:39:06.165 Error: (broadlink) 'onCommand' failed 'AttributeError':''device' object has no attribute 'check_frequency''.
2021-02-03 17:39:06.166 Error: (broadlink) ----> Line 544 in '/home/pi/domoticz/plugins/Broadlink/plugin.py', function onCommand
2021-02-03 17:39:06.166 Error: (broadlink) ----> Line 1715 in '/home/pi/domoticz/plugins/Broadlink/plugin.py', function reset
2021-02-03 17:39:13.531 (broadlink) onCommand called for Unit 1: Parameter 'Select', Level: 0 , Connected : False
2021-02-03 17:39:13.545 (broadlink) Update 1:'undefined' (broadlink - RM24M-Status)
2021-02-03 17:39:13.531 Error: (broadlink) Send error or command for remote controller not set into ini file: Select
2021-02-03 17:39:13.532 Error: (broadlink) Traceback (most recent call last):
2021-02-03 17:39:13.532 File "/home/pi/domoticz/plugins/Broadlink/plugin.py", line 2021, in remote_send
2021-02-03 17:39:13.532 if REMOTETOSEND[k] != 0:
2021-02-03 17:39:13.532 IndexError: tuple index out of range
2021-02-03 17:39:13.532
2021-02-03 17:39:14.548 (broadlink) onCommand called for Unit 1: Parameter 'Down', Level: 0 , Connected : False
2021-02-03 17:39:14.599 (broadlink) onCommand called for Unit 1: Parameter 'Down', Level: 0 , Connected : False
2021-02-03 17:39:14.851 (broadlink) onCommand called for Unit 1: Parameter 'Down', Level: 0 , Connected : False
2021-02-03 17:39:14.548 Error: (broadlink) Send error or command for remote controller not set into ini file: Down
2021-02-03 17:39:14.549 Error: (broadlink) Traceback (most recent call last):
2021-02-03 17:39:14.549 File "/home/pi/domoticz/plugins/Broadlink/plugin.py", line 2021, in remote_send
2021-02-03 17:39:14.549 if REMOTETOSEND[k] != 0:
2021-02-03 17:39:14.549 IndexError: tuple index out of range
2021-02-03 17:39:14.549
2021-02-03 17:39:14.599 Error: (broadlink) Send error or command for remote controller not set into ini file: Down
2021-02-03 17:39:14.600 Error: (broadlink) Traceback (most recent call last):
2021-02-03 17:39:14.600 File "/home/pi/domoticz/plugins/Broadlink/plugin.py", line 2021, in remote_send
2021-02-03 17:39:14.600 if REMOTETOSEND[k] != 0:
2021-02-03 17:39:14.600 IndexError: tuple index out of range
2021-02-03 17:39:14.600
2021-02-03 17:39:14.851 Error: (broadlink) Send error or command for remote controller not set into ini file: Down
2021-02-03 17:39:14.852 Error: (broadlink) Traceback (most recent call last):
2021-02-03 17:39:14.852 File "/home/pi/domoticz/plugins/Broadlink/plugin.py", line 2021, in remote_send
2021-02-03 17:39:14.852 if REMOTETOSEND[k] != 0:
2021-02-03 17:39:14.852 IndexError: tuple index out of range
2021-02-03 17:39:14.852
2021-02-03 17:39:50.673 (broadlink) onCommand called for Unit 2: Parameter 'Set Level', Level: 10 , Connected : False
2021-02-03 17:39:50.691 (broadlink) Update 1:'Learn IR command' (broadlink - RM24M-Status)
2021-02-03 17:39:50.662 Status: User: Admin initiated a switch command (2/broadlink - IR Commands/Set Level)
2021-02-03 17:40:08.847 (broadlink) Update 0:'Off' (broadlink - RM24M-Status)
2021-02-03 17:40:08.826 Error: (broadlink) Traceback (most recent call last):
2021-02-03 17:40:08.826 File "/home/pi/domoticz/plugins/Broadlink/plugin.py", line 1823, in read_type
2021-02-03 17:40:08.826 with open(devfile, 'r', encoding='utf-8') as f:
2021-02-03 17:40:08.826 FileNotFoundError: [Errno 2] No such file or directory: '/home/pi/domoticz/plugins/Broadlink/log/2RM24M.txt'
2021-02-03 17:40:08.826
2021-02-03 17:40:08.826 Error: (broadlink) Error to retrieve type from this file : /home/pi/domoticz/plugins/Broadlink/log/2RM24M.txt
2021-02-03 17:40:08.828 Error: (broadlink) Traceback (most recent call last):
2021-02-03 17:40:08.828 File "/home/pi/domoticz/plugins/Broadlink/plugin.py", line 1803, in broadlink_connect
2021-02-03 17:40:08.828 DEVICE.auth()
2021-02-03 17:40:08.828 File "/usr/local/lib/python3.7/dist-packages/broadlink/__init__.py", line 270, in auth
2021-02-03 17:40:08.828 response = self.send_packet(0x65, payload)
2021-02-03 17:40:08.828 File "/usr/local/lib/python3.7/dist-packages/broadlink/__init__.py", line 323, in send_packet
2021-02-03 17:40:08.828 packet[0x25] = self.devtype >> 8
2021-02-03 17:40:08.828 ValueError: byte must be in range(0, 256)
2021-02-03 17:40:08.828
2021-02-03 17:40:08.829 Error: (broadlink) Error to connect to Broadlink device: 192.168.1.119
zak45
Posts: 952
Joined: Sunday 22 January 2017 11:37
Target OS: Windows
Domoticz version: V2024.4
Contact:

Re: Python Plugin : Broadlink

Post by zak45 »

extremeaudio wrote: Wednesday 03 February 2021 13:11 Thanks for the help. I now have the device showing up in domoticz.

But I now get the following errors in domoticz log

2021-02-03 17:35:48.476 FileNotFoundError: [Errno 2] No such file or directory: '/home/pi/domoticz/plugins/Broadlink/log/2RM24M.txt'
2021-02-03 17:35:48.476
2021-02-03 17:35:48.476 Error: (broadlink) Error to retrieve type from this file : /home/pi/domoticz/plugins/Broadlink/log/2RM24M.txt
Verify that this folder exist : '/home/pi/domoticz/plugins/Broadlink/log
and that your process had enough right on it (RW)
extremeaudio
Posts: 47
Joined: Tuesday 24 November 2020 17:57
Target OS: Linux
Domoticz version:
Contact:

Re: Python Plugin : Broadlink

Post by extremeaudio »

zak45 wrote: Thursday 04 February 2021 12:20 Verify that this folder exist : '/home/pi/domoticz/plugins/Broadlink/log
and that your process had enough right on it (RW)
No there is no such folder at that path.
extremeaudio
Posts: 47
Joined: Tuesday 24 November 2020 17:57
Target OS: Linux
Domoticz version:
Contact:

Re: Python Plugin : Broadlink

Post by extremeaudio »

Should I manually create it ?
zak45
Posts: 952
Joined: Sunday 22 January 2017 11:37
Target OS: Windows
Domoticz version: V2024.4
Contact:

Re: Python Plugin : Broadlink

Post by zak45 »

these are necessaries folders:
Capture.PNG
Capture.PNG (69.66 KiB) Viewed 1603 times
if not present; just create.
extremeaudio
Posts: 47
Joined: Tuesday 24 November 2020 17:57
Target OS: Linux
Domoticz version:
Contact:

Re: Python Plugin : Broadlink

Post by extremeaudio »

That worked. Very greatly appreciate your efforts, I was very close to giving up on Domoticz altogether merely because I was not able to control IR devices. Thank you.
Post Reply

Who is online

Users browsing this forum: No registered users and 1 guest