Good day, is it possible to add a pause of a few seconds in the provisions script? I’ve tried using setTimeout and Sleep, but it didn’t work.
Not directly in a provision script. You could have your provision script execute an extension script and do your sleep in there. But I have to ask, why do you need to do a sleep? Having to add a sleep is a bad design practice.
The script is triggered when eventcode 0 BOOTSTRAP is received and using the SET method changes the Wi-Fi parameters, but periodically SET changes the values before the Wi-FI driver is loaded and the settings are not applied.
So I wanted to add sleep for 10 seconds before declare so that the Wi-FI driver can load.
Well, I’ll deal with the extension script, thanks.
A better solution would be to sync the customers wifi settings every boot. Since I switched to doing this a few years ago, all my issues with regards to wifi “not working” went away.
Here is my provisioning flow:
Sync wifi/lan settings.