Shelly Binding

sounds promising, sent you a PM

Hi @markus7017 and @violine.
Did you got the 3EM/EM3 items checked by now?
My 3EM is working fine with the binding for Power (in W), but not for consumption (0,0).
I am still using my rule based counter to calculate power over time.
P.S.: Within the shelly app math is fine. and the binding is set to debug level.

Hi @DirkNeumann,
yes EM and EM3 are supported now, I just added 2 missing channels for the EM3 some days ago.
You need to be on the DEV build (not the version you install within PaperUI, this has to be uninstalled)
Check: https://github.com/markus7017/myfiles/blob/master/shelly/READMEbeta.md

done that, and running fine. I am just wondering about this strange ā€ž shelly:shellyem3:dc4f227646f0:meter1%23totalKWHā€œ which is not summing up power over time, but only showing average consumption in a 5min? average (as kWh)ā€¦same in the shelly app. makes no sense to me.
Nevertheless I am using my own counter in openhab to sum up power over time.

I take the value from the API snd convert this into kw/h. So if this is something different to the total I would say itā€˜s a firmware bug. Iā€˜ll open a ticket with Alterco to clarify thus. Could ou provide a description and a screenshot of the App?

I will provide a new version of the binding later today including some documentation for general testing. As I said I want to close the release a the weekend, submitting the PR for 2.5.3/2.5.4 depending on the timing.

Send me a PM if you could support with testing
a) latest version of the Binding
b) firmware release 1.6-rc5 with good coap fixes and nee status updates - promising
both are stable and need the final round

I have a call with the Shelly dev team on Tuesday so issues could be address directl with team. Iā€™ll also put the ā€œtotalā€ topic on the list also with regards to store this value in the device + reset by api call

1 Like

Both values (total consumption Px) should be similiar in Shelly and Papier

ich brauche die ChannelId
welcher Wert passt nicht?

bitte den Output von &status

bitte den akt build noch mal testen

1 Like

fyi: Alterco released firmware 1.6 for the Shelly series of devices


Dear all. Firmware 1.6 are released.

Exclusions:
Shelly4pro and Door Sensor will receive update in few days.

Log changes:

New features:

  • Shelly3EM - MQTT Energy topics
  • Shelly DUO&Vintage Actions
  • Dimmer activation switch
  • Dimmer managable debounce
  • Shelly1/PM temperature ADD-ON format F/C
  • Shelly Flood Actions
  • Shelly Dimmer toggle command over MQTT
  • Disable Factory reset from the switch - by user choice
  • Device is owned from someone flag
  • Disable long push to switch on relay
  • DHT22 - support for Shelly1/PM Add-on
  • Internal Temepratyre and Humidity actions for Shelly1/PM Add-on
  • MQTT for external sensors Shelly1/PM Add-on
  • Countdown timer in WebUi
  • Dimmer - transition time is valid when brightness is changed.

Fixes:

  • Shelly 2.5 Roller Mode: Coap description incorrect
  • Shelly Plug-S: Coap description incorrect
  • Dimmer - Factory reset from Button is not correct
  • Shelly1 Duo - color temperature is not correct
  • Shelly Duo&Vinatge CoAP missing
  • Backup Wi-Fi do not work with fixed IP
  • Dimmer - night mode do not report to the cloud
  • Not correct cloud On/Off status
  • Default settings must be unchanched after OTA
  • HT - MQTT - temeperature offset not correct
  • Shelly Dimmer - No brightness status update when changing brightness from switch
  • Shelly 2.5 Coap - device/relay description link not correct
  • Add ā€œTimerā€ on status
  • H&T - offset missing in REST (Json)
  • MQTT still no on/off report for Light contollers.
  • Shelly Sense Coap: device description broken
  • Duplicate Serial even different content of Coap Update
  • Coap sensors updates include all sensor values
  • Shelly RGBW2 / 1PM Coap description broken
  • Shelly Bulb Coap description broken
  • Fix dimmer schedules to enable transition to on and off state
  • Power on default - does not trigger Actions and AutoOff

The latest Shelly Binding DEV build 2.5.2 and Firmware 1.6 are a good combo :slight_smile:


Today I had an alignment call with the Shelly Dev team of Coap optimizations. They will become part of firmware 1.7. They will directly provide beta versions and support to the openHAB project, which will be to simplify integrations and speed up with new devices.

I could also clarify the topic ā€œpersistent Total Engery valueā€

  • The Shelly EM and EM3 will include this feature in 1.7 firmware and also provide an API call to reset it starting over with 0
  • All other devices canā€™t provide that, because of the limited NVRAM size. They need to keep the remaining bytes for other purposes and canā€™t spend the size to store the total values - sounds stupid in the area of GB and TB, but is a limiting factor of the hardware design.
  • Version 1.7 will merge mqtt and CoIoT/CoAP implementation, which will provide a better consistency and frees up some device resources.
  • The committed to fully support CoIoT in the future and will integrate all missing status values as well as some notifications like ā€œsettings updatedā€, or ā€œsensor data updatedā€, ā€œbutton pressedā€ etc. This will allow to do the complete status updates via CoAP and use the REST poll only for fallback (e.g. given the fact that CoAP is UDP-based and the update could get lost on the network level)
  • They just published an updated API Documentation, which help me to get more details and key values, settings etc. I know that it also drives feature requests from you side reading the doc and knowing whatā€™s possible :crazy_face:, which I like, because it shows interest and helps setting the right focus :slight_smile:
  • I agreed with them that we also report inconsistencies or bugs some of us may find (the old doc has plenty of them, didnā€™t checked the new one in detail)

