# PID controller.



## baz senior (Nov 23, 2013)

I have been building a PID controller for my UDS, mostly so I don't have to keep watching it.

I have seen a few version of how others have made these, and went for the one which looked the easiest and cheapest to build,

I started with a 12 volt PID controller, which can be purchased from a certain auction website. All I needed then was a 12 volt computer cooling fan and a box to put it all in.  The box is connected to the UDS with a short piece of 28mm copper pipe, and attached to the UDS with 28mm-3/4" male iron connectors and back nuts.

The PID is set to run at a certain temperature, and trained to maintain and smooth out the up and down temperature effect. It does this with clever calculus, that is able to predict when the heat is needed, and when to stop the fan to maintain an even temperature.

So, having put all this together, it was time to try it out. On advice from another member, I ran the UDS up to temperature, and then "trained" the controller, using a function called auto-tune. This is where it monitors the variations in temperature, and begins to predict the need for heat, switching on the fan as needed.

And it works fantastically, keeping the temp to within five degree's either side of the set temp. It's been running since 3 O'clock and it's now nearly half past eight.

I'll post pics tomorrow, so you can see what I have been prattling on about. 
Iam going to put a piece of Gammon in as well, to see how it fairs with food in it.


----------



## kc5tpy (Nov 23, 2013)

Hello Baz.  These are the things we need to share.  I haven't set up a PID but plan one for my fridge build.  Thanks for the post.  Lookin forward to the pictures.  Keep Smokin!

Danny


----------



## smokerpaul (Nov 23, 2013)

i did the same ,mine connects to the 22mm ball valve and that works fine but this was the prototype i made using a pound shop container,a pid ,a fan, a power switch and a fan isolation switch 













001.JPG



__ smokerpaul
__ May 12, 2013






i am re building it as i want to control 2 uds smokers in competition so i am getting another pid from china the same as this one but putting them both in a plastic project box then i will have 2 plug in k type thermocouples and 2 plug in outboard fan units connected on the drums ,also i am putting variable pots on the fan supplies so i can adjust the speeds of the fans to suit,already ordered fans from china,they are 15cfm fans and i will be able to reduce that 25% with the speed controls they were a great bargain i ordered 3 fans for £3 with free p&p how they sell them for 1 pound each ???


----------



## smokerpaul (Nov 23, 2013)

this is the fans i got from china


----------



## kc5tpy (Nov 23, 2013)

Hello Paul.  Believe it or not I did understand your post. After welding for many years I took an electronics course at University.  So I am a qualified electronics engineer.  Going to do compete?  Good for you I wish you well.  Fly the flag for our U.K. Group.  May I humbly suggest that in the future you painstakingly describe your electronic posts so that new folks with no experience can LEARN from your experience.  You got skills my friend.  It's just that someone just starting out, will read  your post and decide it was written in Latin.  I mean no disrespect; as I said you have talent.  We are members of this group to ( I hope ) encourage new folks to get with the program.  No criticism intended.  Just maybe a more basic explanation would be more helpful to more folks.  Just a thought.  I may be WAY off the mark.  Wouldn't be the first time I was wrong.  Read your post as if you were completely new with no idea of how to build, install and program a PID.  Keep Posting.  Keep Smokin

Danny


----------



## smokerpaul (Nov 23, 2013)

sorry danny

i posted in reply to baz senior  who already has built a temperature controller and has a good knowledge of them, i didn't take non technical members into account, i will try to simplify when explaining on posts but i didn't want to seem long winded when replying to an already knowledgeable member


----------



## kc5tpy (Nov 24, 2013)

Hello Paul.  I meant no disrespect.  I just thought maybe a "new" member might get lost.  Your point is well taken.  I will remember that you both have built a PID and will point folks in your direction if they are having problems with their build.  Keep Smokin!

Danny


----------



## baz senior (Nov 24, 2013)

