Use this forum to chat about hardware specific topics for the ESP8266 (peripherals, memory, clocks, JTAG, programming)

User avatar
By mazur888
#94539 Hi All,
I have esp8266 wemos d1 mini programmed as webserver.
2x ds18b20 temp sensors and 3v3 relay.
its simple code triggering relay when temp reaches 25 degrees in 1 of the probes.
using html, javascript, and ajax.

when I have IP address opened in web browser it all works perfect, relay triggers every time, but when browser is not opened, code doesnt work.
I wonder why digitalWrite inside void loop() wouldn't trigger relay without web browser?
is this normal behaviour?
User avatar
By mazur888
#94550 found the problem. Posting here just in case there is anybody with similar problem,

loop() was missing this line: sensors.requestTemperatures();

sensors.requestTemperatures(); was placed only inside handle on connect, thats why it was only working when browser was on.