Announcement

Collapse
No announcement yet.

Data Field: AppBuilder

Collapse
X
  • Time
  • Show
Clear All
new posts

  • If one wants to try these, they should definitely be converted to code first, otherwise will crash even on F5+.

    Also set correct format for each field so data is displayed correctly (Time for LapTime and Number for others) and remember to flip record switches for fields that record data.

    Since GC doesn't show the labels one might want to put the fields in some logical order. For example I would put them so that Power is first field, then Up, Flat and Down Power in fields 2, 4, 6, LapTime and HR with global variables in remaining 3 and 5 fields.

    Long labels won't fit so I used LapUPwr, LapFPwr, LapDPwr. For example.

    I'm 99% sure no one else will actually go through the trouble to actually try these. But still I think it's quite nice demonstration what you can do with AppBuilder. Might be interesting to substitute power with some other data too, so you could monitor uphill / downhill pace, RE, etc.

    Comment


    • JTH9 that’s great, thanks! Just a reminder that the label will be recorded internally, so you can always download your original FIT and run it through the FitToCSV tool from the FIT SDK. It’s not so convenient but it allows you to recover that information at any point in the future.

      I wouldve liked to record the labels in the summary, like AppBuilder Classic/5, but unfortunately data fields have a pretty low limit on the amount of data to be recorded.

      Also for the record:
      Internal FIT developer field index:
      0-5 = fields 1-6 (graph)
      64-69: laps
      128-133: summary

      You would only need these numbers if you are not recording every field and you want to correlate internal fit fields to what you see in GC, and to the specific field index (1-6). OTOH they will always appear sequentially, so it’s not hard to figure out either way.

      In hindsight I should’ve gone with 1-6, 11-16, and 21-26, but too late now.
      Last edited by FlowState; 01-07-2019, 02:29 PM.

      Comment


      • Yeah, thanks for the info. At least SportTracks.mobi shows the labels correctly. Probably pretty much the only one that currently does.

        Comment


        • JTH9 also here's some suggested simplifications (just less to type and think about). Note that I changed the meaning of the values for global var 2. -1 means downhill, 1 means uphill, 0 means flat, and null means unavailable.

          The original grade equation remains unchanged.

          Set the grade type and display HR:
          SETGLOBAL(2, IFS(GETGLOBAL(1) GT 1.5, 1, GETGLOBAL(1) LT -1.5, -1, GETGLOBAL(1) NEQ NULL, 0)) ; HR
          (If none of the IFS tests are true, the value is null)

          Record power and display sign:
          RECORDSUMMARY(AVG(Power),20) ; RECORDLAP(LAPAVG(Power),19) ; IFS(GETGLOBAL(2) EQ 1,'+', GETGLOBAL(2) EQ -1,'-', 1, '') + RECORD(Power,7,"Power")
          (Using "1" for the last IFS test is a trick for having a default value when none of your other tests are true)

          Display uphill, flat, downhill lap avg power:
          SETV(1, IFS(GETGLOBAL(2) EQ 1, Power)) ; RECORDSUMMARY(AVG(GETV(1))) ; NORECORD() ; RECORDLAP(LAPAVG(GETV(1)))
          SETV(1, IFS(GETGLOBAL(2) EQ 0, Power)) ; RECORDSUMMARY(AVG(GETV(1))) ; NORECORD() ; RECORDLAP(LAPAVG(GETV(1)))
          SETV(1, IFS(GETGLOBAL(2) EQ -1, Power)) ; RECORDSUMMARY(AVG(GETV(1))) ; NORECORD() ; RECORDLAP(LAPAVG(GETV(1)))

          (Same comment about IFS and the default value of null. It's just shorter.)
          Last edited by FlowState; 01-07-2019, 03:29 PM.

          Comment


          • Originally posted by JTH9 View Post
            Yeah, thanks for the info. At least SportTracks.mobi shows the labels correctly. Probably pretty much the only one that currently does.
            If that's the case then at least you could set a longer internal label to be displayed on that site, while still displaying the short label on the watch. If you're curious why GC doesn't show the internal label, it's because they ask devs to set a fixed label in the app manifest. I'm pretty sure the reason is that the app manifest supports multiple languages, while the internal FIT label does not.
            Last edited by FlowState; 01-07-2019, 03:19 PM.

            Comment


            • FlowState thanks for tips with IFS. I agree simpler is better

              Comment


              • These look great JTH9 just wish i knew how to get these working on a Appbuilder 5 for the Fenix5s, i suspect that it would not be possible?

                Comment


                • Unfortunately the answer is no.

                  In theory it would be possible to rewrite the formula for two separate instances of AppBuilder 5. Another for displaying the 3 averages and another to display power with +/- sign and record it.

                  But in practice you would never be able to copy the formula (will cut out even when converted to code) let alone run it on your watch (memory limit). I know as I still have my old Fenix5 and actually tried.

                  I think this one is pretty much exclusive to AppBuilder5+ and Fenix 5+ series of watches.

                  Comment


                  • ah well, thought as much, thanks anyway the grade pace looked like a winner too

                    Comment


                    • Update

                      - Web app has been changed so that you can save it locally and run it without messing around with security settings. No functional changes
                      https://ciq-appbuilder.blogspot.com/p/5plus.html

                      Comment


                      • FlowState Thanks for this wonderful resource!! I'm wondering if there is a field for historical data from the watch... for example, mileage or time spent on all activities over a period of time.

                        Comment


                        • TahoeRunGirl no worries!

                          I think a 7-day history of that kind of thing is available to apps, not the total history. AppBuilder does not support displaying any of that at this time. It could be possible to add it in the future, but only for the most advanced watches (like Fenix 5X Plus or 645 Music), so I don't know if it would be useful for you.

                          Comment


                          • FlowState a couple of more questions about things I ran into on my second test run:

                            1) I tried running two instances of AppBuilder5+ where another shows u/f/d power and another u/f/d pace. This time the lap data was nicely in order, showing first instance, then second, from smaller to larger fields. However, total summary was a bit mixed, showing averages from both first and second instance of AppBuilder5+ alternating randomly, albeit otherwise in correct order. Any idea if this is easy to fix, or something GC related?

                            2) Is it currently possible to record speed data as time per distance? I noticed I can change display format, even format the data before recording, but apparently recorded data cannot be formatted as otherwise it is converted to text. Is there any workaround for this currently?

                            Comment


                            • JTH9 1) I should be able to fix the problem with the multiple instances. It has to do with the way the FIT fields are defined in the manifest (same place that the colours and labels are defined). After I do the update, I would appreciate it if you could test it for me.

                              2) The only way to do this is write as a "string" not a number, and if I did:
                              - You couldn't record it to the graph
                              - It probably wouldn't display at all in Garmin Connect web site, due to a bug
                              - You would have no option to display as a number, as the type is fixed

                              Short answer: no. (Sorry.)

                              The closest you could get to is to record decimal minutes per distance. e.g. 5.50 for 5:30. Ideally GC would allow you to write the raw data as speed (for the correct graph) and display as pace, but that's impossible. It's also related to the fact that they won't let you override native speed with calculated speed, because if they did, they could do it for you.

                              Comment


                              • JTH9 On second thought:

                                1) I do believe this is a GC issue, as data from two different apps shouldn't be interleaved like this. What if it was two unrelated apps, and not two clones of AppBuilder? GC has no way of telling the difference. To be clear, GC doesn't (or shouldn’t) know that AppBuilder 5+ and AppBuilder 5+ (B) are related apps.

                                The workaround I was planning on implementing wouldn't make sense or be practical for any two random apps in the store, for example. We can't all coordinate our FIT info even if we wanted to.

                                Having said this, I urge you to file a bug report with Garmin. Include a screenshot of GC and send them the original FIT file.

                                Also I would like to know if this happens on both GC mobile and the GC website.

                                EDIT: you may also wish to try two actually unrelated apps. dozen Run writes a lot of data for example.
                                Last edited by FlowState; 01-11-2019, 05:51 AM.

                                Comment

                                Working...
                                X