Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

Required fields*

10
  • 2
    Thanks; Do you think that I should rely on I2C to use multiple sensors? Commented Jul 4, 2019 at 6:24
  • 1
    @Sang Inn Woo, Ah I guess you misunderstood my comments on I2C. I said I have bad experience using I2C bus and could not put more than 8 devices on the bus and performance is unstable. So I guessed DS18B20's 1-Wire bus should be as bad. However, I started testing from 1 sensor and adding one by by one. Surprisingly I can add 7 (I have only 7 on hand!) and found everything stable. So I guess there is hope to add to 60! I am using the python3-w1ThermSensor-1.0.5. and I found it easy to setup and test. Commented Jul 4, 2019 at 6:33
  • You might like to read my update, clarifying that I am NOT using I2C. I am still using 1-Wire bus. I can use any GPIO pin. I choose I2C Data pin because it has a built in strong pull up of 1k8. In other words, you can try any other pins. BTW, I don't follow your terminal commands listing 1-Wire devices. Please show me the link for those commands. Thanks. Commented Jul 4, 2019 at 6:44
  • 1
    @ tlfong01 Thank you very much for replying. I am just typing "cd /sys/bus/w1/devices" then "ls" to list DS18B20 sensors that I wired. Is my issue related to powering? In today's trial, when I used 5V 3A USB adapter, I can find four DS18B20 sensors per one bus. However, when I changed USB adapter with 5V 1A, I can find only two sensors. BTW, it would be grealty helpful if you can share details of wiring for DS18B20. Commented Jul 5, 2019 at 13:02
  • 1
    Just as @tlfong01 did, I can now connect 10+ DS18B20 sensors to GPIO 2 or GPIO 3 (which are I2C buses) with stable reading. For GPIO 4, 17, 22, ..., I tried an 1k resister instead of 4.7k for pull-up following the recommendation from @Brick; then I can connect 10+ DS18B20 sensors to those buses. I believe that the problem is now solved with your help. I will try 60 sensors wired to a RPi in early next week and update the post. Commented Jul 17, 2019 at 11:03