Weird oscillation with DHT22

I have a couple of nodemcus with DHT22 as temperature and humidity sensors. I am observing weird oscillations in the temperature history when the temperature should be relatively constant like this:

dht

The amplitude of the oscillation is ~ 3F and the period is ~ 25 minutes. I don’t think it’s the period of my AC coming on. I am collecting data every 30 seconds. Can’t really see this in the humidity data just noise is ± 1%, which I would expect.
I tried moving average filters, but that didn’t really do anything.

Anyone have an idea what’s going on and how to fix this?

How close are your sensors to your nodemcus?

The nodemcu generates a bit of heat.

You could try this config:

  - platform: dht
    pin: D5
    model: DHT22
    update_interval: 15s
    temperature:
      name: "Lounge Room Temperature"
      filters:
        - sliding_window_moving_average:
            window_size: 15
            send_every: 15
            send_first_at: 15
    humidity:
      name: "Lounge Room Humidity"
      filters:
        - sliding_window_moving_average:
            window_size: 15
            send_every: 15
            send_first_at: 15

Gives updates about every 3 minutes which I find is plenty for room temperatures.

The nodemcus are too close, but I can’t really find a good 3D printed cases where that is not the case (maybe pun intended). I use this and this case.

But it turns out I was wrong: I covered the sensor to shield it from any air movement and the oscillations went away.

Thanks for your help.