Alterco/Shelly explicitly mentioned the importance of working with the community and say Thank You for the valuable input we drove into 1.6 the last weeks. Sounds like a Win-Win :slight_smile: +1


My plan:

  • The last 2.5.2 build has only a few issues so itā€™s stable from my point of view
  • Due to the fact that I expect a OH 2.5.3 Addons release in the next 2 weeks (the addon pack, not the binding) itā€™s not realistic to finalize my 2.5.3 stuff and pass the PR process so I decided to pass that release.
  • I will work (again) on the HTTP layer. Iā€™m not happy with the current implementation. I discussed the problem with their developers and we created an approach, which could be a good balance between efficiency and fault tolerance, esp. with regards to firmware 1.7
  • Iā€™ll improve device discovery and implement the new Shelly Vintage.
  • Just from the new API doc I already found out that the DW also has a humidity sensor as well as the 1/1PM addon. Those need to be implemented.
  • However, the presence of the addon as well as the number of sensors could be different, so Iā€™ll go to create those channels dynamically so they are there when the device has the hardware extension.
  • Any other feature request is welcome, also general comments for improvements.
7 Likes

Hi @markus7017
Since Iā€™ve been struggling with the release version for a while and updated a few shellies to 1.6, I gave your new version a try.
The bundle keeps failing to start with this error on a pretty much clean system:

2020-03-11 00:23:14.261 [WARN ] [org.apache.felix.fileinstall        ] - Error while starting bundle: file:/openhab/addons/org.openhab.binding.shelly-2.5.2-SNAPSHOT.jar
org.osgi.framework.BundleException: Could not resolve module: org.openhab.binding.shelly [203]
  Unresolved requirement: Import-Package: org.eclipse.californium.core; version="[2.0.0,3.0.0)"

    at org.eclipse.osgi.container.Module.start(Module.java:444) ~[org.eclipse.osgi-3.12.100.jar:?]
    at org.eclipse.osgi.internal.framework.EquinoxBundle.start(EquinoxBundle.java:383) ~[org.eclipse.osgi-3.12.100.jar:?]     
    at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundle(DirectoryWatcher.java:1260) [bundleFile:3.6.4]      
    at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundles(DirectoryWatcher.java:1233) [bundleFile:3.6.4]     
    at org.apache.felix.fileinstall.internal.DirectoryWatcher.startAllBundles(DirectoryWatcher.java:1221) [bundleFile:3.6.4]  
    at org.apache.felix.fileinstall.internal.DirectoryWatcher.doProcess(DirectoryWatcher.java:515) [bundleFile:3.6.4]
    at org.apache.felix.fileinstall.internal.DirectoryWatcher.process(DirectoryWatcher.java:365) [bundleFile:3.6.4]
    at org.apache.felix.fileinstall.internal.DirectoryWatcher.run(DirectoryWatcher.java:316) [bundleFile:3.6.4]

Any hint what I can check?

You need to install the Californium libs, see https://github.com/markus7017/myfiles/blob/master/shelly/READMEbeta.md

Please stay on version 2.5.2-SNAPSHOT of the binding, 2.5.3 is not ready yet

Hi,
What about the Door sensors?? Today i receive 2 of them and i would like to add them.

Thanks
Nikos

You can try the last 2.5.2 DEV build. Iā€™m working on 2.5.3, but that will take some more time. Please give the 2.5.2 build a try

Hi.
Thanks for your reply.
I have already install the 2.5.2,the binding find the new devices but the values that come back is the lux battery level,uptime and signal strength.no contact.here some screenshots.
Thanks
Nikos


The devices are all the time offline. Only when I close the door they become alive for some seconds and then again offline.

As it is a battery operated device, it will wakeup when contact is opened or closed and then will go back to deep sleep. Thatā€˜s why it is reported as offline, but that should be changed like other shelly battery devices like HT.

Correct,

  • I added illumination, vibration, lastError (this comes from the device) - sometimes an updated API doc helps :wink:
  • Iā€™ll added wakeupReason: List of reasons which woke up the device: battery , button , periodic , poweron , sensor , alarm
  • I need to fix the ā€œdevices goes UNKNOWN when in sleep modeā€ - that has been broken in that build for all sensor types

Iā€™m currently working on refactoring the http access, so you need to be a bit patient to the an updated build.

1 Like

Hi all,

