Precision laboratory thermostat - need acuracy 0.01 - how to?

Greetings. I need a higher accuracy thermostat, at least 0.01 degrees. The sensors data is updated every second and the heating element is controlled by PWM.
As we can see in the HA climate component manual:

“Supported values are 0.1, 0.5 and 1.0.”

With the same accuracy the data goes into the history.
In the configuration of the device (ESPHome) I specify:

      temperature_step:
        target_temperature: 0.01
        current_temperature: 0.01

But of course this is ignored with frontend. Although in the log output I can see that the values are given with the accuracy I need:

In the interface of the thermostats and in the saved history, the accuracy does not exceed 0.1

What components should I use to get the accuracy I need (0.01) in the interface and in the history graphs?

(We are not talking about the absolute accuracy of the dallas sensors themselves here, their error I can measure with a more accurate thermometer and make corrections. I’m more concerned about hysteresis, which I need to correct for, and that’s why I need higher resolution data.)

Changed the topic to ESPHome, as it looks like you want to implement this functionality within that device rather than in HA.

0.01 accuracy for a temperature is going to be expensive and or something custom. It will most likely be something that’s used in manufacturing and the API will cost money too. It will most likely use some sort of manufacturing standard like Modbus or EthernetIP.

If you go DIY, you can build something like this with a Quartz Thermometer.

Otherwise, whatever sensor you’re using will not have an accuracy of 0.01.

As a sidebar, my company runs temperature sensors in a ‘lab like’ environment and we do not deal with temperatures that have an accuracy of 0.01. It’s largely an unrealistic goal and it serves very little purpose. Most of the sensors that we deal with have an accuracy of 0.1.

If you made a DIY sensor from one of the cheap chips in most DIY projects, you are not achieving an accuracy of 0.01. Your significant figures simply show you values out to 0.01. Not only that, but your sensors most likely don’t have a resolution of 0.01. You’ll probably start to notice that they will have a much larger resolution. I.e. the sensor will jump between a voltage * a value and it will be impossible for the sensor to reach values between those 2 numbers.


As another sidebar, I used to work at a company that spent millions on temperature controlled rooms with highly accurate temperature sensors. If your temperature sensor cannot pick up the difference between 2 people inside the room and 0 people in the room, then your sensor is not accurate to the levels you think it is. We had specifications on the rooms saying that at most 2 people were allowed in the rooms because the temperature would swing outside the specified range the room was allowed to operate in.

TLDR: You don’t really need 0.01, you just think you do.

5 Likes

Are you sure? I specifically showed a screenshot that ESP provides data with the required accuracy, and it is HA that ignores this accuracy.

No, because you didn’t supply enough information, although you did include the temperature_step as ESPHome config and didn’t mention HA at all. You mention “the manual” but not which section of which manual. You mention needing a “higher accuracy thermostat” without reference to a baseline thermostat. Finally, you supplied a screenshot of a short section of the logs. We can’t see what data is going from ESPHome.

Putting to one side petro’s wise counsel on accuracy, are you seeing the sensor outputs in HA to 2dp? What and where is the thermostat that is showing 1dp “only”?

If you can get the sensors into HA with 2dp precision, you can easily create an automation that will switch your heater on and off at appropriate temperature readings.

If you really want 0.01 precision on temperature, in your ESPHome config make a sensor with that precision. And if you want a target temperature, make a number with that precision. The built-in climate entities do not support that level of precision.

1 Like

0.01 degree accuracy will be very expensive.

My wife is a biologist and she tells me that the most critical temperatures in her lab are the incubators. Even there ± 1 degree is normal.

The BME280 sensor is the best sensor available in the DIY marketplace. It has a temperature resolution of 0.01°C, but the accuracy is ±1.0°C.

1 Like

Yep. We have temperature controlled automation lines that are clean rooms (FDA bs), we use ±1 ºC which is ±1.8 ºF.

Our experiments refer to the dependence of embryo evolution in the egg on the incubation temperature. Yes, so far it is a DIY level, so cheap dallas sensors are used, their claimed resolution is 0.0625°C at 12 bits. I realize that they have certain errors, they are described in the documentation. However, correction of these errors is impossible if the data received in RF is truncated to one decimal place. All I want to see on the graphs are more accurate values, including fluctuations.
Because the system has a certain inertia and we want to compensate for hysteresis, to do this we need to see the data as accurately and quickly as possible to predict the onset of changes.

