DS18B20 "splitter"

Feels like a simple question, but I can’t find anything from Googling.

How do I share a DBS18B20 temperature sensor with multiple things wanting to read the value?

Doesn’t feel like anything complex, but might need a bit of electronics…

I’m in the midst of doing some upgrades to my heating system; a mixergy tank is going in, and swapping from a Tado based boiler control system to a Honeywell EvoHome.

While the DS18B20 themselves are cheap, you can’t always fit more than one in a hole for a probe, so I’d be curious to be able to read the value from more than one device…

Obviously SWE2a Sensor Connection Module, Sheepwalk Electronics can do multiple DS18B20 to one “reader”… But I want multiple “readers” to one DS18B20…

Your problem will be preventing two devices trying to talk to the sensor at the same time.

If I were trying to solve the problem, I’d prefer to try to read the sensor with one device and push the data to all the others at a software level.

If you must do it with hardware, you will need an intelligent switch that will respond to some signal from each device - say it powers the 1-wire bus, and your intelligent switch then routes the bus and the power to the sensor, and maintains the connection for long enough for the sensor to power up, read and convert the temperature and send the reply. Depending on the accuracy the device asks for, this could be quite a long time - it can take up to 750 ms just to convert the temperature, then it has to be asked to send it, which depends on the enquiring device. Sending the data may take about 20 ms from memory. Only then should your intelligent switch be able to accept a “request” from a different device.

This is what two sensors responding looks like. First, both are asked to “convert” the temperature, then the first is asked for the result and responds, followed by the second. (The blue trace was to trigger the 'scope.)

I think this must have been 11-bits resolution, taking 375 ms to ‘convert’ the temperature.

So yes, the question was simple. I think the solution is anything but simple.

Thanks for the reply.

Yeah, unfortunately easier said than done when devices are closed source etc, can’t be modified in terms of random third party inputs (API or otherwise). So unless there was some other device to take that API input, and then fake it back into the same output as the DS18B20…

… would stand a chance of working. “Frequently” would depend on how rapidly the temperature changed, and again your intelligent recording device would need to recognise the “convert” command - and if there is more than one 1-wire device, decode the address to ensure it only replied when it should, and then when asked for the value, it would report it.
It would need one 1-wire port for the DS18B20, and one for each interrogating device, and it would need to listen on all of those so as to respond in a timely manner, and it might well need to handle several parallel requests for the temperature.

hey @reedy here are some sample libraries to emulate a ds18b20:

you might be able to use this code to do the readings of your single device and output them on 2 slave pins of an arduino

1 Like

A couple of thoughts:

  • I’ve managed to shove 2x DS18B20s inside a thermostat tube designed for one - it’s all about sneaking the pins of the deeper chip through the dent in the shallower one.
  • If you can’t get the pins to go past the dent, can you use the ceramic insulated wire from headphones or motor windings to connect to the chip? They don’t need very much power, and you can then connect them to thicker wire once they’re out of the tube.

From what I can tell, Mixergy have a couple of different designs, I believe some have dedicated thermostat tubes, that aren’t used by anything part of the default install. Mine unfortunately doesn’t, so I’ve had to shove it the probe hole currently with the thermal cutout switch (the two metal probes, like more basic cylinder thermostats have). So there’s limited room, then having to route it via the housing, and through it’s cable access/grommets…

Can provide some pictures if people are interested.

Thinner wire could help to some extent, for sure.

Post a picture.

It occurs to me that if it’s a standard fitting, you might be able to find a better housing with a wider tube.