Author Topic: Anyone using Microcontroller?  (Read 6355 times)

zrim

  • Guest
Anyone using Microcontroller?
« on: January 09, 2010, 04:04:20 PM »
Hi Everyone,

I've had my cheese cave up and running for less than a month.  I am using a travel humidifier to keep the humidity and a mini fridge to keep the temp.

I am turning the fridge on/off using a microcontroller and I am also turning the humidifier on/off using the microcontroller.  The fridge temp and humidity are monitored via sensors that are also connected to the microcontroller.  So far the temp stays +/- 1 degree F and +/- 3% RH. 

Is anyone else doing this?

Alex

  • Guest
Re: Anyone using Microcontroller?
« Reply #1 on: January 09, 2010, 04:41:48 PM »
My frige/cave is connected through an external thermostat. In the cave there is also an ultrasonic humidyfier connected through a timer with on/off cycles. With a digital thermometer/humidity meter inside the fridge I monitor the "truth". Very efficient setup.

zenith1

  • Guest
Re: Anyone using Microcontroller?
« Reply #2 on: January 09, 2010, 08:09:44 PM »
Zrim--I like your set-up, way beyond my levels of expertise though.

zrim

  • Guest
Re: Anyone using Microcontroller?
« Reply #3 on: January 09, 2010, 10:52:11 PM »
Besides the fridge the whole setup proably cost me about $150.  I'm an engineer by trade so this was up my alley.  If you ever want to try, let me know and I could certainly share. 

I tend to trust my sensors but could someone suggest a cheap and fairly accurate device that measures temp and humidity? 

Offline DeejayDebi

  • Old Cheese
  • *****
  • Location: Connecticut
  • Posts: 5,820
  • Cheeses: 106
    • Deejays Smoke Pit and DSP Forums
Re: Anyone using Microcontroller?
« Reply #4 on: January 10, 2010, 01:16:15 AM »
Very impressive setup Zrim. Did you design the circuitry or did you find something pre-existing?

wharris

  • Guest
Re: Anyone using Microcontroller?
« Reply #5 on: January 10, 2010, 02:05:51 AM »
This piques my interest.  Love to know more details.

chilipepper

  • Guest
Re: Anyone using Microcontroller?
« Reply #6 on: January 10, 2010, 02:15:45 AM »
I too am very interested in your setup?  What controller are you using?  I was going to try and do something similar with an Arduino.  I have a temp controller already built for my beer fridge with SSR 's and doing basically half of what you are doing.  I have been curious how the humidity would work out by simply controlling the power to a humidifier.   There are a couple of combination temp/humidity sensors out there but they are a bit pricey.  i assume you need a PC to monitor and control in your setup?  I'm utilizing a simple 2x16 back lit LCD for mine which makes it nice to run without a PC.

What sensors are you currently using?  Sorry for all the questions but the short and sweet of it all is you have our interest now we just need some more details? ;)

Ryan

zrim

  • Guest
Re: Anyone using Microcontroller?
« Reply #7 on: January 10, 2010, 05:05:18 AM »
I'm pretty psyched about this so I'm happy to share!

I am using an Arduino Duemilanove microcontroller ($29).  The system will run just fine with only the Arduino.  I am using an old laptop to read the Arduino's serial output and display it. So for a second let's take the laptop out of the equation.

Sensors:
Humirel HM 1500 humidity sensor.  I forget how much it cost me.
I built a temp sensor out of a thermistor and 10K resistor.  ($3)

Actuators:
Old dorm fridge that I cleaned obsessively (free).
Sunpentown travel humidifier ($50) - I originally made a humidifier out of fish tank supplies but the fridge overpowered it.

Custom Outlet:
I used two solid state relays to individually control two outlets of a standard electrical outlet. ($30 total)

With all of that madeI wrote my arduino code.  Basically I read the voltage from the sensors via the Arduino analog input, then convert the voltage to a physical value (degrees F or % humidity).  Based on those values I turn the outlets on or off using the digital outputs of the Arduino. 

Finally, my laptop sees the Arduino as a serial port when connected so I send some serial strings to the computer and parse/display the values using a simple LabVIEW program.

A couple of notes, the fridge cannot be turned on and off too quickly or it will not respond.  It seems to have some internal timer (a capacitor or something) that is not even overridden by cutting power.  I used some averaging of the temp values as well as hystersis (for example, I want 50F so I turn the fridge on at 51F and I turn it off at 49F) this keeps the fridge operating correctly.

