WiFi.off/WiFi.on, Core vs Photon [SOLVED]

Thanks @ScruffR. I am anxious to try this new script. I assume that you tested the script this time, and it works good for you (and new script can be flashed if reset button is pressed).

I hope to be able to try this within a few hours, I still can’t flash code, but will be doing a complete restart in a bit.

Thanks, Jack

Please don’t suggest I didn’t :unamused:
I had tested my previous sketch too - I just didn’t quite understand your original intention, so it did what I thought you wanted :wink:

And yes, this sketch does what I intend it to do again, if it’s not what you’re looking for, maybe I need more info.

@ScruffR, I am sorry if my questions may seem offensive, they were not meant to. I really appreciate you spending your valuable time to help me.

I have done a factory reload, and flashed your new script to my core. It runs great, saves the RTC etc.
But I am still having a problem if I try to flash script again. I hit the reset button, and try to flash from build.particle.io/build/, but it will not work. could it have something to do with “SYSTEM_MODE(SEMI_AUTOMATIC)”?
Are you using a different way to flash code to your core?
Thanks, Jack

I’ve just tried it myself with Web IDE and it works fine, but if you experience issues, it might be due to the time the Core needs to reconnect to the cloud after the reset, since all this time will be taken off the 3 * SOFTDELAY (30sec) that seem to suffice with my WiFi and internet connection.
Just for testing, you could increase the factor from 3 to whatever number that works for you.

As a side not - once the Core starts breathing cyan, you may want to wait one or two seconds before pressing the flash button on the Web IDE, then the Core should start flashing magenta “slowishly” and after max 25sec it should turn into rapid magenta flashing. If this rapid phase is not coming, you definetly have to increase the flash delay.

1 Like

@ScruffR, your suggestion to wait until the led starts breathing to hit the flash button on the IDE, seems to have fixed it.

So, all is working as desired,
thanks for all your help and patience.
Should we mark this thread “SOLVED”? I don’t know how. can you do that or tell me how?

Glad to hear that it’s working for you now :+1:

I can mark it solved for you, but it’s quite easy.
Just click on the topic title, then there should appear a pencil symbol next to it. Click that and alter the title as desired.

Thanks @ScruffR, for all your help on the WiFi script questions, and for the forum procedure info.