Can not Connect to my cell phone Hotspot

I have a Lumia 950XL (windows phone 10). My wife as a Nokia Lumia 720 (windows phone 8)
The Photon can connect to the Lumia 720 but not the 950XL.
I have multiple ESP8266 devices and they can connect to both phones. Of course other devices (non MCU) such as My Surface and other laptops and other phones can connect to the hotspot on my Lumia 950XL.

Just the Photo. has issues (even connecting to new routers is a problem).
Do others have issues connecting to “new” cell phones or new routers?
What can I do to try and resolve this or provide more information so as to get to the bottom of this?

What’s the RGB led status? What method (CLI, Serial, Phone App) did you use to send the Photon wifi credentials?

I used the CLI to set up the wifi. The LED blinks green and stays blinking green blinking at a constant rate.

Blinking green means it is trying to connect to the hotspot… I wonder if the security profile is causing the issue.

Can you try using OPEN and see if it works?

Yes, I know its trying to connect, but it never ends up connecting :).

Can you try using OPEN and see if it works?

My Hotspot is set to WPA2 Personal. Are you saying try OPEN in spite of this? I don't have the option to not define a password on my phone.

Using CLI and tried
AES+TKIP
TKIP
AES
none of them worked

At one of the talks I was giving someone from the Audience offered using her hotspot on an IPhone (don’t remember the model unfortunately), and it didn’t connect to the hotspot on her phone either. Basically, I couldn’t connect to the AP they had set up there, nor my phone or hers.

