Overcoming problems when using multiple DS18B20 temperature sensors on a long wire one wire network.

แชร์
ฝัง
  • เผยแพร่เมื่อ 13 ม.ค. 2025

ความคิดเห็น • 9

  • @mikefochtman7164
    @mikefochtman7164 2 ปีที่แล้ว +1

    I had some I was using to monitor a GFX heat exchanger and some other 'around the house' items (furnace, incoming water supply, unheated as well as heated spaces). And yeah, I ran into the same issue of accessing by index. But by then I had installed them all, so it took a bit to figure out what the addresses were for each device. But in the end, have to agree, access them by address every time! Thanks for sharing your hard-won experience.

  • @JohnnieNorsworthy
    @JohnnieNorsworthy 2 ปีที่แล้ว +1

    Thank you for this excellent advice. The hours of debugging this you saved benefit everyone. I was just about to install a cluster of these probes all about my house plumbing.

  • @pieandpeas8929
    @pieandpeas8929 ปีที่แล้ว

    I have this exact same issue for nearly the exact same application. I intended to use six waterproof DS18B20 sensors to an Arduino Uno using a star arrangement to control a solar differential system to determine optimal pump operation, so I have the sensors at various places along the pipework. The project works faultlessly with any of four or less sensors, but add a fifth or sixth and I get nothing, or -127C. They all can work individually, so I know there is no fault within each device and they also work in any order of four. However, add more, I get the problems. I had resigned myself to only having four but just last night I started looking at using the ROM device addresses issue instead of index , but thought I would check here first. Thanks jtandhz for this posting and I will return once the changes have been made.

    • @pieandpeas8929
      @pieandpeas8929 ปีที่แล้ว

      Well, I did try this, but without success. I get five of the six sensors working, but adding the sixth reintroduced the errors I was having. What did work, was changing the resistor from the 4k7 to a 1k8. Worked straight away. I will keep monitoring the sensors by address as it will make it easier to debug if things went wrong in future. Thanks for your input.

  • @maciejlegowicz5834
    @maciejlegowicz5834 ปีที่แล้ว

    This is quite interesting. Can you share what pull-up resistor did you use? In our project we have in total 13 sensors with similar topography. I managed, using variable resistors board establish that we needed 2.2KOhm between +5v and data line, however, after unplugging USB power from arduino mega it stops working. Would external power just for sensors help?
    Cheers

    • @jtandhz
      @jtandhz  ปีที่แล้ว +1

      I used a single 4.7K resistor between Vc and the signal on the buss that all my sensors are plugged into. DS18b20 only uses 1ma per sensor and a Megga can supply 40ma per pin so you should not need an external source. Have you looked into your sensors and found if they are counterfeit? Counterfeit sensors may be out of specs of OEM so that could be one possibility.

  • @ThisRandomUsername
    @ThisRandomUsername 4 ปีที่แล้ว

    That is interesting. I got some 18B20s a while ago from Aliexpress, so I'm now expecting them to be fakes. I'll see if I can hook one up later to see if it gets picked up as fake.

    • @jtandhz
      @jtandhz  4 ปีที่แล้ว +1

      The "fakes" still work but I'm wondering if they were what was limiting my array. I would like to see a performance comparison of "fakes" vs. "genuine" 18B20s in a long wire network system.

    • @ThisRandomUsername
      @ThisRandomUsername 4 ปีที่แล้ว

      @@jtandhz Interesting. Yeah, I think setting up an oscilloscope to check the signalling would be an idea. If I find mine are fakes, I might do that, as I'm going working on a in-roof temperature sensor for a fan.
      Edit: I didn't think about this before, but have you tried terminating each end of the run with a pull-up resistor so they parallel up to the 1-wire bus pull-up resistance (I think it's 2k2) like they do on CAN bus and RS-485 systems? It might help with reflections or the resistance in the line playing as much of a role.