Hi,
I've seen some posts about fake DS18B20 sensors floating around. I've bought some sensors for cheap off eBay (Spanish seller). I think I paid around $2-$3 per piece.
I have 6 of these Spanish DS18B20s, and one locally sourced, from a reputable vendor. The Spanish ones "drop off" the 1-wire bus after a while (between 5 minutes up to some hours it seems), and do not show up again. If I disconnect the sensor for a few seconds, it will reappear once reconnected.
The sensors only seem to "drop off" when I actually query them for temperature a few times. They will stay on the bus (at least for a longer time) when I simply query their presence, but don't trigger temperature conversion.
My locally sourced sensor doesn't have the same "disappearing" issues.
I get some CRC errors from both my locally sourced sensor and the Spanish ones - but as mentioned, the issues are not permanent with the locally sourced ones.
Any ideas on how I can tell if the DS18B20s are bad, or if my wiring is simply bad?
At my disposal, I have a logic analyzer, but no scope. What I have seen so far is simply complete silence from the Spanish sensors after their "disappearance" on the bus.
FWIW, I'm using a Raspberry Pi 3, and am thus bit-banging 1-Wire through a GPIO-pin. I've connected 5V VDD to all sensors on my bus (I have a capacity of 5 sensors).