C

Qt Quick Ultralite Motorcycle Cluster Demo

Demonstrates integrating QML and C++, and handling multiple variants of the same design.

Overview

The application demonstrates a Motorcycle Instrument Cluster supporting two different screen configurations: 800x480px and 720x1200px. It's possible to switch between configurations using the SIZE_VARIANT cmake variable.

For example:

cmake .. -DSIZE_VARIANT=small

Setting this variable to small will produce binaries supporting a resolution of 800x480px. Setting it to big will produce binaries supporting a resolution of 720x1200px.

If a platform has enough storage, the application can have a start-up animation with image sequences. The intro variant enables the animation, so its .qmlproject file lists the image files for the animation. This variant is available for the small variant on STM32F769i-discovery and on the desktop platform. Refer to Resource properties and Resource properties for sprite animation sections which explains how to manage resource for image sequences.

Since Qt Quick Ultralite 2.7, this demo uses screen rotation to rotate the application for the NXP MIMXRT1170 platform. To enable this feature, this platform has its own top-level .qmlproject file.

The demo shows how to connect a C++ simulation backend to the QML user interface.

The application contains:

  • start-up animation (only in intro variant)
  • welcome animation
  • driving cycle
  • day mode
  • navigation with keyboard
  • warnings
  • goodbye animation

Target platforms

  • MIMXRT1170 (rotated big variant)
  • RH850-D1M1A (small variant)
  • STM32F769i-discovery (small and intro variant)
  • Infineon TRAVEO™ T2G (small variant)

Screenshots

Start-up animation

Night Mode

Day Mode

Keyboard

Files:

Images:

Available under certain Qt licenses.
Find out more.