xmcImportFunctionSettings Command Syntax - 2022.1 English

Vitis Model Composer User Guide (UG1483)

Document ID
Release Date
2022.1 English
The xmcImportFunctionSettings command sets options for the import function feature in Model Composer. Options are specified in the form of name/value pairs. The current options include:
  • build: Specifies the build environment for Model Composer. Supported values include:
    • release: The default build mode. Generates the specified output, and lets you perform simulation.
    • debug: Provides integration into a third-party compiler to let you step through and observe the imported C/C++ function using standard debug features.
  • compiler: Specifies the third-party compiler to use for debugging purposes. The supported values are:
    • default: Compile with GCC or MinGW compiler for debugging using GDB debugger. Note that GCC or MinGW, and GDB are included with the standard installation of Model Composer.
  • blocks: Specifies the specific block or blocks that you want to observe during the debugging process. If the option is not specified, all imported function blocks in the current design are included for debugging. You can specify one or more blocks using the following command form:
    xmcImportFunctionSettings('blocks', {'block1','block2', ...})
    You can also unset the selection of the blocks using the following command:
    xmcImportFunctionSettings('blocks', {})
    You can use the MATLAB gcb command to get the block path for a specific block. The blocks must be specified as a list of blocks, even if only one block is specified. For example:
    xmcImportFunctionSettings('blocks', {'xmc_optical_flow/Lucas-Kanade'})
Tip: The settings specified by xmcImportFunctionSettings remain set until you exit Model Composer, or change the options using xmcImportFunctionSettings.
Note: In earlier versions of Model Composer, there existed a set of Computer Vision libraries which have been removed from 2020.2 and subsequent releases. You can import these functions into Model Composer as a block using the xmcImportFunction feature. To do this, you need to write a wrapper file around the library function. Refer to the Model Composer HLS examples, Sobel Edge detection and Color Detection (from GitHub), to understand how to write a wrapper file and import it as a block into the Model Composer design.

For example: Type, xmcOpenExample('color_detection') in the MATLAB command window. You can get the latest version of Vision libraries from this GitHub repository.