I would like to monitor the ON and OFF time of my refrigerator and push this data to the server via an ESP8266. Below are my thoughts on how to detect the state of the refrigerator: Use a voltage sensor to detect 230VAC Use an optoisolator Use of a current sensor
Please, kindly advice which would be the best solution and if there exists another. Thanks
-
\$\begingroup\$ Simpler solutions comes to mind. A relay with 230 Vac coil and switch your 5 or 3.3 V from your MCU. \$\endgroup\$winny– winny2019年02月26日 08:33:54 +00:00Commented Feb 26, 2019 at 8:33
-
\$\begingroup\$ Have you considered measuring temperature inside the refrigerator? The temperature should start to decrease when compressor turns on and increase when it turns off. \$\endgroup\$user930473– user9304732019年02月26日 16:17:51 +00:00Commented Feb 26, 2019 at 16:17
2 Answers 2
While a voltage sensor is theoretically feasible with few diodes and a resistors is not something that i suggest ad all when 230VAC is involved.
If you don't want to "hack" the refrigerator you can exploit its "power-on" led light, if any, with a photoresistor/phototransistor. Or you can actually hack the refrigerator and put your optoisolator sensing this power-on led. If you don't have any led you can use an hall effect current sensor, for instance you can search on google "wcs1500 module".
230VAC is dangerous so i'd go with the first two options, if possible.
An 2025 answer: use whatever esp8266-based measuring "smarthome" plug.
Be sure to hack away the original spyware and install a sane opensource firmware instead - esphome, tasmota, etc...
The power consumed somewhat depends on the temperature inside so the power vs time graph resembles sawteeth. Flat power line for an hour = the kids had left it open.