ESP2866 Tasmota Wifi Switch

  • Platform information:
    • Hardware: Raspberry pi 4 2GB
    • OS: _Max2Play


I try to connect a ESP2866 (wemos d1 mini) with flashed tasmota with a hardware pushbutton at GIPO 2 with Openhab.

In the end I want to switch different items with this wifi button (e.x. the light at the kitchen - used a shelly1)
I tried to bring the ESP thru the .items to the system and in combination with a rule. But it didn´t working.

Switch Wlanknopf_1 "Wlan Button 1 " (GF_Office,GF_Wohnzimmer,gSteckdose) [“Lighting”, “Switchable”] {channel=“mqtt:topic:Wlan-Button-001:Wlan-Button-001POWER”}

Here the rule:

rule “Buttons on”
when Item Wlanknopf_1 changed to ON
then {sendCommand(LichtKueche, ON)}

Thanks 4 help

Can you show your openHAB thing definition for this? And also an example of the message openHAB gets from the ESP when the button is pressed?

Does the Shelly switch work? You can control that from openHAB OK outside of this rule?

Also your rule looks slightly strange. Shouldn’t it be (assuming LichtKueche is a valid openHAB switch item):

rule “Buttons on”
when Item Wlanknopf_1 changed to ON

Hello thanks for your reply.

The thing definition is made at Paper UI like you see. Looking thru the messages of MQTTfx and the tasmota console everything seems to be all right. Push - ON / Sec Push=OFF


From your screenshot, your thing channel is mqtt:topic:WlanButton001:Wlan-Button-001POWER, which is not what you’re using in your item definition. Try to change your item to:

Switch Wlanknopf_1 "Wlan Button 1 " (GF_Office,GF_Wohnzimmer,gSteckdose) [“Lighting”, “Switchable”] {channel=“mqtt:topic:WlanButton001:Wlan-Button-001POWER”}

Hi, thanks I changed my mistakes. It doesn´t work abd it´s crazy, because when I change the wlan button item state via paper ui - control, the rule is working.

If I´m using the hardware wifi button, nothing happened.

Can you prove to us that openHAB is receiving a message from your D1? Can you show us your full thing configuration?

I don’t know how to show the configuration and the communication. Could you tell me what to do, please.

Thank you, sorry I’m at rooky level