Your new topic does not fit any of the above??? Check first. Then post here. Thanks.

Moderator: igrr

User avatar
By OzGrant
#88061 G'Day,
Have attached a basic Light-Sleep sketch that blinks the Led OK but then stops randomly.
Often blinks 10 times other times 50. (Hardware is a WeMos mini)
Anyone got any clues.

#include <ESP8266WiFi.h>
void setup() {
pinMode(LED_BUILTIN, OUTPUT);
}
void loop() {
digitalWrite(LED_BUILTIN, LOW);
wifi_set_sleep_type(NONE_SLEEP_T); // Disable light sleep
delay(2000);
digitalWrite(LED_BUILTIN, HIGH);
wifi_set_sleep_type(LIGHT_SLEEP_T); // Enable light sleep
delay(2000);
}