C

Getting started on NXP

Overview

This topic provides all the necessary information to get started on the NXP platforms supported by Qt Quick Ultralite.

Configure the Qt Creator IDE

Assuming that you have all the prerequisites installed, follow these instructions configure the Qt Creator IDE for NXP boards:

To develop for MCUs using the Qt Creator IDE, the MCU plugin is required. Qt Online Installer enables it by default when you install the Qt for MCUs SDK.

To enable or disable the plugin, follow these instructions:

  1. Select Help > About Plugins and choose the MCU Support plugin from the list.
  2. Restart Qt Creator to apply changes

To build and run your application on MCUs, you must create a kit:

  1. Select Edit > Preferences > Devices > MCU
  2. If not already set, provide the path to the Qt for MCUs installation directory.
  3. Select a Target supported by the Qt for MCUs SDK. For example, Qt for MCUs 2.7 - Desktop 32bpp.
  4. In the Requirements section, ensure that the platform-specific requirements are met.
  5. Select Automatically create kits for all available targets on start to create kits automatically.

    Note: You could also manually create/remove kits using Create Kit and Remove Kit.

  6. Click Apply and restart Qt Creator if you choose to create kits automatically.

You could also set up the development environment from the command prompt. See Command-line Setup for NXP Boards for more information.

Flashing the firmware

Flashing and debugging NXP boards requires the board to have the OpenSDA firmware. If an incorrect firmware is flashed, the tools may fail to establish connection with the device.

To check the firmware, connect your device to your development host and open the provided USB storage device. In the DETAILS.TXT file, look for the line starting with "USB Interfaces". It has to list "CDC" and "HID". If these are missing, you are probably using an incorrect firmware.

NXP provides the firmware for download. On the download page, select the type of your type of board and download the "Default firmware application, DAPLink". After flashing this to your board by following the instructions from NXP, the CDC and HID interface should be listed.

Building applications with prebuilt Qt Quick Ultralite libraries

Open the CMake project file for the example you want to build and configure it with the kit you created earlier. Once the project is configured, select Run or press Ctrl+r on your keyboard to build and flash the binary to the target.

Board-specific information

Hardware boardMCUCompilerOperating system(s)
MIMXRT1050-EVKBMIMXRT1052DVL6BGNU Arm GCC 10.3-2021.10, IAR Build Tools for Arm V9.40Bare Metal, FreeRTOS
MIMXRT1060-EVKBMIMXRT1060DVL6BGNU Arm GCC 10.3-2021.10, IAR Build Tools for Arm V9.40Bare Metal
MIMXRT1064-EVKMIMXRT1064DVL6AGNU Arm GCC 10.3-2021.10, IAR Build Tools for Arm V9.40Bare Metal, FreeRTOS
MIMXRT1170-EVKBMIMXRT1176DVMAAGNU Arm GCC 10.3-2021.10, IAR Build Tools for Arm V9.40FreeRTOS

Resource cache policy

By default, an application's resource data is copied to SDRAM on startup. In order to retain these resources in flash and not load them to RAM on startup, add the following QmlProject option to your qmlproject file:

MCU.Config {
    resourceCachePolicy: "NoCaching"
}

Alternatively, it can be enabled only for individual images like this:

ImageFiles {
    files: "big/button.png"
    MCU.resourceCachePolicy: true
}

Note: Set these CMake options before the ImageFiles.files entry.

Available under certain Qt licenses.
Find out more.