Homematic HM-LC-SW2-FM not working in OH3, working in OH2.5.9

I’m moving my current installation (OpenHab 2.5.9) to OH3 M3, running in a Docker container on a Synology NAS.
So far, after a couple of mistakes, everything looks very good.
OH3 is gorgeous and I don’t want to go back :slight_smile:

Almost all of my Homematic components are IP, but I have a HM-LC-SW2-FM in use to switch two power outlets.
This works perfectly fine with OH2.5.9, but when I try to link the two different channels in OH3, the new item always replaces the old one and is linked to both channels.

Linked channels in OH2:

Linked channels in OH3, after I had linked channel 2 to an item “Werkzeugkeller Steckdose 2” and added the second link to channel 1:

After adding another link, it seems to be fine at first. (items are swapped in this example)
Screenshot taken, right after the create link popup closed:

But after closing and reopening the Thing, the configuration is changed and the new item replaced both links:

When I hit the save button (or visit the code tab and go back to the channels tab, I get a warning that the configuration has validation errors:
grafik

When the new item is added, the old item gets removed, not only unlinked.

I restarted the docker container and tried the same procedure with the same result.
Even after deleting and recreating the thing, the issue is the same.

After adding the thing again, I immediately switched to the code tab and back to the channel tab and got the same validation error.
The config looks like this:

UID: homematic:HM-LC-Sw2-FM:bc66fb2985:REQ0269509
label: HM-LCSW2FM Steckdosen, Werkzeugkeller
thingTypeUID: homematic:HM-LC-Sw2-FM
configuration:
  HMP_1_STATUSINFO_MINDELAY: 2
  HMP_2_TRANSMIT_TRY_MAX: 6
  HMP_1_AES_ACTIVE: false
  HMP_2_STATUSINFO_MINDELAY: 2
  HMP_2_AES_ACTIVE: false
  HMP_2_POWERUP_ACTION: POWERUP_OFF
  HMP_-1_INTERNAL_KEYS_VISIBLE: true
  HMP_1_STATUSINFO_RANDOM: 1
  HMP_1_TRANSMIT_TRY_MAX: 6
  HMP_2_STATUSINFO_RANDOM: 1
  HMP_-1_CONF_BUTTON_TIME: 255
  HMP_-1_LOCAL_RESET_DISABLE: false
  HMP_1_POWERUP_ACTION: POWERUP_OFF
bridgeUID: homematic:bridge:bc66fb2985

Is this an issue with the homematic binding?
It seems strange that it’s working perfectly fine in OH2.5.9…

Thanks for any ideas/comments!

In your first screenshot from OH3 I can see that both items have the name and as far as I can see there is a problem with the automatic creation of unique item names. I will have to investigate whether the names are created by the binding or by the UI resp. in openHAB core.
If you create the link to the second item it gets the same name as the first one because the name is not unique. You can overwrite the in the dialog where the item is created. Can you test whether this works?

The validation error maybe has nothing to do with the channel. If switch to the “Thing” tab invalid configuration entries will be marked with red text. I had a similar problem with invalid latitude and longitude values (they had too many digits).

Wow!
Changing the name worked and I was able to link both channels.
I feel stupid not recognising this by myself…

I was able to get rid of the validation error.
Switching on the advanced options revealed the “Conf button timer”
It was set to 255 with a remark that it has to be lower or equal to 254.
Setting it to 254 didn’t work.
253 worked.

Hope this helps!

Thanks for the reply. It seems that the rules to create item names have changed in the UI or in openHAB core. I will create an issue and also an issue that there should be a message if you create a new item with an already existing name.

Hi Martin,

this seems to be a more general issue.
I have recognized the same behavior with another binding as well:

Hope this helps! :slight_smile:
Have a good week!

I have created an issue for the channel naming and it probably has already been solved

I still see this behavior with M4.
Although https://github.com/openhab/openhab-webui/pull/566 seems to be part of M4.
Well, let’s see :slight_smile:
Good to know, how to work around it.