user@openhab-vm:/home/openhab/python-broadlink$ sudo python setup.py install
running install
running bdist_egg
running egg_info
writing broadlink.egg-info/PKG-INFO
writing dependency_links to broadlink.egg-info/dependency_links.txt
writing requirements to broadlink.egg-info/requires.txt
writing top-level names to broadlink.egg-info/top_level.txt
reading manifest file 'broadlink.egg-info/SOURCES.txt'
writing manifest file 'broadlink.egg-info/SOURCES.txt'
installing library code to build/bdist.linux-x86_64/egg
running install_lib
running build_py
creating build/lib
creating build/lib/broadlink
copying broadlink/sensor.py -> build/lib/broadlink
copying broadlink/helpers.py -> build/lib/broadlink
copying broadlink/cover.py -> build/lib/broadlink
copying broadlink/light.py -> build/lib/broadlink
copying broadlink/remote.py -> build/lib/broadlink
copying broadlink/switch.py -> build/lib/broadlink
copying broadlink/protocol.py -> build/lib/broadlink
copying broadlink/init.py -> build/lib/broadlink
copying broadlink/exceptions.py -> build/lib/broadlink
copying broadlink/climate.py -> build/lib/broadlink
copying broadlink/alarm.py -> build/lib/broadlink
copying broadlink/device.py -> build/lib/broadlink
creating build/bdist.linux-x86_64/egg
creating build/bdist.linux-x86_64/egg/broadlink
copying build/lib/broadlink/sensor.py -> build/bdist.linux-x86_64/egg/broadlink
copying build/lib/broadlink/helpers.py -> build/bdist.linux-x86_64/egg/broadlink
copying build/lib/broadlink/cover.py -> build/bdist.linux-x86_64/egg/broadlink
copying build/lib/broadlink/light.py -> build/bdist.linux-x86_64/egg/broadlink
copying build/lib/broadlink/remote.py -> build/bdist.linux-x86_64/egg/broadlink
copying build/lib/broadlink/switch.py -> build/bdist.linux-x86_64/egg/broadlink
copying build/lib/broadlink/protocol.py -> build/bdist.linux-x86_64/egg/broadlink
copying build/lib/broadlink/init.py -> build/bdist.linux-x86_64/egg/broadlink
copying build/lib/broadlink/exceptions.py -> build/bdist.linux-x86_64/egg/broadlink
copying build/lib/broadlink/climate.py -> build/bdist.linux-x86_64/egg/broadlink
copying build/lib/broadlink/alarm.py -> build/bdist.linux-x86_64/egg/broadlink
copying build/lib/broadlink/device.py -> build/bdist.linux-x86_64/egg/broadlink
byte-compiling build/bdist.linux-x86_64/egg/broadlink/sensor.py to sensor.cpython-39.pyc
byte-compiling build/bdist.linux-x86_64/egg/broadlink/helpers.py to helpers.cpython-39.pyc
byte-compiling build/bdist.linux-x86_64/egg/broadlink/cover.py to cover.cpython-39.pyc
byte-compiling build/bdist.linux-x86_64/egg/broadlink/light.py to light.cpython-39.pyc
byte-compiling build/bdist.linux-x86_64/egg/broadlink/remote.py to remote.cpython-39.pyc
byte-compiling build/bdist.linux-x86_64/egg/broadlink/switch.py to switch.cpython-39.pyc
byte-compiling build/bdist.linux-x86_64/egg/broadlink/protocol.py to protocol.cpython-39.pyc
byte-compiling build/bdist.linux-x86_64/egg/broadlink/init.py to init.cpython-39.pyc
byte-compiling build/bdist.linux-x86_64/egg/broadlink/exceptions.py to exceptions.cpython-39.pyc
byte-compiling build/bdist.linux-x86_64/egg/broadlink/climate.py to climate.cpython-39.pyc
byte-compiling build/bdist.linux-x86_64/egg/broadlink/alarm.py to alarm.cpython-39.pyc
byte-compiling build/bdist.linux-x86_64/egg/broadlink/device.py to device.cpython-39.pyc
creating build/bdist.linux-x86_64/egg/EGG-INFO
copying broadlink.egg-info/PKG-INFO -> build/bdist.linux-x86_64/egg/EGG-INFO
copying broadlink.egg-info/SOURCES.txt -> build/bdist.linux-x86_64/egg/EGG-INFO
copying broadlink.egg-info/dependency_links.txt -> build/bdist.linux-x86_64/egg/EGG-INFO
copying broadlink.egg-info/not-zip-safe -> build/bdist.linux-x86_64/egg/EGG-INFO
copying broadlink.egg-info/requires.txt -> build/bdist.linux-x86_64/egg/EGG-INFO
copying broadlink.egg-info/top_level.txt -> build/bdist.linux-x86_64/egg/EGG-INFO
creating 'dist/broadlink-0.17.0-py3.9.egg' and adding 'build/bdist.linux-x86_64/egg' to it
removing 'build/bdist.linux-x86_64/egg' (and everything under it)
Processing broadlink-0.17.0-py3.9.egg
removing '/usr/local/lib/python3.9/dist-packages/broadlink-0.17.0-py3.9.egg' (and everything under it)
creating /usr/local/lib/python3.9/dist-packages/broadlink-0.17.0-py3.9.egg
Extracting broadlink-0.17.0-py3.9.egg to /usr/local/lib/python3.9/dist-packages
broadlink 0.17.0 is already the active version in easy-install.pth
Installed /usr/local/lib/python3.9/dist-packages/broadlink-0.17.0-py3.9.egg
Processing dependencies for broadlink==0.17.0
Searching for cryptography==3.2
Best match: cryptography 3.2
Adding cryptography 3.2 to easy-install.pth file
Using /usr/local/lib/python3.9/dist-packages
Searching for six==1.16.0
Best match: six 1.16.0
Adding six 1.16.0 to easy-install.pth file
Using /usr/lib/python3/dist-packages
Searching for cffi==1.15.0rc2
Best match: cffi 1.15.0rc2
Processing cffi-1.15.0rc2-py3.9-linux-x86_64.egg
cffi 1.15.0rc2 is already the active version in easy-install.pth
Using /usr/local/lib/python3.9/dist-packages/cffi-1.15.0rc2-py3.9-linux-x86_64.egg
Searching for pycparser==2.20
Best match: pycparser 2.20
Processing pycparser-2.20-py3.9.egg
pycparser 2.20 is already the active version in easy-install.pth
Using /usr/local/lib/python3.9/dist-packages/pycparser-2.20-py3.9.egg
Finished processing dependencies for broadlink==0.17.0
Device file data (to be used with --device @filename in broadlink_cli) :
0x279d 10.0.30.99 780f77XXXXXX
temperature = 0.0
BlackBeanControl part :
user@openhab-vm:/home/openhab/BlackBeanControl$ python BlackBeanControl.py -c stb_power
File "/home/openhab/BlackBeanControl/BlackBeanControl.py", line 197
if (len(SentCommand) <> 8) or (not all(c in string.hexdigits for c in SentCommand)):
^
SyntaxError: invalid syntax
user@openhab-vm:/home/openhab/BlackBeanControl$ python2 BlackBeanControl.py -c stb_power
Traceback (most recent call last):
File "BlackBeanControl.py", line 3, in
import broadlink, configparser
File "/usr/local/lib/python2.7/dist-packages/broadlink-0.17.0-py2.7.egg/broadlink/init.py", line 114
dev_type: int,
^
SyntaxError: invalid syntax
Out of curiosity, I even tried python3 :)
user@openhab-vm:/home/openhab/BlackBeanControl$ python3 BlackBeanControl.py -c stb_power
File "/home/openhab/BlackBeanControl/BlackBeanControl.py", line 197
if (len(SentCommand) <> 8) or (not all(c in string.hexdigits for c in SentCommand)):
^
SyntaxError: invalid syntax
Now it is not clear to me whether I may have a conflict that originates from the installation of python-broadlink or the causes are in the BlackBeanControl libraries themselves or somewhere else :(
I would ask for a hint or advice on where I stumbled over :)
From https://github.com/mjg59/python-broadlink python-broadlink 0.17.0 - Installation & Discovering test Works properly
INSTALL
user@openhab-vm:/home/openhab/python-broadlink$ sudo python setup.py install running install running bdist_egg running egg_info writing broadlink.egg-info/PKG-INFO writing dependency_links to broadlink.egg-info/dependency_links.txt writing requirements to broadlink.egg-info/requires.txt writing top-level names to broadlink.egg-info/top_level.txt reading manifest file 'broadlink.egg-info/SOURCES.txt' writing manifest file 'broadlink.egg-info/SOURCES.txt' installing library code to build/bdist.linux-x86_64/egg running install_lib running build_py creating build/lib creating build/lib/broadlink copying broadlink/sensor.py -> build/lib/broadlink copying broadlink/helpers.py -> build/lib/broadlink copying broadlink/cover.py -> build/lib/broadlink copying broadlink/light.py -> build/lib/broadlink copying broadlink/remote.py -> build/lib/broadlink copying broadlink/switch.py -> build/lib/broadlink copying broadlink/protocol.py -> build/lib/broadlink copying broadlink/init.py -> build/lib/broadlink copying broadlink/exceptions.py -> build/lib/broadlink copying broadlink/climate.py -> build/lib/broadlink copying broadlink/alarm.py -> build/lib/broadlink copying broadlink/device.py -> build/lib/broadlink creating build/bdist.linux-x86_64/egg creating build/bdist.linux-x86_64/egg/broadlink copying build/lib/broadlink/sensor.py -> build/bdist.linux-x86_64/egg/broadlink copying build/lib/broadlink/helpers.py -> build/bdist.linux-x86_64/egg/broadlink copying build/lib/broadlink/cover.py -> build/bdist.linux-x86_64/egg/broadlink copying build/lib/broadlink/light.py -> build/bdist.linux-x86_64/egg/broadlink copying build/lib/broadlink/remote.py -> build/bdist.linux-x86_64/egg/broadlink copying build/lib/broadlink/switch.py -> build/bdist.linux-x86_64/egg/broadlink copying build/lib/broadlink/protocol.py -> build/bdist.linux-x86_64/egg/broadlink copying build/lib/broadlink/init.py -> build/bdist.linux-x86_64/egg/broadlink copying build/lib/broadlink/exceptions.py -> build/bdist.linux-x86_64/egg/broadlink copying build/lib/broadlink/climate.py -> build/bdist.linux-x86_64/egg/broadlink copying build/lib/broadlink/alarm.py -> build/bdist.linux-x86_64/egg/broadlink copying build/lib/broadlink/device.py -> build/bdist.linux-x86_64/egg/broadlink byte-compiling build/bdist.linux-x86_64/egg/broadlink/sensor.py to sensor.cpython-39.pyc byte-compiling build/bdist.linux-x86_64/egg/broadlink/helpers.py to helpers.cpython-39.pyc byte-compiling build/bdist.linux-x86_64/egg/broadlink/cover.py to cover.cpython-39.pyc byte-compiling build/bdist.linux-x86_64/egg/broadlink/light.py to light.cpython-39.pyc byte-compiling build/bdist.linux-x86_64/egg/broadlink/remote.py to remote.cpython-39.pyc byte-compiling build/bdist.linux-x86_64/egg/broadlink/switch.py to switch.cpython-39.pyc byte-compiling build/bdist.linux-x86_64/egg/broadlink/protocol.py to protocol.cpython-39.pyc byte-compiling build/bdist.linux-x86_64/egg/broadlink/init.py to init.cpython-39.pyc byte-compiling build/bdist.linux-x86_64/egg/broadlink/exceptions.py to exceptions.cpython-39.pyc byte-compiling build/bdist.linux-x86_64/egg/broadlink/climate.py to climate.cpython-39.pyc byte-compiling build/bdist.linux-x86_64/egg/broadlink/alarm.py to alarm.cpython-39.pyc byte-compiling build/bdist.linux-x86_64/egg/broadlink/device.py to device.cpython-39.pyc creating build/bdist.linux-x86_64/egg/EGG-INFO copying broadlink.egg-info/PKG-INFO -> build/bdist.linux-x86_64/egg/EGG-INFO copying broadlink.egg-info/SOURCES.txt -> build/bdist.linux-x86_64/egg/EGG-INFO copying broadlink.egg-info/dependency_links.txt -> build/bdist.linux-x86_64/egg/EGG-INFO copying broadlink.egg-info/not-zip-safe -> build/bdist.linux-x86_64/egg/EGG-INFO copying broadlink.egg-info/requires.txt -> build/bdist.linux-x86_64/egg/EGG-INFO copying broadlink.egg-info/top_level.txt -> build/bdist.linux-x86_64/egg/EGG-INFO creating 'dist/broadlink-0.17.0-py3.9.egg' and adding 'build/bdist.linux-x86_64/egg' to it removing 'build/bdist.linux-x86_64/egg' (and everything under it) Processing broadlink-0.17.0-py3.9.egg removing '/usr/local/lib/python3.9/dist-packages/broadlink-0.17.0-py3.9.egg' (and everything under it) creating /usr/local/lib/python3.9/dist-packages/broadlink-0.17.0-py3.9.egg Extracting broadlink-0.17.0-py3.9.egg to /usr/local/lib/python3.9/dist-packages broadlink 0.17.0 is already the active version in easy-install.pth
Installed /usr/local/lib/python3.9/dist-packages/broadlink-0.17.0-py3.9.egg Processing dependencies for broadlink==0.17.0 Searching for cryptography==3.2 Best match: cryptography 3.2 Adding cryptography 3.2 to easy-install.pth file
Using /usr/local/lib/python3.9/dist-packages Searching for six==1.16.0 Best match: six 1.16.0 Adding six 1.16.0 to easy-install.pth file
Using /usr/lib/python3/dist-packages Searching for cffi==1.15.0rc2 Best match: cffi 1.15.0rc2 Processing cffi-1.15.0rc2-py3.9-linux-x86_64.egg cffi 1.15.0rc2 is already the active version in easy-install.pth
Using /usr/local/lib/python3.9/dist-packages/cffi-1.15.0rc2-py3.9-linux-x86_64.egg Searching for pycparser==2.20 Best match: pycparser 2.20 Processing pycparser-2.20-py3.9.egg pycparser 2.20 is already the active version in easy-install.pth
Using /usr/local/lib/python3.9/dist-packages/pycparser-2.20-py3.9.egg Finished processing dependencies for broadlink==0.17.0
TEST
user@openhab-vm:/home/openhab/python-broadlink/cli$ python broadlink_discovery --timeout 10 --dst-ip 10.0.30.99 Discovering... ########################################### RMPRO
broadlink_cli --type 0x279d --host 10.0.30.99 --mac 780f77XXXXXX
Device file data (to be used with --device @filename in broadlink_cli) : 0x279d 10.0.30.99 780f77XXXXXX temperature = 0.0
user@openhab-vm:/home/openhab/python-broadlink/cli$ python3 broadlink_discovery --timeout 10 --dst-ip 10.0.30.99 Discovering... ########################################### RMPRO
broadlink_cli --type 0x279d --host 10.0.30.99 --mac 780f77XXXXXX
Device file data (to be used with --device @filename in broadlink_cli) : 0x279d 10.0.30.99 780f77XXXXXX temperature = 0.0
BlackBeanControl part :
user@openhab-vm:/home/openhab/BlackBeanControl$ python BlackBeanControl.py -c stb_power File "/home/openhab/BlackBeanControl/BlackBeanControl.py", line 197 if (len(SentCommand) <> 8) or (not all(c in string.hexdigits for c in SentCommand)): ^ SyntaxError: invalid syntax
user@openhab-vm:/home/openhab/BlackBeanControl$ python2 BlackBeanControl.py -c stb_power Traceback (most recent call last): File "BlackBeanControl.py", line 3, in
import broadlink, configparser
File "/usr/local/lib/python2.7/dist-packages/broadlink-0.17.0-py2.7.egg/broadlink/init.py", line 114
dev_type: int,
^
SyntaxError: invalid syntax
Out of curiosity, I even tried python3 :)
user@openhab-vm:/home/openhab/BlackBeanControl$ python3 BlackBeanControl.py -c stb_power File "/home/openhab/BlackBeanControl/BlackBeanControl.py", line 197 if (len(SentCommand) <> 8) or (not all(c in string.hexdigits for c in SentCommand)): ^ SyntaxError: invalid syntax
Now it is not clear to me whether I may have a conflict that originates from the installation of python-broadlink or the causes are in the BlackBeanControl libraries themselves or somewhere else :(
I would ask for a hint or advice on where I stumbled over :)
Thx