Shop OBEX P1 Docs P2 Docs Learn Events
Temp Sensing Project / Would welcome advice — Parallax Forums

Temp Sensing Project / Would welcome advice

Fred S.Fred S. Posts: 4
edited 2005-04-13 13:42 in BASIC Stamp
Just got into stamp and microcontrollers although I have a well founded technician and programming·background.·I am building a temp controll system for·the interior of an·aluminum enclosed box exposed to the elements in Vermont. The box houses some fairly sensitive computer equipment hence the temp control.· It needs to cover both heating and passive cooling.· It seems fairly straightforward but maybe I need a wakeup call.· This has got to work; first time, every time, etc.·· Ok, I need to sense the temp in 6 or 7 different points within the box and turn on heaters or fans in those areas as temperatures at different point within the box can vary radically due to North South exposure, wind, sun, etc.· For this, the Dallas 1620 seems a good choice(space is not a concerne)·although I'm a little concerned about the semi exposed environment(humidity). If possible, I would use simple RJ11 connectors and POTS cabling as my sensor leads. I have a maximum distance of about 5 feet.·· Now, the program simply loops through the 6 sensor inputs turning on fans or heaters accordingly, or, shuts the whole thing down incase of excessive temperature. High voltage is driven through some sort of transistor array(I really need help with this) to corresponding SSR's which control the heaters/fans.· This seemed so simple and inexpensive using the Stamp that I·assumed I must be in over my head and not seeing the obvious.· Ok, let me hav it and my thanks to anybody responding to this.tongue.gif··

Comments

  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2005-04-12 01:39
    Fred,

    ·· If the box was sealed·(even if it's not), you could use something called a Peltier Junction.· These get hot on one side and cold on the other when current is run through them.· Basically you could have a couple of these setup at both ends of the box (Maybe 4 total).· When you want cold you activate the cold one, when you want heat you activate the heat one.· They do draw some serious current, but I guess no more than a heating element, and these do double duty.

    ·· As for the DS1620, I don't know how exposed it will be, but the same could be said for the other circuitry.· If exposed to the elements inside, your boards could suffer corrosion.



    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
  • Fred S.Fred S. Posts: 4
    edited 2005-04-12 02:23
    Sorry, I didn't explain that the box is about 30 cu.ft.(uninsulated) and the cost of driving any active cooling is prohibitive. Passive cooling will be adaquate as it doesn't get terrifically hot here. But, boy, it sure does get cold. -30F is not uncommon so heat is the big concern. Yeah, humidity/corrosion is a problem but not really fatal although it does contribute to higher maintenance costs on PCB's, etc. The Box, "should have been" insulated making active cooling and humididty control possible. Thanx for your input, Fred
  • bobledouxbobledoux Posts: 187
    edited 2005-04-12 13:15
    I use a DS18B20 that comes in the TO92-style transistor package. I shrink wrap it to protect it from the elements. The wiring can be run to a sealed case. The shrink wrap slows down the response to changing temperature but this should not be a consideration in you application.
  • Chris SavageChris Savage Parallax Engineering Posts: 14,406
    edited 2005-04-12 15:07
    Fred,

    ·· Yeah that's a little larger of a "box" that I was thinking...Perhaps you should consider central Heat/Air?· smilewinkgrin.gif

    ▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
    Chris Savage
    Parallax Tech Support
    csavage@parallax.com
  • allanlane5allanlane5 Posts: 3,815
    edited 2005-04-12 15:55
    I would have thought a 'typical' form of heat for such a device would be a simple light bulb -- 25 watts or so. 30 cubic feet is equivalent to a cube 3' on a side, right?

    And how critical is the temperature over all the box? I would have assumed for a system like that a single thermostat controlling a single light bulb would give sufficient temperature control to keep things from freezing. You can do that with a BS2 and a single temperature sensor (okay, 4 sensor's if you put them in the corners of the box) and a single heating element of some description.

    How are you powering this beast? Keeping the temperature up in -30 degree weather, with no insulation, may take quite a lot of power.
  • Fred S.Fred S. Posts: 4
    edited 2005-04-12 15:56
    Bobledoux, Ahh Yes, the DS18B20 in the TO-92 package is a far better solution and the shrink wrap idea is killer. Thank you!!.· If I could impose again on you to direct me to some sample code, if you know of any, to drive that sensor I would apreciate it.···· Thanx, Fred
  • bobledouxbobledoux Posts: 187
    edited 2005-04-13 13:42
    The sensor is the DS18S20, not the DS18B20.

    Try the Stamp application notes here:

    http://www.parallax.com/html_pages/downloads/basicstamps/documentation_basic_stamp.asp

    The earlier DS1620 was used in example 22.

    Here is the process:

    This should also apply to the DS18S20, but not the DS18B20.
    The data line is bi-directional.
    The sequence to read a temperature between 0 and 125C is the following:
    Send reset pulse and wait for DS1820 to return presence pulse
    Send 0xCC to tell DS1820 to skip rom
    Send 0x44 to tell DS 1820 to read and store temperature.
    Wait 500 mseconds for temperature to be read by the DS1820.
    Send reset pulse and wait for DS1820 to return presence pulse
    Send 0xCC to tell DS1820 to skip rom
    Send 0xBE to read temperature from scratchpad memory in DS1820.
    Read the temperature, one byte is enough above 0C.
    Send reset pulse.

    Reset pulse is a pulse at least 480 microseconds.
Sign In or Register to comment.