Shelly Binding

The PR is merged, so the fix should be included in the SNAPSHOT build. If this doesn’t work try the DEV build I uploaded 10min ago (follow the READMEbeta instructions)

@MartOs @life_is_life @the.gangster @glilienthal Please verify and report test result

4.2-DEV | 4.0.-DEV (outdated) | 3.4.5-DEV (outdated) | README | READMEbeta
Avdanced Users - Shelly Manager - Bugs/Features - API Doc | Firmware Index - Firmware Archive

Note: The DEV build is always newer than the version in the official Distro or Milestone builds. Current development is based on 4.2-SNAPSHOT, 4.1/4.0.x and 3.4.x are outdated (not the latest feature/fix level).

I tried your 4.2 DEV build but get this error:

Error while starting bundle: file:/openhab/addons/org.openhab.binding.shelly-4.2.0-SNAPSHOT.jar
org.osgi.framework.BundleException: Could not resolve module: org.openhab.binding.shelly [309]
  Unresolved requirement: Import-Package: org.eclipse.californium.core; version="[2.7.0,3.0.0)"

	at org.eclipse.osgi.container.Module.start( ~[org.eclipse.osgi-3.18.0.jar:?]
	at org.eclipse.osgi.internal.framework.EquinoxBundle.start( ~[org.eclipse.osgi-3.18.0.jar:?]
	at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundle( [bundleFile:3.7.4]
	at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundles( [bundleFile:3.7.4]
	at org.apache.felix.fileinstall.internal.DirectoryWatcher.doProcess( [bundleFile:3.7.4]
	at org.apache.felix.fileinstall.internal.DirectoryWatcher.process( [bundleFile:3.7.4]
	at [bundleFile:3.7.4]


Hi @markus7017 ,
I have never reverted back to the original code after I had success with my hack. But as the thing has now gone over the hurdle of initialization, probably reverting to the 4.2ML code would also not make a difference ?

However: I am now seeing the problem that I have also read in other posts. After restarting the gateway, everything runs fine for a couple of hours, but then OH stops receiving events from the BLU sensor. There is nothing suspicious in the OH logs (also with TRACE level), while the script console and also diagnostics on the gateway still show that the notifications go out, e.g.

shelly_notification:209 Event from script:1:

I have now enabled MQTT in parallel, this works fine, all messages arrive on the broker and in OH.

I would be happy to provide more debug information, but the logs really show nothing.

as I said follow the instructions READMEbeta, you need to do the feature:install

I finally managed to install this. I can see, discover etc. and no more errors in the logs, but there is still no Total kWh.

Now on the latest openhab snapshot too

are you using the snapshot build or my dev build, bundle:list shows an older version

@markus7017 does the 4.2 DEV supports shellyblugw (blu gateway) ? Thank you


Cool thank you, I will test it tomorrow or Monday.

I’ve installed the 4.2 DEV and indeed now the Bluetooth Gateway is now added.
The “Enable BLU Gateway support” is checked.
I press the BLU door/window button, and I check in the Inbox and I don’t see the device.
I’ve tried several times.
In the log window of the Gateway I see this message:

shelly_bluetooth_sca:65 bluetoth scanner already taken
Unable to start OH-BLU Scanner, make sure Shelly Gateway Support is disabled in device config.

I also see this message

shos_rpc_inst.c:355 0x3ffe1ec4: duplicate id ‘shellyblugw-3ce90e7d66fc’
shos_rpc_inst.c:230 Shelly.GetStatus via HTTP_in POST

What am I doing wrong ?

PS: both device have the latest software

Did you unchecked the „enable BT gatewa“‘in the device UI. My script will not start until you‘ll see a „started successful“ message

OK I’ve added the door/window thing :grinning:
What I don’t understand is why do I have to uncheck the “Enable Bluetooth gateway”… in the gateway.
Do I have to leave it always unchecked ?


I tried this again. Reset everything to scratch and followed the instructions very carefully.
The binding discovers my things, but totalkWh is still missing from my EM50 meters.

What am I doing wrong?

Hi, do you know if the new shelly uni plus would be supported?

yes, it is
check, it lists all supported devices

i cant find the Shelly Plus Uni only the shelly uni.

the link you sent is the Plus UNI, wehre is the problem?

Enable Bluetooth gateway is the Shelly support for redirecting those messages to their cloud
Obviously it is not compatible to local scanners
Keep if off

1 Like

I updated the DEV build to include support for Plus HT Gen3

It also includes a change to use a different value for src in RPC messages, this might help to get rid of “duplicate id” messages in the device debug log, which seems to create trouble when running devices for a longer time. Check here: Non deterministic malfunction of shelly 1 plus

As well as

@MartOs try this build


Updated jar

I need testers

1 Like

To be honest, I came across that recently as well when I was considering if one of the UNI models would help me in my environment. So I checked the readme and if I am not mistaken it only mentioned Shelly Uni but not explicitly PLUS Uni.
I found it in this commit though.
There you added it to the but not to the as far a I could see.