ESP8266 Developer Zone The Official ESP8266 Forum 2017-02-05T00:39:13+08:00 https://bbs.espressif.com:443/feed.php?f=7&t=2514 2017-02-05T00:39:13+08:00 2017-02-05T00:39:13+08:00 https://bbs.espressif.com:443/viewtopic.php?t=2514&p=11234#p11234 <![CDATA[Re: ESP-Now slave with WiFi station+soft-AP mode]]>

Posting here again with what I found in case anyone else can find anything.

I don't think its that the range is short when in AP+STA i think its that there are lots of packet losses due to collisions or something but when you have the two EPS's really close together then the esp-now packets signal is so strong it drowns out the collision.

It seems like esp-now is request-response. The controller sends a message and the slave receives that and and sends an acknowledgement and the controller receives that acknowledgement and all is good and the esp-now send_cb is called with a status of 0. If the controller doesn't get the acknowledgment then the callback gets called with a non-zero status.

So if you have the controller send a message wait for the callback to be called and if the status is not 0 then retry the send again then it will eventually work. And the further away the two ESPs are the more attempts it usually takes before it works. Sometimes you see the slave does get the sent message but the controller keeps re-sending so the slave acknowledgement can get lost too.

Yesterday I wondered if using different channels made a difference and was messing about with that it started working and the messages were always going through successfully on the first send, and that was left running for a few hours sending a message every 15 seconds. But I can't recreate that today and it always takes dozens or even hundreds or retries before a successful send.

No idea. Has anyone got this working?

Statistics: Posted by torntrousers — Sun Feb 05, 2017 12:39 am


]]>
2016-08-10T11:07:26+08:00 2016-08-10T11:07:26+08:00 https://bbs.espressif.com:443/viewtopic.php?t=2514&p=8365#p8365 <![CDATA[Re: ESP-Now slave with WiFi station+soft-AP mode]]>
If the device is not connected to WiFi router, the ESP-NOW connection is very stable.

Statistics: Posted by waiweng83 — Wed Aug 10, 2016 11:07 am


]]>
2016-08-09T17:17:30+08:00 2016-08-09T17:17:30+08:00 https://bbs.espressif.com:443/viewtopic.php?t=2514&p=8349#p8349 <![CDATA[Re: ESP-Now slave with WiFi station+soft-AP mode]]> Statistics: Posted by torntrousers — Tue Aug 09, 2016 5:17 pm


]]>
2016-08-05T21:20:38+08:00 2016-08-05T21:20:38+08:00 https://bbs.espressif.com:443/viewtopic.php?t=2514&p=8299#p8299 <![CDATA[Re: ESP-Now slave with WiFi station+soft-AP mode]]> Statistics: Posted by torntrousers — Fri Aug 05, 2016 9:20 pm


]]>
2016-08-05T00:17:10+08:00 2016-08-05T00:17:10+08:00 https://bbs.espressif.com:443/viewtopic.php?t=2514&p=8291#p8291 <![CDATA[Re: ESP-Now slave with WiFi station+soft-AP mode]]>
It should all work just fine as long as all the devices are connected to the same local network.
What do you get if you use esp_now_is_peer_exist() to check whether a device exists?
If your device does not receive "most of the messages", then I would expect this API to return inconsistent results.

Statistics: Posted by Guest — Fri Aug 05, 2016 12:17 am


]]>
2016-08-04T17:06:03+08:00 2016-08-04T17:06:03+08:00 https://bbs.espressif.com:443/viewtopic.php?t=2514&p=8285#p8285 <![CDATA[ESP-Now slave with WiFi station+soft-AP mode]]>
Should that scenario work? The point is to be able to have a ESP-Now slave be a gateway to a WiFi access point for other ESP-Now controller nodes.

TIA.

Statistics: Posted by torntrousers — Thu Aug 04, 2016 5:06 pm


]]>