Acknowledged
over 1 year ago

onTimerReset not called in a Datafield on Fenix7

I made a data field in which I want to send some BLE notifications to a peripheral device when the user discards the activity.

I pressed the start/stop button in activity and pressed discard, but onTimerReset wasn't called. So curious why. 

The same code works on fr745/fr955 but fenix7.

The outcome looks like the onTimerStop invoked incorrectly instead of onTimerReset on fenix7.

MODEL: FENIX7

FW:14.68

https://forums.garmin.com/developer/connect-iq/f/discussion/352546/ontimerreset-not-called-in-a-datafield

  • But everything works find on fr745. LOL

    I saw some threads in this forum said onTimerReset will be called when clicking save or discard

  • The documentation isn't very clear:

    onTimerStop() as Void

    The activity timer has stopped.

    This method is called when the activity timer goes from a running state to a stopped state.

    onTimerReset() as Void

    The current activity has ended.

    This method is called when the time has stopped and current activity is ended.

    So MAYBE if you would do: start, stop, save then after save onTimerReset would be called (because then the activity ended), and when you press discard they don't bother calling anything, they just remove the app from the memory, and throw away all the fit data collected?