summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: 3b5316b)
raw | patch | inline | side by side (parent: 3b5316b)
author | Tomas <tomasamot@gmail.com> | |
Thu, 7 Aug 2014 20:16:08 +0000 (22:16 +0200) | ||
committer | Tomas <tomasamot@gmail.com> | |
Thu, 7 Aug 2014 20:16:08 +0000 (22:16 +0200) |
src/barometer.c | patch | blob | history |
diff --git a/src/barometer.c b/src/barometer.c
index 0fa9a33e551f0a558b0eb4996a14d7d45fd120c7..2bfd51e019d817487a8aefce7503c290ac54c59f 100644 (file)
--- a/src/barometer.c
+++ b/src/barometer.c
double temp = 0.0;
int result = 0;
- DEBUG ("barometer: abs_to_mean_sea_level_pressure: absPressure = %lf, method = %d",
- abs_pressure,
- config_normalize);
-
if (config_normalize >= MSLP_DEU_WETT)
{
result = get_reference_temperature(&temp);
case MSLP_INTERNATIONAL:
mean = abs_pressure / \
- pow(1.0 - 0.0065*config_altitude/288.15, 0.0065*0.0289644/(8.31447*0.0065));
+ pow(1.0 - 0.0065*config_altitude/288.15, 9.80665*0.0289644/(8.31447*0.0065));
break;
case MSLP_DEU_WETT:
break;
}
+ DEBUG ("barometer: abs_to_mean_sea_level_pressure: absPressure = %lf hPa, method = %d, meanPressure = %lf hPa",
+ abs_pressure,
+ config_normalize,
+ mean);
+
return mean;
}