I had another talk the next day and they set up an open AP for me and I was able to connect to it without any trouble (but it was a different router from the one, the day before since it was right next to me. This router went out to the Internet directly, so I couldn’t connect to other devices or my Surface which has an MQTT broker running on it. So all devices were connected to this second router and I used http://iot.eclipse.org as my MQTT broker. That saved the day.

I can’t connect to the AP at my office either.

I have a few other talks and demos coming up so I’m hoping to be able to use my phone’s hotspot as a fallback, just in case.

I’m not sure since there is little info about this on these modern Phones, but I’ve seen a similar issue with a Samsung Galaxy S5 and iPhone 6 which could be in connection with these Phones also using 5GHz for their hotspots.

Could you check this with something like inSSIDer?

The ESP8266 can connect to my cell phone’s hot spot, without a hitch. So I’m guessing the Photon should be able to as well since the ESP8266 uses a 2.4GHz radio.

Another piece of information…
using the CLI, when I scan for networks, most times I only ever see my Wifi network. Not my cell phone’s hotspot nor any other in the vicinity. No amount of rescan makes them appear.

I also have the Wifi network shared using Connectify (it creates a hotspot) on my desktop. I can connect to this hotspot using the ESP8266, and my Phone, Surface, laptop etc. But once again, I can’t connect to it using the Photon. I’ve shared a connection this way (using Connectifiy) many times for others around me, and no one has had trouble connecting to it, using phones or laptops.

Hmm, could you flash a sketch to your Photon that uses SYSTEM_MODE(SEMI_AUTOMATIC) and only calls WiFi.connect() but not Particle.connect()
Just to see if it’s actually the WiFi you can’t connect to or if it’s the Particle cloud - maybe being blocked by some firewall settings/hotspot limitations.

BTW: Is it one Particle device or have you tested others and only one misbehaves?

I have 2 Photons and an Electron and I tested both Photons.

SYSTEM_MODE(SEMI_AUTOMATIC)

Do I call both this method and the Wifi.Connect() in the setup function?

This is actually a macro that will get processed during compile time, so you’d use it this way

SYSTEM_MODE(SEMI_AUTOMATIC)

void setup()
{
  WiFi.connect(); 
  Serial.begin(115200);
  if (!waitFor(WiFi.ready, 10000))
    Serial.println("Not able to connect to WiFi for 10sec");
  else
    Serial.println("Here we go");
}

void loop()
{
}

Ok, thanks, let me try this.

On a slightly different topic. I’ve never been able to get the “Serial” to start/connect soon enough to see Serial.println() messages in setup. I’'ve tried tools such as Real Term, Putty etc. as well as the CLI serial monitor. I mean I know how to use Real Term and Putty, but I’m not able to connect to th eCOM port in time to see these messages fly by (if that makes sense).

So how does one pull this off exactly?

I see the “Here we go” message. The Photon is breathing green not blue. My phone doesn’t show it is connected, however.

That is odd, as the breathing green would indicate that your device is actually connected to a WiFi.

So let’s test the next step

SYSTEM_MODE(SEMI_AUTOMATIC)

void setup()
{
  WiFi.connect(); 
  Serial.begin(115200);
  while(Serial.read() < 0 && millis() < 10000) Particle.process(); // this waits here till you connect via Serial and hit a key (or max 10sec)
  
  if (!waitFor(WiFi.ready, 10000))
    Serial.println("Not able to connect to WiFi for 10sec");
  else
  {
    Serial.print("Here we go SSID: ");
    Serial.println(WiFi.SSID());
  }
}

void loop()
{
  if (Serial.read() == '\r') Particle.connect();  // to trigger a cloud connect hit enter
}

Sorry, I had to step away and get some other work done before the day ended…
What does “ready” actually mean. Only a connection or that it has received an IP address as well. I know from previous exercises that the device will connect, but not get an IP Address.

What’s happening now is that it breadths green, then after about a minute it starts to flash and this time it attempts another access point. Which has started me going the route of attempting to clear the cached credentials.

I’ll try out this other code and get back to you.

Same process as before
Thanks for the Particle.process() trick!
I see the correct SSID (my cell phone’s hotspot) in the terminal window
I then hit Enter.
Not sure what to expect with Particle.connect(), but I hit it a few times (seeing that it’s in a loop) but I didn’t see any signs of it being connected. The device is not showing as online in my Particle Devices page on Particle.io

I appreciate all of the help with trouble shooting @ScruffR! Hopefully we can get to the end game or file a bug or something.

I also get a case where I see an empty/blank SSID and an IP Address of 0.0.0.0 (I added the localIP() call);

This means that the WiFi module received the IP address, but if you request that IP via WiFi.localIP() it might not have been forwarded to the µC memory and hence you see 0.0.0.0.
To get around this add one call to Particle.process() - which would allow for pending WiFi tasks to be executed - before requesting IP or SSID.

Maybe like this

SYSTEM_MODE(SEMI_AUTOMATIC)

void setup()
{
  WiFi.connect(); 
  Serial.begin(115200);
  while(Serial.read() < 0 && millis() < 10000) Particle.process(); // this waits here till you connect via Serial and hit a key (or max 10sec)
  
  if (!waitFor(WiFi.ready, 10000))
    Serial.println("Not able to connect to WiFi for 10sec");
  else
  {
    Particle.process();
    Serial.printlnf("Here we go\nSSID\t: %s", WiFi.SSID());
    Particle.process();
    Serial.printlnf("localIP\t: %s", WiFi.localIP().toString().c_str());
  }
}

void loop()
{
  int c = Serial.read();
  switch (c)
  {
    case -1:
      // nothing to read, so ignore
      break;
    case '\r':          // hit emter to connect
      Serial.println("Try to connect to cloud");
      Particle.connect();
      Serial.println("See cyan blinking?");
    default:
      Serial.write(c);  // echo what we got
  }    
}

What color sequences do you see on the RGB LED?
Maybe post a video, since each step of the connection process has its own blink pattern, this gives you a good clue where the device is and which parts may be problematic (e.g. taking ages, timing out).

@ScruffR I changed the code to what you posted here. I retained the Macro (SEMI_AUTOMATIC).

Still doesn’t connect (flashing green LED). However, it takes at least 1 minute before I see the “Not able to connect to Wifi for 10 seconds” message.

I’ve has one case where it was flashing the green LED very rapidly. Every once in a while it would change the color for like a micro second to red/magenta and flash green slower (the normal rate) and then after about half a second go back to flashing green rapidly. This just happened 1 after resetting one time. I’ve not bee able to reproduce this. Most times, after resetting, it would just continue to flash green.

Got some good news and some bad news!

It connected and I see the correct SSID and I see an IP Address!
I then hit Enter
I don’t see the “Try to connect to cloud” message
No cyan breathing either
Hit Enter a few more times…nothing.

After about 45 seconds, it goes back to flashing green. Nothing on the Serial monitor after that.
Haven’t been able to reproduce by resetting multiple times and as well as turning my hot spot off and on again and various combinations.