DS18B20 + Protective Sleeve


I have DS18B20 temperature sensors and protective sleeves (40x6 mm) for the sensor. (I want to measure water temperature.)

Just putting the sensors in the sleeves seems kind of unprofessional (especially air between wall and sensor is an insulator)

Any recommendations with what sort of material to fill the protectice sleeves for a good heat transfer?

Thanks in advance!


Sure. Try the heat transfer compound used between transistors and heat sinks.

In theory a highly conducting compound would be best but unless you are trying to get super fast response then any typical solid filler should work. I wouldn't use expandable urethane foam.

If you tube is closed end you could fill it with hot melt by shredding it and dropping hte pieces into your tube.
Heat the tube until the hot melt melts. Then push the sensor into the hot melt.

RTV is OK as well but its harder to get it into your tube, unless the tube is open. If the tube is open you could start by forcing some RTV into the tube, introduce the sensor then force some more RTV into the tube. But this can get messy.

You can get DS18B20 already in a protective housing, on ebay.

They seem waterproof, but they are not.

1 Like

But you can improve the sealing I reckon - silicone sealant and heat-shrink around it perhaps? These units are metal tubes so have fairly good thermal time-constant, but most of them are likely to be fake DS18B20's alas...

I don't know where to get blind-end stainless tubes like these use, but if you find
a source it would be easy to pack with thermal compound (non-electrically conductive, note), and then arrange for a seal at the end.

Hot melt glue lined heat-shrink should be used instead of normal heat-shrink.
And the tube should be potted (full) with some water resistant thermal compound.
Time to take one apart.

A possible issue with hot-melt glue is it doesn't bond well to metal surfaces as its between a wax and polythene in composition. And of course it melts at elevated
temperature(*), which is often a show-stopper for a temperature sensor.

(*) For instance I've had some melt in a car on a sunny day.

If they are fakes, probably, they will be cheap enough to pull the old DS out and just reuse the SS tube with a real DS.
Stainless tube is readily available, but cutting it and then sealing one end is the difficult bit.
Might be worth searching for stainless steel thermometer pockets.
Some standard size tubing like 8-mm OD, can come with a range of fittings like end stops.
You can also find capillary (solder) end stops for SS.
You can glue them or use a SS flux to solder.
Someone in China must make the original tubes/pockets.
As others said, adhesive lined heat shrink is pretty effective.
If the application was very critical like stopping heating tanks going over temperature, I'm not sure I would fully trust a made up sensor.

Make a thermowell from a length of copper tube , crimped and soldered at one end . Drop the sensor down that .
If it’s vertical downwards , put a cc of silicon oil in it to help transfer the heat .

Google thermowell for inspiration

hello prankenandi-andré, I usually speak in french,

all the indications given to you are good. If the water you want to measure is a large volume (pool, tank or aquarium) whose temperature does not change quickly (with a large thermal inertia), you can use the sensor in the sleeve as you intended, it is not unprofessional! The air layer between the inner wall of the sleeve and the sensor will only cause a delay of about 30...45 seconds in the measurement, which will not be noticeable if you do continuous measurements, for example every 2 minutes.
If you fill the sleeve with a compound as indicated, you will reduce this response time, depending on the thermal conductivity of the compound.
Seal the joint between the sleeve and the electric cable with a heat-shrinkable sleeve or glue, so that water does not get inside.

If the temperature difference between the volume of water to be measured and the ambient air temperature is more than 5...10°C, the most important point to respect is this: a length of sensor extension cable of at least 20... 30 cm must be in the environment to be measured (i.e. in the water): if you don't do this, if your sensor is only immersed for the length of the sleeve or a little more, the thermal conductivity of the cable which is out of the water will cause the air temperature to modify the measurement of the water temperature.

If the water whose temperature you want to measure is a small and rapidly changing volume (a trickle of water), then yes, you will need a thin sleeve that is a good thermal conductor and filled with a compound that is also a good thermal conductor.

This sounds quite fanciful - even if the DS18B20 was a gas capillary sensor. I don't think it is.

