openHAB Designer dont work

Hi sihui,

I appreciate the quick response.

Apologies for misleading statement [in mitigation, it was a long email, I was bound to make at least one mistake :slight_smile: ] I meant to say I couldn’t get the full openHAB Designer software working - ie. inclusive of internal browser functionality (when I publish the blog post there will be some whinges if everything is not laid out on a plate). I have in fact been working round the issue by doing exactly what you suggest. I’m using chrome which although can be a bit slow to pick up changes (actually a little on the nondeterministic side at times) works sufficiently well for me to crack on.

More importantly you’ve given me absolution through confirmation.

I kept the pi log in so run a chown as below from time to time and editing things seem to be ok.

sudo chown -vhR pi:pi /etc/openhab
sudo chown -vhR pi:pi /usr/share/openhab

My samba settings are as follows

[pi]
comment= Home Directory
path=/home/pi
browseable=Yes
writeable=Yes
only guest=no
create mask=0777
directory mask=0777
public=no

[OpenHAB Home]
comment= OpenHAB Home
path=/usr/share/openhab
browseable=Yes
writeable=Yes
only guest=no
create mask=0777
directory mask=0777
public=no

[OpenHAB Config]
comment= OpenHAB Site Config
path=/etc/openhab
browseable=Yes
writeable=Yes
only guest=no
create mask=0777
directory mask=0777
public=no

Like you I’m not a Linux Guru, but as my IoT devices, MQTT server, MySQL and openHAB servers are on their own closed network I think security isn’t too much of an issue (for now).

Anyway, thanks for your help

Regards

SQ

Maybe you can avoid that by adding:

force user = openhab
force group = openhab

or pi:pi if you changed the default openHAB user.

Thanks,

I’ll give this a shot.

Regards

Steve

Hi all,

Wasn’t sure whether to revive an old thread here or post a new topic, but I’m having an issue with the designer on Windows 10.

I’ve tried bit the stable version (updated last almost a year ago!) as well as the snapshot but both do not have the editable workspace available. I can browse to my conf files but cannot open any of them.

This happens on my raspberry pi installation as well as a windows installation I did as a test.

In the screenshot above there is a ‘no-entry’ sign attached to the file I’m dragging to the editor.

Any ideas why this is happening?

I went according to the guide at doc.openhab.org/installation/designer.html

Double check your samba conf (lots of examples here in the forum), make sure you have 32Bit Java on your Win installed, make sure you are using designer 0.8 (not the 0.9 version).
Apart from that I have not seen that problem before.

It’s not recommended to use the designer on a Pi. Configure your samba share accordingly and access your files from your Win computer. Much better performance …

Hi @sihui

Still can’t edit any files :frowning:

  1. My samba conf I think is ok since I can navigate to the conf directory and edit the files with notepad++.

  2. I uninstalled my 64 bit Java and installed 32 bit

  3. I added the JRE to the PATH and JAVA_HOME environement variables.
    4.My designer version is 0.8

So that setup didn’t work. I tried then to install the 64 Bit designer (kept the same Java though)

I’m trying two things here…

First is to open and edit files on my local OH2 installation on my Windows 10 laptop. Can’t edit files.
Second is to access the files on the Pi using samba (to browse to the config folder on the Pi which I can see), but can’t edit files there either.

So both ways aren’t working.

I saw that Zulu Java is the recommended platform now so I thought I would have a go so I installed it on my laptop.

The version installed is: (I didn’t find a 32 bit Windows release)

Now the OH2 runtime doesn’t start with the following output:

I think the path settings are ok since ‘java -version’ returned fine.Is Zulu ok for Windows?

I’m stumped? I would really like to start working with the designer

Edit:
Switching back to Oracle Java allowed the OH2 runtime to kick-off fine.

Designer (64 bit) then threw me this…

Installed Designer 32 bit again and it loads, but again not editable, but no error. So it seems like something to do with my Java installation.

Thanks @sihui, I will follow your steps verbatim and see if there’s any joy. I’ll post any findings.

Good, no problems there I guess.

