Acknowledged

a strange problem with BufferedBitmap

A user has reported a problem with one of my watch faces on Fenix 7s (https://apps.garmin.com/pl-PL/apps/c19f2a45-9feb-44ae-9582-f858a1a1b893). I don’t own a Fenix, but the problem shows also on the emulator. To my humble eyes it looks like a possible bug in Connect IQ.

How to repeat: Take a copy of the Analog sample from the SDK distribution (in my case: …/ConnectIQ/Sdks/connectiq-sdk-lin-6.2.1-2023-06-26-124cb49c5/samples/Analog). Compile it for fenix7s (it has to be added to the manifest) and run. The simulator reports the following problem:

Error: Symbol Not Found Error
Details: Failed invoking <symbol>
Stack:
  - onLayout() at …/Analog/source/AnalogView.mc:56 0x10000bf3

Line 56 is

_offscreenBuffer = new Graphics.BufferedBitmap({

so the offending symbol seems to be BufferedBitmap, but this is embedded in a check in line 52 which states:

if (Graphics has :BufferedBitmap) {

So Graphics has BufferedBitmap but then it is not found? What’s going on here?

The Analog sample crashes also on fenix7, but runs happily on fenix6, fenix5 and many others.

(I'm not sure about fenix7x. In this case the simulator complains about ../src/common/menucmn.cpp(308): assert "wxIsStockID(GetId())" failed in SetItemLabel()).

Any help or explanation would be greatly appreciated!

Parents Comment Children
  • Thank you very much for that hint. This is indeed a matter of CIQ 4 and graphics pools. With createBufferedBitmap().get() my program works.

    However, I think my post is still valid as a bug report with the following cures proposed to the SDK creators:

    1. It would be best to make new BufferedBitmap(…) work again. However I can see a problem with the “new” operator if memory is to be allocated in a different way.
    2. Documentation for classes BufferedBitmap and BufferedBitmapReference needs adding a clear information that with API 4 bitmaps have to be created with createBufferedBitmap. Currently the page https://developer.garmin.com/connect-iq/api-docs/Toybox/Graphics/BufferedBitmap.html clearly instructs to use new BufferedBitmap().
    3. The samples distributed with the SDK should be upgraded to cover CIQ4, in particular the Analog sample, which is otherwise very instructive.