Sonoff ZBMINIL2 connected via Tasmota/Mosquitto not switchable

Hello,
I get mad on a Sonoff ZBMINIL2 connected via Tasmota/Mosquitto on OH 4.3.5
I was looking for hours now on forum but I can not Switch the Light from on/off.
Other Zigbee Devices are running..

UID: mqtt:topic:Mosquitto_local:Schalter_Wandlampen_WZ_EZ
label: Schalter Wandlampen WZ/EZ
thingTypeUID: mqtt:topic
configuration:
payloadNotAvailable: Offline
payloadAvailable: Online
transformationPattern:
- “”
availabilityTopic: tele/Tasmota1OG/LWT
bridgeUID: mqtt:broker:Mosquitto_local
location: Wohnzimmer
channels:

  • id: WandlampenWZEZ
    channelTypeUID: mqtt:switch
    label: Schalter WandlampenWZEZ
    description: “”
    configuration:
    commandTopic: cmnd/tele/Tasmota1OG/WandlampenWZEZ/Power
    stateTopic: tele/Tasmota1OG/WandlampenWZEZ/Power
    off: “0”
    on: “1”

I have some WiFi Sonoff mini 2 and my config is as follows. I assume you are aware that the topic can be different in your case, it depends on how it is configured in Tasmota.

label: Sonoff Ligths Kitchen
thingTypeUID: mqtt:topic
configuration:
  payloadNotAvailable: Offline
  availabilityTopic: SonoffMiniLightsKitchen/tele/LWT
  payloadAvailable: Online
bridgeUID: mqtt:broker:MQTT_Broker_OH
channels:
  - id: power
    channelTypeUID: mqtt:switch
    label: Sonoff Ligths Kitchen
    configuration:
      commandTopic: SonoffMiniLightsKitchen/cmnd/POWER
      retained: false
      postCommand: false
      formatBeforePublish: "%s"
      stateTopic: SonoffMiniLightsKitchen/stat/POWER

My Tasmota config related to the topic (Tasmota v13.1.0):

SonoffMiniLightsKitchen

Full Topic (%prefix%/%topic%/)
%topic%/%prefix%/

It is always good idea ro use MQTT Explorer to check how your device is publishing on the broker and you can also send commands.

Hallo nochmal,

ich kriege es einfach nicht auf die Reihe.

Hier ist die Ausgabe bei Betätigung des Lichtschalters in der Konsole der TasmotaBridge und identisch mit dem MQTT Explorer:

Tasmota1OG/tele/SENSOR = {“StrahlerWZ”:{“Device”:“0x93C2”,“Name”:“StrahlerWZ”,“Power”:0,“Endpoint”:1,“LinkQuality”:40}}

Mein Code in openHAB sieht aktuell so aus - allerdings keine Reaktion auf Status oder Schalten:

UID: mqtt:topic:f4f35e27dd:StrahlerEZ
label: StrahlerEZ
thingTypeUID: mqtt:topic
configuration:
payloadNotAvailable: Offline
availabilityTopic: Tasmota1OG/tele/LWT
payloadAvailable: Online
bridgeUID: mqtt:broker:f4f35e27dd
location: Esszimmer
channels:

  • id: SchalterSTrahlerEZ
    channelTypeUID: mqtt:switch
    label: SchalterSTrahlerEZ
    description: “”
    configuration:
    commandTopic: Tasmota1OG/tele/SENSOR
    transformationPatternOut:
    - JSONPATH$.0x93C2.Power
    stateTopic: Tasmota1OG/tele/SENSOR
    transformationPattern:
    - JSONPATH$.0x93C2.Power
    off: “0”
    on: “1”

HILFEEEEE ;.)

english please, this is an international community.

I don’t understand German but I dont use transformations. I also see you use different topics in your channel.

My channel is using the following topics:

commandTopic: SonoffMiniLightsKitchen/cmnd/POWER

stateTopic: SonoffMiniLightsKitchen/stat/POWER

Just a question from my side. Did you flashed your ZBMini L2 with Tasmota ? As far as I know there are two versions of the ZBMini L2.

Zigbee and WiFi via EWLink.

I’m using the Zigbee-Version with Z2M which works with MQTT. And I have no problems with the device, but it’s also new for me.

