-->
Page 1 of 1

Saved settings preventing reconnection?

PostPosted: Thu Oct 23, 2014 10:49 pm
by AdrianClark
Hi,

I've developed some custom firmware for a project I'm working on which automatically connects to a defined wireless network and communicates with other machines as both a client and a server. So far it's working really well and does everything I need it to, but for one problem.

Once the chipset has connected to the network one time, after a power cycle it is never able to reconnect, or even do things like list access points. In fact, in order to get it working at all, I need to reflash the firmware with firmware which resets the complete flash memory (not just the 0x00000 and 0x40000 blocks). Because of this, I'm lead to believe that one of the commands (wifi_station_connect) sets a flag in the flash memory which needs to be cleared in order for those other commands again. I guess this is probably done internally by wifi_station_disconnect, but if the power is lost before that command is called, trying to issue the command fails.

Has anyone else experienced this/have any idea how to clear this flag? The only thing missing from the system I've developed is it's unable to reconnect in the event of lost power.

Cheers

Re: Saved settings preventing reconnection?

PostPosted: Fri Oct 24, 2014 12:57 am
by igrr
I definitely had cases when the module lost power while connecting, and still didn't notice issues like you are describing. It might be a firmware issue. Can you share your code or at least some example that reproduces the problem? How often does that issue happen? Can you dump the settings region of the flash after the module comes into such condition?

Re: Saved settings preventing reconnection?

PostPosted: Wed Nov 05, 2014 12:58 am
by AdrianClark
Sorry about the delay in replying, been very busy at work.

I managed to get another chance to look at it today. Since my last post I upgrade the power supply I was using, and I also upgraded the SDK I was building off to v0.9.2.2 (or whatever the one espressif made public), and rewrote my code from scratch based on the AT example in there, and it seems the problem has gone away. Not sure what exactly it was which fixed it (although probably not the power supply), but at least it's working now.