I have two ds18b20 connected in star topology (3m cable) to a wemos d1 mini inside a cold chamber and sometimes the temperatures are like following a sinewave. Any idea where that might come from ? ds18b20 sinewave

If we look over 24h, it seems to happen once the temperature stabilizes: enter image description here Thanks in advance.

  • 2
    looks like the chamber temperature fluctuates .... what exacly is your question about, the cold chamber or the ds18b20?
    – jsotola
    Jan 4, 2021 at 5:15
  • 1
    I’m voting to close this question because while it is a good and well asked first question I cannot find the IoT aspect of it. I think Physics Stack Exchange site would be better suited for it. Jan 4, 2021 at 20:39
  • Well sensors are part of most IoT devices, my question is more about could these fluctuation be because of sensor reading issue due to the topology or installation? Interferences or something? I did not see such fluctuation at room temperature but wires were way shorter.
    – bnjroos
    Jan 8, 2021 at 8:34

1 Answer 1


Temperature-controlled environment are usually driven by a thermostat, which has slightly different thresholds to turn heating/cooling elements on or off, to avoid switching this every second or so as soon as it goes above/below the desired temperature.

For instance, for a target temperature of -27°C, it could turn on cooling until it reaches -28°C, then turn it off and keep it off even if it goes back up a little, until it reaches -26°C, where it will turn it on again, and so on. This is called hysteresis.

Without that, it would cool until it reaches -27°C, stop, then start again when it goes up to -26.99°C, then stop again when it's back down to -27°C, and so on. This would happen a lot more often then it does with hysteresis. With complex mechanical systems like cooling or heating elements, this is usually not a very good idea.

The fact that it moves back up so quickly may be the sign that there is a (small) source of heat inside the room, or that it is not correctly isolated. Or it may be perfectly within specs.

  • OK thanks for the answer, it feels normal then! I'll just play with the sampling to smooth the curves then!
    – bnjroos
    Jan 8, 2021 at 8:37
  • My guess is that the green one ("front left") is closer to the AC's output (colder, larger amplitude), while the other one is further (not as cold, and less amplitude). Not sure what you are trying to do? Measure? Trigger alarms?
    – jcaron
    Jan 8, 2021 at 15:40

Not the answer you're looking for? Browse other questions tagged or ask your own question.