DS18B20 not working with more than two sensors switched parallel

I’m a complete beginner. I’ve got some basic knowledge back then from school, but well, it didn’t keep me from installing DS18B20 in every room of my flat and wanting to read them via my Arduino Ethernet. :wink: I’ve been using the usual tutorials to set this up. Right now, I have a shielded cord containing two wires (2x0.14 mm^2). I’m using the shield as GND and the two wires as +5V and I/O.

It looks basically like this:
<breadboard with 4.7k pull up resistore from +5V to I/O line>------10 meters -----------5 meters-------

It’s working well, that way, BUT if I add another DS18B20 directly to the rails of my bread board and do a rescan (added such a function to my code), no sensors can be found at all. Also tried it with a different sensor to rule out defective parts.

I bet there’s a very stupid flaw somewhere, but can’t find it. Any ideas? :slight_smile:

Best regards

I bet there’s a very stupid flaw somewhere

Very likely.

I suspect the 4k7 is too big for that amount of cable. I’m sure there has been discussion on this and a 2k2 is more appropriate.

Thanks a lot for the reply. After fiddling for a bit longer with the forum search, I found this interesting discussion: http://forum.arduino.cc/index.php/topic,20574.0.html

My bad.... should have done that in the first place. ;) I will try various approaches, tonight.

Best regards Rajan


Don't give up so quickly !!! I used 8 x DS18B20 and all works fine. My longest stretch of cable between arduino and sensor is 22 meters. My program checking and count the CRC error, really rarely appear.

My way is: - cable : You need to have very good cable, I use the cable manufacturer of "Seven" cat 5e FTP outdoors - resistor changed 4.7k to 3.3K - added the ceramic capacitor on the sensor side 30pF(connected to plus and minus) - the sensor are connected to the following wiring (data - orange, plus - white/orange, minus - green)

And all should be works.

Show your code.