I have three shellyflood sensors but theyā€™re super unstable.
Iā€™m running OH2.5.2 stable, Shelly Binding 2.5.2 and Shellyflood firmware v.1.6.0.

Shelly config:

  • Cloud: OFF
  • Restrict login: ON (with individual PW per device)
  • Report Sensor Value Action: configured to call openhab

Iā€™ve already tried to set eventsSwitch / eventsButton to false, but this does not help much. Sometimes updates make it through and items values get updated sometimes I just see error messages and no item updates. Iā€™m wondering if switching to MQTT would help to get to a stable and reliably config.

Any hints what need to be done to get this working?

In the Karaf debug log I see the following error messages every now and then:

09:17:43.033 [DEBUG] [helly.internal.api.ShellyEventServlet] - CallbackServlet: HTTP/1.1 Request from 192.168.80.224:56150/shelly/event/shellyflood-694835/sensordata?{temp=[22.38],flood=[0],batV=[2.92]}
09:18:00.958 [DEBUG] [helly.internal.api.ShellyEventServlet] - CallbackServlet: HTTP/1.1 Request from 192.168.80.223:46087/shelly/event/shellyflood-694b25/sensordata?{temp=[22.88],flood=[0],batV=[2.89]}
09:18:20.912 [DEBUG] [.discovery.ShellyDiscoveryParticipant] - Shelly device shellyflood-694b25 discovered with empty IP address
09:18:20.912 [DEBUG] [.discovery.ShellyDiscoveryParticipant] - Shelly device shellyflood-694b25 discovered with empty IP address
09:18:20.918 [DEBUG] [.discovery.ShellyDiscoveryParticipant] - Shelly device discovered: IP-Adress=192.168.80.223, name=shellyflood-694b25
09:18:20.925 [DEBUG] [.discovery.ShellyDiscoveryParticipant] - Shelly device discovered: IP-Adress=192.168.80.223, name=shellyflood-694b25
09:18:20.945 [WARN ] [.discovery.ShellyDiscoveryParticipant] - Device discovery failed for device shellyflood-694b25, IP 192.168.80.223, service=shellyflood-694b25: 
null
java.lang.NullPointerException: null
        at org.openhab.binding.shelly.internal.api.ShellyHttpApi.request(ShellyHttpApi.java:474) ~[bundleFile:?]
        at org.openhab.binding.shelly.internal.api.ShellyHttpApi.getDeviceProfile(ShellyHttpApi.java:87) ~[bundleFile:?]
        at org.openhab.binding.shelly.internal.discovery.ShellyDiscoveryParticipant.createResult(ShellyDiscoveryParticipant.java:133) [bundleFile:?]
        at org.eclipse.smarthome.config.discovery.mdns.internal.MDNSDiscoveryService.considerService(MDNSDiscoveryService.java:274) [bundleFile:?]
        at org.eclipse.smarthome.config.discovery.mdns.internal.MDNSDiscoveryService.serviceResolved(MDNSDiscoveryService.java:266) [bundleFile:?]
        at javax.jmdns.impl.ListenerStatus$ServiceListenerStatus.serviceResolved(ListenerStatus.java:106) [bundleFile:3.5.5]
        at javax.jmdns.impl.JmDNSImpl$1.run(JmDNSImpl.java:894) [bundleFile:3.5.5]
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_242]
        at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_242]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_242]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_242]
        at java.lang.Thread.run(Thread.java:748) [?:1.8.0_242]
09:18:20.948 [WARN ] [.discovery.ShellyDiscoveryParticipant] - Device discovery failed for device shellyflood-694b25, IP 192.168.80.223, service=shellyflood-694b25: 
null
java.lang.NullPointerException: null
        at org.openhab.binding.shelly.internal.api.ShellyHttpApi.request(ShellyHttpApi.java:474) ~[bundleFile:?]
        at org.openhab.binding.shelly.internal.api.ShellyHttpApi.getDeviceProfile(ShellyHttpApi.java:87) ~[bundleFile:?]
        at org.openhab.binding.shelly.internal.discovery.ShellyDiscoveryParticipant.createResult(ShellyDiscoveryParticipant.java:133) [bundleFile:?]
        at org.eclipse.smarthome.config.discovery.mdns.internal.MDNSDiscoveryService.considerService(MDNSDiscoveryService.java:274) [bundleFile:?]
        at org.eclipse.smarthome.config.discovery.mdns.internal.MDNSDiscoveryService.serviceResolved(MDNSDiscoveryService.java:266) [bundleFile:?]
        at javax.jmdns.impl.ListenerStatus$ServiceListenerStatus.serviceResolved(ListenerStatus.java:106) [bundleFile:3.5.5]
        at javax.jmdns.impl.JmDNSImpl$1.run(JmDNSImpl.java:894) [bundleFile:3.5.5]
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_242]
        at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_242]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_242]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_242]
        at java.lang.Thread.run(Thread.java:748) [?:1.8.0_242]
