So you're a Noob? Post your questions here until you graduate! Don't be shy.

User avatar
By grad
#61199 I have NodeMcu Esp8266 version 1.0

I want to set a deepSleep for a x seconds...

This is my code

Code: Select all
const int SLEEP_DELAY_IN_SECONDS = 3;



void setup() {
  Serial.begin(115200);
  Serial.println();

}

void loop() {
  Serial.println("hello world");
  ESP.deepSleep(SLEEP_DELAY_IN_SECONDS * 1000000, WAKE_RF_DEFAULT);
  delay(1000);

}


but, this code doesn't work!

When the NodeMcu wakeUp at the second time, I get an error...
Code: Select allsld��|�c�o ��l�"|���2��|cl�p��no�lNN��� cp��$rlsl�r�n�c�oBp�


I've searched in google and I've found this: gpio 16 must be connected to ch_pd!
Well, I am a software developer and not a electronic engeneer... Can you tell me which of the NodeMcu pins is the ch_pd?
Thanks a lot


grad