As said from @DarkoG if you’re using the Tasmota-Syntax your Parameters of your" Thing" should look like he said.

An example(Tasmota) for a switch from my textual SetUp looks:

    Thing mqtt:topic:danny:s2004 "Sonoff S20 04"  (mqtt:broker:danny )     @ "MQTT2" [
         availabilityTopic="tele/schaltdose04/LWT",
         payloadNotAvailable="Offline",
         payloadAvailable= "Online"
      ]
    {
    Channels:
        Type switch : power     "Power "                 [ stateTopic="stat/schaltdose04/POWER", commandTopic="cmnd/schaltdose04/POWER" ]
        Type number : rssi      "WiFi Signal Strength"   [ stateTopic="tele/schaltdose04/STATE", transformationPattern="JSONPATH:$.Wifi.RSSI"]
        Type string : version   "Firmware Version    "   [ stateTopic="stat/schaltdose04/STATUS2", transformationPattern="JSONPATH:$.StatusFWR.Version"]
        Type switch : reachable "Reachable"              [ stateTopic="tele/schaltdose04/LWT", on="Online", off="Offline" ]
        Type string : hardware  "Chip Set            "   [ stateTopic="stat/schaltdose04/STATUS2", transformationPattern="JSONPATH:$.StatusFWR.Hardware"]
        Type string : ipaddress "IP Address          "   [ stateTopic="stat/schaltdose04/STATUS5", transformationPattern="JSONPATH:$.StatusNET.IPAddress"]
        Type string : grouptop  "Group Topic         "   [ stateTopic="stat/schaltdose04/STATUS1", transformationPattern="JSONPATH:$.StatusPRM.GroupTopic"]
    }

As I’m using Z2M my MQTT-Thing for the ZBMini L2 looks:

//-------------------------------------------------ZB Mini L2 no neutral required--------------------------------------------------------------------------------------------------

Thing mqtt:topic:danny:zbminil201 "Sonoff ZBMini L2 01"  (mqtt:broker:danny )   @ "zigbee2mqtt" 
      [ availabilityTopic="zigbee2mqtt/zbminil2_01/availability", transformationPattern="JSONPATH:$.state", payloadNotAvailable="offline", payloadAvailable="online" ] 
    {
    Channels:
        Type switch   : state       "ZBMiniL2 01 Ein/Aus"                     [ stateTopic="zigbee2mqtt/zbminil2_01/state",commandTopic="zigbee2mqtt/zbminil2_01/set/state", on="ON", off="OFF" ]
        Type string   : pob         "ZBMiniL2 01 Power on Behavior"           [ stateTopic="zigbee2mqtt/zbminil2_01/power_on_behavior" ]
        Type number   : linkquality "ZBMiniL2 01 Empfangsstärke LQI"          [ stateTopic="zigbee2mqtt/zbminil2_01", transformationPattern="JSONPATH:$.linkquality" ]
        Type switch   : reachable   "ZBMiniL2 01 Reachable"                   [ stateTopic="zigbee2mqtt/zbminil2_01/availability", transformationPattern="JSONPATH:$.state", on="online", off="offline" ]
        Type datetime : lastseen    "ZBMiniL2 01 Letzter Handshake"           [ stateTopic="zigbee2mqtt/zbminil2_01/last_seen" ]
    }

I use it via UI


and via Soft-Buttons (SNZB01P - handled by a Rule). And of course with the normal Wall-Switch.
Cheers - Peter

HERE THE WORKING SOLUTION

UID: mqtt:topic:f4f35e27dd:SchalterBuero
label: Licht Buero
thingTypeUID: mqtt:topic
configuration:
payloadNotAvailable: Offline
availabilityTopic: tele/Tasmota2OG/LWT
payloadAvailable: Online
bridgeUID: mqtt:broker:f4f35e27dd
location: Buero
channels:

  • id: Power
    channelTypeUID: mqtt:switch
    label: Power
    description: “”
    configuration:
    commandTopic: cmnd/Tasmota2OG/ZbSend
    formatBeforePublish: ‘{“Device”:“0x404D”,“send”:{“Power”:%s}}’
    stateTopic: tele/Tasmota2OG/SENSOR
    transformationPattern:
    - JSONPATH:$[“SchalterBuero”].Power
    off: “0”
    on: “1”