True GDM-6-LD Build - Performance Testing

I have been testing [my build][1] since I finished it last week. This is the sample profile using a Speidel 30L fermenter w/ thermowell filled with around 6 Gal of water. I have not adjusted any settings in BrewPi.

Constant: The greatest variance in maintaining constant temperatures is consistently 0.10 - 0.11° F.




Cooling: The area I have selected has to do with a drop in temperature over time. I’m not sure if this oscillation will be the same as, greater, or less than it is now when the temperature is raised over time. I will post more data as it comes in. The variance I have observed between set and actual is 0.05-0.18° F which I am pretty happy with. I’m not sure if it could get any better than that. It certainly wouldn’t make a difference brewing with any tighter accuracy. LOL






Heating:


TDB
[1]: True GDM-6-LD Build

1 Like

Looks great! Once we got my BevAir up and running we saw accuracy of .05 which is pretty damn incredible.

Cheers,
-Stephen

Yeah I just think my fridge is a little too aggressive. The PID constants could be fine tuned to get even tighter tolerances.

@Elco

Here are graphs from the BrewPi in constant mode with 5 Gal of beer. I’m afraid to mess with any of the constants while there is beer in the fridge but it seems like the fridge temps are all over the place and don’t really follow the fridge set point. This can also be seen in the tests above. I am getting an average swing of ± 0.18°F which I am okay with but I want to know if this graph is showing optimal functionality. There isn’t much information here on tuning the PID controller or what an optimal graph looks like.

Thanks



1 Like

I’d say it looks good enough. Use it like this until the PWM update is ready for fridge use. You’ll be able to achieve a smoother result then, also for the fridge temp.

1 Like

@Elco, I’m beginning to have problems on my second brew. The only thing I did was widen the min and max fridge temperature range from 33.8°F to 25°F and 86°F to 95°F. I have since defaulted back to the original settings just to be sure but it hasn’t fixed the issue. I thought it might be a power supply issue since I’m running the BrewPi off of the RPi via USB but since adding a separate 5v power supply to the BrewPi nothing has changed. Any ideas?

Try halving Kp, Ki and Kd, so there is less of a difference between fridge setting and beer setting.

@Elco I’ll try that and see what happens. I also don’t understand why the positive peak shows 118.4. The logs show positive peaks around 74°F but the field wont update. Also, the math for calculating PID looks wrong if multiplication of the control variable and PID constant is the only operation happening there.

you’'ll have to click all 3 update buttons to update the fields. They are not updated automatically.

@Elco I have pressed all three update buttons. lol I knew it didn’t auto-update. The brewpi actually looks as though it hasn’t been detecting positive peaks lately. The last time it detected a positive peak was yesterday afternoon. The logs show mostly negative peaks. I’m guessing that when there is positive momentum gained due to forces outside of the system, there is no peak recorded. (BrewPi Idle) It has been very hot where I live the last few days. I’m wondering if this is having an effect.

EDIT: The heat has actually just kicked on. There should be a positive peak detected correct?

@Elco I’m still concerned with the math being wrong though. Maybe I’m just being dense and not understanding the math here somehow but none of the PID values appear to be calculating correctly based on the operations “advertised.”

All of the PID values are roughly half as much as they should be based on the math listed. (0.359 * 2.5 = 0.8975)

hmm, this is indeed strange.
What if you hit each button twice? It might sound silly, but perhaps you are getting a cached version by the script, instead of a fresh copy from the controller.

@Elco Nope, that didn’t change anything. Where do I begin trying to unravel this mystery? Also, halving Kp, Ki, and Kd seemed to have had a good effect. I still have ±0.5 swing in temperature though and the graph of when it was operating before is completely different to the way it is now.

Before:

After (Now):

How powerful is your heater?
Both the fridge and the heater are heating the minimum time on each pulse.

You can also try to reduce the filtering on the beer temperature. Filtering causes a lag. You can also increase Kd, which should prevent overshoot.

