OpenEdv-开源电子网

 找回密码
 立即注册
正点原子全套STM32/Linux/FPGA开发资料,上千讲STM32视频教程免费下载...
查看: 71|回复: 1

[XILINX] petalinux-bulid 编译报错,设备树camera_in_axi_gpio_0问题

[复制链接]

1

主题

1

帖子

0

精华

新手入门

积分
16
金钱
16
注册时间
2019-6-13
在线时间
5 小时
发表于 2025-7-1 11:43:16 | 显示全部楼层 |阅读模式
按照教程《领航者ZYNQ之嵌入式Linux开发指南_V3.3》中 “第八章 Linux显示设备的使用”中逐步创建Linux镜像。
使用资料中的 “ZYNQ领航者\vivado_prj\Navigator_7020”中的xsa创建,然后使用 “资源文件\出厂镜像相关\”里的linux内核中的navigators-system-suer.dtsi替换petalinux工程中的system-suer.dtsi。最终使用petalinux-build。
编译报错信息:
  1. ERROR: device-tree-xilinx-v2020.2+gitAUTOINC+f725aaecff-r0 do_compile: Error executing a python function in exec_python_func() autogenerated:

  2. The stack trace of python calls that resulted in this exception/failure was:
  3. File: 'exec_python_func() autogenerated', lineno: 2, function: <module>
  4.      0001:
  5. *** 0002:devicetree_do_compile(d)
  6.      0003:
  7. File: '/home/book/ATK/prj_petlinux/ALIENTEK-ZYNQ-disp-dev/components/yocto/layers/core/meta/classes/devicetree.bbclass', lineno: 131, function: devicetree_do_compile
  8.      0127:            if not(os.path.isfile(dtspath)) or not(dts.endswith(".dts") or devicetree_source_is_overlay(dtspath)):
  9.      0128:                continue # skip non-.dts files and non-overlay files
  10.      0129:        except:
  11.      0130:            continue # skip if can't determine if overlay
  12. *** 0131:        devicetree_compile(dtspath, includes, d)
  13.      0132:}
  14.      0133:
  15.      0134:devicetree_do_install() {
  16.      0135:    for DTB_FILE in ls *.dtb *.dtbo; do
  17. File: '/home/book/ATK/prj_petlinux/ALIENTEK-ZYNQ-disp-dev/components/yocto/layers/core/meta/classes/devicetree.bbclass', lineno: 119, function: devicetree_compile
  18.      0115:        dtcargs += ["-i", i]
  19.      0116:    dtcargs += ["-o", "{0}.{1}".format(dtname, "dtbo" if isoverlay else "dtb")]
  20.      0117:    dtcargs += ["-I", "dts", "-O", "dtb", "{0}.pp".format(dts)]
  21.      0118:    bb.note("Running {0}".format(" ".join(dtcargs)))
  22. *** 0119:    subprocess.run(dtcargs, check = True, stdout=subprocess.PIPE, stderr=subprocess.STDOUT)
  23.      0120:
  24.      0121:python devicetree_do_compile() {
  25.      0122:    includes = expand_includes("DT_INCLUDE", d)
  26.      0123:    listpath = d.getVar("DT_FILES_PATH")
  27. File: '/opt/pkg/petalinux/2020.2/components/yocto/buildtools/sysroots/x86_64-petalinux-linux/usr/lib/python3.7/subprocess.py', lineno: 512, function: run
  28.      0508:            raise
  29.      0509:        retcode = process.poll()
  30.      0510:        if check and retcode:
  31.      0511:            raise CalledProcessError(retcode, process.args,
  32. *** 0512:                                     output=stdout, stderr=stderr)
  33.      0513:    return CompletedProcess(process.args, retcode, stdout, stderr)
  34.      0514:
  35.      0515:
  36.      0516:def list2cmdline(seq):
  37. Exception: subprocess.CalledProcessError: Command '['dtc', '-@', '-p', '0x1000', '-i', '/home/book/ATK/prj_petlinux/ALIENTEK-ZYNQ-disp-dev/build/tmp/work-shared/zynq-generic/kernel-source/arch/arm/boot/dts', '-i', '/home/book/ATK/prj_petlinux/ALIENTEK-ZYNQ-disp-dev/build/tmp/work-shared/zynq-generic/kernel-source/scripts/dtc/include-prefixes', '-i', '/home/book/ATK/prj_petlinux/ALIENTEK-ZYNQ-disp-dev/project-spec/configs/../../components/plnx_workspace/device-tree/device-tree', '-i', '/home/book/ATK/prj_petlinux/ALIENTEK-ZYNQ-disp-dev/build/tmp/work/zynq_generic-xilinx-linux-gnueabi/device-tree/xilinx-v2020.2+gitAUTOINC+f725aaecff-r0', '-o', 'system-top.dtb', '-I', 'dts', '-O', 'dtb', 'system-top.dts.pp']' returned non-zero exit status 2.

  38. Subprocess output:
  39. /home/book/ATK/prj_petlinux/ALIENTEK-ZYNQ-disp-dev/build/tmp/work/zynq_generic-xilinx-linux-gnueabi/device-tree/xilinx-v2020.2+gitAUTOINC+f725aaecff-r0/system-user.dtsi:254.12-274.4: ERROR (phandle_references): /amba_pl/i2c@41600000/ov5640@3c: Reference to non-existent node or label "camera_in_axi_gpio_0"

  40. ERROR: Input tree has errors, aborting (use -f to force output)

  41. ERROR: Logfile of failure stored in: /home/book/ATK/prj_petlinux/ALIENTEK-ZYNQ-disp-dev/build/tmp/work/zynq_generic-xilinx-linux-gnueabi/device-tree/xilinx-v2020.2+gitAUTOINC+f725aaecff-r0/temp/log.do_compile.47778
  42. ERROR: Task (/home/book/ATK/prj_petlinux/ALIENTEK-ZYNQ-disp-dev/components/yocto/layers/meta-xilinx/meta-xilinx-bsp/recipes-bsp/device-tree/device-tree.bb:do_compile) failed with exit code '1'
复制代码
定位问题是设备树文件中:“camera_in_axi_gpio_0” 这个没有定义? 这个完全按照教程中进行为什么会报错呢。请问如何解决
  1. &i2c2 {
  2.         clock-frequency = <100000>;

  3.         ov5640@3c {
  4.                 compatible = "ovti,ov5640";
  5.                 reg = <0x3c>;

  6.                 pwdn-gpios = <&gpio0 61 GPIO_ACTIVE_HIGH>;
  7.                 reset-gpios = <&gpio0 62 GPIO_ACTIVE_LOW>;
  8.                 iprst-gpios = <&<font color="#ff0000">camera_in_axi_gpio_0</font> 0 0 GPIO_ACTIVE_LOW>;

  9.                 status = "okay";

  10.                 #address-cells = <1>;
  11.                 #size-cells = <0>;

  12.                 port@0 {
  13.                         reg = <0>;

  14.                         ov5640_ep: endpoint {
  15.                                 remote-endpoint = <&xlnx_vcap>;
  16.                         };
  17.                 };
  18.         };
  19. };
复制代码


正点原子逻辑分析仪DL16劲爆上市
回复

使用道具 举报

1

主题

46

帖子

0

精华

中级会员

Rank: 3Rank: 3

积分
427
金钱
427
注册时间
2024-3-19
在线时间
288 小时
发表于 2025-7-3 19:03:49 | 显示全部楼层
把camera_in_axi_gpio_0改成camera_in_axi_gpio_1就行了
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则



关闭

原子哥极力推荐上一条 /2 下一条

正点原子公众号

QQ|手机版|OpenEdv-开源电子网 ( 粤ICP备12000418号-1 )

GMT+8, 2025-7-13 02:20

Powered by OpenEdv-开源电子网

© 2001-2030 OpenEdv-开源电子网

快速回复 返回顶部 返回列表