SDK 6.2.0

This seems weird. Big jump to SDK 6? And a dramatic reduction in size?

NOTE: In Eclipse I had to go into PREFERENCES and manually point to the new SDK. The SDK Manager did not update that from SDK 4.2

  • It's boring  cannot get the function println printed. When I rollback the SDK, It crashed on fr255 and other devices.

    The official command monkeydo doesn't work but vscode works, it's a little strange.

  • Yes - I, too, rolled back to previous 4.version and then all Edge x40 devices crash on simulator (on every dc. Command like dc.fillcircle….)

    I‘ve just testet a small datafield with Edge 1040 and System.println(). 
    For me it works as should (Windows, VS Code, SDK 6.2.0).

  • Yes it works for  (Windows, VS Code, SDK 6.2.0), But it doesn't work for  (Windows, monkeydo, SDK 6.2.0). monkeydo is official command line so it must have worked in my thought.

  • Sounds like there are a few issues here that we'll need to look into. I'll get tickets created for the following:

    1. println() not working with monkeydo (fwiw, this doesn't make sense to me off the top of my head because monkeydo is used behind the scenes to push PRGs to the simulator.) I just tried this on Mac, and it's working properly, so I'll have to jump over to another machine and try in powershell.
    2. Underscores not allowed as first character in resource IDs.
    3. Edge devices crashing in sim when using data fields
    4. drawBitmap2() crashing on some devices in the simulator that should support it
    5. Review API symbols not found by the compiler

    Regarding the review APIs, these were unintentionally hidden in the distributed API docs when the 6.2.0 SDK was released, but we updated the docs on the developer site to include these APIs. The distributed docs will be updated to match in a future SDK release.

    Just as a note, I'd recommend to everyone reporting issues in this thread to submit things like these as bug reports in the future: https://forums.garmin.com/developer/connect-iq/i/bug-reports. We monitor the bug reports daily and it's less likely that a bug report will be missed if posted there. Sometimes reports in responses on a thread like this can get missed or may not be noticed right away. Thanks!

  • Thanks to Brandon for prompt response. For println issue, I'm used to using the command line to develop and debug. After I built the .prg file, I did use the following command to put it to the simulator for debuging.

    monkeyd test.prg fr255

    This works fine before 6.2.0 and doesn't work on either Windows or Linux Fedora.

  • Edge devices crashing in sim when using data fields

    Crash only, if 6.2.0 was downloaded but not used and SDK 4.x.x still actual SDK and only with complex datafields and Edge x40 devices!
    (with SDK 6.2.0 the sim does not crash)

  • What is the crash/call stack you see when using drawBitmap2?

  • Here's an update on the issues:

    • println() not working with monkeydo

    I haven't ben able to reproduce this, and neither has the engineering team. We've tested on three different windows machines (at least one in Powershell), two Macs, and two Linux machines (Ubuntu 20.04.6 LTS).

    • Underscores not allowed as first character in resource IDs.

    Generally, resources have not allowed leading underscores on IDs since 2017.  I'm interested to know exactly which kind of resource you're assigning these IDs to. You mentioned settings—are you referring to IDs specifically? FWIW, I tested leading underscores on property IDs in both 4.2.4 and 6.2.0 and they worked (so apparently there's at least one exception to the general rule). That said, there's no reason we can see that underscores should not be allowed in resource IDs, so I'm creating a ticket to fix this.

    • Edge devices crashing in sim when using data fields

    I was able to reproduce this one pretty easily. It appears to only affect 540, 840, and 1040, and likely has nothing to do with 6.2.0 itself, but with recent device profile updates that were made to those devices and released at the same time as 6.2.0. If it is the device profiles, we should be able to make updates without another SDK release.

    • drawBitmap2() crashing on some devices in the simulator that should support it

    I don't know what kind of crash  is experiencing. I did encounter an issue with non-fenix 7 products where I would receive an InvalidPaletteException if I did not specify automaticPalette="false" (using the packingFormat option should also address this). If this is the issue being observed, it's not a bug.

    • Review API symbols not found by the compiler

    This is related to the APIs being hidden in the API docs. We'll have this fixed in an upcoming release along with the doc updates.

  • Thanks , this is the exact issue I'm having with drawBitmap2().

    With SDK 6.2.0 Eclipse did not output any call stack when crashing.

    I have now migrated to VS Code and got the following exception.

    Error: Unhandled Exception Exception: Source must not use a color palette Stack:...

    Even with the exception message I never would have guessed that this relates to the automaticPalette attribute.
    Maybe this is worth mentioning in the documentation of drawBitmap2.

    Is this already working as intended or will drawBitmap2 eventually support a bitmap with palette?
    What do you mean with "using the packingFormat option..."?

    I would like to use the new tintColor feature. If I have to set automaticPalette to false my apps will consumer more memory from the system memory pool (I assume). Which brings me back to another question I have raised.
    May I draw your attention to the following thread. I did not receive an answer from your colleagues.

    https://forums.garmin.com/developer/connect-iq/f/discussion/331999/system-memory-pool-utilization-by-watchui-layer-instances

    I had the issue with '_' as well and the compiler complained on string ID symbols specifically.

  • Thanks for the info—fortunately, I don't believe what you're seeing is a bug. I had to confirm with the engineering team on this myself, because even with the call stack, the cause and resolution weren't apparent to me.

    My basic understanding is that a bitmap may have a palette automatically applied, and that was causing issues with devices that use 16-bit color. This gets into some details I'm not very familiar with, but the API docs for drawBitmap() states "The source color palette must be a subset of the destination color palette" and will throw an exception if it doesn't align with this requirement. Setting automaticPalette="false" avoids this. 

    The other option is to set the packingFormat attribute (see https://developer.garmin.com/connect-iq/core-topics/resources/#bitmappackingformats).

    It looks like there's an opportunity for improvement here because we don't list the InvalidPaletteException as a possible exception with drawBitmap2, but it apparently applies to this method as well. I'll create a ticket to have the docs updated.

    Regarding the forum thread you linked to: we don't actively monitor the discussion threads because we simply aren't staffed to do so. I'll usually keep an eye on things following an SDK release, and we do check the bug reports on a daily basis. The discussion threads are intended for developers to discuss issues and techniques with the developer community. However, I'll see if someone from the team can take a look and address your question.