That’s indeed a technical requirment if you want one esp to be connected to a WPAx and working as the same time as ESP-NOW gateway.
But as you wrote one can just make use of a esp32 board with ethernet to have esp-now on whatever channel. I had like the opposite mileage like you btw. and is was super easy (typical esphome magic) to get ethernet working on my esp’s.
I’m no network specialist but have to communicate a lot with them. They never make use of “smart channel” (I think one vendor calls it that way) but always fix the channel manually. There are various reasons for it but one is probably that auto channeling mostly doesn’t work the user think it does and in reality it often degrades the reliability of a network. Often the sensing for other devices is only scheduled hourly (or even less) on the AP and can cause to hog on dense channels just because a mobile hotspot was on for a short time.
I would expect the author want’s to make use of batteries (maybe paired with solar) for the slave devices. In this case using WPAx is not recommended but ESP-Now is a valid way to minimize power consumption.
I did not have that many issues with getting my ethernet port to work, but it is hard to make a general guide for others to follow, becaus there is no standard ethernet port.
And auto channel works pretty good on most APs. It should only be the cheap ones that rely on only visible said. The decent and good ones look at signal to noise ratio on the different channels.
Where people fail is to use auto channels for multiple APs. 2 might go, but with 3 it can become a cyclic loop where one AP move to another As channel forcing that second AP to move to a third APs channel and third third AP then move to the first APs channel and so on.
With 2 and 3 APs manual setting the channels is better.
With more than 3 APs only automatic WiFi controllers are really capable of it.
WiFi controllers are able to know each APs channel and also there neighbors and their channel and signal strengths.
Adjusting more than 3 APs means adjusting the signal strength too.
The issue with having WiFi and ESP-Now on the same channel is that the battery powered devices is forced to listen to WiFi communication too.
ESP-Now is just a WiFi lite protocol.
The only thing I care about is: Does it work with esphome? And that hardware is what I buy.
In case of esp32 boards with ethernet it is simple as opening:
and choose a board from the configuration examples. In ended up with some Wireless Tag WT32-ETH01 boards which were around $10 and work just a treat.
This issue is actually more a theoretical one. Having a battery powered device awake for 1 second and in deep sleep (radio off) for like 3600 seconds (1 hour) it is probably negligible in terms of power draw. Beside if you are in a dense environment you might be able to influence the channels used by your own wpa-wifi access points but as air is a shared medium you need to accept other participants ether way
Hey, sorry for not saying anything I’ve been too busy lately, thanks for all the replys I’ve been reeading them and gonna try them to my project, I just had one question:
How do I implement this? The board with the ethernet port runs esphome and the others just the code for arduino with espnow? Sorry if this sounds kinda dumb but I’m new in this world of Home assistant and esphome.
Thanks !!
Not sure if you got an answer but, assuming your question is how do you tie espnow to wifi to home assistant, then using two ESP32s (or similar) is a pretty reliable option.
This just needs 4 wires (RX, TX, GND and Power) to be linked between the two boards. One is free to be your espnow receiver and the other is free to wander all over the wifi and deliver espnow messages to home assistant via MQTT.
Are they on ESPNOW? If yes then you can send a MQTT Message to this and it will broadcast on ESPNOW. May need to tweak a little. If you send me link to the code you used for esphome flashlight then I can add it in.
Looks like it should directly talk to HA and not ESPNOW. Unless I know what exact message is needed to be sent via ESPNOW it would be difficult for me to add. Currently it broadcasts whatever it gets via MQTT. But ofcourse I need to tweak it to work better.
ESP-Now can actually run with just one ESP device as a hub, but it puts some limitations on the setup.
If only one device is used, then ESP-Now and WiFi is required to use the same frequency and since the frequency is hardcoded in the ESP_Now code, then it means you WiFi also needs to use a fixed frequency.
Sharing WiFi and ESP-Now on the same frequency might also be problematic, since a high load on the WiFi would then interfere with the ESP-Now.
A better way might be an ESP device with an ethernet board and then it can be MQTT, serial over TCP, webhooks or whatever to connect to HA.
Seems like esp-now is more limited than I thought it would be. Perhaps I should look at a different solution. Bit of a bummer though but it is what it is.
It is not ESP-Now that is limited, but the hardware.
With just one ESP chip you have only one radio.
People link two ESP chips together to get around that limitation, so one chip can run the ESP-Now on one frequency and the WiFi can run on another frequency.