I’m trying to run my photon in offline (semi-automatic) mode. However, I find it still takes a long time to start up and it handshaking with the web service. I want it to be able to work and run my code with weak or no wifi.
Currently, I have these two lines in setup, I find that putting them at the top of the script causes it not to compile. The LED does go white when it finally starts up, but it’s super slow to start and spends a lot of time in fast blinking green with occasional red flashes before startup.
That’s what I thought, but it doesn’t compile if I put it at the top of the script. Moving it inside setup seems to compile and run, and it doesn’t show up in the console now, so I thought it was working but apparently somethings not right.
Any idea why the code would fail to compile in the web IDE with the mode function at the very top?
Sorry for the late reply, thanks so much for the code review.
Yeah, I2C pullups are on one of the chips, and communication there has been alright far as I can tell, although I’m firing it up today to work on your suggestions and the whole system seems to have gone haywire with my cell voltages all reading 65000 (or so).
Of course I foolishly sealed things up inside the case thinking I was done with development, b/c it worked alright on the bench, sigh.
I’ll work on this more and report back if there are further issues. I can confirm that the code compiles now with SYSTEM_MODE() up top, for some reason, and it must have been something else, when I tried it this way originally it wouldn’t compile and the error referenced this function as not being defined.