The idea is that sometimes you might have Wi-Fi connectivity issues that you are trying to debug. You can see that the Photon occasionally starts blinking cyan or green before going back to breathing cyan, but what’s going on? How often is it doing it?
This program logs a bunch of data and saves it in retained memory (preserved across reboots) and uploads it using events when there is a cloud connection. One handy thing you can do is store the events into a Google spreadsheet, described in the link below.
- Lists available Wi-Fi networks, including their SSID, channel, and RSSI (signal strength)
- Lists the currently configured Wi-Fi networks
- Logs when the cloud connection goes up or down
- Logs when the Wi-Fi connection goes up or down
- Logs when the RSSI changes by more than ±10
- When there is no cloud but there is Wi-Fi, pings the Google DNS (220.127.116.11) and does a DNS lookup of api.particle.io to see if there’s external connectivity
Of course you can edit the program to log whatever data you want. I’m not sure how useful this will be, but this is the first shot at it, guessing what might be useful to log.