Membership questions? Log in issues? Email info@brewersassociation.org

Author Topic: Auto tune mash PID?  (Read 2041 times)

Offline Mike-Ale

  • Cellarman
  • **
  • Posts: 36
Auto tune mash PID?
« on: January 09, 2019, 06:56:47 pm »
I just replaced my PID’s (long story) and am noticing that the temps are slightly off. I’ve always thought or maybe even read somewhere that you don’t need to auto tune the mash PID but have recently questioned this idea. Wouldn’t it make sense to auto tune the mash PID since it is the most critical temp reading?? Any experience or advice would be greatly appreciated.

Offline BrewBama

  • Official Poobah of No Life. (I Got Ban Hammered by Drew)
  • *********
  • Posts: 6077
Auto tune mash PID?
« Reply #1 on: January 09, 2019, 09:12:01 pm »
I believe when you do your first brewday with the new PID you do need to let it auto tune to your system. I believe an actual brewday should be used because grain, liquor, pumps, etc will make a difference IMO. Every system has variance so the controller will figure it out and change its settings to adapt. It will most likely overshoot by a few degrees a few times as it learns how much power to use and how long to fire the element to reduce the error. But once AT is complete it should not overshoot very much (if at all) and as the error gap reduces it should send fewer pulses of reduced power to hit the set value.  The AT setting(s) should remain in memory so you’ll not have to run it again unless a process or equipment change is made.

...at least that’s the way I understand it.

Sent from my iPad using Tapatalk
« Last Edit: January 09, 2019, 09:14:19 pm by BrewBama »

Offline Mike-Ale

  • Cellarman
  • **
  • Posts: 36
Re: Auto tune mash PID?
« Reply #2 on: January 10, 2019, 07:29:45 am »
So here is part of my confusion, there is no element in the mash tun, just the inline RTD temp sensor. Can you auto tune the mash PID when there is no element running from it?

I did recently auto tune both elements in the BK and the HLT so I believe they are pretty close to accurate. 



Sent from my iPhone using Tapatalk

Offline TeeDubb

  • Assistant Brewer
  • ***
  • Posts: 117
  • San Jose, CA
Re: Auto tune mash PID?
« Reply #3 on: January 10, 2019, 11:03:48 am »
As long as the heat source controller and the feedback device (sensor) are part of the system and connected to the same PID controller, it should work. But the more elements (thermal boundaries) that are in between the two parts (heat source and feedback sensor), the more difficult it may be for the control algorithm to self learn. An example would be a HERMS system where one fluid is used to heat/cool another. This would create some response lag in the control loop. Some of these PID devices have more robust control laws/software than others and they are not all the same.

I have personally never used the auto-tune system.  I just started with very basic P,I,D term gains and adjusted them myself to achieve a stable feedback loop with tight control. But my heat source and sensor operate in the same fluid.

Offline Mike-Ale

  • Cellarman
  • **
  • Posts: 36
Re: Auto tune mash PID?
« Reply #4 on: January 10, 2019, 11:37:32 am »
As long as the heat source controller and the feedback device (sensor) are part of the system and connected to the same PID controller, it should work. But the more elements (thermal boundaries) that are in between the two parts (heat source and feedback sensor), the more difficult it may be for the control algorithm to self learn. An example would be a HERMS system where one fluid is used to heat/cool another. This would create some response lag in the control loop. Some of these PID devices have more robust control laws/software than others and they are not all the same.

I have personally never used the auto-tune system.  I just started with very basic P,I,D term gains and adjusted them myself to achieve a stable feedback loop with tight control. But my heat source and sensor operate in the same fluid.


TeeDubb,

I am running a three vessel HERMS system and in this case the boil kettle element is the heat source (PID 1) and the mash tun sensor is on a separate PID (PID2). The liquid I would use to auto tune would be water which will be flowing past the sensor that is located in a “T” fitting on the ball valve of the MT. The water will recirculate from the BK to the MT while the auto tune process is going on.  So based on your feedback you are saying this won’t work because the  BK element (PID1) and the mash tun sensor (PID2) are on separate PID’s?


Sent from my iPhone using Tapatalk

