Event callback still called after deiniting it and calling esp_wifi_stop()

trwel4
Posts: 2
Joined: Sun Feb 12, 2023 7:21 pm

Event callback still called after deiniting it and calling esp_wifi_stop()

Postby trwel4 » Sun Feb 12, 2023 7:27 pm

I am trying to develop a mesh application where at the root node, it checks for the existence of the router. If it wasn't there after N seconds, it will make a local mesh network instead.

This is the code I wrote to restart the esp-mesh

rsimpsonbusa
Posts: 124
Joined: Tue May 17, 2016 8:12 pm

Re: Event callback still called after deiniting it and calling esp_wifi_stop()

Postby rsimpsonbusa » Wed Jun 07, 2023 5:08 am

Partially I have same problem or need.

You should monitor the IP_EVENT_STA_GOT_IP and IP_EVENT_STA_LOST_IP. I can vouch for the IP_EVENT_STA_GOT_IP event, which I use to start other tasks only when there is a confirmed connection to the router, made by starting the mesh.

But I have not been able to receive the IP_EVENT_STA_LOST_IP event, in order to manage these tasks correctly. This at root node since it controls the access to the router.

Wrong topic title BTW... and no code... in a hurry? :)

Who is online

Users browsing this forum: No registered users and 25 guests