I can only tell you what I did to make it work:

Win 10 64Bit, installed Java 32Bit from here, installed 32Bit designer 0.8 from here, navigated to the config folder through the samba network share and am able to edit my files.
No need to edit any path or home directories.

Don’t drag them, try double clicking them instead. Dragging doesn’t work for me either.

Good catch, missed that.

Same here :sunglasses:, never tried that. Double clicking the files always works as expected …

And I never tried double-clicking - and that works :laughing:

1 Like

Well, I just tried dragging in Eclipse (on which the Designer is based) and of course in Eclipse dragging works without any problems.

I have a true love/hate relationship with the Designer and I’m more and more leaning towards hate. It’s such a crippled piece of s… For example, who thought that it was a good idea to remove the option to create a new file? Now I always need to drop to a console window and touch a file. Oh no… refresh also removed, so now I have my file, but the Designer doesn’t see it. I have to reopen the config folder so that Designer refreshes and I can finally start editing my file.

Does anyone know if it’s possible to just use Eclipse and load the openHAB DSL related stuff in it (similar to what you can do for C++, Pyhton, PHP, etc.)?

Does anyone also have a problem editing rules in Designer? I’m using OH2 on Synology chroot debian environment, whenever i edit rules file with Designer, i do have “rules file either empty or cannot be parsed correctly!”. I have this error whenever i use Notepad++ or TextWrangler, but why with Designer?? Everytime i have to vi rules file and :wq without changing anything. Btw i use Designer under OSX.

Also when using
Channel ‘astro:sun:local:set#event’ triggered START
Designer gives an error “no viable alternative at input ‘Channel’”. But it works in OH2.

CTRL-N solves your problem :grinning:

Thanks. I had already tried that one before and then it did not work as expected. The problem was that I always picked the ‘Untitled Text File’ (which is selected by default) but then you have the problem that you can’t save it. However, selecting the ‘File’ does the trick.

I’m pretty much convinced that they forgot to rip out the Ctrl-N functionality; they ripped out the Ctrl-S after all :slight_smile:

From a usability point of view the Designer really is a disaster…

It needs improvement, yes :grinning:

1 Like

Yep, I have those issues too. For the Channel problem, I think that the DSL that is used in Smarthome Designer 0.8 is simply too old and doesn’t have support for it. Maybe Smarthome Designer 0.9 supports it, but i have not tried it yet because it supposedly is still very unstable.

The ‘rule file either empty or cannot be parsed’ problem I see as well. I run the Designer on Ubuntu. The config dir of the running openHAB instance is on a Raspberry Pi 3 and shared via NFS. I read somewhere that this probably causes a timing issue. The idea is that the file is marked updated before the Designer is done writing it and openHAB picks it up too quickly. It does read it after logging that error for as far as I can tell. I never have to vi the rule and save it to touch it again. Instead of opening it in vi and saving it, you could also use the ‘touch <filename>’ command. But I don’t think either is necessary.
It probably would be a good idea if openHAB waited a second before reloading the file after it got notified that the file has been updated.

I started down this road to nowhere because I wanted to install the gauge widget from the Eclipse Marketplace where I would have to drag-and-drop the component.

But @marcel_erkel, you gave me a great hint about touching a file. I get the no-entry sign because the workspace is unavailable. But if I open a blank file I can drop the component to it…

I don’t know if the widget would work doing it like this though. I guess I first need to create an empty file in the ‘addons’ folder and drag the item to it, but what would the naming conventionn be? When I have some time I’ll experiment with it and post here if it works

Dear sihui, your link here is not working anymore!
My designer doesn’t let me choose the configuration folder.


Error: “Not a valid configuration folder”

This share is on a synology. Designer is on my windows. It does not work with a mapped share (W:), nor over the “Network” path. I read about openhab_default.cfg missing, but I do not find it. Any idea?

That is correct, the ES Designer is deprecated.
Try Visual Studio Code with the openHAB extension instead:

https://docs.openhab.org/configuration/editors.html#openhab-vscode

Many thanks. Works.

1 Like