OK I have now reconfigured my system so that all the I/O modules are individually powered rather than over the 1- wire cabling, which I am hoping will improve reliability.  Also all sensors are powered.  Now to get back to the other issues.

How do I set the resolution?  Looking at the DS18B20 manual it says that it is done via the scratchpad, but I have no idea how to do that.  My code is all python, so I guess I can write the necessary value to the scratchpad at startup, but what do I write?  The DS18B20 manual on GitHub does not mention the scratchpad.

Thanks

Mick

On 19/02/2019 17:38, Jan Kandziora wrote:
Am 19.02.19 um 14:35 schrieb Mick Sulley:
The failure happened for about 10-20 minutes, reading about every 10
seconds or so, then it recovered and is reading fine again.

All devices are powered.

I could change my code so that it reads fasttemp and if that is 85 it
reads through the others to try to find a good read.  Is that a sensible
thing to do?

What I recommend to do for preparation is:

* power all sensors
* set the sensor EEPROM to 9 bit default resolution.

Then, the readout thread is as follows:

1. trigger a 12-bit resolution conversion on each sensor for initialization.
2. write soemthing to /simultaneous/temperature to trigger all
temperature conversions at the same time.
3. wait a second
4. read /uncached/<sensorid>/latesttemp of each sensor
5. If the result for a sensor is not 85°C, store and go to 2.
6. 85°C. Check the resolution. If it is still 12 bit, that's a valid
reading. Store and go to 2.
7. Power-on-reset. Store an error. Trigger a 12-bit resolution
conversion for that sensor and go to 2.


Kind regards

        Jan


_______________________________________________
Owfs-developers mailing list
Owfs-developers@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/owfs-developers


_______________________________________________
Owfs-developers mailing list
Owfs-developers@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/owfs-developers

Reply via email to