Data Field: AppBuilder

By user request, this app lets you define your own data field, based on a simple math formula like cadence / 2.

If you want to get fancy, there's conditional expressions (like IF in Excel), functions for data analysis (like MIN and AVG), and the data field can also display the text of your choice. The resulting data can be (optionally) written to the activity FIT file.

With AppBuilder, you can implement almost any field that involves math, such as: calculating normalized power and saving the data to the FIT activity file, showing the average pace for even-numbered laps, or recording the amount of time you sprinted.

Full documentation and examples here:
http://ciq-appbuilder.blogspot.com/

AppBuilder 5:
Now with new features! AppBuilder 5 is a completely new app, so please check it out in the store if you are interested in any of the new features.
https://apps.garmin.com/en-US/apps/fd690281-9c22-4fee-a81e-3b7f39aa67c5

- Store up to four formulas per app. Switch between formulas directly on the watch, without using a phone or PC. With four clone apps, you can store up to 16 formulas total
- User variables. Allows for powerful formulas where information can be stored at one point, like the start of a lap, and used later. e.g. Lap elevation change
- Improved timeavg() options. Allows for simpler, more flexible normalized power function
- More functions and variables

4 clones of AppBuilder are available in the store, so you can have 2 formulas in the same activity
  • bservo thanks for the feature suggestion. Can't make any promises, but that's a new request that nobody else has asked for.

    As far as your question goes, you could try comparing Speed to NULL instead of 0.

    For example, if your HR monitor is not connected/enabled, HR will be NULL (and not 0). As explained in the documentation, AppBuilder is designed so that most mathematical operations on NULL yield NULL, so your final result is NULL (which is displayed as "--" in both AppBuilder and some native fields).

    In your case, you would probably want something like

    IF (Speed neq NULL, Speed, X)

    where X is the formula you derived which calculates speed based on power.

    I'm guessing you need LOG/LN for this to work, though. It's an interesting idea because it would open up a whole new class of functions for AppBuilder. I'll think about it -- goes without saying this would only be for modern, CIQ2 devices.
  • Former Member
    Former Member over 7 years ago
    Thanks for the response.

    Yeah, I can't imagine LN or LOG are used frequently, but there's a reason they exist. :) I have been able to get good results fitting the data (on my laptop) by segmenting it and fitting it to different 3rd order polynomials, but it's not quite as elegant and I'm not sure yet how well it will work on the Garmin, but at least the mathematical operators are already there.

    Also, thanks for the heads up on the NULL vs 0. Makes sense. I think that should work.
  • Former Member
    Former Member over 7 years ago
    In an attempt to combine both lap power and current power in same field (rounded to closest 5W) here's the formula I came up with:

    ifs(power eq 0, round(lapavg(power)),power-lapavg(power) gte 0 and power-lapavg(power) lte 95,round(lapavg(power)) plus round((power-lapavg(power))/5)*5/100,power-lapavg(power) lt 0 and power-lapavg(power) gte -95,-round(lapavg(power))-round((lapavg(power)-power)/5)*5/100,power-lapavg(power) gt 95,round(lapavg(power)) plus 0.99,power-lapavg(power) lt -95,-round(lapavg(power))-0.99)

    Ironically it works best in 3 field layout using the middle row, so there kind of goes the original idea why to do this in the first place. Although it works with 4 field screens too, just that the font get's slightly smaller when the "-" sign is shown.

    Anyway it was a fun idea to try out. Here's how it works in practice:

    255.15 would be your average lap power and current power is 15W more
    -255.15 would be your average lap power and current power is 15W less

    255.99 when current power is more than +99W
    -255.99 when current power is less than -99W

    255.00 when power is equal to lap power or you're stopped

    Testing this I came up with another limitation, on Garmin Express settings page the field apparently doesn't allow very long formulas. If I try to paste it gets cut out at certain point. On other hand Connect iOS doesn't work with certain signs in formulas. Maybe I have to dig up my old android phone... :)

    Still I think this is close to limit what the field can handle, I came up with error message on few occasions suggesting that I ran out of memory. Didn't even try with the normalized power formulas :D

    Also not sure if there is more efficient way to present the same data, quite a lot repetition was needed, so bear with the complex readout.
  • Maybe someone can help me. I am missing the datafield from the older Edge series "high to point". When following a course it was helpful to see the rest elevation to the summit.
    Can anybody create this datafield with this app?
  • tomstark, the elevation at the next point (or destination) is not currently available. I checked the Connect IQ API, and those two values are available to apps (for CIQ 2), so it would be theoretically possible to add them in a future version of this app. I do have quite a bit of feature requests in the queue at the moment, but I'll def think about it. The main issue with some of these requests (as simple as they might be) is the risk of making the app too big to handle formulas that people are already using.
  • Update 2.6.32:

    Built AppBuilder (all 4 versions) with the latest SDK, and add support for Edge 1030. (For some reason the apps were auto-migrated to every new device except Edge 1030).
  • Hi,
    I would like to calculate the average ascent speed (TotalAscent_raw / Ascent time * 3600) in m/h.
    How can I calculate the Ascent time from the beginning of the activity (time only when ascending) ?
    Thanks in advance.
  • YVC try:

    TotalAscent_Raw / (SUM(TotalAscent_raw gt PREV(TotalAscent_raw)) * 3600)
  • I get 0.00
    I have changed the formula to
    TotalAscent_raw / SUM(TotalAscent_raw gt PREV(TotalAscent_raw)) * 3600
    but it seems to be about 10 times too high.
    Will try again later.
    And also replacing TotalAscent by Altitude.
  • Former Member
    Former Member over 7 years ago
    I am using Stryd foot pod. If I use variables like altitude_raw or TotalAscent I imagine that those refer to the altitude measurement from the Garmin watch. Is there any possibility to refer to Stryd altitude values?