Of course, maintaining the temperature in the volume of the room with such accuracy is a task that is close to impossible. But not in the small volume of an insulated incubator

Their accuracy is 0.5.

I think you’re confusing Accuracy, Precision, and Resolution.

Accuracy is how close the number is to the actual value.

Resolution is how much change is required before the sensor will show a different value.

Precision (in metrology) is how precise the value is by using sampling.

Precision in software is the number of significant figures.

So right now, all you’re doing is changing significant figures. That does not mean your result is more accurate or more precise.

1 Like

Perhaps accuracy in the sense of deviation from the reference true temperature can be compensated by calibrating the sensor, if I understand it correctly. Accuracy in terms of resolution is a direct characteristic of the sensor, and it is declared by the manufacturer in the datasheet.
I realized that we won’t get far with these sensors, thanks for detailed answers. =)

They stated resolution (or what you quoted is resolution), not accuracy. The stated accuracy on Dallas sensors is 0.5. That means the result you get from your sensor after calibration can be off by as much as 0.5 degrees.

Going off-topic

Even though we are in the U.S., because of my wife’s lab background, we tend to use ºC at home. Also, metric measurements. It just makes so much more sense than “imperial”.

Even in woodworking. What is half of 3 9/16 inches, or what is half of 90cm? (Even “standard” board sizes are just weird. A “2X4” stud is actually 1.5 inches by 3.5 inches.)

I’ve tried using celsius and I have to convert it each time. I have a temp sensor sitting at my desk in C and I still don’t know what it is. I’m pretty sure this one at my desk isn’t calibrated because it feels colder than 72F.

image

More like translation difficulties here )
It really comes down to the fact that the climate and thermostat components in Home Assistant don’t have the accuracy I need (I realize it’s redundant for household use, but I don’t understand why I can’t enable it by specifying it in the configuration). Whereas elsewhere the sensor reads more accurate than 0.1 degrees:

The precision on climate entities is for the controls in the UI. If you want more precision, move away from the climate entities.

2 Likes

This is solved, but for anyone else wondering why digital sensors seem to have the same decimal readings when incrementing/decrementing values, or why high precision instruments aren’t cheap, here is an explanation.
Discounting ambient radiation, self heating noise, and electrical noise near the ADC within ANY temperature sensor, (less maybe a thermocouple).
Digital systems are not infallible, nor absolute. The resolution of theDS18B20 is configurable (9, 10, 11, or 12 bits), with 12-bit readings the factory default state. This equates to a temperature resolution of 0.5°C, 0.25°C, 0.125°C, or 0.0625°C. The actual nonlinearity accuracy error curve for a typical Dallas DS18B20 sensor is shown at the last page of the datasheet, explaining the claimed +/-0.5C accuracy visually.
Speed, Quality, Price, Choose any two. Dallas temperature sensors are good at the cheap bit, and decent quality, but at 12bit it takes 750mS for a conversion.
The Arduino IDE provides support for ESP MCU’s as well as providing a terminal output AND a plotter to visualise your data from sensors (multiple). Averaging multiple samples will slow result rates, but will have the advantage of filtering out intermittent thermal and digital noise better than just one reading. You will still have the nonlinearity error, but you can reduce the noise factors the more samples you average.

I remember clearly going down that rabbit hole of trying to calibrate diodes as temperature sensors as they are inexpensive and relatively linear. The diodes I was trying to sense for temperature were the same diodes I was trying to use as torches (high power, high output Cree XHP70 LEDS). Special circuit board layout for kelvin connections at the LED chips, then there’s the whole constant current thing to interleave with the power circuits to reliably read the true Vf and then calculate the temperature based on an interpolated calibration curve.

Thanks, @ rustym1n3r, basically I already have the details on the dallas sensor figured out for myself. Still, I was able to provide sufficient system stability within the components’ capabilities. Of course, if the thermostat platform had allowed me to control the values with an accuracy of 0.05 instead of 0.1, I could have achieved a more accurate setting.


Since the system has high inertia, I would have observed sensor noise drifts here, but there really aren’t any. Quite a good result for this budget of electronic components. However, instead of using a mechanical relay, I had to switch to a solid state one, which greatly improved stability by increasing the PWM frequency and thus reducing the response time, as well as setting more accurate modulation ranges for turning the thermostat on and off. The secret is that when the temperature threshold is triggered, I do not cut off the power supply to the heating element, but reduce it by a few percent by experimentally selecting the range.