|
|
|
@ -105,14 +105,14 @@ void AP_Baro_SITL::_timer()
@@ -105,14 +105,14 @@ void AP_Baro_SITL::_timer()
|
|
|
|
|
|
|
|
|
|
AP_Baro::SimpleAtmosphere(sim_alt * 0.001f, sigma, delta, theta); |
|
|
|
|
float p = p0 * delta; |
|
|
|
|
float T = 303.16f * theta - 273.16f; // Assume 30 degrees at sea level - converted to degrees Kelvin
|
|
|
|
|
float T = 303.16f * theta - C_TO_KELVIN; // Assume 30 degrees at sea level - converted to degrees Kelvin
|
|
|
|
|
|
|
|
|
|
temperature_adjustment(p, T); |
|
|
|
|
#else |
|
|
|
|
float rho, delta, theta; |
|
|
|
|
AP_Baro::SimpleUnderWaterAtmosphere(-sim_alt * 0.001f, rho, delta, theta); |
|
|
|
|
float p = p0 * delta; |
|
|
|
|
float T = 303.16f * theta - 273.16f; // Assume 30 degrees at sea level - converted to degrees Kelvin
|
|
|
|
|
float T = 303.16f * theta - C_TO_KELVIN; // Assume 30 degrees at sea level - converted to degrees Kelvin
|
|
|
|
|
#endif |
|
|
|
|
|
|
|
|
|
_recent_press = p; |
|
|
|
|