Hey all! New to posting in this community but have been a lurker for quite some time. Really enjoying hacking my new Photon.
One issue I’ve had over the years of hacking MCUs is forgetting what program I had flashed onto them. Particle’s cloud API helps remedy this by exposing remote function calls (remote variable evaluation is awesome too). The issue now is keeping the filename string updated in the code.
I searched for a native constant that holds the filename currently flashed on the device but couldn’t fine one. Does one exist? If so, it would be awesome if there was one added eventually.
Something like:
PARTICLE_USER_APP_NAME // or similar
Additionally, the same constant could be updated on the dashboard next to the relevant device so you could just look there as well. Either solution would be great.
That's very similar to what I've done. Having a constant available however just makes it simple, since the expectation is that it would always contain the correct/current value.
Hi, I’m reading this forum since some days and new the Particle community.
I tried to run the code above on my Photon (firmware 0.4.5) and simply copy & pasted it to the Web IDE. Unfortunately it does not work for me. Only __FILE__ has correct value while __DATE__ & __TIME__ are empty.
That’s working all there variables are available, so indeed it is related to sprintf(). I will try using Particle Dev later this after noon, but since that is compiled in the cloud as well, shouldn’t the result be the same?