Shelly Binding

No. If I understood correctly you will get TRV-support with the 3.4 release (October?).
If you want it now you need the developer version. Read the readme 3posts above.

Edit: my bad, was fixed on Gen2-support.

No, TRV is already supported.

My bad, was thinking about gen 2

I’m using 3.4 with Shelly1 and temperature sensors. I’ve alleady some Shelly1 I did configure under 3.3 which are ok. Now I added a Temperature sensor to another Shelly1 under 3.4. The temperature sensor is shown in the shelly interface but not in openhab. I did a delete and rescann, but no difference. No channel data for the temperature sensor is shown.

Apologies, just to clarify:

If I upgrade OH from 3.2 to 3.3 it will automatically install version 3.3 of the Shelly binding which includes support for the TRV?

This means that I don’t need to install the Dev version, correct?

If this is all true, how does it know whether to upgrade to the gen1 or gen2 version of the binding? And which version of the binding is installed by default on a new OpenHAB installation?

Apologies if answered before but why are there two versions of the binding? What if I have both gen1 and gen2 devices on my network, which should I use?

Thanks,

Ben.

Thank you very much for your effort @markus7017 .
Successfully installed the 3.4.0 Beta to get my two 2PMs (connected to the shelly 2x wall switch) into openhab.
Not sure if I’m doing something wrong or it’s simply not (yet) supported. Unfortunately I was not able to find any info on if this is the case.

I’m trying to set up (multi) button-presses within latest version of Openhab 3 and the beta of the binding to activate some rules.

rule "test button press"
when
    Channel "shelly:shellyplus2pm-relay:485519a284e8:relay1#button" triggered
then
    logInfo ("schalter.rules", "shelly button pressed")
end

But nothing is happening/showing up in the logs when I’m pressing the left button of the wall switch.
When I configure the channel via UI, it keeps being ā€œidleā€ and also no other rule is executed - only when I manually ā€œrunā€ the rule. But not when triggered by the physical button.

Sidenote:

Any idea of what I’m missing or is it the (currently) expected outcome?

Edit:
I changed eventsCoIoT to ā€œfalseā€ (was true) and now I see some data in debugging. Seems (!) to have made a difference…
But something really weird whenever I press a button now:

ā€œThing ā€˜shelly:shellyplus2pm-relay:485519a284e8’ changed from UNKNOWN (CONFIGURATION_PENDING): The device was restarted and is again being initializedā€ to Online

For gen2 devices, you need the dev version. This is independent to TRV support.

If the 3.3.0 version discovers the TRV you are fine, otherwise you need to uninstall this one from the UI and install the -gen2 build following the instructions.

Iā€˜m in the process to merge the current code base into the dist, but my expectation is that this will take another 3-6 weeks.

In the meantime use the gen2 build. Hardening for Gen1 devices is almost done, now we move to the gen2 devices and just today I received dev samples of all new devices Shelly presented on their event.

—

3.4.0-Gen2 build for Plus/Pro+Gen1 | 3.4.0-DEV Gen1 stable build
README | READMEbeta for more info on first installation
Avdanced Users - Shelly Manager - Bugs/Features - API Doc
Gen1: Firmware Index - Firmware Archive

—

Note: The DEV build is always newer than the version in the official Distro or the Milestone builds check [here]

Iā€˜ll check the Pro 4PM

Did you tried the latest Gen2 build? I just did some fixing a few days ago

will add this to the test list for Gen2

Thank, newest build solved this. The temperature channel is shown.

the newest build shows an error:

> 2022-07-30 10:31:18.031 [WARN ] [mmon.WrappedScheduledExecutorService] - Scheduled runnable ended with an exception: 
> java.lang.NoClassDefFoundError: org/openhab/binding/shelly/internal/api1/Shelly1ApiJsonDTO$ShellyStatusLight
> 	at org.openhab.binding.shelly.internal.api1.Shelly1HttpApi.getLightStatus(Shelly1HttpApi.java:286) ~[?:?]
> 	at org.openhab.binding.shelly.internal.handler.ShellyLightHandler.updateDeviceStatus(ShellyLightHandler.java:330) ~[?:?]
> 	at org.openhab.binding.shelly.internal.handler.ShellyBaseHandler.refreshStatus(ShellyBaseHandler.java:499) ~[?:?]
> 	at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515) ~[?:?]
> 	at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:305) ~[?:?]
> 	at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:305) ~[?:?]
> 	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) [?:?]
> 	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) [?:?]
> 	at java.lang.Thread.run(Thread.java:834) [?:?]
> Caused by: java.lang.ClassNotFoundException: org.openhab.binding.shelly.internal.api1.Shelly1ApiJsonDTO$ShellyStatusLight cannot be found by org.openhab.binding.shelly_3.4.0.202207162149
> 	at org.eclipse.osgi.internal.loader.BundleLoader.generateException(BundleLoader.java:529) ~[org.eclipse.osgi-3.17.200.jar:?]
> 	at org.eclipse.osgi.internal.loader.BundleLoader.findClass0(BundleLoader.java:524) ~[org.eclipse.osgi-3.17.200.jar:?]
> 	at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:416) ~[org.eclipse.osgi-3.17.200.jar:?]
> 	at org.eclipse.osgi.internal.loader.ModuleClassLoader.loadClass(ModuleClassLoader.java:168) ~[org.eclipse.osgi-3.17.200.jar:?]
> 	at java.lang.ClassLoader.loadClass(ClassLoader.java:521) ~[?:?]
> 	... 9 more