J'ai acheté, soudé, vendu ou installé plus de 3.000 de ces capteurs Dallas, je dois savoir ce que je dis :grinning:

Vraiment? Je soumets qu’il seulement menas vous avez fait la même erreur 3000 fois.

You must be right. By the way, if your sleeve is 40 mm long, immerse only 20 mm in water, you will make a very good measurement ! rigolo

If you are referring to the 6mm stainless steel tubes, a 10mm intrusion into water is fine.

All right. My previous post was tongue-in-cheek; I'm used to working with pros, so I wasn't paying attention to the context of this discussion. Consider the first figure, regardless of the temperatures listed. This could be your aquarium: room temperature 70°F, aquarium temperature 70°F, everything in thermal equilibrium. To measure the temperature of your aquarium, you can immerse the 10 mm probe, good thing; but you can also not bother to install the probe inside, and pull a cable through the room: put your probe anywhere in the air of the room, it will tell you the temperature of the aquarium.


Look at what I wrote: "when the temperature difference exceeds about 10°C".
Professional cooks have to cool down very quickly (in special refrigerators) the food coming out of the oven, before putting it on hold at 40°F, for the future meal. In the professional context, the probe would not measure the right temperature, because at the place of the red circle, a thermal flow goes from the probe (hot) to the external cable (cold), and its copper conductors very good thermal conductors: thermal flow, so temperature difference, so the sensor is marred by a temperature shift (maybe 45°F) with respect to the food to be measured, because the copper electrical conductors carry this temperature to the core of the chip. It takes (at least) twice the length of the sleeve immersed in the mass to be measured, to reduce this offset.

Same thing in the other direction of temperature differences. In order to use the probes properly, I specify that they should have 20..30 cm of cable length in the cold environment.

33% of the users don't care,
33% install the probe flush to the inner wall (and come back to tell me that the probe gives false measurements),
33% will put about 15..20 cm of cable length in the cold room which is the minimum, that's why I say 30cm. If I had said 20cm, they would have put 10cm, which is not enough.

Technical work requires taking into account the psychological behavior of users...


Mais pour votre aquarium, vous avez raison, vous pouvez utiliser la sonde n'importe comment, elle donnera toujours une mesure plus ou moins approximative de la température de l'eau. Même hors de l'aquarium !

No you're not. The pros would tell you about thermowells whereby both the sensor and the cables stay dry - which is something you might learn about from the amateurs and children on this forum.

Have to agree - the “sheathed waterproof DS18B20 “ are simply the chip inside a sheath filled with silicon sealant and a piece of shrink fit around the cable exit - they are not workable for long term use in damp/wet conditions.
A thermowell is the solution, universally used in industry to measure gas/liquid temperatures. Easily made for “amateur “ use if you don’t want to buy one.

If you want really accurate precision best quality water temperature ( I’m pretty sure you don’t) you need stirred water anyway , insulated tank walls , lid , some money , etc and not ask on a hobby forum. ( have a look at water baths )

c'est pas vrai ! ils sont aussi cons ici qu'ailleurs...

And likely saner too. I have looked for a commercial one for DS18B20. I found they are either ridiculously expensive or unavailable altogether, I can't remember which. I needed them for mains pressure copper pipework, 2MPa. Not much point in talking about running wet cable through glands here... I made a couple of thermowells using a drilled brass plug in a T fitting. Only one went into service, as I found that simply keeping the sensor against the pipe under a foam sleeve was just as effective, even if not so professional. Arduino's loop is 1 sec. I used "Arctic Cooler" heat sink compound, but I'm now sure that acid-free silicon goo would be just as good. The sort of stuff used for sticking mirrors on tiles. I understand that there was nothing at all special about 3M's goo used in solar water heaters - except the eye-watering price.

For drain temperature at atmospheric, I just have the sensor in a rubber bung in a T with poly piping. A 10mm protrusion is just fine. Everything was checked against a wet Brannan mercury-in-glass 0-50 thermometer, which says quite a lot for the DS18B20.

FWIW, I believe reply #9 says the people here are as stupid as they are everywhere else.