OpenHAB designer issues

I’m working with the OpenHAB designer, trying to write rules using the ctrl+space command but my intellisense doesn’t seem to work properly. Mostly it doesn’t allow me to use it for imports or a few functions here and there. I’m using the latest, version 1.8.3 with no luck. I noticed some other people are having trouble with theirs not recognizing the “now” command and other things. I also saw a previous suggestion to look for the .eclipse folder, which I don’t seem to have on my PC.

Is there a fix for this at all? And if not should I use a different version of the editor?

1 Like

I totally agree with all of the above points. There are big issues with OpenHAB designer at the moment that really make it useless.
One additional point is the missing 64bit Java support on the Windows platform. But when installing the 32bit Java parallel the Network Health binding stops working.
Another thing is the really poor performane. Even when using it on a Intel Core I3 platform, eyery click takes 2-3 seconds to complete.
An one last point: If you have edited a file (items or rules) with Designer and after that edit the same file with a simple text editor, openhab will stop working completely. I don’t know what OpenHAB designer is doing with the files but this is really annoying. The only remedy is to create a new file, paste in exactly the same code as in the not working file and then it restarts working.

As Openhab’s main advantage compared to other platforms are the possibilities of inidividually configuring all the rules etc. it seems hardly understandable that there is only such a poor tool for this. So I also would like to have a fix for all that.

1 Like

There are a few points about this:

First thing is, openHAB would regularly be served from a server, but configuration should be done from a client. This would prevent problems in using 32bit and 64bit Java versions in parallel.
Second thing is, openHAB does not like the windows line break <LF><CR>
If using a more advanced editor like notepad++, you will have no issues with non openHAB Designer editing (at least, you would see the wrong line break if switched on invisible characters).
In question of slow reaction, try to use only small files (yes, that’s annoying, too). When developing a rule, I write it down in it’s own rule file, and the auto completion works almost flawless.

As a last point, please be aware that OH2 is in beta, so there are other priorities in development than fixing an old configuration tool, and bear in mind, that OH2 will make use of Eclipse SmartHome Designer, which is under development, too.

Did you find a way around the network health issue?

Where are your openHAB installs residing?
I have openHAB on a Raspberry Pi and am editing my files through a samba share on a windows machine with Designer and/or Eclipse Smarthome and have not any of the above mentioned problems … network health is also working fine.

The issue with OpenHab designer does not only interfere with network health but also with some other Java programs that I need on my notebook and these programs require 64bit Java (so I also have the need for 64 bit Java on my client, not only on my server). Apparently a parallel installation of 32 bit and 64 bit Java leads to several strange situations and causes a number of programs not to work correctly. So it is a pity that there is no 64 bit version of Designer.

Thank you for that hint, I was not aware of the simple windows editor as a potential cause. I will use notepad++ from now on.

Yes, going back to an old Java Version helped. The result of all my testing was that network health binding only works correctly with outdated Java versions. Of course, this is also only another annoying workaround and a security issue…

Regarding ctrl+space, i. e. IntelliSense or method suggestion:

I am using “openHAB Designer” from version 1.8.3 and “Eclipse Smart Home 0.8.8 Designer win64”.
My base JDK (system-wide on the client) is an Oracle JDK 8 / 64 bit. (And openHAB runs somewhere else on a server.)
Both Designers do syntax checking (though very differently), however they do not allow for method suggestion. I. e. when in a rule I type the name of a Hue lamp and a dot, I would hope to get suggested “state” and other public methods / properties.

Am I misunderstanding functionality, and/or is there a workaround?
Do I need to install additional libraries so that the API of org.openhab.* become known?

Do you press ctrl-space after doing the dot? How long do you want after hitting ctrl-space space for the dialog to pop up?

The is nothing additional required. Being across a network it might take some time , 30 seconds or more, the very first time you press ctrl-space.

Thanks @rlkoshak for reconfirming … and silly me: I have multiple Windows keyboard drivers / input modifiers installed, and Control-Space changed those mappings rather than ended up in Eclipse. I was blind to recognize what I was doing. I have then disabled that function (http://superuser.com/questions/363873/how-to-disable-ctrl-space-selecting-chinese-keyboard-on-windows-7). Now the method suggestion in fact works, and the GUI freezing every few keystrokes has vanished - must have been driver ping-pong. Could have saved me quite some pain during the past months. :confused: