How to bind a Homematic CCU2 Variable to a number item in openhab2

I couldn’t find how to do this in OH2

This is what i had in my OH1 Itemfile:

Switch Alarm_Aktiv		"Alarmanlage aktiv"  (gAnwesenheit)	{homematic="variable=Alarmanlage aktiv"}

What would be the correct Syntax vor OH2?

Check here:

It should be something like: {channel="<channel_name>"} (if you are using the 2.x homematic binding)
You can find the channel name from PaperUI->Configuration->Things (click on a Thing to see its channels)

I read the docs many times there is no hint how to build the channel name for a homematic ccu variable like in OH1. See my example. In general a homematic channel requires in oh2 type and address both do not exist for Variables. Or I do not know.
In paper ui the variables are not listed. There is no auto discovery for variables the docs say.

Any other help for my example. Maybe by binding maintainers.

The easiest way to get the channel name is to use the Paper UI. There you can see the variables with their channel ids, e.g.

If you click on the marked icon the channel ID is copied to the clipboard.

Does’t Homematic CCU Variables work with Homematic2 Binding??? Only with Homegear? I understood only discovery of variables works with Homegear.

I can’t see no Variables in PaperUI under the GATEWAY-EXTRAS. Even I can’t see the RELOAD_VARIABLES.
All what I see in GATEWAY-EXTRAS is:

I tried to get the Variable with the following statement. There is no Error at the log, but also no effect.

Switch Alarm_Aktiv		"Alarmanlage aktiv"  (gAnwesenheit)	{cahnnel="homematic:GATEWAY-EXTRAS-CCU:ccu:GWE00000000:1#Alarmanlage aktiv"}

Any other Idee how to get the link to the variable? With OH1 it does work. For now in parallel to OH2 Binding. I’m using the simultaneously but want to get rid off the homematic1 binding in my OH2 installation.

In your definition are two errors: cahnel instead of channel and in variable names the spaces are replaces by “_”.
But if you don’t see a channel group “Gateway-variable” the binding probably did not detect the variables (BTW: detecting variables does not only work with Homegear. I have got a CCU2 and it works).

Which version of OH and CCU firmware are you using?

You can check the log files (especially openhab.log). There should be same messages regarding GATEWAY-EXTRAX. If not you can try to restart openhab or even uninstall and reinstall the Homematic add-on.

Thanks for helming. I corrected the Errors at the Items definition. But the Variable does not work and sync with CCU. Even early after starting OH I see something in the log that Variables have been renamed to ‘_’ instead of space.

Also after reinstalling homematic binding, starting, stoping OH and reseting my CCU with backup no variables are found at GATEWAY-EXTRAS in paperUI. I also used the hint from docs when no Variables are listed to set gatewayType=ccu. But it remains. Also starting only with one homematic binding / uninstalling the homematic1 binding didn’t help.

But reseting my CCU to factory level helps with the -1 Failure at the HM-ES-TX-WM Device for now.

I will try to restore my CCU completely with new Firmware, maybe there is something wrong. And next install and uninstall OH2. Maybe I will switch to snapshot. I didn’t want to do this because of stability, but the Group discovery vor thermostat groups was solved some days ago.
When I can’t solve the problem what log level do you need to help further?

I thinks in this case log level TRACE may be necessary.

Maybe I will switch to snapshot. I didn’t want to do this because of stability, but the Group discovery vor thermostat groups was solved some days ago.

There have been lots of other improvements in the snapshot (also regarding variables). Normally the quality of the snapshots is really good.


After complete new install of OH2 I can find the Variables and Scripts in GATWAY-EXTRAS.
And Variables work now perfect.:slight_smile:

But I could’t install OH2 snapshot because the install script for synology OH2 snapshot is bugy.
Any Idea how i could install just only the news homematic2 binding? Is it possible?

I don’t know about the synology version. But if you have access to the file system you can try to copy the Homematic add-on to the addons directory.

Good idea. Was not easy to find it on this Site wehre the snapshots are. But it worked. Now I got groups to at my Things Must Check tomorrow for errorrs and bind Thermostat groups to items. After that i can maybe uninstall homematic one binding.