pvvx / ATC_MiThermometer

Custom firmware for the Xiaomi Thermometers and Telink Flasher
https://github.com/pvvx/pvvx.github.io/tree/master/ATC_MiThermometer
Other
2.9k stars 202 forks source link

Offset and Slope factor issue #542

Open octane321 opened 2 weeks ago

octane321 commented 2 weeks ago

hi there, and first of all many thanks to your work - i love it!

But i´m struggling getting 10 sensors equalized in temp and humidity reading. Trying to use only offset, only slope or both combined gives me worst equalized sensors than before.. So i dived a bit into the calculations and found out, that "calibration" with offset and slope is really annoying and need a high effort if you want to do it the right way.

My personal opinion for temp. "normalization" and i´m still on research (same again for humidity):

Step A: Correct deviation on linear behavior

Result All sensors should have quiet the same changes when temp and hum changes But the measured temp. are still all different

Step B: Correct the offset

Request / Idea It would be much more easier to take only a high and low measurement per sensor and put that into a calibrate linear function with a Set Point value for low and high value Do you see any chance getting this implemented into the firmware?

Thanks in advance and have a great time!

octane321 commented 2 weeks ago

should be calculated like this:

Tcali = ((T_high_meas - T_low) / (T_high - T_low)) x + (T_high_meas - (((T_high_meas - T_low_meas) / (T_high - T_high_meas)) T_high))