Connect IQ datafield

Hello!

I have a NPE Runn mounted to my treadmill, it measures belt speed and incline.

On my forerunner 965 I have installed a ConectIQ datafield that captures the incline/elevation gain. It the shows in Garmin Connect as shown below:

runn1
runn2

Is there any way I can get this data into Intervals.icu?

Regards
Ronny

1 Like

You can probably do that quite easily. However I see that you are getting your runs into Intervals.icu via Strava. Strava doesn’t give Intervals.icu the original activity files. You need to connect Garmin to get fit files. Garmin activities will replace Strava ones so you won’t get dups.

Before going through all that download the fit file for one of those runs from Garmin Connect and have a look at it on fitfileviewer.com. Hopefully that elevation gains stuff is in a field in the session message. Then you can easily view it in Intervals.icu.

Thank you David!

I had a look at the fot file in fitfileviewer, and found this field:
fit1

Total ascent seems to be the field I need :slight_smile:

I will start using Conect to sync my runs in the future.

I have started syncing my runs from garmin, but I dont seem to get my head around how to make that field visible in intervals. How do I get it to show in run details?

You need to click “Custom” under the timeline chart and then “Add Field”. Then click “Fit file field” near the bottom of the dialog and choose it. I did this for you.

You need to do Actions → Reprocess File to see this for existing runs from Garmin. I did that for your Sunday run.

Screenshot 2024-01-29 at 06.57.27

Great, thank you @david :grinning:

1 Like

@david Could we also use this to make GAP calculations? I would love to, because my coach has me doing some uphills intervalls, and he prescribes grade adjusted paces, so it looks like I’m not following the plan he has prescribed, but also TSS evaluation is not correct.

It is presented as a Graph in Garmin connect, so it is somehow plotted against time. Then, I suppose it’s relatively easy to have it per interval.

That field is just total ascent, How do you propose to get grade from that, just assume it was constant for the whole workout and dive total ascent by total distance ? Fine if it was, but woefully out if the grade wasn’t constant.

I have this graph in Garmin Connect, so I suspect it can be imported in intervals somehow, and if so then calculate GAP. It’s the ‘‘how to get it’’ I’m missing.

This graph’s name is ‘Incline Percentage’ which you can view in Intervals as ‘Gradient’ graph, ‘Pente’ in French.
Just add a chart with that metric.

I have added it, but it does not seem to ‘‘see’’ the NPE RUNN data. It juste does not appear.

What is that???
Give us some more info, we can’t guess where the stream is coming from…
If it is a IQ dev field, create a Custom Stream. Charts - Custom Streams - Add Stream:

NPE RUNN is mentionned in the first post of this thread, so I assumed the context was clear. Here is a Dcrainmaker post about it.

This is a device that captures the treadmill belt speed and grade, much more precise than reported by the treadmill itself (wich is generally woefully inaccurate).

Using your instructions, I now have the same graph as in Garmin connect. Can I use the same information to have GAP calculations?

The above screenshot should be enough to guide you on how to make it visible in Intervals. If not, tell me where exactly you’re having problems. The ‘Record field’ dropdown should show the inclineRunn stream as a selectable one.

Yeah, I posted and then figured it out, so I edited my post, but not fast enough. Sorry.

I have the graph, now my question is if I can use it to have GAP per lap.

That would require a script which calculates GAP (using an trustworthy algorithm) from the Incline and belt speed streams.
Intervals by default uses the Enhanced_speed and Enhanced_elevation for calculating GAP using the model defined in the Settings. (usualy Strava Run GAP model).
The script should then be written to use your Custom Streams and the same model.

I created this with the help of ChatGPT, but the return I get is ‘’?‘’. I’m no programmer, so any help is appreciated.

My custom stream Name is RUNN incline, the code is RUNNincline and it comes from the inclineRUNN fit field.

The pace should be the same as outdoors activities, as the RUNN acts as an accelerometer.

function calculateGAP(pace, incline) {
    return pace * (1 + 0.0075 * incline);
}
function processGAP() {
    let lapGAPResults = [];
    if (activity && activity.intervals) {
        let lapData = [];
        activity.intervals.forEach(interval => {
            const lapIndex = interval.getField('lap'); 
            const pace = interval.getField('Enhanced_speed'); 
            const incline = interval.getstream('RUNNincline'); 

            if (Enhanced_speed !== undefined && inclineRunn !== undefined) {
                if (!lapData[lapIndex]) {
                    lapData[lapIndex] = {
                        totalPace: 0,
                        totalinclineRunn: 0,
                        count: 0
                    };
                }

                lapData[lapIndex].totalEnhanced_speed += pace;
                lapData[lapIndex].totalinclineRunn += incline;
                lapData[lapIndex].count += 1;
            }
        });

        lapData.forEach((lap, index) => {
            if (lap.count > 0) {

                const avgPace = lap.totalPace / lap.count;
                const avgIncline = lap.totalincline / lap.count;

                const lapGAP = calculateGAP(avgPace, avgincline);

                lapGAPResults.push({
                    lapIndex: index,
                    GAP: lapGAP
                });
            }
        });
    } else {
        console.log("No intervals data found or activity is null.");
    }

    return lapGAPResults;
}

You have to call the function to execute the script

Place this at the end of your script:

data = processGAP();

I now get this error message : Validation failed: RUNNGAP must be a number

What do you want to show? All values for each lap? You have to convert it to a string and select the Type “Text” (in the Type tab). If it’s ONE value, you have to select only this value. Currently you are returning an array.