09:18:20.948 [DEBUG] [.discovery.ShellyDiscoveryParticipant] - Shelly device shellyflood-694835 discovered with empty IP address
09:18:20.951 [DEBUG] [.discovery.ShellyDiscoveryParticipant] - Shelly device shellyflood-694835 discovered with empty IP address
09:18:20.953 [DEBUG] [.discovery.ShellyDiscoveryParticipant] - Shelly device discovered: IP-Adress=192.168.80.224, name=shellyflood-694835
09:18:20.954 [DEBUG] [.discovery.ShellyDiscoveryParticipant] - Shelly device discovered: IP-Adress=192.168.80.224, name=shellyflood-694835
09:18:20.975 [WARN ] [.discovery.ShellyDiscoveryParticipant] - Device discovery failed for device shellyflood-694835, IP 192.168.80.224, service=shellyflood-694835: 
null
java.lang.NullPointerException: null
        at org.openhab.binding.shelly.internal.api.ShellyHttpApi.request(ShellyHttpApi.java:474) ~[bundleFile:?]
        at org.openhab.binding.shelly.internal.api.ShellyHttpApi.getDeviceProfile(ShellyHttpApi.java:87) ~[bundleFile:?]
        at org.openhab.binding.shelly.internal.discovery.ShellyDiscoveryParticipant.createResult(ShellyDiscoveryParticipant.java:133) [bundleFile:?]
        at org.eclipse.smarthome.config.discovery.mdns.internal.MDNSDiscoveryService.considerService(MDNSDiscoveryService.java:274) [bundleFile:?]
        at org.eclipse.smarthome.config.discovery.mdns.internal.MDNSDiscoveryService.serviceResolved(MDNSDiscoveryService.java:266) [bundleFile:?]
        at javax.jmdns.impl.ListenerStatus$ServiceListenerStatus.serviceResolved(ListenerStatus.java:106) [bundleFile:3.5.5]
        at javax.jmdns.impl.JmDNSImpl$1.run(JmDNSImpl.java:894) [bundleFile:3.5.5]
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_242]
        at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_242]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_242]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_242]
        at java.lang.Thread.run(Thread.java:748) [?:1.8.0_242]
09:18:20.980 [WARN ] [.discovery.ShellyDiscoveryParticipant] - Device discovery failed for device shellyflood-694835, IP 192.168.80.224, service=shellyflood-694835: 
null
java.lang.NullPointerException: null
        at org.openhab.binding.shelly.internal.api.ShellyHttpApi.request(ShellyHttpApi.java:474) ~[bundleFile:?]
        at org.openhab.binding.shelly.internal.api.ShellyHttpApi.getDeviceProfile(ShellyHttpApi.java:87) ~[bundleFile:?]
        at org.openhab.binding.shelly.internal.discovery.ShellyDiscoveryParticipant.createResult(ShellyDiscoveryParticipant.java:133) [bundleFile:?]
        at org.eclipse.smarthome.config.discovery.mdns.internal.MDNSDiscoveryService.considerService(MDNSDiscoveryService.java:274) [bundleFile:?]
        at org.eclipse.smarthome.config.discovery.mdns.internal.MDNSDiscoveryService.serviceResolved(MDNSDiscoveryService.java:266) [bundleFile:?]
        at javax.jmdns.impl.ListenerStatus$ServiceListenerStatus.serviceResolved(ListenerStatus.java:106) [bundleFile:3.5.5]
        at javax.jmdns.impl.JmDNSImpl$1.run(JmDNSImpl.java:894) [bundleFile:3.5.5]
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_242]
        at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_242]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_242]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_242]
        at java.lang.Thread.run(Thread.java:748) [?:1.8.0_242]
