Problems connecting Particle Photon to the wifi

OK, so I am trying out the new Spark Photon. It’s too bad I can’t get it connected to the wifi. I went through these steps to connect over usb:
http://docs.particle.io/photon/connect/#installing-the-particle-cli
When I got to the point for doing particle setup this is basically what happened:

C:\Users\admin>particle setup
                  _   _      _        _
 _ __   __ _ _ __| |_(_) ___| | ___  (_) ___
| '_ \ / _` | '__| __| |/ __| |/ _ \ | |/ _ \
| |_) | (_| | |  | |_| | (__| |  __/_| | (_) |
| .__/ \__,_|_|   \__|_|\___|_|\___(_)_|\___/
|_|                     https://particle.io/

> Setup is easy! Let's get started...
> It appears as though you are already logged in as xxxxxxxxxxxxxx
? Would you like to log in with a different account? No

! PROTIP: Hold the MODE/SETUP button on your device until it blinks blue!
! PROTIP: Please make sure you are connected to the internet.

> I have detected a Photon connected via USB.
? Would you like to continue with this one? Yes
! The Photon supports secure Wi-Fi setup. We'll try that first.

! PROTIP: Wireless setup of Photons works like a wizard!
! PROTIP: We will automagically change the Wi-Fi network to which your computer is connected.
! PROTIP: You will lose your connection to the internet periodically.

Potentially unhandled rejection [2] Unable to find mac address in response (WARNING: non-Error used)
> No nearby Photons detected. Try the `particle.js help` command for more information.
? Would you like to wait and monitor for Photons entering setup mode? No

> Ok, bye! Don't forget `particle.js help` if you're stuck! <3

So then I tried doing particle serial wifi in the command prompt. This is what happended when I did that:

C:\Users\admin>particle serial wifi
? Should I scan for nearby Wi-Fi networks? Yes
? Select the Wi-Fi network with which you wish to connect your device: xxxxxxx
? Should I try to auto-detect the wireless security type? No
? Security Type: WPA2
? Wi-Fi Password: xxxxxxxxxxx
Attempting to configure Wi-Fi on COM7
I said: w
timed out on SSID:
Something went wrong Serial prompt timed out - Please try restarting your device

Yep, I tried restarting my device and ran into the same problem. So then, I tried using real term (it is a serial terminal thing) and here is what happened then:

SSID: xxxxxxxxxxxx
                                                          
Security 0=unsecured, 1=WEP, 2=WPA, 3=WPA2: 3
                                 
Password: xxxxxxxxxxx
                                                          
Thanks! Wait while I save those credentials...

annnnnddddd guess what? Nothing happened after that. lets just say this. I NEED HELP!

@SlinkyMation, you may want to edit your post to remove the sensitive info!

What type of router are you using? Is it dual band and do both bands have the same SSID? The Photon will only connect to an SSID uniquely associated with a 2.4GHz wifi router band.

Ok, so I am using a dual band router and yes they both have the same SSID. One of the bands is 2.4GHz and the other one is 5.0GHz. Is that a problem?

@SlinkyMation, change the SSID of the 2.4GHz band and connect to that with the Photon.

OK. So I was wrong. The 2.4 GHz band and 5.0 GHz band do have different SSID’s and my Photon was connected to the 2.4 GHz band. So this is not the problem. Any other ideas?

@SlinkyMation, good then that eliminates that problem. Does your SSID or password contain spaces? Have you tried the iOS or Android app for connecting?

Since you have CLI installed, you may want to update the system firmware to the latest release: https://github.com/spark/firmware/releases

You can flash via USB using the instructions provided. Then try connecting again. :slight_smile:

Hi,

Having issue with setting device via iOS app.

Device is flashing cyan rapidly with orange.
Tried to flash new keys public and private. Refresh firmware and tinker app. With factory reset. No luck

When you reflash keys, be sure to send the new key to the cloud, with particle keys send <device> keyfile

Getting:
running dfu-util -l
Found DFU device 2b04:d006
running dfu-util -l
Found DFU device 2b04:d006
running dfu-util -d 2b04:d006 -a 1 -s 34:612 -U pre_device.der
running openssl rsa -in pre_device.der -inform DER -pubout -out pre_device.pub.pem
Error saving key from device… Error: Command failed: unable to load Private Key
652:error:0D07207B:asn1 encoding routines:ASN1_get_object:header too long:/SourceCache/OpenSSL098/OpenSSL098-52.10.1/src/crypto/asn1/asn1_lib.c:153:
652:error:0D068066:asn1 encoding routines:ASN1_CHECK_TLEN:bad object header:/SourceCache/OpenSSL098/OpenSSL098-52.10.1/src/crypto/asn1/tasn_dec.c:1302:
652:error:0D06C03A:asn1 encoding routines:ASN1_D2I_EX_PRIMITIVE:nested asn1 error:/SourceCache/OpenSSL098/OpenSSL098-52.10.1/src/crypto/asn1/tasn_dec.c:810:
652:error:0D094071:asn1 encoding routines:d2i_ASN1_SET:error parsing set element:/SourceCache/OpenSSL098/OpenSSL098-52.10.1/src/crypto/asn1/a_set.c:218:address=140420243885200 offset=905566360
652:error:0D0680A8:asn1 encoding routines:ASN1_CHECK_TLEN:wrong tag:/SourceCache/OpenSSL098/OpenSSL098-52.10.1/src/crypto/asn1/tasn_dec.c:1315:
652:error:0D06C03A:asn1 encoding routines:ASN1_D2I_EX_PRIMITIVE:nested asn1 error:/SourceCache/OpenSSL098/OpenSSL098-52.10.1/src/crypto/asn1/tasn_dec.c:827:
652:error:0D08303A:asn1 encoding routines:ASN1_TEMPLATE_NOEXP_D2I:nested asn1 error:/SourceCache/OpenSSL098/OpenSSL098-52.10.1/src/crypto/asn1/tasn_dec.c:747:Field=iqmp, Type=RSA
652:error:0D09A00D:asn1 encoding routines:d2i_PrivateKey:ASN1 lib:/SourceCache/OpenSSL098/OpenSSL098-52.10.1/src/crypto/asn1/d2i_pr.c:99:

Error saving key to device… Error: Command failed: unable to load Private Key
652:error:0D07207B:asn1 encoding routines:ASN1_get_object:header too long:/SourceCache/OpenSSL098/OpenSSL098-52.10.1/src/crypto/asn1/asn1_lib.c:153:
652:error:0D068066:asn1 encoding routines:ASN1_CHECK_TLEN:bad object header:/SourceCache/OpenSSL098/OpenSSL098-52.10.1/src/crypto/asn1/tasn_dec.c:1302:
652:error:0D06C03A:asn1 encoding routines:ASN1_D2I_EX_PRIMITIVE:nested asn1 error:/SourceCache/OpenSSL098/OpenSSL098-52.10.1/src/crypto/asn1/tasn_dec.c:810:
652:error:0D094071:asn1 encoding routines:d2i_ASN1_SET:error parsing set element:/SourceCache/OpenSSL098/OpenSSL098-52.10.1/src/crypto/asn1/a_set.c:218:address=140420243885200 offset=905566360
652:error:0D0680A8:asn1 encoding routines:ASN1_CHECK_TLEN:wrong tag:/SourceCache/OpenSSL098/OpenSSL098-52.10.1/src/crypto/asn1/tasn_dec.c:1315:
652:error:0D06C03A:asn1 encoding routines:ASN1_D2I_EX_PRIMITIVE:nested asn1 error:/SourceCache/OpenSSL098/OpenSSL098-52.10.1/src/crypto/asn1/tasn_dec.c:827:
652:error:0D08303A:asn1 encoding routines:ASN1_TEMPLATE_NOEXP_D2I:nested asn1 error:/SourceCache/OpenSSL098/OpenSSL098-52.10.1/src/crypto/asn1/tasn_dec.c:747:Field=iqmp, Type=RSA
652:error:0D09A00D:asn1 encoding routines:d2i_PrivateKey:ASN1 lib:/SourceCache/OpenSSL098/OpenSSL098-52.10.1/src/crypto/asn1/d2i_pr.c:99:

One device updated successfully and one has error

I moved 2 posts to an existing topic: Trouble conecting the photon using an android app

1 Like

I’m having a similar issue. I’m connecting to an open wifi network that does not have a captive portal (at least not for me because I whitelisted the Photon’s MAC address).

The network has no password so the security is 0…but when I set it up via the serial terminal it still asks for a cipher. I tired 0, but that didn’t work. I tried 1 (AES) and then it tried to connect, but never did and went back to listening mode after a short amount of time.

When I set it up via usb through particle setup on the command line it does not ever get an IP either.

We are having problems connecting the Photon to a wifi SSID containing spaces. I was reading on the web this is a common issue on Photon. Since we work on a commercial product, we must adjust to our clients’ SSID, so we look for a solution to accept spaces and special characters on SSID.

We use API 0.6.4. Does someone know if new releases have solved this issue?

Thanks for your comments

What API? Do you mean Device OS version or something else?
There is no Device OS v0.6.4 for Photons. This is Electron only.
Do you mean 0.6.3 or 0.7.0?

1 Like