P2 drops cloud connection and does not reconnect

I have a Photon 2 board that has been running my code for several months. A few days ago I upgraded to 5.9.0. Yes, my code changed but very slightly. After that the P2 would disconnect from WiFi quite often (I see the fast green flashes) and then reconnect. Sometimes it would not reconnect.

It might be solid green or solid cyan. While this is happening my code is still running fine, just no connection to the cloud. The P2 would go into this mode within an hour, two at the most, after a reboot. Last night I downgraded to 5.5.0 and now the P2 has run all night without any warnings or errors logged.

This is a typical log file when it enters solid cyan:

0000160544 [ncp.rltk.client] WARN: Disconnect linkError=00000000 reason=ffff:   connected stage, loss beacon
0000176073 [comm.protocol] ERROR: Event loop error 1
0000176103 [system] WARN: Communication loop error, closing cloud socket
0003420544 [ncp.rltk.client] WARN: Disconnect linkError=00000000 reason=ffff:   connected stage, loss beacon
0003424627 [ncp.rltk.client] WARN: Disconnect linkError=00000000 reason=0000:   
0003432357 [comm.protocol] ERROR: Event loop error 1
0003432380 [system] WARN: Communication loop error, closing cloud socket

Any advice would be helpful. Since 5.5.0 has now run 10x the MTBF on 5.9.0 it feels like this is not a problem with my code. Any advice is welcome.

This should be fixed in Device OS 6.3.0. See this very long thread for an explanation.

Thanks for the note. I saw that thread but my symptoms seemed different.

My P2 ran 24 hours without a single link error. I went up to 6.2.1 and within an hour it had gone to solid cyan and the log shows the connected stage, loss beacon error. So this validates that 5.5.0 doesn't have the problem. I'll move back to that until 6.3 is available.

Jim

Hey, it is available.
You need to enable pre-release versions if you are using VS Code/Workbench.

Thank you @gusgonnet I put 6.3.0 up this morning and it is now 3.5 hours without any network warnings from the OS. Looks like this does fix it. Whew.

2 Likes