Awesome, just awesome. This worked way better than I had hoped. I called it a night at 10.30pm, and got down the garden at Eight this morning. There was still heat in what was left of the charcoal.

So after a quick clean out, I loaded it up again, with a few good chunks of Oak in amongst the coals. I had soaked a bargain bit of Gammon for six hours to get some of the saltiness out of it, and got that ready for cooking.

I lit the UDS, waited until it got to temp and then let the controller take over the running of the temp. I started it around 10.30, put the meat in at 11.30 and left it to it's own devices. I kept watching the temp on the ET-73, just to make sure nothing went wrong, as there have been one or two good gusts of wind. I wanted to make sure that didn't over-ride the controller fan.

It works fantastic. I can only assume that it is able to monitor and further correct it's control, as today it has been bang on target for the temp, it has only swung a couple of degree's either way. When you realise this is trying to control a charcoal burn, which will have varying heat output from different lump size, and quality of the wood used, plus the slow reaction to any input that is made, then this thing is cleverer than me.
It sure beats juggling lever valves.

Here's some pic's.

http://s1230.photobucket.com/user/BBQBAZ/library/PID Controller?sort=6&page=1


Roll on tea time! nana2.gif


Edit: Also posted in UDS builds on the main forum, as I have been asked by a member who cannot see the posts in this group.


----------



## smokerpaul (Nov 24, 2013)

baz

your pid looks very similar to mine!! you know what they say great minds and all that!!!


----------



## baz senior (Nov 24, 2013)

Nah, I shamelessly copied it.  Great minds do the thinking and the fools follow!
I did consider all the options, and decided not to use a centrifugal fan, as I thought it would be too fierce. That and I had the fan and controller already, so I just got a box from Maplins to put it in.
It's all 12v so safe for outdoor use.

It's just started to struggle a bit, and has dropped 5 degree's C, so it might be running out of charcoal. Iam still wondering if it actively monitors and adjusts to suit, or if it auto-tunes and then works solely off that parameter.
Iam the only engineer who now has any idea of what a PID controller does. All the other guys just use it as a digital controller. So it goes to show that doing homework benefits the company in the long run. :biggrin:


----------



## smokerpaul (Nov 24, 2013)

i am going to use the fan on the drum with a separate control box,with all the research i have done ,it seems that 15 cubic feet per min is around the ideal air flow for a uds ,but putting a fan speed control in the design means i will have a more versatile unit.also i input the air through a ball valve making it easier to shut the air off when i lift the lid because you will find on our type of smoker that the coals fire up when the lid is off and blowing air in as well makes the temperature spike when you replace the lid very much higher!!!!!


----------



## baz senior (Nov 25, 2013)

That's the thing with this game. What might work faultlessly for me, might be a royal pain for someone else, it's all down to the variables on the day. No ones UDS is the same.

At the end of the day, the PID should help to take care of all the variables, and smooth things out. I may have been lucky and just happened to have got the right sized fan that is happy on my drum, but it works great. 
There are gaps around the outside edge of the fan, as the hole saw I used was too large. But covering them up has a negative effect on the temp, and drags it down rapidly. I have no idea why this is, I would have assumed that having a tight enclosure would provide more air into the drum, but it seems to not be that way. Maybe there is a maximum that the bore of the pipe (28mm) can support.
For now, Iam going to leave it alone and really try it out as much as possible. I'll see how it performs, it might be with a higher outside temp in summer it won't work, but that's all part of the fun.


----------



## smokerpaul (Nov 25, 2013)

last time i used my controller it was struggling to get up to temp, the fan was blowing and the temp would not go up past 210f i ended up wrapping 2 old towels around my drum and that sorted the problem ,i think it was not getting enough air ,along with the very low ambient temp outside ,hence the re build also making another uds so i want a dual unit


----------



## wade (Dec 20, 2013)

A welding blanket is great to wrap around the smoker when it gets cold at night.


----------