The humidity is easy but I do have some fear that I am punishing the humidifier.  It turns on an off a lot but it seems to be necessary in order to keep the humidity tolerance tight.

I've attached some pics.

Let me know what you think and I'd love some feedback.



zenith1

  • Guest
Re: Anyone using Microcontroller?
« Reply #8 on: January 10, 2010, 04:24:06 PM »
Zrim-that is great work. The electronics part is outside of my area of knowledge but with my neighbor who is an electrician maybe we can come close to your work for my cave. Thanks for the feedback!

Offline DeejayDebi

  • Old Cheese
  • *****
  • Location: Connecticut
  • Posts: 5,820
  • Cheeses: 106
    • Deejays Smoke Pit and DSP Forums
Re: Anyone using Microcontroller?
« Reply #9 on: January 10, 2010, 04:36:40 PM »
Very kewl Zrim nice work!

chilipepper

  • Guest
Re: Anyone using Microcontroller?
« Reply #10 on: January 10, 2010, 04:51:21 PM »
Cool another Arduino fan!!  O0  Great work!

Sounds very similar to half of my controller for my beer fridge.  I'm thinking it would be fairly easy to modify mine to add another SSR and sensor for humidity.  I suppose you could add some delay code to your program to keep the humidifier from cycling too often.  I added a 2 minute delay to the switching portion of my code so that if I open the door and let the cold out it doesn't try and toggle the fridge on and off and ruin the compresser.

I wonder if there would be any advantage to using a element based humidifier rather than ultrasonic.  With the ultrasonic basically spraying out humidity it may be easier to confuse the sensor. Although in your case size is an issue and I'm not sure you could find a humidifier that small unless you port it into the side of your fridge somehow. 

Anyway, great project and thanks for the inspiration and testing!

Ryan

Offline Gürkan Yeniçeri

  • The one who masters temperature and humidity can make any cheese.
  • Old Cheese
  • *****
  • Location: Canberra / Australia
  • Posts: 703
  • Cheeses: 36
  • It's not a hobby, it's an addiction, a good one.
    • Artizan Peynirci
Re: Anyone using Microcontroller?
« Reply #11 on: January 10, 2010, 10:31:48 PM »
I was going to ask if it is Arduino or a PIC on the other entry but now it is answered. I am thinking of getting a second fridge and wiring it up so that I can monitor humidity and temp over the internet from work  8) (now that is a geek).

Do you have the schematics for your sensor wiring?

zrim

  • Guest
Re: Anyone using Microcontroller?
« Reply #12 on: January 10, 2010, 11:44:51 PM »
I don't have any schematics drawn up but it is simple.  The humidity sensor just has 3 wires 5V, Gnd and the Voltage Output (representing humidity).  Those can be wired directly into Arduino, dead simple.

The temperature sensor is a little more DIY.  I used a 10KOhm thermistor and a 10KOhm resistor.  They are wired in series from 5V to Gnd.  The voltage output is taken from the wire connecting the thermistor and the resistor.  That way you can figure out the instananeous resistance of the thermistor by performing a voltage divider.  That resistance can be used to calculate the temperature (big formula in the thermistor data sheet).

I RDP into my cheese cave computer from work and from my phone.  Very geeky!  A light and a webcam could go in there too, I am tempted.

FRANCOIS

  • Guest
Re: Anyone using Microcontroller?
« Reply #13 on: January 11, 2010, 12:44:09 AM »
My cooler back in the US used a similar concept.  I used a ceramic honeywell humidity sensor (wall mount) and connected this to a digital honeywell control that would read humidity and power a relay for over/under conditions.  The relay opened a solenoid for water flow and also powered up a booster pump (from a soda dispensing machine).  It boosted linepressure to the greenhouse misting system I had running along the cieling.  The temp was simple and just used the Johnson walk in coller control.  I also used an school bell timing control to schedule exhaust "events" to remove ammonia.  The controls probably cost me a total of $150 (all off Ebay), but I had to purchase wire, conduit and install myself.

zrim

  • Guest
Re: Anyone using Microcontroller?
« Reply #14 on: January 11, 2010, 12:56:13 AM »
Francois,

Sounds pretty cool.  I think mist would be a great way to go, especially if I decided to make a larger cave at some point.