Brew fridge thermostat

thermostat-1

Reader [Will R] sent in a thermostat mod for his brew fridge. His friends had found a perfectly fine bar refrigerator and wanted to repurpose it for brewing beer. A previous batch of microbrew had been mangled by the Australian heat so they wanted something that could maintain the perfect temperature. The fridge’s built-in thermostat wouldn’t rise above 5 degrees so they had to build their own. [Will] used a 10K NTC thermistor to measure the temperature. It’s connected to an ATtiny25 microcontroller that does the comparison and determines whether to turn on the compressor. He referenced SparkFun’s relay tutorial for the switching side. Although he didn’t etch a board for this project, the design file is included along with all the code on the project site.

Comments

  1. Why use an op-amp when a microprocessor will do, huh… ;)

  2. cynic says:

    @mephistopheles
    Beat me to it, came to say the exact same thing.
    At least it’s not a full arduino setup.

    I’m not sure why they feel the need to use a voltage regulator when running on batteries. The ATT25 will run on anything between 1.1v-5.5v and it’s just turning that extra two volts into heat, right where it’s least wanted.

  3. niun says:

    nah, i think it’s ok to use a microcontroller in such a device, so you could easily extend the device to do some additional things like blinking an led or storing a temperature log.
    also the voltage regulator will not turn all off the extra two volts into heat, but you are right, its more obstructive than usefull

  4. Brewer_Guy says:

    I’m actually doing something quite similar for a school project, but using a Cypress micro-controller evaluation board that was given to us. Nice build though.

  5. Arthur says:

    >extra two volts into heat, right where it’s least wanted.

    I Came in to post just that, i would of moved the thermistor to the other side of the board, as opposed to right by the voltage regulator.

  6. Andrew says:

    Ok, I know this is obvious to some of you but I’ve serious been looking all over with no success. I’m trying to order perfboard like this but the online catalogs at mouser, etc. don’t often have pictures so, I’m not sure what I’m ordering. Where do you get this stuff??

  7. will says:

    @cynic:
    As you mentioned, the attiny will be happy with up to 5.5v, but the battery pack is spitting out a bit more than 6v at full charge, I wasn’t sure how it’d react to that. I could have used just two batteries, but then the SSR might not have switched properly, as it’s rated for 5V, and at 4.88v (which the 7805 is chugging out) it already has 6kOhms of resistance while switched on. If I wasn’t to use a 7805 I’m not really sure how I would have approached the situation…

    I did experiment with using a comparator but couldn’t get it working quite properly, and it was way easier to implement with the avr along with some nice features like hysteresis.

    @arthur:
    In regards the placement of the thermistor, it’s not actually near the 7805, and the transistor wouldn’t be putting out much heat, though I did take this into consideration and mounted it high and bent away from the ICs.

    @andrew:
    You can get perfboard from futurlec reasonably cheaply, and they have good international shipping charges too.

    Thanks all for the feedback

  8. mosheen says:

    Why not just run a diode in-line with the power? It should drop around 0.7v and give you a decent output. I do the same with my PICs and haven’t had one burn up yet.

  9. matt says:

    this might be a dumb question, but can’t the whole thing be replaced with something like this: http://www.parallax.com/Store/Components/AllIntegratedCircuits/tabid/154/List/1/ProductID/84/Default.aspx

  10. kyoorius says:

    Or to use even less power (zero electricity) , tear open an old home thermostat and use the bimetallic coil and mercury switch!

  11. morcheeba says:

    Kids these days and their complicated solid-state solutions! Back in the Atomic Age, we’d cover the temperature sensor in asbestos, and then use our slide rules to calculate the correct amount of plutonium to stick in the fridge to counteract the cooling effect of the chiller.

  12. Brett says:

    I have a prototype I have completed with all analog components. An comparator compares the voltages of 2 set values with the input of the voltage from the temp sensor. One controls the high set point one controls the low. The inputs are reversed so that the one goes high when the temp is >= the high threshold and the other goes high when the temp is <= the low threshold.

    These inputs are put into an SR latch built from some NAND gates. This tells the compressor to turn on or off and also has LEDs to indicates the state, Blue for too cold, red for too hot, green for just right. An wall wort is powering a standard 7805 setup to run the whole thing.

    I plan on improving the entire circuit so that you can adjust the freezer to kegerator serving temp or fermenting temps. Also working on adjusting the whole thing with one large pot instead of two onboard ones.

    I was thinking of going with the ATiny micro but my EE friend convinced me analog was the way to go.

    Nice project though. Maybe in the future I will go this way to add an LCD or preset temp levels or something.

  13. Jan says:

    btw, a 7805 needs a voltage difference of at least 2.5 – 3 V between output and input to achieve stable regulation. there is no real voltage regulation in this circuit, it’s just the voltage drop over the 7805’s pass element. you could have achieved the same effect by putting to diodes in series with the battery. if stable 5 V are needed you should have chosen a low-drop regulator such as LD1117-5.0 LP2950-5.0, LM2940-5.0

    regards,

    jan

  14. will says:

    @mosheen:
    ah, that’s a great idea! i didn’t consider doing that, but it’d pretty much be perfect. i’ll rip out the 7805 soon and pop in a diode.

  15. ragar says:

    I like the circuit regardless, it will bring people to start their own little projects, seeing things can be done with just a few components. From what it does I’d say a µc and opamp solution are on par here, even costwise.

    For the 7805 in general you should use 100nF capacitors on the input and output, they will keep the IC from oscillating, which can happen if you don’t use them. See the datasheet for this, it’s strongly recommended. If you can’t make sure the outputvoltage is always lower than the inputvoltage you should use a diode from the output to the input (1n400x will do), or the ic might die from current flowing backwards into it.

  16. matt says:

    The microprocessor also allows you to add and tweak the hysteresis of the control. I seem to remember hearing that you don’t want to turn the compressor on and off very quickly, but I may be mistaken.

  17. Rlyeh_drifter says:

    “My first thought was that a comparator would be an elegant solution, however after ordering a low-power comparator I found that it required a 2V difference between the two inputs for it to switch. This was completely impractical as a 2V difference translated to a 47 degree temperature change.”

    hihi, ja klar! Wahrscheinlich pull-up vergessen oder kein SingleSupply.

  18. MRE says:

    zenier to handle over voltage…

  19. ragnar says:

    Meinst wohl rail to rail, Rlyeh_drifter

  20. Relaxalittle says:

    niun – “I’m not sure why they feel the need to use a voltage regulator when running on batteries. The ATT25 will run on anything between 1.1v-5.5v and it’s just turning that extra two volts into heat, right where it’s least wanted.”

    Perhaps the idea to use a non battery power source was the initial idea or planned for the future.

  21. Rlyeh_drifter says:

    @ragnar:
    nein, ich meinte eigentlich den Effekt, dass sich die Ausgangsspannung invertiert wenn man den Eingangsspannungsbereich verlässt (Phase reversal).
    War aber nur blindes raten, die meisten Komparatoren können das eh.
    Rail to Rail bezieht sich immer auf die Ausgangsspannung, und die sollt ja hier (mit pull up) wurscht sein.

    english:
    my guess was exceeded input voltage range at the comparator, which may have caused phase reversal. Or he may have used an open collector comparator without pullup.

  22. James Lawson says:

    This can be implemented at lower cost and easier using a comparator or even a Darlington transistor. Also hysteresis is possible and easy to implement in both these configurations.

  23. rasz says:

    easier for someone who works with analog and doesnt know digital. I hate analog stuff, it scares me. Digital on the other hand is so logical and simple. You just drop a chip and write software for it, no need foe osciloscope and wondering why the gain is all wrong, why it stops working when temperature changes etc.

  24. Brett says:

    I ran this off of a 9v ac-dc transformer. I plan on integrating this into the power inside the freezer so that there is only one plug going into the wall. The existing thermostat unplugs and a relay easily plugs into its place. I am working with a Solid State Relay now to be able to trigger the 120vAC with the 5vDC directly.

  25. Bruce says:

    I have a ‘similar’ set up for my brewing fridge. All it really takes is a bulb and cap stat. Place the bulb in the fridge and then plug the fridge into the stat. Adjust the fridge settings all the way down, and then set the stat to the temp you want. It may be crude but it work and is UL approved.

  26. Bruce says:

    PS. for the kegerator lets see some digital scale hacks to show on an LCD display of how many beers are left!! I’m in the planning stage of doing this with my eeepc 700!!!

  27. It’s a simple enough modification, but ultimately this is what hacks are all about – make something work the way you want it to just using a bit of brainpower.

    Obviously a more complex solution, but I’ve heard of something similar using a wireless temperature probe and a home automation controller. The fridge would be set to max cold and then turned on and off using the controller based on the temp. Overkill for sure, but temp can be varied extremely easily.

  28. jOrge says:

    Spring is not just for cleaning, but also for fixing your home heating and cool system. My roommates and I check the furnace , make sure the fan is running properly, and sometimes replace the thermostat. We like to use our furnace to circulate and clean the air to remove all of the pollen that is in the air. Invensys makes some nice controlls and I’ve also found a brand called PECO that uses a custom algorithm to run the fan during the spring time. The only site I’ve been able to buy them at is thermostatlinevoltage.com there may be other sources out there though. Just some thoughts.

  29. Mr.Big says:

    This time is not just for washing, but also for fixing your home heat and cool system. My family and I check the furnace filter, make sure the fan is running correctly, and sometimes replace the thermostat. We like to use our furnace to circulate and clean the air to remove all of the pollen that is in the air. Invensys makes some nice controlls and I’ve also found a brand called PECO that uses a custom algorithm to run the system fan during the spring time. The only site I’ve been able to buy them at is thermostatlinevoltage.com there may be other sources out there though. Just some thoughts.

  30. jOrge says:

    Spring is not just for washing, but also for repairing your home heating and cool system. My family and I check the furnace , make sure the fan is running correctly, and sometimes replace the thermostat controller. We like to use our furnace to circulate and clean the air to remove all of the pollen that is in the air. Honeywell makes some nice controlls and I’ve also found a brand called PECO that uses a custom algorithm to run the fan during the spring time. The only site I’ve been able to buy them at is thermostatlinevoltage.com there may be other sources out there though. Just some thoughts.

  31. leslie says:

    Hi ..
    I would like to build ATtiny25 cooling thermostat. Where can I download the hex file is working. thank you …

  32. Asa says:

    I really have no idea, but could you not in theory, just bypass the thermostat controller for a refrigerator with a house thermostat? With beer you need to keep it at say 68 degrees which a house thermostat will do just fine. I haven’t tried it yet, but for those who are just looking to do just that and not delve into the world of circuit board creation, is it not possible?

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

Follow

Get every new post delivered to your Inbox.

Join 92,073 other followers