JSN-SR04T and Deep Sleep

Issue #33 resolved
Former user created an issue

Hi.

I used your library with very mich success with an JSN-SR04T and with HC-SR04.

Today I tried to use the JSN with Arduino deep sleep mode. I uploaded the code, it runs once and displays valid results on the serial console, then ESP8266 gets to sleep. After a specified time it wakes up and the code shall run again but it does not. Instead the ESP8266 hangs and the LED of the JSN is on or fast flashing. No more output on serial. Once I disconnect TRIGGER_PIN or ECHO_PIN it runs fine and sleep works well. I tried it with 3-pin and 4-Pin wiring, same result.

Any ideas whats wrong?

Comments (2)

  1. Tim Eckel repo owner

    My guess is that when the ESP8266 wakes up the pin states are not retained. So, when it tries to send another ping it doesn't work. Doesn't sound like a NewPing problem, sounds more like a ESP8266 issue.

  2. Log in to comment