@kennethlimcp I treid now the safemode. In safe mode the device stays connceted.
@Dave I reset device after the safe mode and the device stays a long time for hours connected to the cloud. It seems that the powersupply is ok. I think it’s a sporadically. Is there someting to pay attention in the code.
Cool! So yes checking your code would be good. Look for anything that blocks (like a hard delay) for long periods of time. If you block more than 10-30 seconds, your device may disconnect from the cloud. The newer multi-threading support on the Photon should reduce this problem considerably however.