09:18:27.270 [DEBUG] [helly.internal.api.ShellyEventServlet] - CallbackServlet: HTTP/1.1 Request from 192.168.80.225:48076/shelly/event/shellyflood-6945c4/sensordata?{temp=[22.62],flood=[0],batV=[2.90]}
09:19:10.950 [DEBUG] [ly.internal.handler.ShellyBaseHandler] - shellyflood: Status update triggered thing initialization
09:19:10.952 [DEBUG] [ly.internal.handler.ShellyBaseHandler] - shellyflood: Start initializing thing ShellyFlood02, type shellyflood, ip address 192.168.80.224, CoIoT: true
09:19:11.077 [DEBUG] [ly.internal.handler.ShellyBaseHandler] - shellyflood: Initializing device shellyflood-694835, type SHWT-1, Hardware: Rev: , batch ; Firmware: v1.6.0 / 20200309-104406 (43056d58)
09:19:11.078 [DEBUG] [ly.internal.handler.ShellyBaseHandler] - shellyflood: Shelly settings info: {"device":{"type":"SHWT-1","mac":"2CF432694835","hostname":"shellyflood-694835","sleep_mode":true},"wifi_ap":{"enabled":false,"ssid":"shellyflood-694835","key":""},"wifi_sta":{"enabled":true,"ssid":"crazylan","ipv4_method":"dhcp","ip":null,"gw":null,"mask":null,"dns":null},"wifi_sta1":{"enabled":false,"ssid":null,"ipv4_method":"dhcp","ip":null,"gw":null,"mask":null,"dns":null},"mqtt": {"enable":false,"server":"192.168.33.3:1883","user":"","id":"shellyflood-694835","reconnect_timeout_max":60.000000,"reconnect_timeout_min":2.000000,"clean_session":true,"keep_alive":60,"max_qos":0,"retain":false,"update_period":30},"coiot": {"update_period":15},"sntp":{"server":"time.google.com","enabled":true},"login":{"enabled":true,"unprotected":false,"username":"sucre","password":"tWVoZjmWe-diEc9jm933"},"pin_code":"","name":"","fw":"20200309-104406/v1.6.0@43056d58","discoverable":true,"build_info":{"build_id":"20200309-104406/v1.6.0@43056d58","build_timestamp":"2020-03-09T10:44:06Z","build_version":"1.0"},"cloud":{"enabled":false,"connected":false},"timezone":"Europe/Zurich","lat":47.376900,"lng":8.541690,"tzautodetect":true,"tz_utc_offset":3600,"tz_dst":false,"tz_dst_auto":true,"time":"09:19","unixtime":1584523151,"sensors":{"temperature_threshold":0.0,"temperature_unit":"C"},"sleep_mode":{"period":24,"unit":"h"}, "report_url":"http://192.168.80.203:8080/shelly/event/shellyflood-694835/sensordata", "flood_detected_url":"", "flood_gone_url":"", "rain_sensor":false}
09:19:11.080 [DEBUG] [ly.internal.handler.ShellyBaseHandler] - shellyflood-694835: Device has relays: false (numRelays=0, is roller: false (numRoller=0), is Plug S: 
false, is Dimmer: false, has LEDs: false, is Light: false, has Meter: false (numMeter=0, EMeter: false), is Sensor: true, is Sense: false, has Battery: true (low battery threshold=20%), event urls: btn:false,out:false,pushfalse,roller:false,sensor:true
09:19:11.143 [DEBUG] [ing.shelly.internal.api.ShellyHttpApi] - Check/set Sensor Reporting URL
09:19:11.421 [DEBUG] [ly.internal.handler.ShellyBaseHandler] - shellyflood: Thing successfully initialized.
09:19:11.426 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood: CoIoT Message from /192.168.80.224:5683: ACK-2.05   MID=18072, Token=, OptionSet={"Unknown (3332)":0x534857542d31233639343833352331}, "{"blk":[{"I":1, "D":"sen".. 201 bytes
09:19:11.428 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood: CoIoT Device Description for SHWT-1#694835#1: {"blk":[{"I":1, "D":"sensors"}],"sen":[{"I":23, "D":"flood", "T":"S", "R":"0/1", "L":1},{"I":33, "D":"temperature", "T":"T", "R":"-40/125", "L":1},{"I":77, "D":"battery", "T":"B", "R":"0/100", "L":1}]}       
09:19:11.431 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood:    id=1: sensors
09:19:11.433 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood: Adding 3 sensor definitions
09:19:11.435 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood:    id 23: flood, Type=S, Range=0/1, Links=1
09:19:11.437 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood:    id 33: temperature, Type=T, Range=-40/125, Links=1
09:19:11.439 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood:    id 77: battery, Type=B, Range=0/100, Links=1
09:19:11.483 [DEBUG] [ly.internal.handler.ShellyBaseHandler] - shellyflood: Updating sensor
09:19:11.485 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood: CoIoT Message from /192.168.80.224:5683: NON-2.05   MID=18073, Token=, OptionSet={"Uri-Path":["cit","s"], "Unknown (3332)":0x534857542d31233639343833352331, "Unknown (3412)":0x9600, "Unknown (3420)":0x0100}, "{"G":[[0,23,0],[0,33,22.".. 38 bytes
09:19:11.488 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood: CoIoT Sensor data {"G":[[0,23,0],[0,33,22.4],[0,77,95]]}
09:19:11.489 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood: 3 status updates received
09:19:11.491 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood:  Sensor value[0]: Index=23, Value=0.0 (flood, Type=S, Range=0/1, Link=1: sensors)        
09:19:11.493 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood:  Sensor value[1]: Index=33, Value=22.4 (temperature, Type=T, Range=-40/125, Link=1: sensors)
09:19:11.495 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood:  Sensor value[2]: Index=77, Value=95.0 (Battery, Type=B, Range=0/100, Link=1: sensors)   
09:19:11.497 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood: Process 3 CoIoT channel updates
09:19:11.499 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood:  Update[0] channel battery#batteryLevel, value=95.00 % (type class org.eclipse.smarthome.core.library.types.QuantityType)
09:19:11.503 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood:  Update[1] channel sensors#flood, value=OFF (type class org.eclipse.smarthome.core.library.types.OnOffType)
09:19:11.505 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood:  Update[2] channel sensors#temperature, value=22.40 Ā°C (type class org.eclipse.smarthome.core.library.types.QuantityType)
09:19:11.508 [INFO ] [home.model.script.Shelly.rules.......] - Shellyflood02_Flood - changed to: OFF
09:19:11.529 [INFO ] [e.smarthome.model.script.System.rules] - Notify_All - received command: WaschkĆ¼che W-Verteilung: Wasser-Sensor Alarm aus.
09:19:11.544 [DEBUG] [ly.internal.handler.ShellyBaseHandler] - shellyflood: 2 more updates requested
09:19:13.271 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood: CoIoT Message from /192.168.80.224:5683: NON-2.05   MID= 3598, Token=null, OptionSet={"Uri-Path":["cit","s"], "Unknown (3332)":0x534857542d31233639343833352331, "Unknown (3412)":0x9600, "Unknown (3420)":0x0100}, "{"G":[[0,23,0],[0,33,22.".. 38 bytes     
09:19:13.274 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood: Serial 256 was already processed, ignore update; payload={"G":[[0,23,0],[0,33,22.4],[0,77,95]]}
09:19:14.006 [DEBUG] [ly.internal.handler.ShellyBaseHandler] - shellyflood: Thing ShellyFlood03 is now online
09:19:14.009 [DEBUG] [ly.internal.handler.ShellyBaseHandler] - shellyflood: Updating sensor
09:19:14.011 [WARN ] [ommon.WrappedScheduledExecutorService] - Scheduled runnable ended with an exception: 
java.lang.IllegalArgumentException: The validated object is null
        at org.apache.commons.lang.Validate.notNull(Validate.java:192) ~[?:?]
        at org.apache.commons.lang.Validate.notNull(Validate.java:178) ~[?:?]
        at org.openhab.binding.shelly.internal.api.ShellyHttpApi.getSensorStatus(ShellyHttpApi.java:177) ~[?:?]
        at org.openhab.binding.shelly.internal.handler.ShellyComponents.updateSensors(ShellyComponents.java:183) ~[?:?]
        at org.openhab.binding.shelly.internal.handler.ShellyBaseHandler.updateStatus(ShellyBaseHandler.java:361) ~[?:?]
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) ~[?:1.8.0_242]
        at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:308) ~[?:1.8.0_242]
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:180) ~[?:1.8.0_242]
        at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:294) ~[?:1.8.0_242]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_242]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_242]
        at java.lang.Thread.run(Thread.java:748) [?:1.8.0_242]
