GithubHelp home page GithubHelp logo

ESP8266 resetting about deepsleepscheduler HOT 11 CLOSED

prosenb avatar prosenb commented on June 3, 2024
ESP8266 resetting

from deepsleepscheduler.

Comments (11)

PRosenb avatar PRosenb commented on June 3, 2024

Hi,

Thanks for your message. The idea is to only have scheduler.execute() in your loop() method like this:

void loop() {
  scheduler.execute();
}

Please remove all other code in loop(). Does it still reset the esp8266?

You can move the code you have in loop() to callback methods like your initializeModem() and schedule it on regular basis.

from deepsleepscheduler.

kulwinderjit avatar kulwinderjit commented on June 3, 2024

It does not work with simple code. I am using nodemcu dev board featuring esp12e. I have checked that delay of up to 8 seconds work but not 9+ seconds.

`#include <DeepSleepScheduler.h>

void setup() {

Serial.begin(115200);

scheduler.scheduleDelayed(initializeModem, 9000);

}

void loop() {

scheduler.execute();

}

void initializeModem(){

Serial.println();

Serial.println("Initializing modem...");

}`

`ets Jan 8 2013,rst cause:4, boot mode:(3,6)

wdt reset
load 0x4010f000, len 1384, room 16
tail 8
chksum 0x2d
csum 0x2d
vac02aff5
~ld
`

from deepsleepscheduler.

PRosenb avatar PRosenb commented on June 3, 2024

Hi @kulwinderjit ,
Thanks for testing it out. Unfortunately, I don't have an ESP8266 here at the moment. Could you check if the following workaround solves the issue?

#include "DeepSleepScheduler.h"

void periodicExecution() {
  scheduler.scheduleDelayed(periodicExecution, 5000);
}

void setup() {
  scheduler.schedule(periodicExecution);
}

void loop() {
  scheduler.execute();
}

from deepsleepscheduler.

kulwinderjit avatar kulwinderjit commented on June 3, 2024

Updated library to 3.2. It does not work

ts Jan 8 2013,rst cause:2, boot mode:(3,6)

load 0x4010f000, len 1384, room 16
tail 8
chksum 0x2d
csum 0x2d
v8b899c12
~ld

from deepsleepscheduler.

PRosenb avatar PRosenb commented on June 3, 2024

Hi @kulwinderjit
Could you try my code above? Does it work with it?
Thanks,
Pete

from deepsleepscheduler.

kulwinderjit avatar kulwinderjit commented on June 3, 2024

yes i have tried your code it worked and then i changed 5000 to 9000 and it started resetting again. Then i saw there is library update 3.2 after updating it stopped working with 5000 and even 1000.

from deepsleepscheduler.

PRosenb avatar PRosenb commented on June 3, 2024

I see, thanks for testing it. The version 3.2 is not yet released. Please continue to use 3.1 for now and I will look into it when I get an ESP8266 again.

from deepsleepscheduler.

kulwinderjit avatar kulwinderjit commented on June 3, 2024

I see. I got 3.2 update on platformio but not in arduino ide.

from deepsleepscheduler.

PRosenb avatar PRosenb commented on June 3, 2024

Interesting.. So platformio seems not to honour the tag.
I hope you're not blocked any more with 3.1 and the workaround above.

from deepsleepscheduler.

kulwinderjit avatar kulwinderjit commented on June 3, 2024

yes i have tried your code it worked and then i changed 5000 to 9000 and it started resetting again
It does not work with interval 9 sec or more. I have requirement of around 60 second timeout. Your code worked because you put 5000 ms interval which works.

from deepsleepscheduler.

PRosenb avatar PRosenb commented on June 3, 2024

Hi @kulwinderjit,
I got an ESP8266 and updated DeepSleepScheduler on master. Does it work well for you now?

from deepsleepscheduler.

Related Issues (14)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.