Datafield - OnTimerLap with workout file

Dear all,
I'm developing a datafield for Edge 520. I would like to compute the average of a info quantity over a lap.
I'm using the funcion onTimerLap() to identity the time when a lap is created. I could manage to make the callback work (both on simulator and edge).
But It looks to me onTimerLap() does not work when using a workout file.

Below you find small datafiled for laps counting.
When I use it without workout file, it work correctly.
When I use a workout file, it give a value of 3 laps when I start the activity and then it doesn't count neither of laps nor autolap.
Has anybody succesfully used ontimerlap() with a workout file?

using Toybox.WatchUi as Ui;

class Lap_counterView extends Ui.SimpleDataField {

var lap = 0;

// Set the label of the data field here.
function initialize() {
SimpleDataField.initialize();
label = "Lap counter";
}

function onTimerLap()
{
lap += 1;
}
// The given info object contains all the current workout
// information. Calculate a value and return it in this method.
function compute(info) {
// See Activity.Info in the documentation for available information.
return lap;
}
}
  • Just had this reported for my data field too.
    What's needed to give this issue more traction? Seems like a no-brainer to me, onTimerLap() should be fired in workout mode, certainly users seem to expect that behaviour.
  • Same here on a Fenix 3 HR, somehow onTimerLap() is different when using a Workout :(. If this is not supported, then please see this a very wanted feature request.
  • I'm wondering if there is any update to report on this issue. As far as I can see now the issue still exists.
  • Issue still exists.. Any update?
  • Forerunner 235: same problem

    Last firmware.

    I created an app to calculate avg datas during a lap. It works very well with manual lap button.
    Today, I started a 30-30 training session, and data are not updated between slow and fast intervals.

    Will you fix that bug ?
    I'm ready to publish my app. Should I state it won't work with training programs ?
  • Thanks for checking in. As of right now we don't have any word from the device teams on whether or not this change will be implemented. If you want to publish your app with a disclaimer that it is not for use in structured workouts, I feel this would be acceptable for now, but it is ultimately up to you.

    Thank you,
    -Coleman
  • Fajar acciona

    Would you please consider changing this?
    I was really disappointed to see that I could access sooooo many fields (time, cadence, temperature, ...) to find that I cannot display for example the remaining time in the current lap of my workout.

    Developpers face the same issue and almost apologize to their users because this sound soooo stupid that everyone take it as a bug.

    This info IS available as Garmin show it on a screen when a user does a custom workout.

    Because of this I'm constantly jumping back and forth between standards screens.

    The platform sounded promising at first.

    Sorry for that no so positive message but that is one more annoyance of the ConnectIQ workout/Training/Calendar.
  • The platform sounded promising at first.
    It is promising. It just never promised to be a silver bullet, or that your imagination and your algorithms are the only limits to what you can do on/with a Garmin fitness device.
  • Could you let us know what is the status of this issue?
    I would really appreciate if you could fix this bug. It shouldn't really matter whether new lap was initiated using lap button, auto-lap, workout step or interval.
  • We're aware of this issue, but I don't see any activity since Coleman's response in February. I'll ask to have its priority raised. Since the actual bug report thread is over here, I'm going to close this thread.