Replacing Tasmota firmware with EsphomeLib

I see you have an id for the momentary… yes it’s working… just the LED and the momentary button staying on in HA…

hmmm. strange that the button is staying on in HA. Maybe try adding an id for the momentary in ESP

just tried that. nope

ESP8266s don’t have pins with number 25 - ESP8266s only have pins GPIO0 through GPIO16

And I also tried the on_press trigger we chatted about on discord, and it did work for me flawlessly… Just to rule out this explanation: Are you sure you’re uploading to the correct device? (I’ve been bitten by this before, spend time working out why something doesn’t work then figure out OTAs did not apply or used the wrong device).

To check, you can rename a switch and see if it changes in HA too.

Yes I was surprised with Pin 25 for that reason but thought it was a virtual pin… I took it from the docs…

I can make the momentary thing work but I’m not seeing the on/off in the integration and the LED’s behave properly.

Definitely the right switch.

Does this help at all? I don’t have Sonoff’s so don’t have experience in them.

@DavidFW1960 I also have the same experience with Tasmota tried all different flavors of their firmware.

I’m ready to try ESPhomelib, just want a stable environment.
How was your experience? Can the flashing be done over OTA ?

Is it correct to say that I will miss the web interface that Tasmota has for manual configuration compared to ESPhomelib?

I have 4 sonoffs S20 and 1 Basic.

edit: what about the RF Bridge - is possible to install esphome on that device?

I don’t know. Def flash OTA but I have not seen/found a working configuration yet. I just don’t think ESPhome is up to prime time yet. I’m back with Tasmota again.

Def miss the web interface. Everything is done via the YAML which you compile and flash.

Once flashed though do you really need a web interface for the device? I would imagine they would be set and forget…

You can enable a simple web interface, this only allows simple functions like toggling the switces etc. For me the move to ESPhome has been brilliant, the native integration into HA without mqtt is nice. i have moved over 2 x Sonoff TH10, 1 x sonoff S26, 1 Sonoff 4ch pro, 2 x brilliant smart plugs (tuya) and a mirabella genio bulb. i used tuya-convert to get the tuya based ones to tasmota and then used it to upload esphome. easy as

Yes but the S26… does it function the same as it did with Tasmota with the LED’s? I would have persisted longer if I got some help with the YAML file that actually helped.

I can’t believe my use-case is unusual or unique and that there are not standard published configurations for a simple switch. Compare that with the information on the Tasmota Github…

And Tasmota is great despite my recent frustrations.

I don’t even understand the philosophy of how all the different parts of the YAML fit together and there doesn’t seem to be any coherent information I can read in one place.

Hi Dave
My use of the s26 is fairlysimple, blue led on when connection to wifi, blinking/off when issue
red led on/off when relay toggled

I thought the doco on esphome was pretty comprehensive.
i just see it as i would a package in HA. for me as it was in yaml was easier to fathom. Also remember esphome is a pretty new kid of the block, thats why we should publish any configs to the cookbook page. this will help new users.

Also have a look at franck esphome examples. some good info in there.

i can’t help with the esphomelib stuff as i’m a tasmota user and have no plans on switching.

i can maybe offer some insight (not a solution) to the disconnects. if they are related to what i’m experiencing. and others seem to be.

for what it’s worth, i’ve written my own firmware for a thermostat and a garage door controller and they both experience the disconnect issue as well, no relation to tasmota, so i’m thinking this is less a tasmota issue and an esp8266/lwip issue.

if by disconnects you mean that you can no longer talk to the tasmota devices after X period of time with either a simple ping or mqtt, this is seemingly becoming more common. there’s lots of discussion in various places about it. i’ve tried a few different versions of the the esp8266 lib (2.4.0/2.4.2/stage) and haven’t had a version where the problem doesn’t manifest itself.

i have one anecdotal piece of evidence that it might be related to crossing between 2.4/5GHz on the router (asus rt-3100 running asus merlin) as my mqtt server (creatively named raspberrypi) is on 2.4 and the ESPs seemingly don’t have an issue establishing a connection between themselves and the mqtt server. my HA implementation (venv style) is on a secondary raspberry (just as creatively named rasp02) on the 5GHz frequency and it can’t connect to the mqtt server (raspberrypi). they two are crossing frequencies and i’m at a loss as to why that could be an issue. i don’t seem to have any other issues with other devices.

to solve all this someone suggested a ping routine in the firmware to occasionally keep connections alive. this basically keeps the ESP8266s ARP table fresh. i don’t think this function exists in tasmota yet and i wasn’t going to recompile my thermostat/garage door firmware with this functionality when it didn’t fix the two raspberry’s talking issue.

the other suggestion was an ARP responder. this makes a lot more sense for my implementation here at home and through lots of packet capture i can confirm that the ESP8266s do NOT respond to broadcast ARP queries like they should (or they are being lost for some reason between 2.4G/5Ghz).

the ARP responder sends out the reply for the ESP8266s and this fixes the lack of connectivity issue, every time, immediately. i can stop the arp_responder and after a time communication between ESPs and my compute device (my notebook) can no longer connect. i fire up the ARP responder and everyone can talk to everything every where.

ymmv. and this may not be the solution you are looking for.

this is still very much a work in progress and i am not a programmer by trade (but i play one on TV!). code here: https://github.com/loph917/arp_responder

Tried 2.3.0 core? That works flawlessly for me.

Unfortunately all the dev releases of 6.4.1.x based on 2.3.0 core (even the precompiled ones fro Tasmota site) all put my switches into a boot loop which is a bunch of fun. 2.5.0 is normal behaviour but the disconnects…

That’s why I was looking to switch to esphome.

the 4th one there looks like what I’m looking for… I might give it a crack

If you want the green led to turn on when the switch is on, add this under the ‘switch’ section:

on_turn_on:
- light.turn_on: led
on_turn_off:
- light.turn_off: led

and make sure your green_led id is led, or change it to whatever.
I opted not to because I find the green led annoying an not needed (the thing it’s connected to is on if the switch is on, I don’t need to look at the led…)

I have managed to add the webinterface with OTA

ota:

web_server:
  port: 80

2 Likes

it is supported, did you try it? Wonder how are the commands to send/receive all the RF signals

I dont see that mentioned on the ESPhome guides/docs.

yes RF is supported, but no mention on how to use RF signals