C

Commmand-line Setup for Infineon/Cypress Boards

Command line setup

To get started from the command line, ensure that the following environment variables are set:

  • Qul_DIR to the Qt for MCUs SDK install path.
    <QT_INSTALL_PATH>\QtMCUs\<VERSION>

    where,

    • <QT_INSTALL_PATH> is the Qt install directory,
    • and <VERSION> is the directory containing the Qt Quick Ultralite version you are using, for example 1.8.0.
  • Create the GHS_ARM_COMPILER_DIR environment variable and set it to the Green Hills Compiler for Embedded ARM installation path. For example:
    GHS_ARM_COMPILER_DIR=C:\ghs\comp_201954
  • Create the TVII_GRAPHICS_DRIVER_DIR environment variable and set it to the Graphics Driver for Traveo II Cluster Series installation path. For example:
    TVII_GRAPHICS_DRIVER_DIR=C:\Cypress\TVII-GraphicsDriver-1.0.0-6MA0
  • Create the CYPRESS_AUTO_FLASH_UTILITY_DIR environment variable and set it to the Cypress AutoFlashUtility installation path. For example:
    CYPRESS_AUTO_FLASH_UTILITY_DIR=C:\Cypress\CypressAutoFlashUtility-1.0

Build configuration

Qt Creator provides a build configuration with the kit that you created earlier for the Qt for MCUs 1.9 - TVIIC2D6M-BAREMETAL 32bpp target. If you are using a command-line setup, configure using the following CMake variables. For more information, see the CMake Manual.

Warning: The incremental build with Green Hills MULTI Compiler fails when the Ninja generator is used. CMake warns you about this on using the Ninja generator. It is recommended to use the NMake Makefiles or NMake Makefiles JOM generator instead.

  • QUL_PLATFORM

    The platform to build must be set to tviic2d6m-baremetal for this board.

    -DQUL_PLATFORM=tviic2d6m-baremetal
  • CMAKE_TOOLCHAIN_FILE

    This platform supports the GHS for ARM toolchain.

    -DCMAKE_TOOLCHAIN_FILE=%Qul_DIR%\lib\cmake\Qul\toolchain\ghs-arm.cmake
  • QUL_COLOR_DEPTH

    The supported color depth by this platform is 32-bit.

    Note: If this variable is not set, default color depth is used while configuring for the platform.

    -DQUL_COLOR_DEPTH=32

Building applications with prebuilt Qt Quick Ultralite libraries

The following example builds the minimal example for Infineon/Cypress TVIIC2D6M:

cd %Qul_DIR%\examples\minimal
mkdir build
cd build
cmake .. -G "Ninja" -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE=%Qul_DIR%\lib\cmake\Qul\toolchain\ghs-arm.cmake -DQUL_PLATFORM=tviic2d6m-baremetal
cmake --build .

Once you have successfully built the minimal example application, use the one of the following commands to flash it:

With the MiniProg4 probe:

cmake --build . --target flash_minimal
"%CYPRESS_AUTO_FLASH_UTILITY_DIR%\bin\openocd.exe" -s "%CYPRESS_AUTO_FLASH_UTILITY_DIR%\scripts" -f interface/jlink.cfg -c "transport select swd" -f target/traveo2_6m.cfg -c "program Release/automotive verify exit"

The same procedure applies to any other application.

Available under certain Qt licenses.
Find out more.