# Electron won't connect to cloud today- was working when I set it up yesterday

I setup my new electron yesterday- Everything setup fine and Tinker ran, and a small program I loaded posted data when it was supposed to. I unplugged it from LiPo/USB overnight. Upon restoring power this morning I get the following:

1. Green flashing for 10-20 secs
2. cyan flashing for 10+ secs
3. one short cyan breathe cycle
above 3 steps repeat indefinitely. The Electron no longer shows up in the PC console or mobile app.

I tried to get into safe mode- magenta is flashing when I release the mode switch, but it doesn’t stay flashing magenta- instead it breathes cyan for a second or so, then back to flashing green for a while, then it repeats.
Under these conditions, I can see the Electron as COM20 in Windows Device manager.
If I issue
"particle list"
CLI command, I get a response showing that BM1_Electron is online

If I put it in DFU mode, LED stays a flashing yellow. But, the Electron’s USB Com port does not show up in Device Manager under these conditions. Issuing a CLI command:
particle flash BM_Electron1 tinker (BM1_Electron is my device name)
I get the response:
Flash failed- timed out
which is what I would expect with no USB com port showing up in device manager (unless it programs via USB HID, for example- I don’t know)
I’m stumped- I can’t get into Safe mode, or re-flash it, so I don’t know what is wrong. Nothing at all was touched/changed overnight, after which time it went astray.

That’s kind of strange. I’d flash the Electron cloud debug software (in DFU mode, blinking yellow) which should show what’s actually happening via the USB serial debug.

If you want to flash it over USB, you should use

particle flash --usb tinker, otherwise it’ll try to OTA.

Thanks Moors7. With that command it reported that it flashed Tinker successfully.
But, it still exhibits the same symptoms. I will next try rickkas7’s suggestion re debug.

1 Like

particle update might also help, depending on the current version of system firmware.

Thanks rickkas7.
I managed to flash the combined-electron.bin file and I am getting plenty of debug info via USB serial monitor. Most of it is not meaningful to me at this stage, but I do see a WARN: internet available, cloud not reachable (which is what I gather from the LED sequence).
and earlier on I see:
WARN Read00000508115 [system] WARN cloud socket connection failed -1
There are a whole pile of Modem AT commands sent- all that I can see are “OK” - successful.
Unless I stumbled upon it by mistake, I have NOT unclaimed the module.
Nothing in Billing would indicate anything wrong with the SIM account.
As I mentioned, everything was fine when I powered it down- then these symptoms as soon as I powered it back on this AM.

I’m not sure about trying this now when I just flashed the debug code from rickkas7 and am trying to follow up on the debug messages I get with him.

You can message me the whole log or submit it as a support ticket as I can’t tell what’s wrong without the whole log.

That is to be expected, since in DFU Mode the device is not a COM device but a DFU device and for that you need to have the correct DFU drivers installed.

Thanks ScruffR. I’m completely new to Particle and many of the other MCUS I work with do have serial bootloaders, so I was going on past experience. With help from others on the forum, I’m now able to flash code via USB and am trying to debug the problem.

1 Like

The Particle devices can be flashed via serial or DFU.
To chose one over the other you need to put the device in the dedicated state.
For serial flashing you’d use Listening Mode and particle flash --serial firmware.bin
while for DFU you’d use … well … DFU Mode with particle flash --usb firmware.bin

Thanks again. I did read over the docs regarding the many operating modes. But, all of it didn’t sink in at the time, I guess. The Teensy and Expressif MCUs that I use basically have only 1 mode of flashing. I’ve only got about a day working on the proton and electron modules I just bought.

2 Likes

Rick- I responded to this by replying to the email I got from you, and attaching the file. Don’t know if this is the right way to go. I can try to attach it in a forum reply if you didn’t get it.
In the meantime I ran particle doctor. It did the first few steps OK, but not the keys. Here is the message it returned:

Resetting server and device keys

Put the device in DFU mode
Tap RESET/RST while holding MODE/SETUP until the device blinks yellow.
? Select Continue when ready Continue
Okay! New keys in place, your device will not restart.
The Doctor didn’t complete sucesfully. Make sure your device is in DFU mode (blinking yellow), and that your computer is online.: Error creating keys: Command failed: C:\WINDOWS\system32\cmd.exe /s /c “openssl ecparam -name prime256v1 -genkey -out 1b003a001347373333353132_ec_new.pem”
‘openssl’ is not recognized as an internal or external command,
operable program or batch file.