09:19:14.606 [DEBUG] [ly.internal.handler.ShellyBaseHandler] - shellyflood: Updating sensor
09:19:14.668 [DEBUG] [ly.internal.handler.ShellyBaseHandler] - shellyflood: 1 more updates requested
09:19:17.726 [DEBUG] [ly.internal.handler.ShellyBaseHandler] - shellyflood: Updating sensor
09:19:17.788 [DEBUG] [ly.internal.handler.ShellyBaseHandler] - shellyflood: 0 more updates requested
09:19:24.790 [DEBUG] [.discovery.ShellyDiscoveryParticipant] - Shelly device shellyflood-6945c4 discovered with empty IP address
09:19:24.790 [DEBUG] [.discovery.ShellyDiscoveryParticipant] - Shelly device shellyflood-6945c4 discovered with empty IP address
09:19:24.795 [DEBUG] [.discovery.ShellyDiscoveryParticipant] - Shelly device discovered: IP-Adress=192.168.80.225, name=shellyflood-6945c4
09:19:24.799 [DEBUG] [.discovery.ShellyDiscoveryParticipant] - Shelly device discovered: IP-Adress=192.168.80.225, name=shellyflood-6945c4
09:19:24.818 [WARN ] [.discovery.ShellyDiscoveryParticipant] - Device discovery failed for device shellyflood-6945c4, IP 192.168.80.225, service=shellyflood-6945c4: 
null
java.lang.NullPointerException: null
        at org.openhab.binding.shelly.internal.api.ShellyHttpApi.request(ShellyHttpApi.java:474) ~[bundleFile:?]
        at org.openhab.binding.shelly.internal.api.ShellyHttpApi.getDeviceProfile(ShellyHttpApi.java:87) ~[bundleFile:?]
        at org.openhab.binding.shelly.internal.discovery.ShellyDiscoveryParticipant.createResult(ShellyDiscoveryParticipant.java:133) [bundleFile:?]
        at org.eclipse.smarthome.config.discovery.mdns.internal.MDNSDiscoveryService.considerService(MDNSDiscoveryService.java:274) [bundleFile:?]
        at org.eclipse.smarthome.config.discovery.mdns.internal.MDNSDiscoveryService.serviceResolved(MDNSDiscoveryService.java:266) [bundleFile:?]
        at javax.jmdns.impl.ListenerStatus$ServiceListenerStatus.serviceResolved(ListenerStatus.java:106) [bundleFile:3.5.5]
        at javax.jmdns.impl.JmDNSImpl$1.run(JmDNSImpl.java:894) [bundleFile:3.5.5]
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_242]
        at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_242]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_242]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_242]
        at java.lang.Thread.run(Thread.java:748) [?:1.8.0_242]
