Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WiFi.beginAP works intermittently on MKR wifi1010 #174

Open
davecorbett1961 opened this issue May 1, 2021 · 1 comment
Open

WiFi.beginAP works intermittently on MKR wifi1010 #174

davecorbett1961 opened this issue May 1, 2021 · 1 comment
Labels
type: imperfection Perceived defect in any part of project

Comments

@davecorbett1961
Copy link

davecorbett1961 commented May 1, 2021

Hi,

I have been having problems with WiFi.beginAP() failing on a regular basis, i.e. about 50% of times I try it. I have tried different variations, for example:

  status = WiFi.beginAP(ssid, pass);
  if (status != WL_AP_LISTENING) {
    Serial.println("Creating access point failed");
    // don't continue
... or this:
  while ( status != WL_AP_LISTENING)
  {
    status = WiFi.beginAP(ssid, pass);
    // wait for connection:
    delay(100);
  }

I have updated my Arduino to latest firmware (1.4.3) and upgraded the WiFiNINA library to 1.8.8, but the problem still occurs and is and hard to reproduce consistently. Do you have any ideas what may be causing this? Can you suggest how I should troubleshoot this problem?

Can anyone confirm what conditions might result in WiFi.beginAP() not connecting?

I have noticed that in lines like these: status = WiFi.beginAP(ssid, pass); "status" appears in orange, not black as in the examples, i.e. it appears to be a reserved word. Could this be a problem? I have tried changing to a normal variable name like "wifi_status" but I still get the problem...

The sketch which has the problems is very SRAM constrained. I typically have about 4000 bytes free after compilation, and the compiler gives "instability" warnings. Could this be a factor? I am trying to monitor the amount of free memory and as far as I can see I still have at least 2000 bytes free memory at all times.

Appreciate any help here!

@per1234 per1234 added the type: imperfection Perceived defect in any part of project label May 1, 2021
@davecorbett1961
Copy link
Author

So I suspect that my problem is down to memory issues, I don't see the problem when I have significantly more memory free. Also, I don't get the problem immediately after re-downloading the sketch. Is there a way I can initialise the WIFI module before attempting WiFi.beginAP() ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: imperfection Perceived defect in any part of project
Projects
None yet
Development

No branches or pull requests

2 participants