Hello I bought the new Shelly Plus HT (SNSN-0013A), unfortunately the org.openhab.binding.shelly-3.4.0-gen2.jar binding always remains on CONFIGURATION_PENDING.

http://IP/rpc/Shelly.GetConfig:

{"ble":{"enable":false},"cloud":{"enable":false,"server":"shelly-43-eu.shelly.cloud:6022/jrpc"},"devicepower:0":{},"ht_ui":{"temperature_unit":"C"},"humidity:0":{"id":0, "name":null, "report_thr":1},"mqtt":{"enable":false,"server":null,"client_id":"shellyplusht-441793d0dbc0","user":null,"topic_prefix":"shellyplusht-441793d0dbc0","rpc_ntf":true,"status_ntf":false},"sys":{"device":{"name":"Shelly-BZ-PlusHT","mac":"441793D0DBC0","fw_id":"20220602-132134/plushtprod1-g7578881","discoverable":true},"location":{"tz":"Europe/Berlin","lat":51.366160,"lon":12.420820},"debug":{"mqtt":{"enable":false},"websocket":{"enable":false},"udp":{"addr":null}},"ui_data":{},"rpc_udp":{"dst_addr":null,"listen_port":null},"sntp":{"server":"time.google.com"},"sleep":{"wakeup_period":43200},"cfg_rev":22},"temperature:0":{"id":0, "name":null, "report_thr_C": 0.5},"wifi":{"ap":{"ssid":"ShellyPlusHT-441793D0DBC0","is_open":false, "enable":false},"sta":{"ssid":"SSID","is_open":false, "enable":true, "ipv4mode":"dhcp","ip":null,"netmask":null,"gw":null,"nameserver":null},"sta1":{"ssid":null,"is_open":true, "enable":false, "ipv4mode":"dhcp","ip":null,"netmask":null,"gw":null,"nameserver":null},"roam":{"rssi_thr":-80,"interval":60}}}

http://IP/rpc/Shelly.GetStatus:

{"ble":{},"cloud":{"connected":false},"devicepower:0":{"id": 0,"battery":{"V":5.26, "percent":67},"external":{"present":false}},"ht_ui":{},"humidity:0":{"id": 0,"rh":69.1},"mqtt":{"connected":false},"sys":{"mac":"441793D0DBC0","restart_required":false,"time":"11:16","unixtime":1659172564,"uptime":53,"ram_size":239676,"ram_free":169540,"fs_size":458752,"fs_free":196608,"cfg_rev":22,"available_updates":{"beta":{"version":"0.11.0-beta2"}},"wakeup_reason":{"boot":"deepsleep_wake","cause":"button"}},"temperature:0":{"id": 0,"tC":25.1, "tF":77.2},"wifi":{"sta_ip":"IP","status":"got ip","ssid":"SSID","rssi":-30}}

maybe I can be helped
Greetings

Thanks everyone for your help (and @markus7017 for developing such a great binding!)

Just wanted to say that upgrading to 3.3 meant that the TRV showed up as a Thing type so I was able to add it to my platform without having to install a Dev build.

@markus7017, I am still unable to mount the gen2 binding, even following all steps to the letter, multiple times. But perhaps I have a clue. I delete all .things but I have several devices that consistently show up as a new thing in my inbox. They are there now; two 1’s, a 1PM and a 2.5. These are real devices but they are already on my network and are defined as .things. It is as if they are some sort of ghost devices that are not purged with a clean-cache. Could some device information be lurking in a config file that is preventing the gen2 binding from being mounted?

check the jsondb,?it has all the thing definitions in json format. stop oh, delete the definitions you want to get rid of. You could grep the folder for the ids you are looking for

which device are you using?

strange, try updated build

@markus7017 This is the org.openhab.core.thing.Thing.json file? I can delete all of the shelly device references in this file to completely clear any device history?

yes, make sire to keep the format after esiting (remove complete shelly related entries and keep the others unmodified)

grep the json db folder for ā€žshellyā€œ there are also the links for channels to items

keep a backup cop if the filder

Make sure to have installed the latest gen2 build (and removed rhe Shelly binding, which comes wirh tge IH standard install).The device must be online and in discovery mode. Best is to do a device revoot from the Web UIwait 15sec and the. start OH discovery