Widget: Compass



https://apps.garmin.com/en-US/apps/7115691d-7456-43ef-92bd-92a5885f16c7

A simple compass widget that looks eerily similar to the built-in compass on the Fenix3. On devices with a magnetic compass, the compass will report your heading (the direction you are facing). For devices without device support, the compass will display your heading (the direction you are travelling).

*Note*: I understand there is a 10 second timeout on the vivoactive, and this makes the widget less useful than I'd like. I've created an app version that is available here. https://apps.garmin.com/en-US/apps/663c7106-883c-4fbc-9a89-e01d9e9983ac

Revision History

1.0.5
* Center text displayed when not able to acquire a compass heading or GPS position.

1.0.4
* Removed debug tracing.

1.0.3
* Resolve issue with compass heading not being displayed correctly on the vivoactive.

1.0.1
* Resolve issue with serialization of application properties.

1.0.0
* Initial Revision
  • It would be trivial. If I were to provide this, would you want it to display the compass wheel or the cardinal direction indicator?
  • Former Member
    Former Member over 9 years ago
    If you could ad both of them it would be great but the direction in mils and mgrs gps position is enough! :)
  • Former Member
    Former Member over 9 years ago
    How to read the compass correctly

    Hi Travis,
    After studying all the available demo apps and trying different approaches, I still couldn't succeed showing the heading of the sensor and the heading of the position as independent data.
    While traveling on a boat, I need to read the direction ofthe boat but I also want to use the compass to read the bearing towards a point of interest at the coast.

    I also tried the direct interpretation of the X & Y data of the magnetotron (as shown in the demo app 'AccelMag') but the result is also not very reliable.
    Would you have any advice and some pieces of relevant source code ?
    Thanks so much
    Uwe
  • Former Member
    Former Member over 9 years ago
    2.7 killed the compass

    This widget worked great on my Forerunner 230 running the 2.6 software. Tonight I updated to 2.7, and the compass seems lost. Even after it engages the GPS, it doesn't point the right way -- or even *any* way consistently, although the circle turns green. Drat.
  • Try changing the mode to Position or Sensor in the menu. The code I'm using for the those modes is exactly the as it was in the previous version. I added the Magnetic mode, which needs a lot of work (calibration mostly).

    Travis
  • Former Member
    Former Member over 8 years ago
    Vivoactive gets Stale signal

    Hi there,

    I've just been trying your widget and I get the message STALE SIGNAL on a Vivoactive. It doesn't matter which way up I hold it :)

    Not sure where you've got with the widget, but if you want to check which way up the device is being held, then use the accel data and it will show you the floor.

    That is assuming that the orientation of the mag and accel sensors is the same.

    Don't feel you need to reply to this, but I thought you might want know about the vivoactive.

    R.
  • I don't use the mag sensor data at all in any released version. It was very inaccurate for many people, and I didn't want to go through the trouble of 'calibrating'. The data you see on the vivoactive is entirely based on position. I believe that if you see a stale signal indicator that the GPS data coming back is old. This should only happen if a GPS fix cannot be retrieved.

    Travis