Feature Request: Flash on Connect

Well, I am working on a project that deep sleeps for certain amount of time and it’s far away from me. I want to flash new firmware but the photon is offline. So… I need to keep track of when it wakes in order to flash it with new firmware… But, this is troublesome because it wakes fro 30 seconds and then goes back to sleep for certain amount of time, and I have to be real sharp on timing.

It would be great to have an option to send new firmware on connect. So when the photon connects to the cloud, new firmware will be flashed to the photon.

Just a thought :smile:

2 Likes

Its been promised before, it seems to be planned for before electron release, since the electron will often sleep in many use cases (battery powered).

1 Like

Has there been any news on this feature since this post? I’m looking for flash on connect also.

You can do it via product now, and you can create a product with 25devices for free.
Its not perfect though, since the device will start and run the local code for a while before starting to flash, for photon its around 10seconds, but maybe that is ok in your use case.

A product is not a good solution if each device needs its own code though, it gets messy fast, but is technically possible by locking version numbers.

I assume I can check if an update is pending after 10 seconds via System.updatesPending() to prevent going back to sleep?