8

I have a RasPi model B rev. 2.0 and two DS18B20 1-wire temperature sensors and they are working individually fine. I know I should be able to connect multiple 1-wire sensors in parallel but I can't detect any sensors when connecting more than one at the same time (to the same GPIO pin). Individually I can detect each sensor.

This is one of the sensors and the only one connected: Sensor 1 works OK

This is the other and the only one connected: Sensor 2 works OK

When I connect both in parallel it shows nothing under /sys/bus/w1/devices/: Does not work

I have connected my sensors to pin 7 (GPIO 7) which is the dedicated 1-wire pin.

As they work individually, I am pretty sure I am connecting it correctly:

  • Red to 3.3V
  • Yellow to GND
  • Black to GPIO 7

And when having multiple sensors I am just connecting both reds, both yellows and both blacks in to a terminal strip.

Is this my sensors being faulty or am I doing something wrong?

UPDATE #1, 2014-Dec-18, 22:42

I am using the built-in pull-up resistor in my Python programming and it has been suggested by @joan that I should try with a real 4.7K Ohm resistor instead as the built-in may be too weak to support multiple sensors.

Beauvais
  • 285
  • 5
  • 11

1 Answers1

2

On the DS18B20's that I've used, the yellow wire goes to the GPIO pin and black connects to the ground pin. Also, as Joan suggests, use a 4k7 resistor between 3V3 and the GPIO pin. (Only one resistor, regardless of the number of DS18B20's.)

See https://learn.adafruit.com/adafruits-raspberry-pi-lesson-11-ds18b20-temperature-sensing for more info.

goldilocks
  • 60,325
  • 17
  • 117
  • 234
Jim
  • 21
  • 2