Shop OBEX P1 Docs P2 Docs Learn Events
which digital thermometer to use? — Parallax Forums

which digital thermometer to use?

OakGraphicsOakGraphics Posts: 202
edited 2009-11-18 00:54 in Accessories
I have been looking at the DS series digital thermometers, and I am trying to find an easy - multi thermo solution with the least amount of pins.
I see the DS1820 is a 1-wire, and it looks the simplest to set up. I essentially need 6 or so temps monitored for motor and power supply thermal shutdown circuits.
I am using a propeller for this, and plan on showing the temps on an lcd / tv screen or maybe 7-segment led readouts.

Any suggestions?

Each thermo will be about 3 to 6 feet away from the 'base', and first thought was in a star topography, but have read in the ds1820 that it might not be the best way. I could string them in parallel, and in bridge mode (drop downs of 3 feet from parallel run). I need to monitor temperatures in upwards of 125c for stepper motors.



Thanks in advance,
Daniel

Comments

  • ElectricAyeElectricAye Posts: 4,561
    edited 2009-11-14 18:45
    I've used DS18B20's for 6 foot lengths, with each sensor having its own 6 ft. unshielded cable reaching back to a "plug box" made of molex connectors, with the plug box being about 2 feet from the Propeller, and I haven't detected any problems so far.

    I haven't checked lately to see if it was updated but the 1-wire object, SpinOneWire, needed a slight mod to do negative temps.

    My .02 cents worth.

    smile.gif
  • OakGraphicsOakGraphics Posts: 202
    edited 2009-11-14 23:34
    ElectricAye said...
    I've used DS18B20's for 6 foot lengths, with each sensor having its own 6 ft. unshielded cable reaching back to a "plug box" made of molex connectors, with the plug box being about 2 feet from the Propeller, and I haven't detected any problems so far.

    I haven't checked lately to see if it was updated but the 1-wire object, SpinOneWire, needed a slight mod to do negative temps.

    My .02 cents worth.

    smile.gif

    Thats sounds good. I would pretty much have the same rig so I will go that route. I don't expect to be in negative temps while operating it, but would still like to know the mod if you had it lying around, or I will search the forums to see what the fix was.

    Sounds fun!
  • ElectricAyeElectricAye Posts: 4,561
    edited 2009-11-17 21:10
    I said...
    ....
    I haven't checked lately to see if it was updated but the 1-wire object, SpinOneWire, needed a slight mod to do negative temps. ....
    Here's the mod.· It's just the insertion of one line that reads:
    temperature := ~~temperature  {Modified 9 Dec 2008 to provide negative temps.} 
    

    PRI ReadTemperature(ThermalAddress) | temperature, degC, degF, WatchDogDS18b20
      {Read the temperature from a DS18B20 sensor.}
      {Waits up to 10 seconds for the sensor to provide data.}
      ow.reset
      ow.writeByte(ow#MATCH_ROM)
      ow.writeAddress(ThermalAddress)
      ow.writeByte(ow#CONVERT_T)
      {Reset WatchDogDS18b20 to zero...}
      WatchDogDS18b20 := 0
      repeat {Repeat until the called sensor tells us it is ready to give data...}
        waitcnt(clkfreq/100 + cnt)
        {Increment the watch dog on every pass and if the wait for a sensor exceeds
          about 1000 iterations, then there is a problem, therefore return to main program.}
        WatchDogDS18b20 := (WatchDogDS18b20 + 1)
          IF WatchDogDS18b20 > 1000 {About 10 seconds.}
            {Consider lighting up a warning LED.}
             return
        IF ow.readBits(1) 'The sensor is ready to provide data.
          ow.reset 'Say okay and prep the data line.
          ow.writeByte(ow#MATCH_ROM) 'Tell the sensor you want to match a ROM
          ow.writeAddress(ThermalAddress) 'Send out the ROM to match.
          ow.writeByte(ow#READ_SCRATCHPAD) 'Open up the sensor's scratchpad.
          temperature := ow.readBits(16) 'Read the data.
          temperature := ~~temperature  {Modified 9 Dec 2008 to provide negative temps.}  
          ' Convert from fixed point to floating point
          degC := f.FDiv(f.FFloat(temperature), 16.0)
          ' Convert Celsius to Fahrenheit
          degF := f.FAdd(f.FMul(degC, 1.8), 32.0)
          result := degF  {The result is the temperature in degrees F.}
          return 'Return to the main program...
    {*** End of method ReadTemperature ***}
    
  • OakGraphicsOakGraphics Posts: 202
    edited 2009-11-18 00:54
    ElectricAye said...

    Here's the mod. It's just the insertion of one line that reads:

    cool beans - literally! smile.gif Okay I will try it out when I get the thermos. I am ordering them from ebay. 10 of them for 16$.
Sign In or Register to comment.