Http item switching socket (Blitzwolf)

hello,
i’m new to openhab.
My item (Alan socket) does not work:

Switch Licht_Wohnzimmer_Stehlampe (gWohnen) {http=">[ON:POST:192.168.178.49/cm?cmnd=Power%20ON] >[OFF:POST:192.168.178.49/cm?cmnd=Power%20OFF]"}

If I send the request via url it works.
What did I do wrong?

Errors in the logs?

no errors in the log

2020-02-10 18:03:48.749 [ome.event.ItemCommandEvent] - Item ‘Licht_Wohnzimmer_Stehlampe’ received command ON
2020-02-10 18:03:48.789 [vent.ItemStateChangedEvent] - Licht_Wohnzimmer_Stehlampe changed from OFF to ON
2020-02-10 18:03:52.343 [ome.event.ItemCommandEvent] - Item ‘Licht_Wohnzimmer_Stehlampe’ received command OFF
2020-02-10 18:03:52.383 [vent.ItemStateChangedEvent] - Licht_Wohnzimmer_Stehlampe changed from ON to OFF

but in the openhab.log:

2020-02-09 15:38:58.276 [WARN ] [org.apache.karaf.services.eventadmin] - EventAdmin: Exception during event dispatch [org.osgi.service.event.Event [topic=openhab/command/Licht_Wohnzimmer_Stehlampe] {item=Licht_Wohnzimmer_Stehlampe, bridgemarker=true, command=ON, timestamp=1581262738270} | {org.osgi.service.cm.ManagedService, org.osgi.service.event.EventHandler}={service.id=387, service.bundleid=233, service.scope=bundle, event.topics=openhab/*, service.pid=org.openhab.http, component.name=org.openhab.binding.http, component.id=243} | Bundle(org.openhab.binding.http_1.14.0 [235])]
java.util.UnknownFormatConversionException: Conversion = ‘O’
at java.util.Formatter$FormatSpecifier.conversion(Formatter.java:2691) ~[?:1.8.0_222]
at java.util.Formatter$FormatSpecifier.(Formatter.java:2720) ~[?:1.8.0_222]
at java.util.Formatter.parse(Formatter.java:2560) ~[?:1.8.0_222]
at java.util.Formatter.format(Formatter.java:2501) ~[?:1.8.0_222]
at java.util.Formatter.format(Formatter.java:2455) ~[?:1.8.0_222]
at java.lang.String.format(String.java:2940) ~[?:1.8.0_222]
at org.openhab.binding.http.internal.HttpBinding.formatAndExecute(HttpBinding.java:294) ~[?:?]
at org.openhab.binding.http.internal.HttpBinding.internalReceiveCommand(HttpBinding.java:147) ~[?:?]
at org.openhab.core.binding.AbstractBinding.receiveCommand(AbstractBinding.java:97) ~[?:?]
at org.openhab.core.events.AbstractEventSubscriber.handleEvent(AbstractEventSubscriber.java:49) ~[?:?]
at org.apache.felix.eventadmin.impl.handler.EventHandlerProxy.sendEvent(EventHandlerProxy.java:415) [bundleFile:?]
at org.apache.felix.eventadmin.impl.tasks.HandlerTask.runWithoutBlacklistTiming(HandlerTask.java:82) [bundleFile:?]
at org.apache.felix.eventadmin.impl.tasks.SyncDeliverTasks.execute(SyncDeliverTasks.java:104) [bundleFile:?]
at org.apache.felix.eventadmin.impl.tasks.AsyncDeliverTasks$TaskExecuter.run(AsyncDeliverTasks.java:166) [bundleFile:?]
at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) [?:1.8.0_222]
at java.util.concurrent.FutureTask.run(FutureTask.java:266) [?:1.8.0_222]
at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149) [?:1.8.0_222]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624) [?:1.8.0_222]
at java.lang.Thread.run(Thread.java:748) [?:1.8.0_222]

Please How to use code fences.

You will never see errors in events.log.

The error looks like it is complaining about the “O” from “ON” in the URL. I don’t know if the binding supports URL encoding symbols like that. You might try just putting in the space or an escaped space \ instead of the %20.

The %20s would probably work if the format config setting was set to false.

The %20 s would probably work if the format config setting was set to false.

hi,

that’s it. Now it works.

Thank you very much!