How to display altitude on the watchface

I see some ConnectIQ watchfaces can display the altitude. I wanted to try this but couldn't find a way yet. They result in errors or permisson problems. How I can get the altitude displayed on the watchface? How I should call it with what methods or what reading I should get and calculate etc?
Any help appreciated.
  • Former Member
    Former Member over 9 years ago
    You can use Toybox.Activity.getActivityInfo().altitude to get the current altitude. Then Toybox.System.getDeviceSettings().elevationUnits == Toybox.System.UNIT_METRIC can be used to check if it is meters or feets.
  • You can use Toybox.Activity.getActivityInfo().altitude to get the current altitude. Then Toybox.System.getDeviceSettings().elevationUnits == Toybox.System.UNIT_METRIC can be used to check if it is meters or feets.


    Ok, thanks. ;)