你好,我现在在agx xavier使能pps驱动,系统版本是35.1.0,做法如下:
- 在tegra194-p2888-0000-a00.dtsi中加入pps模块:
pps {
//here use gpio for the pin in which you want pps signal.
gpios = <&tegra_main_gpio TEGRA194_MAIN_GPIO(A, 0) GPIO_ACTIVE_LOW>;
compatible = “pps-gpio”;
assert-falling-edge;
status = “okay”;
}; - 修改了pps-gpio.c(line 189 return -EINVAL 改为 return ret)
然后运行./nvbuild.sh -o $PWD/kernel_out 编译出tegra194-p2888-0001-p2822-0000.dtb 和 Image,然后刷到Xavier中,发现可以在dmesg中看到pps0,设备,但是还是会有报错,kernel log如下:
[ 0.447522] pps_core: LinuxPPS API ver. 1 registered
[ 0.447531] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti giometti@linux.it
[ 2.973651] pps-gpio pps: failed to request PPS GPIO
[ 5.771731] pps_core: source pps.-1 got cdev (246:0)
[ 5.771750] pps pps0: new PPS source pps.-1
[ 5.775693] pps pps0: Registered IRQ 284 as PPS source
并且接入pps信号利用ppstest 工具去看还是有问题,无法正常解析。
可以帮我看下是什么问题吗?