Data Folder in Template Applications - 2024.1 English

Porting Guide for embeddedsw Components System Device Tree Based Build Flow (UG1647)

Document ID
UG1647
Release Date
2024-06-21
Version
2024.1 English

A YAML file named <app_name>.yaml must be added inside the data folder. This YAML file is a replacement of the older AMD proprietary metadata files (*.mss, *.tcl). For example, the data folder in the hello_world template folder must contain a file named hello_world.yaml.

The YAML file contains the following sections:

  • Headers, copyrights, versions, and generic information such maintainer and type.
    # SPDX-License-Identifier: MIT
    %YAML 1.2
    ---
    title: <Description of the yaml file>
     
    maintainers:
      - Name(s) of the maintainer(s) 
     
    type: <Describes the type of baremetal module the yaml file describes, e.g, apps>
     
    description: 
      < A brief description of the Application >
  • Specification(s) that help(s) picking up the application properly for a given platform (processor/OS configuration).
    supported_processors:
      - <The list of CPUs the library supports>
       
     
    supported_os:
      - <The list of OSes the library supports>
  • Specification(s) that describes the dependencies of the application. An application can depend on certain driver/IP configurations which must be present in the system device tree for the application to be compiled. In addition, an application can also depend on the libraries and can, by default, need specific library configurations depending upon the use case.
    depends:
    # e.g. lwip applications need atleast one ethernet IP in the design
        <driver_name1>
            - <List of properties of driver/IP1 that the application relies upon>
        <driver_name2>
            - <List of properties of driver/IP2 that the application relies upon>
     
    depends_libs:
        <Library 1 that should be configured>:
            <lib1 param1>: <lib1 val1>
            <lib1 param2>: <lib1 param2>
        <Library 2 that should be picked>:
            <lib2 param1>: <lib2 val1>
  • Specification(s) that describes the OS-level and linker-related requirements of the application. These will be used when the application requires some change in the OS level parameter or the linker heap and stack size. For more details on linker generation, refer to the Application: Hardware Dependency and Linker Script Generation section.
    os_config:
        <os name i.e. freertos or standalone>:
            <os param name e.g. freertos_total_heap_size>: <os param value e.g. 262140>
     
    linker_constraints:
    # Default Stack and Heap size is set to 0x2000 for Platforms other than Microblaze.
    # For Microblaze, the sizes are set to 0x400.
        stack: <Required Stack size e.g. 0xA000>
        heap: <Required Heap size e.g. 0xA000>
  • A sample application YAML (freertos_lwip_udp_perf_client.yaml):
    # SPDX-License-Identifier: MIT
    %YAML 1.2
    ---
    title: FreeRTOS lwIP UDP Perf Client
    maintainers:
        - Klmn rtyu <klmn.rtyu@domain.com>
     
    type: apps
     
    description: The FreeRTOS LwIP UDP Perf Client application is used for creating UDP
        client and measure UDP uplink performance using light-weight IP stack (lwIP). This
        application sets up the board to use default IP address 192.168.1.10, with MAC address
        00:0a:35:00:01:02. This application creates UDP client on board and make connection
        with UDP server running on host machine. It will display connection information
        along with interim and average UDP statistics for data transfer.
     
    supported_processors:
        - psu_cortexa53
        - psu_cortexr5
        - psv_cortexa72
        - psv_cortexr5
        - psx_cortexa78
        - psx_cortexr52
        - ps7_cortexa9
        - microblaze
     
    supported_os:
        - freertos10_xilinx
     
    depends:
        emaclite:
            - reg
            - interrupts
        axiethernet:
            - reg
            - interrupts
        emacps:
            - reg
            - interrupts
     
    depends_libs:
        lwip213:
            lwip213_api_mode: SOCKET_API
            lwip213_dhcp_does_arp_check: true
            lwip213_dhcp: true
            lwip213_ipv6_enable: false
            lwip213_pbuf_pool_size: 16384
            lwip213_memp_n_pbuf: 1024
            lwip213_mem_size: 524288
            lwip213_n_tx_descriptors: 512
        xiltimer:
            XILTIMER_en_interval_timer: true
     
    os_config:
        freertos:
            freertos_total_heap_size: 262140
     
    linker_constraints:
        stack: 0xA000
        heap: 0xA000