• Optimal Monkey C

    Over the past two years, the Connect IQ team has been rewriting the Monkey C build tools from scratch to create a more modern, advanced toolchain. The first preview of the tools came in 2020 when we announced Monkey Types. Today, we are providing our first look at the new and improved Monkey C toolchain.

    Here are some of the improvements:

    Optimizing Code Generator

    The compiler now has a new optimization pass. This optimization pass will perform constant folding, constant substitution, branch elimination and a few other optimizations before generating your executable. These optimizations will make your code smaller and more performant without any code changes.

    You can use the -O command line option to set the optimization level. You can set the command line option in the Visual Studio Code plug in from the Workspace settings:

    Currently, level range from 0 (no optimizations) to 2 (release). Level 2 should bring the most code space reduction. 

    Typing by Default

    We want to build the tools your need to enable you to create the best apps for your customers. One of those tools is the Monkey Types, the gradual type system for Monkey C, that we announced at GDVC 2020. Since that first version, it's ability to detect errors at compile time has only grown. We believe the system is ready for prime time.

    We are enabling Monkey Types to type check code at the gradual level by default. This level operates between dynamic and static typing, checking the API but not requiring you to type your application. You can learn more about the Monkey Types system and how to configure it for your project here.

    Typing is not required for optimizations, and can be disabled within the Visual Studio Code project settings or with -l 0 from the command line.

    Improved Code Analysis

    The old compiler leaned heavily on the device virtual machine, transforming your code to bytecode with limited analysis in between. The new compiler features now transform your source into an intermediate representation (IR) that is used through the rest of the compilation phases. While still operating as a dynamic language, the IR has enough information to perform the complex analysis necessary for type checking and code generation. The compiler will be able to find many more errors up front, so you don't have to find them at runtime.

    Import and Object Instantiation

    With the old compiler, import behaved differently between type syntax and functional syntax. With the type syntax, the module name of referenced classes could be inferred by the list of imports; but in function code, it had to be explicitly stated:

    import B;
    
    // Type syntax - no module
    function usageExample() as ClassInB {
        // Functional syntax - required module
        return B.ClassInB();
    }

    With the new compiler, import works the same with types and functional syntax:

    import B;
    
    // Type syntax - no module
    function usageExample() as ClassInB {
        // Functional syntax - no more module
        return ClassInB();
    }

    Note that using statements retain the module requirement for backwards compatibility.

    Improved Logging

    If you encounter a bug with the monkeyc compiler you will need to generate logs to provide with your report. Here are the options to create debug logs:

    Long Option Argument Description
    --debug-log-level 0 = Errors, 1 = Basic Debug, 2 = Intermediate Debug, 3 = Verbose Debug Specifies the verbosity level for the output.
    --debug-log-output Path to log file to generate Specifies the path to the log file to create
    --debug-log-device Device identifier Allows limiting logs to a specific device when building a Monkey Barrel.

    Be aware that the log levels include increasingly more information about your source project. If you want to keep your project information private, limit the logging level to 1 or less. More verbosity will make it easier for Garmin to debug reported issues.

    Try it Today

    We have several improvements planned but wanted to let you try it for yourselves. You can find the beta in the SDK manager under "Connect IQ 4.1.4.Compiler 2 Beta":

    Please provide feedback on the forums. We look forward to your feedback.

    • Jun 16, 2022
  • Garmin Introduces the Edge 1040 and 1040 Solar

    Today, Garmin announced the new Edge® 1040 and 1040 Solar. These bike computers support Connect IQ System 5.

    Never stop cycling with Edge 1040. It’s our first GPS bike computer with multi-band GNSS technology for even better coverage in the most challenging environments. It’s also packed with performance features that help you understand your strengths and weaknesses to coach you through any challenge.

    You will need Connect IQ SDK version 4.1.4 or higher to develop for the Edge 1040. Get the latest SDK and device configurations with the SDK Manager. Learn more about the Edge 2022 personality in the User Experience Guidelines.

    • Jun 7, 2022
  • Garmin Developer Virtual Conference is Back!

    Date: October 12, 2022

    Cost: Free

    Join us virtually on October 12th to learn about all things Garmin developer programs, including Garmin developer announcements and information for the year ahead.

    You’ll have the chance to engage with:

    • Presentations
    • Breakouts
    • Q&A

    Registration opens early September on the GDVC site. Join our developer event mailing list to be notified when registration is open or check back regularly for updates on the Connect IQ Developer ForumAnd remember to mark October 12, 2022 in your calendar.

    If you missed last year’s event, click here to view our breakout videos. 

      

    Learn about the Garmin developer programs featured at GDVC:

    Connect IQTm

    Garmin Connect Developer Program

    ANT® Wireless

    • Jun 3, 2022
  • Garmin Introduces Forerunner 955 and Forerunner 255 Series

    Today, Garmin announced the new Forerunner 955 and Forerunner 255 Series. These running smartwatches will support Connect IQ System 5 in an upcoming release.

    Lead the pack with Forerunner® 955, the premium GPS running and triathlon smartwatch. The training readiness feature tells you when you’re primed for a productive session — while daily suggested workouts adapt to your performance and recovery alongside the race widget, which provides training tips, course details and completion time predictions. While you’re en route or out in the world, you can navigate confidently, thanks to multi-band GPS and full-color, built-in maps. And with traditional buttons and a touch display, you can tap into a full picture of your health — from sleep to training — with up to 15 days of battery life in smartwatch mode.

    Run at a higher level with the Forerunner® 255 smartwatch series. These GPS running smartwatches help you train and recover smarter with features such as race widget, which helps you plan your race-day strategy with daily suggested workouts. Morning report with HRV status reveals your overall health along with the day ahead. Plus, get up to 14 days of battery life in smartwatch mode for a full picture of your health — from sleep to training.

    Get the latest SDK and device configurations with the SDK Manager. Learn more about the fēnix 2022 personality in the User Experience Guidelines.

    • Jun 1, 2022
  • Garmin Introduces the D2 Mach 1

    Today, Garmin announced the new D2TM Mach 1 Series. This aviation smartwatch, based on the fēnix® 7 series, will support Connect IQ System 5 in an upcoming release.

    Accelerate the adventure with the D2 Mach 1 GPS aviator smartwatch. With classic style and a modern AMOLED touchscreen display, this premium timepiece offers the most advanced tools for flying — plus health and fitness features that enhance your pilot life.

    Get the latest SDK and the D2 Mach 1 device configurations with the SDK Manager. Learn more about the fēnix 2022 personality in the User Experience Guidelines.

    • Mar 28, 2022
  • Connect IQ System 5 SDK Now Available

    Connect IQ System 5 is here! The Connect IQ 4.1.1 SDK is now available from the SDK manager. System 5 better, faster and stronger than before with several key enhancements and updates.

    New Metrics

    System 5 has all new access to device metrics including:

    API

    Description

    ActivityMonitor.Info.respirationRate

    Get the current respiration value

    ActivityMonitor.Info.timeToRecovery

    Get the current time to recovery

    SensorHistory.getBodyBatteryHistory()

    Get device Body Battery history

    SensorHistory.getStressHistory()

    Get device stress history

    System.Stats.batteryInDays

    Get the amount of battery remaining in days

    UserProfile.Profile.vo2MaxRunning

    Get the user’s running VO2 Max

    UserProfile.Profile.vo2MaxCycling

    Get the user’s cycling VO2 Max

    UserProfile.getUserActivityHistory()

    Get an iterator of the user’s past activities

    Weather.getSunrise()

     Get the sunrise time for a location

    Weather.getSunset()

     Get the sunset time for a location

     

    Updated App Settings

    The new app settings system is now deployed in Connect, Connect IQ and Garmin Express.

    With the new <group> tag, you can tie related settings together. These will appear as a single entry in mobile that is editable within its own page. With the enableIfTrue attribute, you can disable a group based on if the user has selected a Boolean within the settings. The new array setting allows for growable lists of sub-objects within your settings. Best of all, these settings can work with any Connect IQ device.

    You can learn more in the Properties and Settings chapter of the Core Topics section.

    New Profiler

    The new Connect IQ profiler will help you improve your on-device app performance by giving you visibility to which calls are taking time in your app.

    In a future device update, you will be able to profile your app on device by compiling the app with the -k option. After you run, a file named <appname>.PRF will be generated in the LOGS folder. You will be able load the PRF file into the simulator profile tool for analysis.

    New! New Authentication Module

    System 5 introduces a new Toybox module Authentication. The Authentication module provides a new function that is similar to Communications.makeOAuthRequest(). The main differences are that the request will open in the Connect IQ Store mobile app, and that the Authentication module is available to all app types in the foreground. Now your data fields and watch faces can initiate authentication without using a background service.

    Supported Devices

    Connect IQ System 5 has rolled out on a number of devices with more coming:

    Now Available

    Public Beta Available

    Coming Soon

    Forerunner® 245 Series
    Forerunner® 745
    Forerunner® 945
    Forerunner® 945 LTE
    Venu® Series
    Venu® 2 Series
    Venu® 2 Plus Series
    Vivoactive 4 Series

    Edge® 530
    Edge® 830
    Edge® 1030
    Edge® 1030 Plus

    epixTM (gen 2)
    fēnix® 5 Plus Series
    fēnix® 6 Series
    fēnix® 7 Series
    Instinct® 2 Series
    MARQ® Series
    quatix® 6
    tactix® 6
    Venu® Sq Series

    Get the SDK

    System 5 is ready to make your apps better, faster, and stronger. You can download the SDK from the SDK manager to begin updating your apps.

    • Mar 22, 2022
  • Garmin Introduces the Descent G1 Series

    Today, Garmin announced the new DescentTM G1 Series. This dive computer, based on the Instinct® 2 series, support Connect IQ System 5.

    Explore both of your worlds with Descent G1. This rugged, easy-to-use dive computer features a bold design that stands out with a high-contrast, easy-to-read display. Descent G1 is built for multiple types of diving, whether you’re a recreational or technical scuba diver, or even a free diver. It’s also enabled with GPS to help mark your entry and exit points. Descent G1 doubles as a smartwatch with built-in sports apps, smart features and all-day health monitoring.

    The Descent G1 series requires Connect IQ SDK 4.0.10. Get the latest SDK and the Descent G1 and Descent G1 Solar device configurations with the SDK Manager. Learn more about the Instinct® 2022 personality in the User Experience Guidelines.

    • Mar 2, 2022
  • The Real Devices of Connect IQ (Part 1)

    Last October, we introduced System 5. Since then, the list of supported devices has grown considerably. With the announcement of the fēnix® 7  series, the epixTM (Gen 2) series, and the Instinct® 2 series, you have many more Connect IQ devices available to develop for. These new devices add some variety to the Connect IQ System 5 family; from button to touchscreen, black and white to color memory-in-pixel (MIP) to AMOLED, and resource-constrained to resource-abundant.

    In this series, we are going to create taxonomies for the System 5 devices. We will also present some things for you to consider when targeting a device or if it makes sense to target a device at all.

    The Real Glamour Devices of Connect IQ

    While Connect IQ devices have mostly used memory in pixel (MIP) displays, we now have multiple products with high color AMOLED or liquid crystal displays. These products have more resources and can make much richer app experiences.

    epix (Gen 2)

    Watch Face Memory

    128 KB

    Data Field Memory

    256 KB

    Device App Memory

    768 KB

    Screen

    416x416 AMOLED (65536 colors)

    Screen Shape

    Round

    Input

    Five-button and touchscreen

    Personality

    fēnix 2022

    Real Devices Tagline

    I’m epic in more ways than one

    The epix is the premium active smartwatch. With a gorgeous AMOLED display, over two weeks of battery life, button and touch inputs and API level 4.0.0, this is the device that does it all and can support the best app experience possible.

    The epix can be used as both a touchscreen or button-only watch, so your apps should work for both inputs.  Check DeviceSettings.isTouchScreen() to see if the device is running with the touchscreen disabled.

    The fēnix 7 and epix series use a different Wi-Fi solution than other wearables. If you are using the Communications.startSync2() to download content over Wi-Fi, make sure your servers support the TLSv1.2_2019 cypher set.

    Venu® 2 Series

    Watch Face Memory

    128 KB

    Data Field Memory

    256 KB

    Device App Memory

    768 KB

    Screen

    416x416 AMOLED 65536 colors (Venu 2 and 2 Plus)
    360x360 AMOLED 65536 colors (Venu 2S)

    Screen Shape

    Round

    Input

    Touchscreen with start and back buttons

    Personality

    Venu 2021

    Real Devices Tagline

    There’s always a time and a place for me

     The Venu 2 series offers a bright, crisp AMOLED display, wellness features like Body BatteryTM energy monitoring and the Health SnapshotTM feature, sleep scores and insights, more than 25 built-in indoor and GPS sports apps, preloaded workouts and much more. All three of these devices use API level 4.0.0 and can take advantage of the new graphics features offered.

    While Venu 2 Plus offers integration with your phone’s voice assistant, Connect IQ does not offer any integration with the device microphone. Users are allowed have music apps play through the onboard speaker.

    Venu and Venu Sq - Music Edition

    Watch Face Memory

    512 KB

    Data Field Memory

    32 KB

    Device App Memory

    1024 KB

    Screen

    390x390 AMOLED 65536 colors (VenuTM)
    240x240 LCD 65536 colors (VenuTM Sq Music Edition)

    Screen Shape

    Round

    Input

    Touchscreen with back and start buttons

    Personality

    Vivoactive 2019

    Real Devices Tagline

    Round or square, I’m ready to go

    The Venu was Garmin’s first wearable with a round AMOLED display, and the Venu Sq - Music Edition was Garmin’s first Connect IQ wearable with a square liquid crystal display. Both devices use API level 3.3.0.

    When making always-on watch faces for Venu and Venu Sq, you need to ensure in low power mode that any individual pixel isn’t activated for more than four minutes at a time. In low power mode, use thin fonts and move elements between frames.

    Best Practices for AMOLED Displays

    With AMOLED displays, every pixel uses power, and apps with bright, solid-color backgrounds can drain the battery faster. When designing pages, use a light-on-dark design with gradients that fade to black as opposed to the bright solid color designs of MIP:

    NO

    YES

    Watch faces in always-on mode on AMOLED devices are very different than MIP devices. When your WatchFace.onEnterSleep() is called, you can check DeviceSettings.requiresBurnInProtection() to see if you are rendering for an AMOLED device. When rendering in always-on mode, you need to obey the following rules:

    • Your watch face can only update once a minute.
    • Your watch face can only enable 10% of the pixels on the screen.
    • No pixel can be on for over three minutes (Venu and Venu Sq series only).

    See this article for more information on making watch faces for AMOLED devices.

    API Level 4.0.0 provides new graphics tools like the graphics pool to manage resources, alpha-blended primitives, new resource-packing formats and more. With the fēnix 7 series, epix and Venu 2 series, there is a whole generation of Connect IQ wearables that support these APIs. See this article on how to take full advantage of the graphics capabilities of these devices.

    The Real Slender Devices of Connect IQ

    These System 5 devices have 128 KB or less allocated for device apps and 64 KB for widgets. This means your application storage can get crowded in a hurry.

    Forerunner® 245 / fēnix 6s/ fēnix 6 / Enduro®

    Watch Face Memory

    96 KB (245,  fēnix 6s)
    112 KB ( fēnix 6, Enduro)

    Data Field Memory

    32 KB

    Widget Memory

    64 KB

    Device App Memory

    128 KB

    Screen

    240x240 64 color MIP (245,  fēnix 6s)
    260x260 64 color MIP ( fēnix 6)
    280x280 64 color MIP (Enduro)

    Screen Shape

    Round

    Input

    Button

    Personality

    Forerunner 2018

    Real Devices Tagline

    We can run all day and all night

     While these devices are not entry-level by any means, the have siblings (Forerunner 245 Music,  fēnix 6s Pro Series,  fēnix 6 Pro Series,  fēnix 6X Series) that have more Connect IQ resources.

    Of this family, the Enduro has the largest screen (280x280) but does not have any additional Connect IQ RAM, and does not have the Graphics pool of API level 4.0.0. Using a full screen 64 color bitmap on this device can quickly eat into your application memory. Keep your resource use to a minimum when possible.

    Forerunner 55

    Watch Face Memory

    96 KB

    Data Field Memory

    32 KB

    Widget Memory

    64 KB

    Device App Memory

    128 KB

    Screen

    208x208 8 color MIP

    Screen Shape

    Round

    Input

    Button

    Personality

    Forerunner 2018

    Real Devices Tagline

    Size doesn’t matter

    The Forerunner 55 is our first entry-level Forerunner with full System 5 support. From a functionality perspective, it’s not much different than a Forerunner 245. The primary difference is the eight-color (RGB111) 208x208 screen. Focus on using color for adding accents in your designs and save better imagery for AMOLED devices.

    Venu Sq

    Watch Face Memory

    96 KB

    Data Field Memory

    32 KB

    Widget Memory

    64 KB

    Device App Memory

    128 KB

    Screen

    240x240 LCD (65535 colors)

    Screen Shape

    Square

    Input

    Touch Screen

    Personality

    Vivoactive 2019

    Real Devices Tagline

    I may be square, but I’m full of surprises

     The non-music version of the Venu Sq has less resources than the music version. In contrast to the Forerunner 55, the Venu Sq features a full-color liquid crystal display. In order to save memory, the resource compiler by default is using 8-bit dithered images rather than 16-bit images. This cuts the required memory for images in half with limited visual impact.

    Unlike with round watches, data fields will not be obscured by a round screen, which means you can take advantage of the full area.

    Instinct 2 Series

    Watch Face Memory

    64 KB

    Data Field Memory

    32 KB

    Widget Memory

    64 KB

    Device App Memory

    96 KB

    Screen

    176 x 176 2 color MIP

    Screen Shape

    Semi-Octagon

    Input

    Button

    Personality

    Instinct 2022

    Real Devices Tagline

    When you enter the octagon, you never leave

    For all of you who said that Connect IQ devices couldn’t surprise you any more, we present the Instinct 2. It is a rugged entry-level outdoor wearable with many of the features that customers love from the fēnix line. It has a black-and-white octagonal screen with a sub-window and has the lowest memory limit for apps. Surprise!

    Let’s start with the sub-window. Think of the sub-window as the sidekick to the main screen. You can put iconography in the sub-window to provide context for your page, use it as a data field, add a button hint and more. The sub-window does not use a separate Dc; the screen is treated as a single image. Use the WatchUi.getSubscreen() API to get the boundaries.

    With the Instinct 2S, the sub-screen extends a few pixels past the primary border of the screen. To allow drawing to the full sub-screen area, the Dc.getWidth() extends to include the sub-screen. This means that while the screen advertises itself as 163x156, outside of the sub-window it is 156 x 156. The seven pixels to the right are under the lens. Data fields will advertise their boundaries correctly.

    Speaking of data fields, the data field shapes and obscurities are more complex than with round watch faces. The bottom portion of the screen can be used as a data field, which is a smaller space than most devices:

    Best Practices for Entry-Level Devices

    When building for these devices, make sure you optimize your resources to use the minimum bit depth necessary. Focus on including the just the core functionality for your app, and where it makes sense, use build exclusions to remove functionality.

    Next Time on the Real Devices

    In part 2, we will focus on the music capable wearables and the Edge® devices.

    • Feb 28, 2022
  • Garmin introduces the Instinct 2 series

    Today, Garmin announced the new Instinct® 2 series. These wearables, supporting API level 3.2, are the first of the Instinct line to support Connect IQ System 5.

    Whatever you do, own it with Instinct® 2. This rugged GPS smartwatch is tough enough to keep up with you and unique enough to fit your style. Do more of what you love with preloaded activity profiles and stay connected to what matters with smart features.

    The Instinct 2 requires Connect IQ SDK 4.0.10. Get the latest SDK and the Instinct® 2 device configuration with the SDK Manager. Learn more about the Instinct® 2022 personality in the User Experience Guidelines.

    • Feb 9, 2022
  • Garmin introduces the D2 Air X10

    Today, Garmin announced the new D2Tm Air X10, a new aviation wearable using API level 4.0.0.

    Navigate your day with D2 Air X10. This GPS aviator smartwatch has piloting tools you’ll want preflight, in-flight and postflight. And it offers advanced health and fitness features to help you track your wellness — plus keep you connected between flights.

    Use the SDK Manager to update your device library to add D2 Air X10 support to your apps.

    • Feb 8, 2022