1
0
Fork 0
mirror of https://github.com/opentx/opentx.git synced 2025-07-25 17:25:13 +03:00

Temperature threshold missing

This commit is contained in:
bsongis 2012-03-19 21:51:52 +00:00
parent 16bf388c30
commit 32b6726968

View file

@ -968,7 +968,7 @@ void menuProcFrsky(uint8_t event)
int16_t barMin = convertTelemValue(source, bmin);
int16_t barMax = convertTelemValue(source, bmax);
if (threshold) {
thresholdX = (uint8_t)((int32_t)100 * (threshold - barMin) / (barMax - barMin));
thresholdX = (uint8_t)(((int32_t)(threshold - barMin) * (int32_t)100) / (barMax - barMin));
if (thresholdX > 100)
thresholdX = 0;
}