Deprecation of screen family in resource compiler

Former Member
Former Member
I noticed this in the release notes for 2.2.1:

"Deprecate Round Watch, Square Watch, Semi-Round Watch and Tall Watch generic devices. If one of these generic devices is detected in a manifest file at compiler time a warning is printed indicating the device will be removed in the future."

What is the logic behind this decision from Garmin? My understanding would be that instead of 'resource-round_watch/xxx', for example, I would have to know which devices have a round face and create a folder for each with duplication of files for each device type. Instead of generically, 'all round watches' I now have to know which ones have the round face. I've seen reference to a round 240x240 resolution, is there a new watch coming out that is round, but different than the 218x218 face that encouraged this?

Will the screen size family of qualifiers still function for this? I can't seem to make those work in the simulator, is there an example of syntax for that?

Is this just removal of the manifest file family type declaration, but the folder structure will still exist and function?

Thanks
Chris
  • What is the logic behind this decision from Garmin?

    The deprecated names are device qualifiers, not family qualifiers. They are actual device names for devices that do not actually exist. As an example, resources-round_watch is the equivalent of resources-fenix3 except that the latter is for an actual device. It is safe to deprecate them because there is no actual device that uses them. They were put into use before the actual devices were announced, and before the concept of family qualifiers was created.

    My understanding would be that instead of 'resource-round_watch/xxx', for example, I would have to know which devices have a round face and create a folder for each with duplication of files for each device type. Instead of generically, 'all round watches' I now have to know which ones have the round face.

    Again, these were actual device names, not device families. The device families still exist. The family names that are currently in use are captured in {SDKROOT}/bin/devices.xml, but I've captured them here...

    • round
    • round-218x218
    • round-240x240
    • semiround
    • semiround-215x180
    • rectangle
    • rectangle-205x148
    • rectangle-148x205
    • rectangle-240x400
    • rectangle-200x265


    I've seen reference to a round 240x240 resolution, is there a new watch coming out that is round, but different than the 218x218 face that encouraged this?

    I can't speak to what is coming, but there is really no reason for Garmin to add support for a new device family unless there is a device coming that would be in that family.

    Will the screen size family of qualifiers still function for this? I can't seem to make those work in the simulator, is there an example of syntax for that?

    Yes. I'm betting the reason that you're having trouble is because you are trying to mix a device qualifier with a family qualifier. i.e., you've got a folder named resources-round_watch-218x218 (remember round_watch is a device qualifier, but the resolution is part of a family qualifier... you can't mix them). If you want to generically add resources for all devices that are round, you'd create a resources-round folder. If you want to further extend that to add resources for devices that are round and have 240x240 resolution, the folder would be named resources-round-240x240. All of this is described in the programmer's guide here.
  • Former Member
    Former Member over 8 years ago
    Thanks for the clarification.

    I've been using the device qualifier of 'round_watch' (without -218x218) instead of the family of 'round'. This makes more sense now.
  • Former Member
    Former Member over 8 years ago
    ..one more question: in the properties of the watch/manifest file is this:


    references the "Round 240x240 Family", will there be a replacement for the device types in favor of the families?
  • That name, while sort of misleading, is the name of a fictional device (much like round_watch was). After Garmin announces a device with that matches the family round-240x240, they will create a new device entry for that. Developers will need to update their resource folder name and then build with the SDK version that supports the new device. After some time has passed, Garmin will deprecate the junk device name.

    Travis
  • Former Member
    Former Member over 8 years ago
    Got it, thanks!
  • I don´t get it...

    Got an App which based on a Vivoactive. Then I sucessfully added Epix, Fr920xt and VivoactiveHR.
    Epix and FR920 must have a different LauncherIcon, so I created:
    • resources-epix\drawables
    • resources-fr920xt\drawables

    and put drawables.xml & the resized image into it.

    The VivoactiveHR also has a different screen resolution. The layout has also be copied and modified:
    • resources-vivoactive_hr\layouts


    So far, so good. Works!

    Now I added fenix3, tactix Bravo & quatix3.
    After finding this thread, I added
    • resources-round-218x218\drawables
    • resources-round-218x218\layouts

    resized LauncherIcon to 40x40 but I receive:
    BUILD: ERROR: The specified icon is larger (61x43) than the allowed icon size (40x40) for fenix3

    Tried different styles with "_" or "-". Checked my devices.xml. Selected the 1.4.x SDK.
    Nothing helped. I can see in the console that it refers on the "resources"-folder without any appendix.

    Eclipse Mars2 (4.5.2), Connect SDK 2.2.3
  • What's happening is that as of 2.2.3, "round-240x240" is no longer there (it was a generic device, and not a family), so the compiler doesn't see resources-round-218x218 and uses whatever the default is.

    You could add resources-fenix5 and resources-fenix5x (the two 240x240 devices) or use a family based qualifier as shown in the programmer's guide
  • Hmm, it is still not clear for me.
    I understood that the "round_watch" was just a kind of placeholder and was removed.
    But in 2.2.3 devices.xml there are still:
    [HTML]<device_families>
    <device_family id="round" >
    <device_family id="218x218" />
    <device_family id="240x240" />
    </device_family>[/HTML]
    And the fenix3 (218x218) is also marked with the fitting attribute:
    [HTML]<device id="fenix3" part_number="006-B2050-00" name="fenixTm 3 / tactixTm Bravo / quatixTm 3" family="round-218x218">[/HTML]

    or use a family based qualifier as shown in the programmer's guide

    The above is the approach from the programmers guide...
    Just tested the approach with 240x240 and a fenix5. It works!

    The 218x218 contains fenixTm 3, tactixTm Bravo & quatixTm 3. I don´t want to create three identical resources, which have to be taken care of.
  • Former Member
    Former Member over 8 years ago
    I think there's some confusion here so I'm gonna try to highlight what I understood from reading it.

    The previous "generic devices" (square_watch, round_watch, etc) are going to be removed as they were really just placeholders for upcoming device/device families (square_watch -> vivoactive, round_watch -> fenix 3, etc).

    The generic "round-240x240" device is actually the addition of a new family (the round-240x240 family) but in order to make it a target-able device before the actual device (fenix 5) became available it was listed as a "device" with a device ID that would match the eventual family ID of the real device. When the fenix 5 was added the round-240x240 device was removed but the family still exists because the fenix 5/5x are both part of that family. This is a pattern we'll use moving forward to avoid ending up with a bunch of generic devices with not very useful names (round_watch2, round_watch3, etc).

    Now, I believe the problem initially reported by HerrRiebmann is that a launcher icon resource defined at a family level (round-218x218) is not being applied to all the devices in the round-218x218 family. If that's the case this is probably a bug. I'd ask that you post the bug to the bug reports forum (reminder to check the bug report forum rules).