Xinyuan-LilyGO / LilyGo-HiGrow

https://pt.aliexpress.com/item/32815782900.html
120 stars 51 forks source link

HiGrow accuracy or missing calibration #51

Closed ro85ac closed 1 year ago

ro85ac commented 2 years ago

I have 4 HiGrow board and all have the same issue:

As a note: I made the same test with Xiaomi Soil Sensor and the values are correct. https://www.aliexpress.com/item/32848400991.html

IMG_9874 IMG_9876

ro85ac commented 2 years ago

After digging more I found that you calculate the soil moisture using method map from WMath.cpp long map(long x, long in_min, long in_max, long out_min, long out_max)

And the actual code is: map(soil, 0, 4095, 100, 0);

@LilyGO @lewisxhe Why did you send the parameters 0 and 4095 when the actual values read by the sensor are ~1475 (min) and ~3280 (max)?

LilyGO commented 2 years ago

After digging more I found that you calculate the soil moisture using method map from WMath.cpp long map(long x, long in_min, long in_max, long out_min, long out_max)

And the actual code is: map(soil, 0, 4095, 100, 0);

@LilyGO @lewisxhe Why did you send the parameters 0 and 4095 when the actual values read by the sensor are ~1475 (min) and ~3280 (max)?

Because the soil medium is different, it is impossible to do a unified calibration.