Local Compile and particle dev

I think that local compile and dfu should babe possible with particle dev as an option. Yesterday compile in the cloud outage should be the perfect example as to why.

I know that local compile is possible, but it does take some time and effort on the user side (Did that yesterday to keep on working). I think particle dev should be akin arduino ide. I don’t mind the default being cloud compile but have the option to local compile easily.

I know the risks of the local repository being out of date , but this is something you can address with a menu comman ‘update local tools’ or a similar mechanism.

Anyway, I do think that this is a feature that needs to be implemented soon in the roadmap.

I second that proposal.
We should not be so dependent on online only tools that can be broken at one central location. The currently ongoing firmware auto-update fiasco is another example of frustrating and dangerous practices (that has cost me many mystery debugging hours) that can be avoided by giving the local developer full control over what changes. If I know that I am developing in a stable yet obsolete environment, with known problems (for example bad I2C implementation), that is OK. If I run into some obstacle that has a documented solution in a newer version, then I can manually choose to make changes.
Add some USB based utilities to facilitate starting up the device (link to AP and register), reset to factory option.
In reality, I should be able to buy, configure, develop for, deploy and maintain a Photon without ANY Particle online dependencies unless I explicitly build them in.
So yes, give us a more robust “Arduino like” stand alone IDE.

1 Like

Same thoughts here, although I’ll also add that @suda has identified cloud configuration selection (and hopefully, by extension, local compiles + uploads) as a future enhancement in Particle Dev: https://github.com/spark/spark-dev/issues/86

While waiting for that to happen, I wrote an atom.io package to handle offline compiles+uploads for use with atom. I haven’t tried installing my package within Particle Dev itself, but it should be possible, too.

It’s not the cleanest solution, and there are issues related to the refresh/selection of the serial ports (especially if you work with multiple devices simultaneously), so ymmv!

(EDIT: finally fixed the atom.io package – you should now be able to install it directly from atom – search for the particle-local-compiler package)

If you’re using atom, ensure you #include "application.h", use .cpp file extensions and your code should compile locally. Also, .cpp/.h libraries should be in the same folder as your main sketch. Finally, you’ll have to declare your prototypes manually, either in a .h file or at the top of your main .cpp file.

If I get the time, I’ll see to the cleaning up of the package and also testing it within Particle Dev.

2 Likes