I recently bought 2 Shelly PlusPlugS and tried to configure them in openhab 4.3.2 (docker version) with shelly plugin updated to 4.3.5 SNAPSHOT with
bundle:install https://github.com/markus7017/myfiles/blob/master/shelly/org.openhab.binding.shelly-4.3.0-SNAPSHOT.jar?raw=true
Once the thing is created it shows immediatelly in the UI " COMMUNICATION_ERROR unexpected problem occured"
I tried with several firmware versions up to the Beta 1.5.1 and with and without password and I get always the same result.
2025-03-11 17:52:03.317 [DEBUG] [shelly.internal.ShellyHandlerFactory] - NetzwerkschrankStromversorgung: Create new thing of type shelly:shellyplugs using ShellyRelayHandler
2025-03-11 17:52:03.325 [DEBUG] [shelly.internal.ShellyHandlerFactory] - Thing handler for uid shelly:shellyplugs:NetzwerkschrankStromversorgung added, total things = 17
2025-03-11 17:52:05.328 [DEBUG] [y.internal.handler.ShellyBaseHandler] - shellyplugs-netzwerkschrankstromversorgung: Using default userId admin from binding config
2025-03-11 17:52:05.329 [DEBUG] [y.internal.handler.ShellyBaseHandler] - shellyplugs-netzwerkschrankstromversorgung: Using default password from bindingConfig (userId=admin)
2025-03-11 17:52:05.329 [DEBUG] [y.internal.handler.ShellyBaseHandler] - shellyplugs-netzwerkschrankstromversorgung: Config: Device address=192.168.2.124, HTTP user/password=admin/***, update interval=60
Events: Button: false, Switch (on/off): false, Push: false, Roller: trueSensor: true, CoIoT: true
Blu Gateway=false, Range Extender: true
2025-03-11 17:52:05.329 [DEBUG] [y.internal.handler.ShellyBaseHandler] - shellyplugs-netzwerkschrankstromversorgung: Start initializing for thing NetzwerkschrankStromversorgung, type shellyplugs, Device address 192.168.2.124, Gen2: false, isBlu: false, alwaysOn: true, hasBattery: false, CoIoT: true
2025-03-11 17:52:05.397 [DEBUG] [y.internal.handler.ShellyBaseHandler] - shellyplugs-netzwerkschrankstromversorgung: Unexpected API result: 404/Not Found
org.openhab.binding.shelly.internal.api.ShellyApiException:
at org.openhab.binding.shelly.internal.api.ShellyHttpClient.innerRequest(ShellyHttpClient.java:213) ~[?:?]
at org.openhab.binding.shelly.internal.api.ShellyHttpClient.httpRequest(ShellyHttpClient.java:113) ~[?:?]
at org.openhab.binding.shelly.internal.api1.Shelly1HttpApi.getDeviceProfile(Shelly1HttpApi.java:133) ~[?:?]
at org.openhab.binding.shelly.internal.handler.ShellyBaseHandler.initializeThing(ShellyBaseHandler.java:336) ~[?:?]
at org.openhab.binding.shelly.internal.handler.ShellyBaseHandler.lambda$0(ShellyBaseHandler.java:192) ~[?:?]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539) [?:?]
at java.util.concurrent.FutureTask.run(FutureTask.java:264) [?:?]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:304) [?:?]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) [?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) [?:?]
at java.lang.Thread.run(Thread.java:840) [?:?]
Any Idea what I am doing wrong?
Any help is appreciated.
Thanks
Michael
I enabled TRACE loglevel and now we see that setting is not known by the shellyplugs
18:13:14.523 [DEBUG] [ly.internal.handler.ShellyBaseHandler] - shellyplugs-netzwerkschrankstromversorgung: Start initializing for thing NetzwerkschrankStromversorgung, type shellyplugs, Device address 192.168.2.124, Gen2: false, isBlu: false, alwaysOn: true, hasBattery: false, CoIoT: true
18:13:14.524 [TRACE] [.shelly.internal.api.ShellyHttpClient] - NetzwerkschrankStromversorgung: HTTP GET http://192.168.2.124/shelly
Accept-Encoding: gzip
User-Agent: Jetty/9.4.54.v20240208
Content-Type: application/x-www-form-urlencoded
18:13:14.541 [TRACE] [.shelly.internal.api.ShellyHttpClient] - NetzwerkschrankStromversorgung: HTTP Response 200: {"name":"Netzwerkschrank ","id":"shellyplusplugs-fcb4670e3c84","mac":"FCB4670E3C84","slot":0,"model":"SNPL-00112EU","gen":2,"fw_id":"20250221-145401/1.5.1-beta1-g172c5bb","ver":"1.5.1-beta1","app":"PlusPlugS","auth_en":false,"auth_domain":null}
Content-Type: application/json
Content-Length: 244
Pragma: no-cache
Server: ShellyHTTP/1.0.0
Connection: close
18:13:14.543 [TRACE] [.shelly.internal.api.ShellyHttpClient] - NetzwerkschrankStromversorgung: HTTP GET http://192.168.2.124/shelly
Accept-Encoding: gzip
User-Agent: Jetty/9.4.54.v20240208
Content-Type: application/x-www-form-urlencoded
18:13:14.559 [TRACE] [.shelly.internal.api.ShellyHttpClient] - NetzwerkschrankStromversorgung: HTTP Response 200: {"name":"Netzwerkschrank ","id":"shellyplusplugs-fcb4670e3c84","mac":"FCB4670E3C84","slot":0,"model":"SNPL-00112EU","gen":2,"fw_id":"20250221-145401/1.5.1-beta1-g172c5bb","ver":"1.5.1-beta1","app":"PlusPlugS","auth_en":false,"auth_domain":null}
Content-Type: application/json
Content-Length: 244
Pragma: no-cache
Server: ShellyHTTP/1.0.0
Connection: close
18:13:14.560 [TRACE] [.shelly.internal.api.ShellyHttpClient] - shellyplugs-netzwerkschrankstromversorgung: HTTP GET http://192.168.2.124/shelly
Accept-Encoding: gzip
User-Agent: Jetty/9.4.54.v20240208
Content-Type: application/x-www-form-urlencoded
18:13:14.574 [TRACE] [.shelly.internal.api.ShellyHttpClient] - shellyplugs-netzwerkschrankstromversorgung: HTTP Response 200: {"name":"Netzwerkschrank ","id":"shellyplusplugs-fcb4670e3c84","mac":"FCB4670E3C84","slot":0,"model":"SNPL-00112EU","gen":2,"fw_id":"20250221-145401/1.5.1-beta1-g172c5bb","ver":"1.5.1-beta1","app":"PlusPlugS","auth_en":false,"auth_domain":null}
Content-Type: application/json
Content-Length: 244
Pragma: no-cache
Server: ShellyHTTP/1.0.0
Connection: close
18:13:14.576 [TRACE] [.shelly.internal.api.ShellyHttpClient] - shellyplugs-netzwerkschrankstromversorgung: HTTP GET http://192.168.2.124/settings
Accept-Encoding: gzip
User-Agent: Jetty/9.4.54.v20240208
Content-Type: application/x-www-form-urlencoded
18:13:14.592 [TRACE] [.shelly.internal.api.ShellyHttpClient] - shellyplugs-netzwerkschrankstromversorgung: HTTP Response 404: Not Found
Content-Length: 9
Server: ShellyHTTP/1.0.0
Connection: close
18:13:14.594 [DEBUG] [ly.internal.handler.ShellyBaseHandler] - shellyplugs-netzwerkschrankstromversorgung: Unexpected API result: 404/Not Found
org.openhab.binding.shelly.internal.api.ShellyApiException:
at org.openhab.binding.shelly.internal.api.ShellyHttpClient.innerRequest(ShellyHttpClient.java:213) ~[?:?]
at org.openhab.binding.shelly.internal.api.ShellyHttpClient.httpRequest(ShellyHttpClient.java:113) ~[?:?]
at org.openhab.binding.shelly.internal.api1.Shelly1HttpApi.getDeviceProfile(Shelly1HttpApi.java:133) ~[?:?]
at org.openhab.binding.shelly.internal.handler.ShellyBaseHandler.initializeThing(ShellyBaseHandler.java:336) ~[?:?]
at org.openhab.binding.shelly.internal.handler.ShellyBaseHandler.lambda$0(ShellyBaseHandler.java:192) ~[?:?]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539) [?:?]
at java.util.concurrent.FutureTask.run(FutureTask.java:264) [?:?]
at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:304) [?:?]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136) [?:?]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635) [?:?]
at java.lang.Thread.run(Thread.java:840) [?:?]
More debugging.
Looks like this is the code where we fail:
public ShellyDeviceProfile getDeviceProfile(String thingType, @Nullable ShellySettingsDevice device)
throws ShellyApiException {
if (device != null) {
profile.device = device;
}
if (profile.device.type == null) {
profile.device = getDeviceInfo();
}
String json = httpRequest(SHELLY_URL_SETTINGS);
and the constant is
public static final String SHELLY_URL_SETTINGS = "/settings";
When I enter the url in a browser I get back the same error “not found”
Maybe shellyplugs is the wrong thing?
You have a shellyplusplugs, right?
The thing is shellyplugs or shellyplusplug
Greets
Oh man, of course. Thanks for your hint.