09:19:24.823 [WARN ] [.discovery.ShellyDiscoveryParticipant] - Device discovery failed for device shellyflood-6945c4, IP 192.168.80.225, service=shellyflood-6945c4: 
null
java.lang.NullPointerException: null
        at org.openhab.binding.shelly.internal.api.ShellyHttpApi.request(ShellyHttpApi.java:474) ~[bundleFile:?]
        at org.openhab.binding.shelly.internal.api.ShellyHttpApi.getDeviceProfile(ShellyHttpApi.java:87) ~[bundleFile:?]
        at org.openhab.binding.shelly.internal.discovery.ShellyDiscoveryParticipant.createResult(ShellyDiscoveryParticipant.java:133) [bundleFile:?]
        at org.eclipse.smarthome.config.discovery.mdns.internal.MDNSDiscoveryService.considerService(MDNSDiscoveryService.java:274) [bundleFile:?]
        at org.eclipse.smarthome.config.discovery.mdns.internal.MDNSDiscoveryService.serviceResolved(MDNSDiscoveryService.java:266) [bundleFile:?]
        at javax.jmdns.impl.ListenerStatus$ServiceListenerStatus.serviceResolved(ListenerStatus.java:106) [bundleFile:3.5.5]
        at javax.jmdns.impl.JmDNSImpl$1.run(JmDNSImpl.java:894) [bundleFile:3.5.5]
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_242]
        at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_242]
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_242]
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_242]
        at java.lang.Thread.run(Thread.java:748) [?:1.8.0_242]
09:19:28.271 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood: CoIoT Message from /192.168.80.224:5683: NON-2.05   MID= 3599, Token=null, OptionSet={"Uri-Path":["cit","s"], "Unknown (3332)":0x534857542d31233639343833352331, "Unknown (3412)":0x9600, "Unknown (3420)":0x0100}, "{"G":[[0,23,0],[0,33,22.".. 38 bytes     
09:19:28.274 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood: Serial 256 was already processed, ignore update; payload={"G":[[0,23,0],[0,33,22.4],[0,77,95]]}
09:19:43.370 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood: CoIoT Message from /192.168.80.224:5683: NON-2.05   MID= 3600, Token=null, OptionSet={"Uri-Path":["cit","s"], "Unknown (3332)":0x534857542d31233639343833352331, "Unknown (3412)":0x9600, "Unknown (3420)":0x0100}, "{"G":[[0,23,0],[0,33,22.".. 38 bytes     
09:19:43.374 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood: Serial 256 was already processed, ignore update; payload={"G":[[0,23,0],[0,33,22.4],[0,77,95]]}
09:19:58.372 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood: CoIoT Message from /192.168.80.224:5683: NON-2.05   MID= 3601, Token=null, OptionSet={"Uri-Path":["cit","s"], "Unknown (3332)":0x534857542d31233639343833352331, "Unknown (3412)":0x9600, "Unknown (3420)":0x0100}, "{"G":[[0,23,0],[0,33,22.".. 38 bytes     
09:19:58.374 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood: Serial 256 was already processed, ignore update; payload={"G":[[0,23,0],[0,33,22.4],[0,77,95]]}
09:20:13.471 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood: CoIoT Message from /192.168.80.224:5683: NON-2.05   MID= 3602, Token=null, OptionSet={"Uri-Path":["cit","s"], "Unknown (3332)":0x534857542d31233639343833352331, "Unknown (3412)":0x9600, "Unknown (3420)":0x0100}, "{"G":[[0,23,0],[0,33,22.".. 38 bytes     
09:20:13.493 [DEBUG] [helly.internal.coap.ShellyCoapHandler] - shellyflood: Serial 256 was already processed, ignore update; payload={"G":[[0,23,0],[0,33,22.4],[0,77,95]]}
09:22:10.681 [DEBUG] [.discovery.ShellyDiscoveryParticipant] - ServiceInfo [ServiceInfoImpl@185156988 name: 'shellyflood-694835._http._tcp.local.' address: '(null):80' status: 'DNS: JmDNS-/192.168.80.201 [/192.168.80.201] state: probing 1 task: null', has NO data, empty]
09:22:10.684 [DEBUG] [.discovery.ShellyDiscoveryParticipant] - ServiceInfo [ServiceInfoImpl@1019210741 name: 'shellyflood-694835._http._tcp.local.' address: '(null):80' status: 'DNS: JmDNS-/192.168.80.203 [/192.168.80.203] state: probing 1 task: null', has NO data, empty]
09:22:10.688 [DEBUG] [.discovery.ShellyDiscoveryParticipant] - ServiceInfo [ServiceInfoImpl@548092231 name: 'shellyflood-694B25._http._tcp.local.' address: '(null):80' status: 'DNS: JmDNS-/192.168.80.201 [/192.168.80.201] state: probing 1 task: null', has NO data, empty]
09:22:10.692 [DEBUG] [.discovery.ShellyDiscoveryParticipant] - ServiceInfo [ServiceInfoImpl@2045138607 name: 'shellyflood-694B25._http._tcp.local.' address: '(null):80' status: 'DNS: JmDNS-/192.168.80.203 [/192.168.80.203] state: probing 1 task: null', has NO data, empty]
09:22:30.682 [DEBUG] [.discovery.ShellyDiscoveryParticipant] - ServiceInfo [ServiceInfoImpl@1081290897 name: 'shellyflood-6945C4._http._tcp.local.' address: '(null):80' status: 'DNS: JmDNS-/192.168.80.201 [/192.168.80.201] state: probing 1 task: null', has NO data, empty]
09:22:30.689 [DEBUG] [.discovery.ShellyDiscoveryParticipant] - ServiceInfo [ServiceInfoImpl@1485437599 name: 'shellyflood-6945C4._http._tcp.local.' address: '(null):80' status: 'DNS: JmDNS-/192.168.80.203 [/192.168.80.203] state: probing 1 task: null', has NO data, empty]
09:23:15.960 [DEBUG] [ing.shelly.internal.api.ShellyHttpApi] - : Shelly API timeout (TimeoutException: Total timeout 5000 ms elapsed), retry

