Ambient Pressure and Mean Seal Level Pressure Mismatch

I've been seeing a discrepancy between the watch-calculated mean sea level pressure and true calculations based on the watch-observed ambient pressure.  Based on the actual mean sea level pressure in the area, the value returned from meanSeaLevelPressure appears inaccurate.  Here are more specific details from the simulator using simulated data:

  • Activity.Info.meanSeaLevelPressure returns a value of 102154.98 Pa (This is the seemingly incorrect value, should be 101045 Pa).
  • Activity.Info.ambientPressure returns a value of 87026.59 Pa
  • Activity.Info.altitude returns a value of 1242.70 m
  • SensorHistory.getTemperatureHistory (the last value in the iteration) returns a temperature of 25.5 C

Using that ambient pressure (87026 Pa) and altitude (1242 m), the mean sea level pressure should be 101045 Pa1, or 99957 Pa2 with a Temperature correction.  The returned meanSeaLevelPressure is substantially off using the Garmin API.  There should be only a couple areas where that error could occur 

  1. The altitude used in meanSeaLevelPressure is substantially (roughly 100m) different than that of Activity.Info.altitude .  
  2. The temperature correction used in  meanSeaLevelPressure is different than returned by SensorHistory.getTemperatureHistory , however the documentation of meanSeaLevelPressure  only suggests it is corrected for altitude
  3. The formulas used to calculate meanSeaLevelPressure  in the API have an error.

Does anyone have any more insight into the specifics of the calculations and data Activity.Info.meanSeaLevelPressure utilizes?  I'm consistently seeing errors in my watch face from actual measurements to the displayed data using the API data.  Is there anything I may be missing?


References for calculations:

1)Elevation, Station (QFE) and Sea Level (QNH) Pressure Calculator (sensorsone.com)

2) Mean sea level pressure calculator (converter) (wind101.net)

  • This is something you really want to look at on a real device and not the sim.  To compute MSL pressure it needs ambient presume and elevation, and based on device there are different ways to calibrate the altitude/elevation.  You can enter a specific value, use GPS, or DEM.

    And then there's the case where you can be in the same location, but the weather, therefore ambient pressure, changes over time

    And then even on a real device, getXyzHistory isn't real time, but is only saved every few minutes (you can tell how often by using the "when" values of two adjacent samples. In the sim some of this data is "canned" and doesn't change over time

    Here for example are graphs of getPressureHistory and getTemperatureHistory in the sim.  Both are canned and never change:

  • Thats a great thought --- I'll work on building a quick test app for my actual watch and update the post with that data if I'm seeing the same issue

  • Update with actual device data (still seeing the same issue as the sim, been monitoring the data for a couple hours): 

    • meanSeaLevelPressure returns 98517.5 Pascals (still doesn't match typical calculations, should be 98803.0 Pascals)
    • ambientPressure returns 88806.8 Pascals
    • altitude returns 890.6 meters     [actual altitude at location is 886.5 meters, this is pretty accurate]
    • getTemperatureHistory returns 26.7 C

    Using the device measured ambient pressure and altitude, the non-temperature corrected value for MSL Pressure should be 98803.0 Pascals.   Although that seems close, it is noticeably off when using inHg values for aviation.   

    The Garmin API meanSeaLevelPressure converts to an altimeter setting of 29.09 inHg. Using widely accepted calculations from the measured ambientPressure results in 98803.0 Pascals results in an altimeter setting of 29.18 inHg [actual value from weather service is 29.17 inHg].   

    What is interesting is the Garmin Barometer widget also shows the "correct" calculated value of 29.18 inHg.  All this to say that the meanSeaLevelPressure value that is returned from the Garmin API neither matches the Garmin Barometer widget data, nor widely accepted calculation methods.  Unless they're using some other method or pulling data from elsewhere, it seems like there's an error in the meanSeaLevelPressure calculations in Toybox.Activity.

  • I thought altitude was based on GPS reading .. my Mk1 is new to me and i am noticing that the altitude changes over a range of 10 m at my desk near the beach . currently 40m . assumed it was based on tide change (i keep the GPS on) .. .  the pressure detection i assume is the same as the one used for depth on a dive which has to be a manometer of sorts (not calculated) & a critical datapoint.