Openhab + working KNXD : sitemap not efficient

Hi everyone,

It makes time since I use Openhab on a daily basis. I own a house with a 80 devices installation and Openhab acts as a supervisor for multiple purposes : rollershutter management and centralization, hot water heating during low-tariffs electricity periods, presence simulation when away, etc …

But I didn’t make any effort to go further than this, because … well, I don’t touch to something that works as I want.

But now, I want to update my old OH2 installation, and give a try to the fresh new OH3.

I started by buying a fresh new RPi 4B, on which I installed the latest openhabian at the beginning of this month. I wanted to use it as a development platform, in order to keep my old OH2 working, until the new one could be ready to replace it. And here started all my problems.

I use a KNX IP Gateway interface on my knx network (an ABB IPS/2.1, which is not a router. It can hold only one connection, which was for my OH2 installation). I was happy to discover that KNXD could be set up with the openhabian-config menu (I gave once a try to eibd but never managed to get it running). So I installed it and managed to make it work with my KNX ABB IP interface.

I’m pretty sure of my configuration because :

  • knxd daemon is running and stays alive
  • knxtool vbusmonitor1 ip: shows me informations on my KNX network (such as temperatures transmitted by sensors, with the corresponding GroupAddress).
  • knxtool groupswrite ip: GA 0 or 1 also works fine

But it is impossible to manage my OH2 installation to talk to this KNXD instance, instead of talking directly to my KNX IP Gateway. I didn’t look to the OH3 configuration for the moment. This has to be done once my OH2 installation will be working.

Here is my configuration :

  • OH2 running on an OrangePi with the address 192.168.0.61
  • OH3 running on the fresh new RPi4 with the address 192.168.0.76. KNXD also runs on this machine.
  • My ABB IPS/2.1 KNX IP interface with the address 192.168.0.201

On the RPi4
My knxd.cfg contains the following parameters :

KNXD_OPTS="-e 0.0.1 -E 0.0.2:8 -D -T -R -S -b ipt:192.168.0.201"

What I understand with these parameters is that :

  • knxd holds the 0.0.1 physical address in my KNX network (which is free), and will allow clients to connect, giving them KNX addresses between 0.0.2 and 0.0.9.
  • It will allow the KNX Discovery protocol (letting ETS5 find this interface for KNX programming for example).
  • It enables Tunneling, Routing in the KNXD Server.
  • It binds to my KNX ABB IPS/2.1 gateway which has the 192.168.0.201 IP address.

When looking at what is listening on this machine :

$ netstat -an | grep LISTEN
tcp6       0      0 :::6720                 :::*                    LISTEN

On the OrangePi
My OH2 installation runs on files configuration. My KNX bridge is declared in a .things file which starts with the following :

Bridge knx:ip:KNXD “KNXD DAEMON@192.168.0.76” @ “KNX” [
type=“ROUTER”,
ipAddress=“192.168.0.76”,
portNumber=6720,
readingPause=50,
responseTimeout=10,
readRetriesLimit=3,
autoReconnectPeriod=35,
localIp="",
localSourceAddr=“0.0.2” ]

When restarting Openhab (but simply changing the .things file should be sufficient), I can see in the event log that Openhab never successes to connect to KNXD.

The bridge remains OFFLINE. Not setting a convenient localSourceAddr leads to the following message in my log file :

‘knx:ip:KNXD’ changed from UNKNOWN to OFFLINE (COMMUNICATION_ERROR): invalid individual address:

Setting the type of connection to “TUNNEL” instead of “ROUTER” shows me this message in the log :
`

‘knx:ip:KNXD’ changed from UNKNOWN to OFFLINE (COMMUNICATION_ERROR): timeout connecting to control endpoint /192.168.0.76:6720

What didn’t I understand ?

I don’t have any idea to go further. Any help would be appreciated.

Thanks in advance, and sorry for this long message, which was the only way to describe what I want to do.

Eric.

`