Thanks a lot

Did you installed the binding using PaperUI?
You need to use the DEV build, info: READMEbeta.md

Hi Markus

thanks for your feedback and help. I followed the READMEbeta guide but californium* and element-connector* were not installed by openhab when stored into the addons folder (ownership and permissions were correct). To solve this I installed the Tradfi binding, followed by the download of the Shelly2.5.3-snapshot binding.

With the result that the shelly binding seems to work properly and stable :slight_smile:

Will the final 2.5.3 version, that was announced today, have the dependencies included?

FYI: Although itā€™s working I still see the following NullPointer exception in the console every now and then

23:01:49.537 [WARN ] [.discovery.ShellyDiscoveryParticipant] - Device discovery failed for device shellyht-f391ff, IP 192.168.80.226, service=shellyht-f391ff: null
java.lang.NullPointerException: null
at org.openhab.binding.shelly.internal.api.ShellyHttpApi.request(ShellyHttpApi.java:474) ~[bundleFile:?]
at org.openhab.binding.shelly.internal.api.ShellyHttpApi.getDeviceProfile(ShellyHttpApi.java:87) ~[bundleFile:?]
at org.openhab.binding.shelly.internal.discovery.ShellyDiscoveryParticipant.createResult(ShellyDiscoveryParticipant.java:133) [bundleFile:?]
at org.eclipse.smarthome.config.discovery.mdns.internal.MDNSDiscoveryService.considerService(MDNSDiscoveryService.java:274) [bundleFile:?]
at org.eclipse.smarthome.config.discovery.mdns.internal.MDNSDiscoveryService.serviceResolved(MDNSDiscoveryService.java:266) [bundleFile:?]
at javax.jmdns.impl.ListenerStatus$ServiceListenerStatus.serviceResolved(ListenerStatus.java:106) [bundleFile:3.5.5]
at javax.jmdns.impl.JmDNSImpl$1.run(JmDNSImpl.java:894) [bundleFile:3.5.5]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_242]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_242]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_242]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_242]
at java.lang.Thread.run(Thread.java:748) [?:1.8.0_242]
23:01:49.537 [WARN ] [.discovery.ShellyDiscoveryParticipant] - Device discovery failed for device shellyht-f391ff, IP 192.168.80.226, service=shellyht-f391ff: null
java.lang.NullPointerException: null
at org.openhab.binding.shelly.internal.api.ShellyHttpApi.request(ShellyHttpApi.java:474) ~[bundleFile:?]
at org.openhab.binding.shelly.internal.api.ShellyHttpApi.getDeviceProfile(ShellyHttpApi.java:87) ~[bundleFile:?]
at org.openhab.binding.shelly.internal.discovery.ShellyDiscoveryParticipant.createResult(ShellyDiscoveryParticipant.java:133) [bundleFile:?]
at org.eclipse.smarthome.config.discovery.mdns.internal.MDNSDiscoveryService.considerService(MDNSDiscoveryService.java:274) [bundleFile:?]
at org.eclipse.smarthome.config.discovery.mdns.internal.MDNSDiscoveryService.serviceResolved(MDNSDiscoveryService.java:266) [bundleFile:?]
at javax.jmdns.impl.ListenerStatus$ServiceListenerStatus.serviceResolved(ListenerStatus.java:106) [bundleFile:3.5.5]
at javax.jmdns.impl.JmDNSImpl$1.run(JmDNSImpl.java:894) [bundleFile:3.5.5]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_242]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_242]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_242]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_242]
at java.lang.Thread.run(Thread.java:748) [?:1.8.0_242]