This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

[参考译文] AM67:自定义 Yocto 映像中的 OpenVX 支持

Guru**** 2587365 points
Other Parts Discussed in Thread: AM67, SYSBIOS

请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

https://e2e.ti.com/support/processors-group/processors/f/processors-forum/1540488/am67-openvx-support-in-custom-yocto-image

器件型号:AM67
主题中讨论的其他器件: SYSBIOS

工具/软件:

您好:  

我们的一位模块客户想要将 OpenVX 用于定制 Yocto 构建环境而不是 AM67 Processor SDK、请参阅如何将 OpenVX 组件实现到定制构建环境中的任何指导?

谢谢、此致  

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    您好、Tim:

    我正在将您的问题发送给我们的专家。 请期待尽快答复。

    此致、

    Suren

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    您好、Suren、  

    你有什么更新给我吗?  

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    尊敬的 TimL:

    对于 Yocto 构建、TI OpenVX 组件通过 ti-vision-apps.bb 配方[0]提供。 由此生成的 libtivision_apps.so 将包括核心 TIOVX 组件/接口、以及一些基本测试应用。 运行目标内核的远程内核的二进制 文件将是相邻 ti-edgeai-firmware.bb [1]的一部分 — 这些固件是预编译的,只要您至少有 2GB DDR、即可在无需修改的情况下适用。

    因此、您的模块客户应该能够使用 meta-edgeai 中的这两种方法来获得 TIOVX 的核心元件。

    如果 OpenVX 应用计划在 C7xMMA 加速器/NPU 上利用 TIDL 的 AI 加速、也需要 TI-tidl [3]方法。

    还有用于用户级应用的其他组件[2]。 这些并不是创建应用程序所明确需要的、但所有 SDK 示例都依赖于这些示例、例如 edgeai-gst-apps、edgeai-tiovx-kernels、edgeai-tiovx-modules。  

     [0] https://git.ti.com/cgit/edgeai/meta-edgeai/tree/recipes-tisdk/ti-psdk-rtos/ti-vision-apps.bb?h=scarthgap-next 

    • 版本将在这里很重要! 例如、SRC_URI 中的 branch=refs/tags/REL.PSDK_analytics.AM62A.11.01.00.04。 此类版本需要与 PSDK_FW / ti-edgeai-firmware 和 ti-tidl [3]方法的 SDK 版本相匹配。 最好在此使用 SDK 安装作为基础、以便版本已经同步。 一些分支上的头似乎并不是 100%一致的所有食谱(我看到这对于当前的 scarthgap-next )

    [1] https://git.ti.com/cgit/edgeai/meta-edgeai/tree/recipes-tisdk/ti-psdk-rtos/ti-edgeai-firmware.bb?h=scarthgap-next 

    [2]https://git.ti.com/cgit/edgeai/meta-edgeai/tree/recipes-tisdk/edgeai-components?h=scarthgap-next 

     [3] https://git.ti.com/cgit/edgeai/meta-edgeai/tree/recipes-tisdk/ti-tidl?h=scarthgap

    BR、
    Reese

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    您好 Reese、  

    感谢您的回复、很抱歉耽误您的时间。 我在编译 ti-vision-apps 时卡住了、 需要 aarch64-oe-linux-gcc、我注意到 am67 ti-psdk 有一个 linux-devkit 文件夹、其中包含 aarch64-oe-linux-gcc 二进制文件。 这个 SDK 是否具有 TI Processor SDK 的特殊功能、或者我是否可以使用通用 Yocto SDK 来编译 ti-vision-apps?  

    我附加了以下构建错误:   


    错误:TI-vision-apps-11.01.00-r0_edgeai_13 do_compile:oe_runmake 失败
    错误:TI-vision-apps-11.01.00-r0_edgeai_13 do_compile:ExecutionError('/home/embedded/workspace/scarthgap-next/am67xx_build/tmp/work/armv8a-linux/ti-vision-apps/11.01.00/temp/run.do_compile.2026994、1,无,无)
    错误:存储在/home/embedded/workspace/scarthgap-next/am67xx_build/tmp/work/armv8a-linux/ti-vision-apps/11.01.00/temp/log.do_compile.2026994 中的失败日志文件
    日志数据如下:
    | debug:执行 shell 函数 do_compile
    |注意:make -j 16 Yocto_build
    | CP -RF /home/embedded/workspace/scarthgap-next/am67xx_build/tmp/work/armv8a-linux/ti-vision-apps/11.01.00/repo/psdk_include /*/home/embedded/workspace/scarthgap-next/am67xx_build/tmp/work/armv8a-linux/ti-vision-apps/11.01.00/repo/.
    |profile=release build_emulation_mode=no target_cpu=A53 target_os=linux TIDL_path=/home/embedded/workspace/scarthgap-next/am67xx_build/tmp/work/armv8a-linux/ti-vision-apps/11.01.00/repo/tidl_j7 make app_utils
    |make[1]:输入目录“/home/embedded/workspace/scarthgap-next/am67xx_build/tmp/work/armv8a-linux/ti-vision-apps/11.01.00/repo/sdk_builder “
    | make -C /home/embedded/workspace/scarthgap-next/am67xx_build/tmp/work/armv8a-linux/ti-vision-apps/11.01.00/repo/app_utils
    |make[2]:输入目录/home/embedded/workspace/scarthgap-next/am67xx_build/tmp/work/armv8a-linux/ti-vision-apps/11.01.00/repo/app_utils
    | SHEL=/bin/sh
    |target_makefiles=utils/console_IO/mak/concerto.mak utils/file_IO/mak/concerto.mak src utils/ipc_test/mak/concerto.mak/mak/concerto. src src src src src src src src src src src
    |仅将 Linux OS 保留在 target_combos 中
    |在 target_combos 中仅保留 A53 CPU
    |未定义 TIARMCGT_ROOT=
    |文件 TIARMCGT_LLVM_ROOT=$(PSDK_TOOLS_PATH)/ti-cgt-armllvm_3.2.LTS
    |未定义 GCC_SYSBIOS_ARM_ROOT=
    |文件 CGT6X_ROOT=$(PSDK_TOOLS_PATH)/ti-cgt-c6000_8.3.7
    |文件 CGT7X_ROOT=$(PSDK_TOOLS_PATH)/ti-cgt-c000_5.0.0.LTS
    |未定义的 GCC_Windows_root=
    gcc_linux_root=/usr/文件
    环境 gcc_QNx_root=/home/embedded/qnx800/host/linux/x86_64/usr/bin
    |######################################################################
    | target_combin=J722S:Linux:A53:1:release:GCC_linux_arm
    |[gcc]编译 C99 app_log_writer.c
    |[GCC]编译 C99 app_log_reader.c
    |/bin/sh:1:aarch64-oe-linux-gcc: not found
    |make[2]:***[/home/embedded/workspace/scarthgap-next/am67xx_build/tmp/work/armv8a-linux/ti-vision-apps/11.01.00/repo/sdk_builder/concerto/finale.mak:318:/home/embedded/workspace/scarthgap-next/am67xx_build/tmp/work/armv8a-linux/ti-vision-apps/11.01.00/repo/app_utils/out/J722S/A53/LINUX/release/module/utils.console_io.src /app_log_writer.o]错误 127.
    |make[2]:***等待未完成的作业…
    |/bin/sh:1:aarch64-oe-linux-gcc: not found
    |make[2]:离开目录/home/embedded/workspace/scarthgap-next/am67xx_build/tmp/work/armv8a-linux/ti-vision-apps/11.01.00/repo/app_utils
    |make[2]:***[/home/embedded/workspace/scarthgap-next/am67xx_build/tmp/work/armv8a-linux/ti-vision-apps/11.01.00/repo/sdk_builder/concerto/finale.mak:318:/home/embedded/workspace/scarthgap-next/am67xx_build/tmp/work/armv8a-linux/ti-vision-apps/11.01.00/repo/app_utils/out/J722S/A53/LINUX/release/module/utils.console_io.src /APP_LOG_READER.o]错误 127.
    |maker[1]:***[makerules/makefile_tiovx_PTK_imaging.mak:8:app_utils]错误 2.
    |make[1]:离开目录“/home/embedded/workspace/scarthgap-next/am67xx_build/tmp/work/armv8a-linux/ti-vision-apps/11.01.00/repo/sdk_builder “
    | make:***[makerules/makefile_linux_arm.mak:347:Yocto_build]错误 2.
    |错误:OE_runmake 失败
    |警告:从 shell 命令退出代码 1。
    错误:任务 (/home/embedded/workspace/scarthgap-next/sources/meta-edgeai/recipes-tisdk/ti-psdk-rtos/ti-vision-apps.bb:do_compile) 失败、退出代码为“1"</s>“
    注意:任务摘要:尝试了 6489 个任务、其中 6483 不需要重新运行、1 个任务失败。

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    您好、Tim:

    是的、它正在寻找该编译器“aarch64-oe-linux-gcc",“,似乎、似乎没有找到它使用默认路径查找的编译器。  

    此 SDK 是 TI Processor SDK 中的特殊版本吗、还是可以使用通用 Yocto SDK 来编译 ti-vision-apps?  [/报价]

    您是说这个 编译器 (而不是 SDK)是否具有我们的 SDK 中的特殊功能? 我预计 Yocto 中默认使用的编译器就足够了

    此 vision_apps 中以前是否有已成功编译的组件? 我很好奇是否有一个特定子组件(仍在 vision-apps 配方中)正在寻找不同的编译器(可能是硬编码/错误)。  

    BR、
    Reese

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    您好、Tim:

    AArch64-OE-Linux 是 Yocto 用于构建 SDK 的默认编译器、上面提到的 Linux-Devkit 目录核心是从一个 Yocto 配方打包在 SDK 中的工具链。 因此、我认为通用 Yocto 构建就足以构建 ti-vision-apps 配方。

    请问您正在运行什么命令来构建此配方?

    理想情况下、命令应为:

    MACHINE=j722s-evm bitbake -k ti-vision-apps

    在您的情况下、以下命令的输出是什么、

    MACHINE=j722s-evm bitbake -e | grep "^TARGET_PREFIX"

    请确保机器变量指向 j722s-evm、而不是 am67(因为 meta-ti 层中没有此类机器)

    此致、

    Shreyash

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    你好  Shreyash、  

    感谢您后续访问我使用的元 tq Yocto 层自定义 SOM 配置的机器配置。
    https://github.com/tq-systems/meta-meta tq.comb/blob/scarthgap/meta-meta-machine/tqma67xx-mba67xx.conf tq

    我们的 BSP 基于庞大的参考发行版、该发行版默认包括基于 TI 模块的构建的 meta-ti。 除此之外、我还添加了以下层来构建 BSP:

    BB_VERSION =“2.8.0"</s>“
    BUILD_SYS =“x86_64-linux"</s>“
    NATIVELSBSTRING =“通用“
    TARGET_SYS =“ARM-SYS-eabi"<xmt-block0>“ tq
    MACHINE =“tqma67xx-mba67xx-k3r5"</s>“
    DISTRO =“dumpling-wayland-ti"</s>“
    DISTRO_VERSION =“5.0.10"</s>“
    tune_features =“arm armv7a vfp thumb callconvention-hard“
    TARGET_FPU =“硬“
    元数据
    meta-poky =“head:ac257900c33754957b2696529682029d997a8f28“
    META-OE
    meta-python =“head:491671faee11ea131feab5a3a451d1a01deb2ab1“
    META-ARM
    meta-arm-toolchain =“head:8e0f8af90fefb03f08cd2228cde7a89902a6b37c“
    meta-ti-BSP =“head:8c258e731e62954ff41460febc2c036fb5ca552c“
    meta-rauc =“head:a0f4a8b9986954239850b9d4256c003c91e6b931“
    meta-qt6 =“head:c58fdf7af5d92f5dc0a3446a9865580511ae8691“
    Meta-Meta tq
    META 饺子=“HEAD:fe1884498d531d0363710fc0c98de8bc7f014885“
    META-edgeai =“scarthgap:dd0dd867bb84e1872001cd4669fd6139b8257712“
    Meta-Arago-Distro
    Meta-Arago-Extras
    meta-arago-test =“scarthgap:5ca2748e530c78c316b47044da163e51ad775df“
    meta-ti-extras =“head:8c258e731e62954ff41460febc2c036fb5ca552c“
    meta-ti-basic =“scarthgap:3265fc78d1dd1642c112a2f3f42507bfa176d9“
    元网络
    元文件系统
    meta-multimedia =“head:491671faee11ea131feab5a3a451d1a01deb2ab1“
    MET-CLANG =“scarthgap:aef850f7fa53121c74b244b7ae40d31fb9809ccf“

    Im 从我们的元饺子层构建定制的 tq 镜像-image-weston-debug:
    https://github.com/images-systems/meta-image-weston-debug.bb tq tq.comb/blob/scarthgap/meta-dumpling/recepes-images/images/images-image-weston-debug.bb tq

    要使用 CI-META tq 中的自定义 setup-environment 脚本初始化 buildspace im、请执行以下操作:
    https://github.com/tq ci-systems/ci-meta-environment./blob/scarthgap/setup-environment tq

    我添加了  TI-vision-apps TI-edgeai-firmware 通过我的 local.conf 中的 image_install:append 变量打包到映像  

    机器??=“tqma67xx-mba67xx"</s>“
    Distro?=“dumpling-wayland-ti"</s>“
    packet_classes ?=“package_rpm"</s>“
    user_classes ?=“buildstats"</s>“
    PATCHRESOLVE =“noop"</s>“
    BB_diskmon_DIRS ??=“\
    STOPTASKS、${TMPDIR}、1G、100K \
    STOPTASKS、${DL_DIR}、1G、100K \
    STOPTASKS、${State_DIR}、1G、100K \
    STOPTASKS、/tmp、100M、100K \
    Halt、${TMPDIR}、100 米、1K \
    HALT、${DL_DIR}、100M、1K \
    Halt、${State_DIR}、100M、1K \
    停止、/tmp、10M、1K“
    PACKAGECONFIG:append:pn-qemu-system-native =“ sdl“
    CONF_VERSION =“2"</s>“
    Accept_TI_EULA =“1"</s>“
    Accept_QT6_EULA =“1"</s>“
    Qt_Edition =“开放源代码“
    #image_install:append =“ ti-vision-apps ti-edgeai-firmware“

    为了构建映像、我正在运行 bitbake tq image-weston-debug 命令
    您将在下面找到所请求的 bitbake 环境命令的输出:

     machine=tqma67xx-mba67xx bitbake -e | grep “^target_prefix “
    target_prefix=“aarch64-linux-"<xmt-block0>“ tq   


    谢谢、此致

    Tim


     

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    您好、Tim:

    您能尝试更改 ti-vision-apps 配方中 do_compile 下的以下行吗?

    CROSS_COMPILE_LINARO=aarch64-oe-linux-
    最终目的  
    CROSS_COMPILE_LINARO=aarch64-tq-linux-

    此致、

    Shreyash

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    您好 Shreyash、

    谢谢你帮助了很多,我不得不修复其他几个软件包,但现在我有 ti-vision-apps 可用在/opt/

    /opt/vision_apps # ls -al
    共计 296
    drwxrwxr-x 2 根根 4096 Mar 9 2018 .
    drwxr-xr-x 5 根根 4096 Mar 9 2018 ..
    -rw-r--r-- 1 根根 345 Mar 9 2018 app_c7x.cfg
    -rwxr-xr-x 1 根根 117 Mar 9 2018 run_app_arm_fd_exchange.sh
    -rwxr-xr-x 1 根 root 57-2018 年 3 月 9 日 run_app_c7x.sh
    -rw-r--r-- 1 根根 147 Mar 9 2018 run_app_heterogeneous.sh
    -rwxr-xr-x 1 根根根 765 Mar 9 2018 run_app_load_test.sh
    -rwxr-xr-x 1 根 root 266 Mar 9 2018 run_app_viss.sh
    -rwxr-xr-x 1 root root 518 Mar 9 2018 vision_apps_init.sh
    -rwxr-xr-x 1 根根 68072 Mar 9 2018 vx_app_arm_fd_exchange_consumer.out
    -rwxr-xr-x 1 根根 68152 Mar 9 2018 vx_app_arm_fd_exchange_producer.out
    -rwxr-xr-x 1 根根 67664 Mar 9 2018 vx_app_arm_ipc.out
    -rwxr-xr-x 1 根根 67648 Mar 9 2018 vx_app_arm_mem.out
    -rwxr-xr-x 1 根根 67640 Mar 9 2018 vx_app_arm_remote_log.out
    -rwxr-xr-x 1 根根 67920 Mar 9 2018 vx_app_c7x_kernel.out
    -rwxr-xr-x 1 根根根根 71112 Mar 9 2018 vx_app_flatives.out
    -rwxr-xr-x 1 根根 67632 Mar 9 2018 vx_app_conformance_core.out
    -rwxr-xr-x 1 根根 67800 Mar 9 2018 vx_app_conformance_hwa.out
    -rwxr-xr-x 1 根根根 67656 Mar 9 2018 vx_app_conformance_tidl.out
    -rwxr-xr-x 1 根根 67712 Mar 9 2018 vx_app_conformance_video_io.out
    -rwxr-xr-x 1 根根 67696 Mar 9 2018 vx_app_heap_stats.out
    -rwxr-xr-x 1 根根 67696 Mar 9 2018 vx_app_load_test.out
    -rwxr-xr-x 1 根 root 67952 Mar 9 2018 vx_app_viss.out  

    当我尝试执行 vision_apps_init.sh 时、我得到了一些内存映射 erros、您还能帮助我们解决这个问题吗?  

    /opt/vision_apps #./ vision_apps_init.sh
    /opt/vision_apps # 0.000000 s:app_log:错误:无法映射内存@ 0xa7000000、大小为 262144 字节!!

    提前感谢您

    Tim

  • 请注意,本文内容源自机器翻译,可能存在语法或其它翻译错误,仅供参考。如需获取准确内容,请参阅链接中的英语原文或自行翻译。

    您好、Tim:

    您是否确实改变了存储器映射、即在 firmware-builder/PSDK-RTOS 的 Vision_apps/platform/j722s/RTOS 中? 还是使用默认配置?

    我在一些 Yocto 方法中看到了对 SDK 11.1 的引用、但此 SDK 尚未推出。 您的 Yocto 设置是基于特定的 TI-SDK、还是直接从某个分支的最新提交中获取了配方和位置信息? 我想知道在获取最新版本(或至少在您启动时)时版本控制是否存在一些差异、我看到我们有一个提交 、该提交被提升到 11.1 相关版本[1](父提交之前显示 11.1)。

    您可能缺少一个.dTBO、它告诉 Linux 它应该使用什么 DMA 分割。 我们已经更改了在最后几个版本中应用此功能的方式、我想知道是否存在不同步的情况并导致问题。 /boot/dtb/ti 目录中是否有一个名为“k3-j722s-edgeai-apps.dtbo"或“或“k3-j722s-vision-apps.dtbo"的“的文件? 这些覆盖层用于为 Linux 设置这些 DMA 区域、远程内核(例如用于 AI 加速的 C7x)本应已在其固件中烘烤这些区域。  

    • 此覆盖在您的引导分区(运行时,请参见/run/media/BOOT-mmcblk1p1/uEnv.txt)中的 uEnv.txt 中应用。

    [1] git.ti.com/.../