( I am running 64bit Windows 10)

That notwithstanding, when I rebooted Electron I did get back to a breathing cyan LED. I couldn’t however see it on the IOS particle app, nor could I successfully ping it from the PC console app.
So I thought I’d better re-flash Tinker, as I suspect that the debug file you asked me to load would have over-written it.
After tinker flashed successfully, I no longer get the breathing cyan- just a sustained flashing cyan LED.
I went back and did the device doctor procedure again- resulting again in breathing cyan LED but no connectivity to the cloud, according to the Ping.
I don’t know what to try next, but suspect the keys, I guess.
Thanks

This indicates that OpenSSL isn’t properly set up.
If you use the Windows Installer it should get installed and added to the PATH environment variable - I guess that hadn’t happened before.

However, if you have a breathing cyan LED there is no keys issue.
How are you pinging the device?
Are you using console.particle.io?

@scruffr- My mistake. I thought it was breathing cyan, but I was looking at an angle. When I look straight down, I see it is actually breathing white. (Might have been some wishful thinking too). This was right after the particle Doctor routine. After I flashed the tinker program I get flashing green followed by flashing cyan. This never stops, although an odd red flash occurs.
I am pinging from console and there is no response.
There is an. openSSL - win32 folder off my C: root. It was created when I first started using the particle PHOTON a week ago. But, I am running Win 64 bit, if that matters. There are also lots of OpenSSL files in my Arduino folder under Expressif, as I use ESP8266, 32
Thanks

Rick- here is the log. Sorry- I don’t know how to attach a file in this forum yet.

    65.471 AT send      14 "AT+UPSDA=0,4\r\n"
65.842 AT read OK    6 "\r\nOK\r\n"

[ Modem::detach ] = = = = = = = = = = = = = = =
65.842 AT send      12 "AT+CGATT=0\r\n"
69.223 AT read OK    6 "\r\nOK\r\n"

[ Modem::detach ] = = = = = = = = = = = = = = =
69.223 AT send      12 "AT+CGATT=0\r\n"
69.224 AT read  +   13 "\r\n+CGREG: 0\r\n"
69.234 AT read  +   14 "\r\n+CIEV: 9,1\r\n"
CIEV matched: 9,1
69.244 AT read OK    6 "\r\nOK\r\n"

[ Modem::powerOff ] = = = = = = = = = = = = = =
69.244 AT send      12 "AT+CPWROFF\r\n"
72.105 AT read OK    6 "\r\nOK\r\n"

