knxd / pyknyx Goto Github PK
View Code? Open in Web Editor NEWThis project forked from thomaskleffel/pknyx
Python KNX Framework
License: GNU General Public License v3.0
This project forked from thomaskleffel/pknyx
Python KNX Framework
License: GNU General Public License v3.0
Link in line 58 in the file https://github.com/knxd/PyKNyX/blob/master/README.rst is broken
I've been trying to use PyKNyX with a RPi 3 in order to create a "Wireless KNX device".
I have a BeagleBone + TPUART running KNXD 0.14.15 (args: "-e 9.0.0 -E 9.9.200:14 -DTRS -b tpuarts:/dev/ttyO4"); it works all right. I've been using before as my ETS interface + router: I successfully get the multicast from other router (Weinzierl) on the same network.
Now I have a RPi3 in which I installed KNXD 0.14.13 + PyKNyX. I want this to communicate in multicast; however I just partially succeeded: When I send some KNX message via ETS to the TP bus I do get it in the RPi, but when the RPi attempts to answer I don't get the message in the TP bus. I am pretty sure that I'm getting some of settings wrong, but I can't figure out what. The KNXD args are: "-e 10.0.0 -E 9.0.200:8 -u /tmp/eib -b ip:".
I'd be most happy if some one would be of help in this.
UPDATE1{
I tried with "knxtool" something like: knxtool groupwrite local: 1/2/3 0
and it worked (= I could get the message routed from the RPi to BeagleBonethe:TP bus). But still can't make PyKNyX to send...
}
UPDATE2{
1 - I've tried to connect to remote IP router (KNXD running with -e 9.0.0 -E 9.9.200:3 -RS -b tpuarts:/dev/ttyO4
) but PyKNyX won't connect. I've monitored with wireshark and no messages are sent when the RPi3 is not running KNXD;
2 - I've tried to add the -RS
to the RPi, but together with -b ip:
it creates loops;
3 - I've tried to put the KNXD (TP<->IP) server in other multicast (-e 9.0.0 -E 9.9.200:3 -R --Server=224.11.11.11:3672 -b tpuarts:/dev/ttyO4
) and the RPi3 like this (-e 11.0.0 -E 11.1.1:8 -RS -u /tmp/eib -b ip:224.11.11.11:3672
): this works for one device, but when I start other RPi3 with same settings the loops start (obviously).
4 - I tried some other hacks inside the PyKNyX that didn't help.
}
Thank you!
Tried PyKNyX on a debian 9 installation ends up in an error while creating a device:
apt-get install git
mkdir ~/software
cd ~/software
git clone https://github.com/knxd/PyKNyX PyKNyX
cd PyKNyX/
python setup.py sdist
cd dist
pip install PyKNyX\ knxd-2.0.0.dev1.tar.gz
cd ~
pyknyx-admin.py createdevice accture
cd accture
python -V
Python 2.7.13
./admin.py checkdevice
Traceback (most recent call last):
File "./admin.py", line 18, in <module>
main()
File "./admin.py", line 14, in main
AdminUtility().execute()
File "/usr/local/lib/python2.7/dist-packages/pyknyx/tools/adminUtility.py", line 205, in execute
args.func(args)
File "/usr/local/lib/python2.7/dist-packages/pyknyx/tools/adminUtility.py", line 146, in _checkDevice
runner = DeviceRunner(args.loggerLevel, args.devicePath, args.gadMapPath)
File "/usr/local/lib/python2.7/dist-packages/pyknyx/tools/deviceRunner.py", line 97, in __init__
Logger("%s-%s" % (DEVICE_NAME, DEVICE_IND_ADDR))
NameError: global name 'Logger' is not defined
Commenting "Logger()" in "/usr/local/lib/python2.7/dist-packages/pyknyx/tools/deviceRunner.py" ends up in next error:
./admin.py checkdevice
MainThread::Logger level is 'info'
MainThread::Device path is './accture'
MainThread::Device name is 'accture'
MainThread::Device Individual Address is '1.1.1'
MainThread::Allocate ETS addr 1.1.1 to device
Traceback (most recent call last):
File "./admin.py", line 18, in <module>
main()
File "./admin.py", line 14, in main
AdminUtility().execute()
File "/usr/local/lib/python2.7/dist-packages/pyknyx/tools/adminUtility.py", line 205, in execute
args.func(args)
File "/usr/local/lib/python2.7/dist-packages/pyknyx/tools/adminUtility.py", line 147, in _checkDevice
runner.check(args.printGroat)
File "/usr/local/lib/python2.7/dist-packages/pyknyx/tools/deviceRunner.py", line 140, in check
from device import DEVICE
File "./accture/device.py", line 5, in <module>
from acctureFB import AcctureFB
File "./accture/acctureFB.py", line 4, in <module>
from pyknyx.api import logger, schedule, notify
ImportError: cannot import name logger
Installed modules:
pip list
APScheduler (3.5.1)
blinker (1.4)
cryptography (1.7.1)
enum34 (1.1.6)
funcsigs (1.0.2)
futures (3.2.0)
idna (2.2)
ipaddress (1.0.17)
keyring (10.1)
keyrings.alt (1.3)
pip (9.0.1)
pyasn1 (0.1.9)
pycrypto (2.6.1)
pygobject (3.22.0)
PyKNyX-knxd (2.0.0.dev1)
pytz (2018.4)
pyxdg (0.25)
SecretStorage (2.3.1)
setuptools (33.1.1)
six (1.10.0)
tzlocal (1.5.1)
wheel (0.29.0)
Issue:
when running python3 pyknyx/scripts/pyknyx-group.py --help
, this error ocurrs:
File "pyknyx/scripts/pyknyx-group.py", line 399 print gad,tab ^ SyntaxError: Missing parentheses in call to 'print'. Did you mean print(gad,tab)?
Suggestion:
print(gad, tab)
instead of:
print gad,tab
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.