@Elco The reptile heat cable is 100W. The build thread has pictures and all of the info. It’s the wattage you recommended. Lol I linked to the build thread in the first post of this thread.

Okay so I’ve reduced the beer slow filter delay to 78 seconds and increased Kd to 3 from 0.075 when I halved everything.

Kp 2.5, Ki 0.125, Kd 3

I’ll post graphs when I’ve gotten some data back.

@Elco So nothing I did really seemed to get the oscillation under control. I only primary for 14 days so that brew is done and I have another batch already in the fridge. One notable thing that I found with that particular brew is that the thermowell I was using was half full of sanitizing solution. My buddy had washed it and not drained it. I didn’t think that would be a big deal but perhaps the liquid in the tube was causing the problem.

The new batch is doing really well (1.5 days in) right now just like the previous batch first started. I have my fingers crossed that it was somehow the liquid in the thermowell that was causing the problems.

@Elco, I have ordered a new Raspberry Pi power supply, usb cord, new separate power supply for the BrewPi, and upgraded to a RPi 2 from an old B because the USB power is known to be temperamental. I should know how that works out by Friday. I am doing this to hopefully rule out any suspicion that something I have done in the setup of the system is wrong. I believe that there is either a bug(s) in the firmware when used on the Spark/Photon, I have faulty temperature sensors, or the BrewPi mainboard is somehow malfunctioning.

It’s hard to know if there is a bug because there may only be a couple people here with a complete Photon based BrewPi fridge build that are active on the forum.

The fermentation starts out fine and I get the accuracy advertised (± 0.1°C) and then the pattern changes seemingly randomly, like I have shown, resulting in loss of accuracy in the form of oscillation of up to + and - 1°F that persists until a new fermentation is started. Normally this wouldnt be a big deal if that oscillation happened over a day or so but with a high powered PID system this oscillation happens repeatedly and quickly. I think it could very possibly lead to undesirable consequences in flavor if this were to happen during the initial phase.

I will report back as soon as I have some actionable information.

Here is the tail of stdout. I haven’t seen any errors reported in stderr

Sep 30 2015 23:21:36 {“BeerTemp”: 71.77,“BeerSet”: 71.56,“BeerAnn”:null,“FridgeTemp”: 71.60,“FridgeSet”: 70.19,“FridgeAnn”:null,“State”:0}
Sep 30 2015 23:22:49 {“BeerTemp”: 71.79,“BeerSet”: 71.56,“BeerAnn”:null,“FridgeTemp”: 71.83,“FridgeSet”: 70.02,“FridgeAnn”:null,“State”:4}
Sep 30 2015 23:24:04 {“BeerTemp”: 71.78,“BeerSet”: 71.56,“BeerAnn”:null,“FridgeTemp”: 70.55,“FridgeSet”: 69.97,“FridgeAnn”:null,“State”:8}

@Elco, would a bug in filter initialization also cause the Control Algorithm page to incorrectly report the math operations being done? This is what worries me most as it makes my changes to the PID constants almost blind. Do you currently have a Photon BrewPi fridge set up with the latest public release firmware to confirm or deny my suspicions? Also, is there a flag I can set to get more complete logging for debugging these kinds of issues?

When this problem is solved I would like to start a thread on BrewPi system debugging to standardize the problem solving process.

I realize you have a lot going on with both the product and business side of the project so I’m trying my best to accurately report back with my findings and autonomously problem solve but I can only do so much with the spare time I have. I would love to be able to just dive into the code but I have been pretty busy at work.

Thanks

@Elco As far as I can see there is a bug in the implementation of the overshoot estimators and peak detection. My system consistently performs well until high krausen and then when the fermentation slows, the system begins to lose accuracy over time. ( Up to eventually~±1.5°F every couple of hours) The system copes well with an increase in heat generated by fermentation but when it stops generating that heat it seems that the system has no way to correct for it quickly.

I have changed power supplies, cables, RPi, and my fridge is running well.

I’m nearly positive this is a firmware issue. I hope it is resolved in the new update.