Offline BrewBama

  • Official Poobah of No Life. (I Got Ban Hammered by Drew)
  • *********
  • Posts: 6077
Re: Auto tune mash PID?
« Reply #5 on: January 10, 2019, 01:23:12 pm »
As long as the heat source controller and the feedback device (sensor) are part of the system and connected to the same PID controller, it should work. But the more elements (thermal boundaries) that are in between the two parts (heat source and feedback sensor), the more difficult it may be for the control algorithm to self learn. An example would be a HERMS system where one fluid is used to heat/cool another. This would create some response lag in the control loop. Some of these PID devices have more robust control laws/software than others and they are not all the same.

I have personally never used the auto-tune system.  I just started with very basic P,I,D term gains and adjusted them myself to achieve a stable feedback loop with tight control. But my heat source and sensor operate in the same fluid.

Great information


Sent from my iPhone using Tapatalk

Offline TeeDubb

  • Assistant Brewer
  • ***
  • Posts: 117
  • San Jose, CA
Re: Auto tune mash PID?
« Reply #6 on: January 10, 2019, 02:53:20 pm »
At the risk of providing mis-information, I think I would need a little more information or a schematic that shows the system arrangement to help answer the question. Some questions or clarifications in lieu of this:

- I'm assuming your system is all electric.
- You are using your boil kettle as a heat source during mash, so it's like a traditional Hot Liquor Tank.
- You say water being circulated while auto-tuning. I'm assuming this means you won't actually be brewing, but using water instead of wort.
- The Boil Kettle contains a water heating element that is controlled by, call it, PID#1 and has a related sensor, (call it sensor #1) in the boil kettle water. You have a pump that moves the water around in the Boil kettle and past sensor #1. Please confirm.
- During Mash, your wort (or plain water during the tuning) would be pumped out of the Mash Tun, past a sensor (call it sensor #2) into a coil submerged in the Boil Kettle which also contains separate plain water. The wort then returns back into the Mash Tun.
- Sensor #2 is connected to PID#2.

Questions: What does PID#2 control / what is it commanding?

Initial guess is that PID#2 is not really needed during mash, unless it is trying to control something. You can just watch the temperature it displays and that is the best indicator of live mash temp.  PID #1 will control the boil kettle water (being used as a HLT) to your mash setpoint on PID #1 and with some slight lag, the mash temp in the mash tun will follow it closely. Auto-tuning PID#1 with this arrangement should work fine.

I hope I'm getting this right without a schematic.  Every system is a little different.

Offline Mike-Ale

  • Cellarman
  • **
  • Posts: 36
Re: Auto tune mash PID?
« Reply #7 on: January 10, 2019, 04:26:29 pm »
TeeDubb,

Your assumptions are spot on from my description of my system but I didn’t describe it properly. I am actually running a 3 vessel all electric herms system. My system is the 20 gallon Spike system. I wasn’t sure if I could auto tune the mash PID because the mash tun does not have an element in it. When I was describing it in earlier posts, I was using the boil kettle to heat the water and then I pumped it in past the sensor in the mash tun. The temp read outs were different by almost 4 degrees on the mash and boil PIDs. I assumed maybe a degree to degree and half due to heat loss but 4 seemed high. I was also using a thermo pen inside the MT valve that was giving me the same temp as the (correct) BK temp. The BK was accurate so that is why I was curious about the mash PID.  I did find out through another forum that calibrating the RTD sensor within the PID menu could help. I was able to do this and things seem to be working accurately now. I appreciate all of your help!!  Thank you!!


Sent from my iPhone using Tapatalk

Offline TeeDubb

  • Assistant Brewer
  • ***
  • Posts: 117
  • San Jose, CA
Re: Auto tune mash PID?
« Reply #8 on: January 10, 2019, 10:56:54 pm »
Cool - I just looked at the Spike system (very nice!) and confirmed that your MT PID does not control anything and is simply a display for mash temp.

I have been annoyed by temperature calibration in the past as well. I know that my PID controller drifts a little bit as it warms up (2-3 degrees F), so I always let it run for 10 min before calibrating the probe it uses against a known standard, like you did. Amazingly, my $20 digital kitchen thermometer is my go-to reference.

Happy brewing!