[ Modem::powerOn ] = = = = = = = = = = = = = =
72.415 AT send       4 "AT\r\n"
73.735 AT send       4 "AT\r\n"
75.055 AT send       4 "AT\r\n"
76.375 AT send       4 "AT\r\n"
76.385 AT read UNK   3 "AT\r"
76.395 AT read OK    6 "\r\nOK\r\n"
76.605 AT send       7 "AT E0\r\n"
76.615 AT read UNK   6 "AT E0\r"
76.625 AT read OK    6 "\r\nOK\r\n"
76.625 AT send      11 "AT+CMEE=2\r\n"
76.635 AT read OK    6 "\r\nOK\r\n"
76.635 AT send      19 "AT+CMER=1,0,0,2,1\r\n"
76.645 AT read OK    6 "\r\nOK\r\n"
76.645 AT send      15 "AT+IPR=115200\r\n"
76.655 AT read OK    6 "\r\nOK\r\n"
76.755 AT send      10 "AT+CPIN?\r\n"
76.775 AT read OK    6 "\r\nOK\r\n"
0000076775 [system] INFO: ARM_WLAN_WD 1
0000076775 [s
[ Mode
76.776 AT send       9 "AT+CGSN\r\n"
76.796 AT read UNK  19 "\r\n352580082953501\r\n"
76.806 AT read OK    6 "\r\nOK\r\n"
76.806 AT send       9 "AT+CGMI\r\n"
76.816 AT read UNK  10 "\r\nu-blox\r\n"
76.826 AT read OK    6 "\r\nOK\r\n"
76.826 AT send       9 "AT+CGMM\r\n"
76.836 AT read UNK  13 "\r\nSARA-U260\r\n"
76.846 AT read OK    6 "\r\nOK\r\n"
76.846 AT send       9 "AT+CGMR\r\n"
76.856 AT read UNK   9 "\r\n23.20\r\n"
76.866 AT read OK    6 "\r\nOK\r\n"
76.866 AT send       9 "AT+CCID\r\n"
76.876 AT read  +   30 "\r\n+CCID: 8934075500003392520\r\n"
76.886 AT read OK    6 "\r\nOK\r\n"
76.886 AT send      11 "AT+UPSV=1\r\n"
76.896 AT read OK    6 "\r\nOK\r\n"
76.896 AT send      11 "AT+CMGF=1\r\n"
76.906 AT read OK    6 "\r\nOK\r\n"
76.906 AT send      13 "AT+CNMI=2,1\r\n"
76.916 AT read OK    6 "\r\nOK\r\n"
76.916 AT send       9 "AT+CIMI\r\n"
76.926 AT read UNK  19 "\r\n214074303090723\r\n"
76.936 AT read OK    6 "\r\nOK\r\n"

[ Modem::register ] = = = = = = = = = = = = = =
76.936 AT send      10 "AT+CREG?\r\n"
76.947 AT read  +   14 "\r\n+CREG: 0,0\r\n"
76.957 AT read OK    6 "\r\nOK\r\n"
76.957 AT send      11 "AT+CGREG?\r\n"
76.967 AT read  +   15 "\r\n+CGREG: 0,0\r\n"
76.977 AT read OK    6 "\r\nOK\r\n"
76.977 AT send      12 "AT+CGREG=2\r\n"
76.987 AT read OK    6 "\r\nOK\r\n"
76.987 AT send      11 "AT+CREG=2\r\n"
76.997 AT read OK    6 "\r\nOK\r\n"
76.997 AT send      10 "AT+CREG?\r\n"
77.007 AT read  +   14 "\r\n+CREG: 2,0\r\n"
77.017 AT read OK    6 "\r\nOK\r\n"
77.017 AT send      11 "AT+CGREG?\r\n"
77.027 AT read  +   15 "\r\n+CGREG: 2,0\r\n"
77.037 AT read OK    6 "\r\nOK\r\n"
92.037 AT send      10 "AT+CREG?\r\n"
92.037 AT read  +   14 "\r\n+CIEV: 2,2\r\n"
92.047 AT read  +   30 "\r\n+CREG: 5,\"CF35\",\"1228C8\",2\r\n"
92.057 AT read  +   36 "\r\n+CGREG: 5,\"CF35\",\"1228C8\",2,\"01\"\r\n"
92.068 AT read  +   14 "\r\n+CIEV: 3,1\r\n"
92.078 AT read  +   14 "\r\n+CIEV: 7,1\r\n"
92.088 AT read  +   14 "\r\n+CIEV: 9,2\r\n"
CIEV matched: 9,2
92.098 AT read  +   30 "\r\n+CREG: 5,\"CF35\",\"1228B7\",2\r\n"
92.108 AT read  +   36 "\r\n+CGREG: 5,\"CF35\",\"1228B7\",2,\"01\"\r\n"
92.119 AT read  +   14 "\r\n+CIEV: 2,1\r\n"
93.639 AT read  +   32 "\r\n+CREG: 2,5,\"CF35\",\"1228B7\",2\r\n"
93.649 AT read OK    6 "\r\nOK\r\n"
93.649 AT send      11 "AT+CGREG?\r\n"
93.659 AT read  +   38 "\r\n+CGREG: 2,5,\"CF35\",\"1228B7\",2,\"01\"\r\n"
93.670 AT read OK    6 "\r\nOK\r\n"
93.670 AT send      10 "AT+COPS?\r\n"
93.770 AT read  +   43 "\r\n+COPS: 0,0,\"CAN Rogers Wireless Inc.\",2\r\n"
93.781 AT read OK    6 "\r\nOK\r\n"
93.781 AT send       9 "AT+CNUM\r\n"
93.781 AT read  +   30 "\r\n+CREG: 5,\"CF35\",\"1228C8\",2\r\n"
93.792 AT read  +   36 "\r\n+CGREG: 5,\"CF35\",\"1228C8\",2,\"01\"\r\n"
93.813 AT read OK    6 "\r\nOK\r\n"
93.813 AT send       8 "AT+CSQ\r\n"
93.823 AT read  +   13 "\r\n+CSQ: 9,2\r\n"
n"
93.844 AT send      14 "AT+UPSND=0,8\r\n"
93.854 AT read  +   17 "\r\n+UPSND: 0,8,0\r\n"
93.864 AT read OK    6 "\r\nOK\r\n"
93.864 AT send      23 "AT+UPSD=0,7,\"0.0.0.0\"\r\n"
93.874 AT read OK    6 "\r\nOK\r\n"
93.874 AT send      36 "AT+UPSD=0,1,\"spark.telefonica.com\"\r\n"
93.885 AT read OK    6 "\r\nOK\r\n"
93.885 AT send      15 "AT+UPSD=0,6,0\r\n"
93.895 AT read OK    6 "\r\nOK\r\n"
93.895 AT send      14 "AT+UPSDA=0,3\r\n"
95.965 AT read OK    6 "\r\nOK\r\n"
95.965 AT send      14 "AT+UPSND=0,0\r\n"
95.965 AT read  +   14 "\r\n+CIEV: 2,2\r\n"
95.976 AT read  +   31 "\r\n+UPSND: 0,0,\"10.40.252.128\"\r\n"
95.986 AT read OK    6 "\r\nOK\r\n"
0000095986 [system] INFO: ARM_WLAN_WD 2
0000095986 [system] INFO: ARM_WLAN_WD 2
000000000095987 [system] INFO: Cloud: connecting
0000095987 [system]0000095987 [s0000095988 [system] WARN: Read Server Address = type:255,default0000095988 [system] WARN: Cloud socket connection failed: -1
000socketSocket(TCP)
95.989 AT send      12 "AT+USOCR=6\r\n"
96.000 AT read  +   13 "\r\n+USOCR: 0\r\n"
96.010 AT read OK    6 "\r\nOK\r\n"
Socket 0: handle 0 was created
0000096010 [system] TRACE: socketed testSocket=0
00000socketConnect(0,po    96.011 AT send      25 "AT+USOCO=0,\"8.8.8.8\",53\r\n"
98.541 AT read OK    6 "\r\nOK\r\n"
0000098541 [system] TRACE: socket_connect()=success
0000098541 [system] TRACE: Close
98.541 AT send      12 "AT+USOCL=0\r\n"
98.812 AT read OK    6 "\r\nOK\r\n"
socketFree(0)
0000098812 [system] WARN: Internet available, Cloud not reachable!
00000000098813 [system] INFO: 0000098814 [system] TRACE: sparkSocket Now =-1
0000098814 [system] WARN: Read Server Address = type:255,defaulting to device.spa0000098815 [system] WARN: Cloud socket connecti0000098815 [system] WARN: Resetting WLAN due to 2 failed connect0000098816 [systemsocketSocket(TCP)
98.817 AT send      12 "AT+USOCR=6\r\n"
98.827 AT read  +   13 "\r\n+USOCR: 0\r\n"
98.837 AT read OK    6 "\r\nOK\r\n"
Socket 0: handle 0 was created
0000098837 [system] TRACE: socketed testSocket=0
00000socketConnect(0,po    98.838 AT send      25 "AT+USOCO=0,\"8.8.8.8\",53\r\n"
99.118 AT read OK    6 "\r\nOK\r\n"
0000099118 [system] TRACE: socket_connect()=success
0000099118 [system] TRACE: Close
12 "AT+USOCL=0\r\n"
99.389 AT read OK    6 "\r\nOK\r\n"
socketFree(0)
0000099389 [system] WARN: Internet available, Cloud not reachable!
00000000099390 [system] WARN: Resetting WLAN due to
[ Modem::disconnect ] = = = = = = = = = = = = =
99.391 AT send      14 "AT+UPSDA=0,4\r\n"
99.762 AT read OK    6 "\r\nOK\r\n"

[ Modem::detach ] = = = = = = = = = = = = = = =
99.762 AT send      12 "AT+CGATT"
101.083 AT read OK    6 "\r\nOK\r\n"

[ Modem::detach ] = = = = = = = = = = = = = = =
101.083 AT send      12 "AT+CGATT   101.084 AT read  +   13 "\rCGREG: 0\r\n"
101.094 AT read  +   14 "\r\n+CIEV: 9,1\r\n"
CIEV matched: 9,1
101.104 AT read OK    6 "\r\nOK\r\n"

[ Modem::powerOff ] = = = = = = = = = = = = = =
101.104 AT send      12 "AT+CPWRO


The important bit is whether or not OpenSSL is set up in your environment PATH.
If not, you need to add it.

If the device is breathing white, this indicates that the cellular modem isn’t even switched on - which might be indicating the running firmware is not switching it on.

1 Like

Good news- I now have it working again, at least tinker anyway. There was already an entry
OPENSSL_CONF C:\openSSL-Win32\bin\openssl.cfg
in the environment variables- made by the particle install (dfu-util, I guess)