Announcement

Collapse
No announcement yet.

Data Field: AppBuilder

Collapse
X
  • Time
  • Show
Clear All
new posts

  • You could try: https://forums.garmin.com/forum/deve...31#post1310631

    In order to get IF you would simply need to divide normalized power with your current FTP, so I believe you would need to enter it like this:

    (AVG0(IFS(Timer GTE 30,TIMEAVG0(Power,30)^4))^0.25) / FTP

    for Lap IF:

    (LAPAVG0(IFS(LapTime GTE 30,TIMEAVG0(Power,30)^4))^0.25) / FTP

    Also make sure you configure the data field to display decimal (2 places) and write your current FTP as a number in the formula, otherwise it won't work.

    Hope this helps

    Comment


    • Originally posted by JTH9 View Post
      You could try: https://forums.garmin.com/forum/deve...31#post1310631

      In order to get IF you would simply need to divide normalized power with your current FTP, so I believe you would need to enter it like this:

      (AVG0(IFS(Timer GTE 30,TIMEAVG0(Power,30)^4))^0.25) / FTP

      for Lap IF:

      (LAPAVG0(IFS(LapTime GTE 30,TIMEAVG0(Power,30)^4))^0.25) / FTP

      Also make sure you configure the data field to display decimal (2 places) and write your current FTP as a number in the formula, otherwise it won't work.

      Hope this helps


      Thank you! Seems works fine. Do you know if it’s possibile to do the same in running mode with power from stryd? Thank you

      Comment


      • Yes it's possible, but it's a bit of a hack to get it working.

        Normally in running mode native power data recording is not supported, but it can still be viewed if you have also paired your Stryd as a power meter in watch sensor settings. The reason you need to do it like this is that AppBuilder cannot read power data directly from Stryd IQ field which records the data to its own developer fields.

        Luckily the watch can have up to two IQ data fields, so you could have AppBuilder calculate IF from native power channel and additionally have Stryd IQ data field to display / record power to developer fields.

        Hopefully I could explain it so that it makes sense to you. It's a bit of a mess currently. It would be a lot easier if Garmin would simply support power in running mode natively.

        Comment


        • Pretty big update for anyone who's still following this thread:

          - AppBuilder, and AppBuilder2-4 are now "AppBuilder Classic". I made a small update to change the app names and I have frozen development on those apps. The idea is that any formula which works today should work on those apps forever. The alternate clones are now identified with letters -- "B", "C", and "D" -- instead of numbers, because...

          - AppBuilder 5 has been released to the store!

          I put in some of the best suggestions, along with a couple of small ones.

          Comment


          • New features [CIQ 2 only]
            • Local variables
            • Log and ln functions
            • New activity variables: distanceToNextPoint, distanceToDestination, elevationAtNextPoint, elevationAtDestination
            • And last, but not least:
              The ability to store multiple formulas and select them without a phone or PC

            AppBuilder 5 and its three clones are now available:
            https://apps.garmin.com/en-US/apps/f...e-3b7f39aa67c5
            https://apps.garmin.com/en-US/apps/7...7-dc2bcceb6fc2
            https://apps.garmin.com/en-US/apps/f...5-46dc1d939f3f
            https://apps.garmin.com/en-US/apps/3...d-dca71ea10b98
            Last edited by FlowState; 11-09-2018, 06:11 PM.

            Comment


            • AppBuilder 5: New features
              Note: old CIQ1 devices (*) will not get any new features, due to severe memory constraints. For them, Appbuilder 5 is identical to AppBuilder Classic, but you do get four more configuration slots for your formulas.

              (* FR230/235, FR630, FR920XT, Vivoactive, Fenix 3/HR, D2 Bravo/Titanium, Quatix 3, Tactix Bravo)

              As always, please replace square brackets below with parentheses

              * Local variables

              SETV[index, value]
              - Sets the variable identified by index to value. Index is a number that identifies your variable. To do nothing, use NULL for Index -- this is useful in conditionals (see examples below)
              - Returns the same value that was passed in

              GETV[index]
              - Retrieves a previously set value from the variable identified by index
              - Returns NULL if SETV was not previously called for index

              Examples:
              https://ciq-appbuilder.blogspot.com/...s.html#fn_getv

              Unlike most programming languages, the arguments to IF are always evaluated, so the following will not work as expected (variable 1 will always be set to Timer):
              IF [Timer GT 3000, SETV[1, Timer], NULL]

              Instead, you want:
              SETV[1, IF[TIMER GT 3000, TIMER, NULL]]

              * Log/ln functions
              LOG[x, b]
              - Returns the log base b of x, or NULL if the result is undefined


              LN[x]
              - Returns the natural log of x, or NULL if the result is undefined

              * New activity variables: distanceToNextPoint, distanceToDestination, elevationAtNextPoint, elevationAtDestination
              Available on select CIQ 2 devices supporting full navigation, like 935 and Fenix 5. This should cover both course points and waypoints.

              Short forms: distpoint, distdest, elevpoint, elevdest

              Units:
              Distance: km or miles, depending on device distance units. Use _raw suffix for metres
              Elevation: metres or feet, depending on device altitude units. Use _raw suffix for metres

              * Store multiple formulas and select them directly on the watch

              The app now has 4 configuration profiles. The procedure for selecting a profile directly on the watch is:

              - Select a sport with AppBuilder on a data page
              - Double-click the START button before the activity starts -- or within the first 10 seconds -- to enter "config mode"
              - If the timer is now paused, AppBuilder will display "Press START". Press START to start the timer.
              - AppBuilder will now display the profile number and label: e.g. "1:AppBuilder"
              - Press LAP repeatedly to switch profiles
              - Double-click START again to save your changes. AppBuilder will display "Cfg Saved"
              - Discard the activity

              The next time you start AppBuilder, your new profile will be in effect.

              If you accidentally entered config mode or you want to lose your changes, no problem.
              - After entering config mode, just double-click START again, without selecting a new profile, and all will be well. You can even continue to the record the activity if you want. AppBuilder will have been computing and recording in the background, with the original formula.
              OR
              - Just discard the activity without double-clicking START

              - Note: the double-click window is a very generous 2 seconds. The normal window for double-clicking a mouse is half a second. I'm curious to hear feedback on this method. I know it isn't intuitive, but I can't think of any other way to configure a datafield without a phone....
              Last edited by FlowState; 11-12-2018, 04:52 AM.

              Comment


              • More AppBuilder 5 changes which should make Normalized Power formulas simpler and more versatile.

                New options for TIMEAVG(), which takes the rolling/moving average of a value over time.

                (Please replace square brackets below with round brackets)

                TIMEAVG(value, X, strictWindow, pauseMode)

                - value: The value to be averaged
                - X: Size of the window, in seconds

                - strictWindow: (optional)
                0 (default): Does not wait until the sample window is full
                Returns an average even with the number of samples is less than the window size
                1: Waits until the sample window is full
                Returns NULL when the number of samples is less than the window size

                - pauseMode: (optional)
                0: (default): Reset data on pause
                When timer is paused, discards all samples (previous and current). Returns NULL
                1: Keep data during pause
                When timer is paused, keeps existing samples but does not collect new ones. Returns last known average
                2: Collect data during pause
                When timer is paused, continues to collect samples regardless. Returns the current average. This also applies to the beginning of an activity, before it has started. (But this can be overridden with a something like IF (Distance NEQ null)

                Note:
                TIMEAVG[value, X] is the same as TIMEAVG[value, X, 0, 0]

                Examples
                1) Normalized Power (native): Activity average
                Original formula:
                AVG0[IFS[Timer GTE 30 and [Timer - MAX[if [PREV[timer] eq null, timer, null]] plus 1] gte 30, TIMEAVG0[Power,30]^4]]^0.25

                New formula:
                AVG0[TIMEAVG0[Power,30,1]^4]^0.25

                2) Lap NP (native): Carries the rolling average over from prev lap
                LAPAVG0[TIMEAVG0[Power,30,1]^4]^0.25

                3) Lap NP: Resets at start of each lap
                LAPAVG0[IFS[LapTime GTE 30,TIMEAVG0[Power,30,1]^4]]^0.25

                These formulas all use a "strict window" which means that the average is not defined until you have a full 30 seconds of data.
                Last edited by FlowState; 11-09-2018, 12:36 PM.

                Comment


                • I moved all the docs and examples to one place:
                  http://ciq-appbuilder.blogspot.com/

                  It's a little rough right now, but all the information is there

                  This will avoid forum issues as well eliminating the need to go to 5 different places to see all the examples.

                  Comment


                  • Made a major update to the docs at http://ciq-appbuilder.blogspot.com/. It's broken down into separate pages now, including examples, functions and variables (activity data). The complete lists of variables and functions are at the top of their respective pages, so hopefully it's a lot easier to find what you're looking for.

                    The examples are greatly improved: it's visually clear what's part of the formula and what isn't, and there's a button next to each example to copy the formula to the clipboard.
                    Last edited by FlowState; 11-11-2018, 10:39 PM.

                    Comment


                    • Update 5.2 (AppBuilder 5):

                      - Add new "pause mode" option for PREV. PREV can now keep/collect data while the timer is paused.
                      PREV(X, pauseMode)

                      pauseMode (optional)
                      0: (default) discards data, returns null while timer is paused
                      1: returns old data while timer is paused (does not collect new data)
                      2: collects new data while timer is paused

                      - Fix examples involving user variables and storing data at beginning of lap. (Laps can be taken while the device is paused)

                      - Add new example: Last Lap HR
                      SETV(IF (PREV(LapCount, 2) LT LapCount, 1, NULL), PREV(LAPAVG0(HR),2)) ; GETV(1)
                      Last edited by FlowState; 11-12-2018, 04:55 AM.

                      Comment


                      • Big update for CIQ1 devices: Added previously CIQ2-exclusive functions: AVG, AVG0, LAPAVG, LAPAVG0, LOG, GETV/SETV and PREV's pauseMode.

                        Now you can calculate Normalized Power or Last Lap HR on older watches, and more of the previously CIQ2-only examples will work now.

                        I updated the documentation and fixed a few problems (lap metrics were miscategorized as CIQ2-only, for example).

                        Note: On AppBuilder 5 and CIQ1 devices, the Time2 format now does the exact same thing as Time: it formats seconds as [hours:]minutes:seconds. If you need Time2 (minutes:seconds) on CIQ1 devices, please use AppBuilder classic.

                        I'm keeping these changes on AppBuilder 5 only for now (and not porting them to AppBuilder Classic). I'm probably not going to update the Classic app except to fix bugs, at this point.
                        Last edited by FlowState; 11-12-2018, 10:59 PM.

                        Comment


                        • Latest update (5.3.3):

                          - Fix crash when selecting profile with blank formula
                          - Add setting for "Quick Profile Select Hotkey" to help you if you have 2, 3 or 4 AppBuilders in the same activity and you want to switch profiles on the watch.
                          Options:
                          - Disabled
                          - Double-click once [default]
                          - Double-click twice
                          - Double-click 3 times
                          - Double-click 4 times

                          Normally you would be unable to configure more than one field independently on the watch, because they all react to the same initial double-click hotkey. This would make the feature for configuring your fields on the watch pretty useless, since they would all be changing in lockstep.

                          With this setting, you set each of your AppBuilders to a different hotkey, and you can configure them sequentially. Or you can just disable the hotkey if you don't like it.

                          e.g. 3 AppBuilder fields in one activity.
                          Set A to "Double-click once", B to "twice" and C to "3 times".

                          The first double-click will let you change A's profile
                          The second double-click will save A's changes and enter profile selection for B
                          The third double-click will save B's changes and enter profile selection for C.

                          If you want to skip configuring any of the fields, simply leave the profile unchanged, and the field will return to normal after you exit config mode.

                          Comment


                          • Hi I'm just starting to dip my feet into AppBuilder. I've installed AppBuilder 5 on my Fenix 3 & the CIQ 1 configuration for NP

                            AVG0(IFS(Timer GTE 30 and (Timer - MAX(IFS (PREV(timer) eq null, timer)) plus 1) gte 30, TIMEAVG0(Power,30)^4))^0.25

                            I'm trying to modify this to give my max 20 Min NP for the activity. I thought the configuration might work, however I get a CIQ error when I start the activity. It may be a resource issue on a CIQ1 device, but was wondering if anyone could help me to get it working.

                            MAX(TIMEAVG0(AVG0(IFS(Timer GTE 30 and (Timer - MAX(IFS (PREV(timer) eq null, timer)) plus 1) gte 30, TIMEAVG0(Power,30)^4))^0.25, 1200))

                            Cheers

                            Comment


                            • hotdogpartysausage unfortunately that won't work because:
                              -TIMEAVG stores the data for all the samples and most watches (even 935 and Fenix 5 "non-plus") don't have enough memory available to data fields for 1200 samples (in this app)
                              - Even if you had enough memory, you want a rolling max over time which is not something that is supported by appbuilder

                              There are approximations for the moving average that don't involve storing all the samples (although not available in appbuilder), but I don't think you can calculate a rolling MIN or MAX over time without storing all the samples, so this would never be feasible except for Fenix 5, 645 Music or other devices.

                              This is probably the kind of thing that would need to be done in a dedicated data field.

                              Having said all that, normalized power is an average (over your entire activity), so:
                              - The longer you ride, the less it should change
                              - I don't even know what the 20 minute max signifies, in this case (but TBH I'm not a cyclist)

                              It would be like taking the lap max of your average lap pace afaik -- an interesting calculation but not sure what it would signify.

                              EDIT: Clearly the previous post has nothing to do with rolling min/max. My mistake!
                              Last edited by FlowState; 11-13-2018, 02:10 PM.

                              Comment


                              • Thanks for the detailed explanation. I was hoping there might be a way to do it with appbuilder without creating a dedicated datafield. Never mind

                                fwiw. 20 minute power can be used amongst other power intervals to give a rough estimate of cycling FTP. It can be seen retrospectively on completion of an activity & saving. I thought it might be interesting to see real time on a periodic update

                                Comment

                                Working...
                                X