New System Design: Distance between DS18B20s, Data Logging


Am designing a new project and want to collect data from a number of sensors, then log it to analyze patterns.

Would be grateful if I can get some design review / critique on a couple things.

  1. Using an Arduino Mega1280
  2. Collecting temperature, time, and unique sensor ID from DS18B20 sensors
  3. Twelve (12) DS18B20s will be clustered in one area
  4. Approximately 33 metres away, a second group of four (4) DS18B20 sensors.
  5. Connecting the two groups via Cat6e underground cable.
  • Where should or can the Arduino be located?
  • Can it be located at either end without loss in reliability or complicating setup?
  • We are thinking about using Cat 6 underground cable to 'daisy chain' all sixteen (16) sensors together since much of this will be outdoor and the two groups of sensors will be separated by an outdoor distance of roughly 30 metres.


Any hints? recommendations? or flat out problems with this?

Is this possible or highly probable?

Am grateful for suggestions or highlights of anything that appears out of sorts (won't work.)

Thank you for your input and help.


segu's picture

Re: New System Design: Distance between DS18B20s, Data Logging

 Hi Clinton

I do not know if the next will help you. Since 2008 I have four wired DS1822  24/7/365 two indoors and two outdoors about 4 meters between the two indoors and 4 meters between the two outdoors and about 12 meters between the indoor and outdoor and about 3 meters to the Atmega 168. Three wires (red,black,yellow to know wich is wich) twisted by hand (half day twisting wires!!) and powered by 5 V. Tried parasitic power but do not like/trust. Still working now and hope working "in vitam aeterna".

In 2007 the DS1822 was a cheap DS18S20 that was a cheap DS18B20. I have tried all. Tried to 12 DS1822 in about 20 meters (and DS18S20 and DS18B20). Keep in mind it takes about a second to have the value from one DS18x2x. I do not remember exactly the Arduino but tried Atmega 8, Atmega 88 and Atmega 168 and the amount of RAM was little. Also keep in mind each DS18xx has one ID and that can complicate things. You must pair ID and position in the chain if you need to know the temperature from a particular place. Also keep in mind the CAT cable is 4 pairs of two twisted pairs. Try data and ground in one pair and power in another. Also read carefully the datasheet and friend Google if you use parasitic power in 30 meters of #24 wire. All activities in the wire are square waves.

Hope this help a little and good luck with all your project.



SunBeam's picture

Re: New System Design: Distance between DS18B20s, Data Logging


Thank you for your quick reply and your experience. We are planning on separating out the lines and twisting power with a ground on one twisted pair and data with another ground in a second twisted pair.

Hope that this drives things further and cleaner.

Will let you know when there are more questions.

Thanks again,



fluppie007's picture

Re: New System Design: Distance between DS18B20s, Data Logging

SunBeam, are you still on this project? I'm also considering logging multiple DS18S20 sensor's with a eMon TX.

greenhph's picture

Re: New System Design: Distance between DS18B20s, Data Logging

Twisting Wires :    I have used this for 20 metres plus - it only takes minutes.

Cut about 5% over length - since twisting shortens the final product.

Group and tape the ends together - fix one end group to "ground" ( or a friend holding it) and put the other end in the chuck of a hand held electric drill (preferably one with controllable speed)      Hold tightly and tension slightly.

Then - Whizzo !





alco's picture

Re: New System Design: Distance between DS18B20s, Data Logging

my emontx (well..actual a nanodeRF with emontx look-a-like shield from martin) is holding 3x DS18B20 sensors (not 18S!) for reporting the systemtemp, water temp and basement temp. working great :)

sourcecode is on my github ( and some info on my website
I'm working out a few blog postings on this moment so there will be more info about my systems soon there.

Comment viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.