Power consumption of esphome vs custom MQTT

Hi *
I want to try esphome again. I use custom mqtt at the moment.
I have built a simple SGP30 appliance with 4 relays.
board is Olimex ESP32-POE-ISO.
On a unify poe switch I compared the power consumption of the esphome device with the mqtt device, both connected via Ethernet.
esphome takes 3.96W and mqtt 2.88W.

I would really like to use esphome, but with 30 boards in the house this would mean an addition of ~30W in total, which outweighs the benefits of using esphome for me.

Is there any way to optimize the power consumption in esphome?


Do you have wifi part disabled? If not, wifi has power_save_mode - setting in wifi part. By default it’s set to none for 8266 and light for ESP32. You can try HIGH and see if consumption drops.


The Ethernet component does not compile together with the wifi component, so I don’t think this would help.

Yeah, you’re right.
Well, i guess maybe you could play with sleep mode a bit? But, at the end these 30W of difference will bring, i think ,under 1€/USD per year at the end and there’s really not worthed any effort…

Well, I agree, that the money isn’t worth the effort. However, I find it hard to accept a less efficient implementation, if a better solution (in terms of energy consumption) is possible. Particularly if I already have it running.

I would invest the time to migrate, always having the thought in mind that a better solution is possible…

Ha! I found the reason, and it’s stupid.
The relays work active low and I didn’t invert them.
I just realized that. Now, that they are off, it draws the same power as before.

Funny though, I had the board and the relays already cased in and couldn’t see the leds of the relays. Since it is still a testrun, I have nothing attached to the relays, which could indicate the correctness of the relay states. Furthermore, since the logic was not inverted, home assistant showed them in off-state.

I hope I can save someone some time with this stupidness :wink: