Weird temp oscillation with old Arduino version

Hi!
I just finished to set my brewpi and I’m testing it fermenting some cider.

I think that it’s working quite well, but I see some oscillation on the beer and fridge temp that is quite weird, for example a big drop right after it was applied some cool.

I have a small chest freezer, with a “reptil heat cable” around the walls of it.

Any ideas? I leave you here a screenshot of the graph and the configuration I’m using right now. THanks in advance!!

Min Temperature:
1,0
Max Temperature:
30,0
PID: Kp:
10,0
PID: Ki:
0,051
PID: Kd:
2,0
PID: maximum:
10,0
Integrator: Max temp error C:
0,5
Temperature idle range top:
1,0
Temperature idle range bottom:
-1,0
Heating target upper bound:
0,301
Heating target lower bound:
-0,199
Cooling target upper bound:
0,199
Cooling target lower bound:
-0,301
Maximum time in seconds for heating overshoot estimator:
600
Maximum time in seconds for cooling overshoot estimator:
1200
Beer fast filter delay time:
3
Beer slow filter delay time:
4
Beer slope filter delay time:
4
Fridge fast filter delay time:
1
Fridge slow filter delay time:
4
Fridge slope filter delay time:
3

I just add the overnight graph if it cool helps.

Try first with Kd and Ki at zero and optimize for Kp to have little overshoot. Then tweak Ki and finally if needed Kd.

Thank you so much! I tried to optimize KP as suggested testing different numbers, and I can see less overshoot (right now with KP 2,5 / KI 0 / KD 0). The problem is that the beer temp still changes too much, mostly as soon as the cooling start , isn’t? Any further suggestions to try to keep it more steady? Thanks for the amazing job!

My guess is that you taped the temp sensor to the side of your carboy, correct?
20l of beer can’t change temperature that quickly.

With a sensor taped to the outside, you are measuring half fridge temp half beer temp. A thermowell is much better.

You should also move your fridge temp sensor closer to the back of the fridge where it cools so it doesn’t have as much lag.

Indeed! Yes, actually since is just a test batch I’m fermenting just 4l on a glass carboy. Next time I’ll use my SS Bucket with the thermowell on the lid.

Just curious, the big drops after the cooling part do you think is also related with the temp probe attached to the side?

Thanks again!

Yes, the advice about moving the fridge sensor still stands.
You can set Ki back for steady state errors, but make sure the proportional part remains dominant unless your are at steady state. Too much/fast integral action can also cause overshoot.

I have a small chest freezer, with the fridge temp sensor attached to the wall of it, I don’t know if that changes something.