External NVPPS not triggering deserailiser

Please provide the following info (tick the boxes after creating this topic):
Software Version
DRIVE OS 6.0.8.1
DRIVE OS 6.0.6
DRIVE OS 6.0.5
DRIVE OS 6.0.4 (rev. 1)
DRIVE OS 6.0.4 SDK
other

Target Operating System
Linux
QNX
other

Hardware Platform
DRIVE AGX Orin Developer Kit (940-63710-0010-300)
DRIVE AGX Orin Developer Kit (940-63710-0010-200)
DRIVE AGX Orin Developer Kit (940-63710-0010-100)
DRIVE AGX Orin Developer Kit (940-63710-0010-D00)
DRIVE AGX Orin Developer Kit (940-63710-0010-C00)
DRIVE AGX Orin Developer Kit (not sure its number)
other

SDK Manager Version
1.9.3.10904
other

Host Machine Version
native Ubuntu Linux 20.04 Host installed with SDK Manager
native Ubuntu Linux 20.04 Host installed with DRIVE OS Docker Containers
native Ubuntu Linux 18.04 Host installed with DRIVE OS Docker Containers
other

Hello,

We have fed external PPS to Orin. We have verified by interrupts.

335:       7459          0          0          0          0          0          0          0          0          0          0          0  c2f0000.gpio  29 Edge      nvpps_isr

We are enabling gpio mode in nvpss from application.

nvidia@tegra-ubuntu:~/Documents$ sudo dmesg | grep gpio
[    0.200230] input: gpio-keys as /devices/platform/gpio-keys/input/input0
[    1.384362] nvpps c6a0104.nvpps: gpio_pin(509)
[    1.384406] nvpps c6a0104.nvpps: gpio_to_irq(335)

When we run nvsipl camera app or driveworks we get below error.

[  407.297103] cdi-mgr sipl_devblk_7: cdi_mgr_gpio_intr_wait: wait_event_interruptible failed -512
[  722.347334] cdi-mgr sipl_devblk_0: cdi_mgr_gpio_intr_wait: wait_event_interruptible failed -512
[  722.347339] cdi-mgr sipl_devblk_2: cdi_mgr_gpio_intr_wait: wait_event_interruptible failed -512
[  822.270250] cdi-mgr sipl_devblk_7: cdi_mgr_gpio_intr_wait: wait_event_interruptible failed -512

Logs are attached below.
nvsipl_log.txt (82.7 KB)

Can you help us understand how to get out of this issue?

FSYNC Device tree changes are below

 fsync-groups {
	status = "okay";
	fsync-group@0 {
		id = <0>;
		status = "okay";
		generators = <&gen0>;
	};
	fsync-group@1 {
		id = <1>;
		status = "okay";
		generators = <&gen1>;
	};
	fsync-group@2 {
		id = <2>;
		status = "okay";
		generators = <&gen2>;
	};
	fsync-group@3 {
		id = <3>;
		status = "okay";
		generators = <&gen3>;
	};
};

NVPPS DT changes are below

nvpps {
  compatible = "nvidia,tegra194-nvpps";
  #address-cells = <1>;
  #size-cells = <1>;
  reg = <0x0 0xc6a0104 0x0 0x118>;
  gpios = <&tegra_aon_gpio TEGRA234_AON_GPIO(EE, 6) GPIO_ACTIVE_HIGH>;
  interface = "eqos_0";
  sec_interface = "mgbe2_0";
  status = "okay";
};

Also dmesg pps gives below.

nvidia@tegra-ubuntu:~/Documents$ sudo dmesg | grep pps
[    0.067742] pps_core: LinuxPPS API ver. 1 registered
[    0.067743] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
[    1.384350] nvpps c6a0104.nvpps: nvpps_probe
[    1.384362] nvpps c6a0104.nvpps: gpio_pin(509)
[    1.384406] nvpps c6a0104.nvpps: gpio_to_irq(335)
[    1.384408] nvpps c6a0104.nvpps: using ptp notifier method with interface(eqos_0)
[    1.384410] nvpps c6a0104.nvpps: tsc_res_ns(32)
[    1.384480] nvpps c6a0104.nvpps: nvpps cdev(509:0)
[    1.384601] nvpps nvpps0: tegra_gte_register_event succeed
[    1.384692] nvpps nvpps0: Registered IRQ 335 for nvpps
[    1.384707] nvpps c6a0104.nvpps: TSC config ptx 0x13
[   22.877145] nvpps nvpps0: tsc_lock_stat:25
[   23.901144] nvpps nvpps0: tsc_lock_stat:24
[   24.925149] nvpps nvpps0: tsc_lock_stat:24
[   25.949134] nvpps nvpps0: tsc_lock_stat:24
[   26.973142] nvpps nvpps0: tsc_lock_stat:24
[   27.997136] nvpps nvpps0: tsc_lock_stat:24
[   38.237143] nvpps nvpps0: tsc_lock_stat:45
[   39.261135] nvpps nvpps0: tsc_lock_stat:44
[   40.285140] nvpps nvpps0: tsc_lock_stat:44
[   41.309134] nvpps nvpps0: tsc_lock_stat:44
[   42.333140] nvpps nvpps0: tsc_lock_stat:44

Kindly let me know how do I proceed. I have spoken to the camera vendor Quanta and they are optimistic that if MPF2 signals reach camera they should be triggered.

Thanks!!
Jishnu

Hi @VickNV

When i run driveworks I see below error which could be the indicator why pps is not triggering.

IMX728SetDeviceConfig[434]Quanta write MNR Data
[13-02-2024 09:35:15] EndpointNVPPS: no PPS event received; missing PPS/GPS signal?
[13-02-2024 09:35:15] EndpointNVPPS: switching to timer mode until PPS signal is available.
[13-02-2024 09:35:15] SIPLClient: ImageQueue timeout
[13-02-2024 09:35:15] SIPLNotifier: Event notification queue timeout
[13-02-2024 09:35:15] SIPLClient: ImageQueue timeout
[13-02-2024 09:35:15] SIPLNotifier: Event notification queue timeout
[13-02-2024 09:35:15] SIPLClient: ImageQueue timeout
[13-02-2024 09:35:15] SIPLNotifier: Event notification queue timeout
[13-02-2024 09:35:15] SIPLClient: ImageQueue timeout
[13-02-2024 09:35:15] SIPLNotifier: Event notification queue timeout
[13-02-2024 09:35:15] SIPLNotifier: Event notification queue timeout
[13-02-2024 09:35:15] SIPLClient: ImageQueue timeout
IMX728SetDeviceConfig[434]Quanta write MNR Data
[13-02-2024 09:35:16] SIPLClient: ImageQueue timeout
[13-02-2024 09:35:16] SIPLNotifier: Event notification queue timeout
[13-02-2024 09:35:16] SIPLClient: ImageQueue timeout
[13-02-2024 09:35:16] SIPLNotifier: Event notification queue timeout
[13-02-2024 09:35:16] SIPLClient: ImageQueue timeout
[13-02-2024 09:35:16] SIPLNotifier: Event notification queue timeout
[13-02-2024 09:35:16] SIPLClient: ImageQueue timeout
[13-02-2024 09:35:16] SIPLNotifier: Event notification queue timeout
[13-02-2024 09:35:16] SIPLNotifier: Event notification queue timeout
[13-02-2024 09:35:16] SIPLClient: ImageQueue timeout
IMX728SetDeviceConfig[423]Quanta write Calibration Data
[13-02-2024 09:35:17] EndpointNVPPS: no PPS event received; missing PPS/GPS signal?
[13-02-2024 09:35:17] EndpointNVPPS: switching to timer mode until PPS signal is available.

I can still see my external pulse is hitting and I see the counter incrementing

335:       1975          0          0          0          0          0          0          0          0          0          0          0  c2f0000.gpio  29 Edge      nvpps_isr


335:       2012          0          0          0          0          0          0          0          0          0          0          0  c2f0000.gpio  29 Edge      nvpps_isr
nvidia@tegra-ubuntu:~$ sudo dmesg | grep pps
[sudo] password for nvidia: 
[    0.068275] pps_core: LinuxPPS API ver. 1 registered
[    0.068276] pps_core: Software ver. 5.3.6 - Copyright 2005-2007 Rodolfo Giometti <giometti@linux.it>
[    1.374704] nvpps c6a0104.nvpps: nvpps_probe
[    1.374716] nvpps c6a0104.nvpps: gpio_pin(509)
[    1.374778] nvpps c6a0104.nvpps: gpio_to_irq(335)
[    1.374781] nvpps c6a0104.nvpps: using ptp notifier method with interface(eqos_0)
[    1.374782] nvpps c6a0104.nvpps: tsc_res_ns(32)
[    1.374893] nvpps c6a0104.nvpps: nvpps cdev(509:0)
[    1.375015] nvpps nvpps0: tegra_gte_register_event succeed
[    1.375101] nvpps nvpps0: Registered IRQ 335 for nvpps
[ 1113.667781] nvpps nvpps0: failed to get PTP_TSC concurrent timestamp from interface(eqos_0)

Hence the below now makes sense that cdi is not getting the event. Do you see something or some setting I am missing to enable which is blocking the notification to cdi?

nvidia@tegra-ubuntu:~$ sudo dmesg | grep gpio
[    0.188761] input: gpio-keys as /devices/platform/gpio-keys/input/input0
[    1.374716] nvpps c6a0104.nvpps: gpio_pin(509)
[    1.374778] nvpps c6a0104.nvpps: gpio_to_irq(335)
[    1.380787] nvethernet 2310000.ethernet: failed to get phy reset gpio error: -2
[    1.387063] nvethernet 6810000.ethernet: failed to get phy reset gpio error: -2
[    1.393720] nvethernet 6910000.ethernet: failed to get phy reset gpio error: -2
[    1.402135] nvethernet 6a10000.ethernet: failed to get phy reset gpio error: -2
[    1.409882] nvethernet 6b10000.ethernet: failed to get phy reset gpio error: -2
[ 1055.011109] cdi-mgr sipl_devblk_0: cdi_mgr_gpio_intr_wait: wait_event_interruptible failed -512
[ 1151.356259] cdi-mgr sipl_devblk_7: cdi_mgr_gpio_intr_wait: wait_event_interruptible failed -512
[ 1194.030238] cdi-mgr sipl_devblk_0: cdi_mgr_gpio_intr_wait: wait_event_interruptible failed -512
[ 1194.030262] cdi-mgr sipl_devblk_2: cdi_mgr_gpio_intr_wait: wait_event_interruptible failed -512

Thanks!!
Jishnu

Also @VickNV

I see that my below configs are not set.

nvidia@tegra-ubuntu:~$ zcat /proc/config.gz | grep -i pps
CONFIG_PPS=y
# CONFIG_PPS_DEBUG is not set
# PPS clients support
# CONFIG_PPS_CLIENT_KTIMER is not set
# CONFIG_PPS_CLIENT_LDISC is not set
# CONFIG_PPS_CLIENT_GPIO is not set
# PPS generators support

Do i need to enable them in defconfig? If yes can you please help me how to do menuconfig/ defconfig inside kernel?

Thanks!!
Jishnu

Your command seems to be missing the --syncMuxSelDes (or -U) option, which is required according to the application code snippet below:

    /* The following functions are applicable only if HW has a capability to support */
#if !NV_IS_SAFETY
    if ((cmdline.bGpioIdxDes == true) || (cmdline.bFsyncMuxDes == true)) {
#else
    if (cmdline.bGpioIdxDes == true) {
#endif
...
    }

Hi @VickNV

I did try -U option but it didn’t work. I will see if I have some logs Ill try sharing. Are you sure I need not enable PPS configs in defconfig? I saw some Jetson forum posts asking to enable this via kernel rebuild.

Thanks
Jishnu

Hi @VickNV

Here is the log with -U I tried today as well. Please share your feedback what to try next to get this working.
nvsipl_log_with_multplexer.txt (46.9 KB)

Please do share some steps I can try. I am completely blocked and lost as I have nothing more try. I am really really stuck.

Thanks!!
Jishnu

As mentioned in your other topic, it seems that a wrong deserializer driver is used. Please contact Quanta and see if they can help with this.

Main: /dvs/git/dirty/git-master_modular/camera/fusa/sipl/src/core/CNvMCamera.cpp: 371: LogPlatformCfg: 	DeserInfo deserInfo
Main: /dvs/git/dirty/git-master_modular/camera/fusa/sipl/src/core/CNvMCamera.cpp: 372: LogPlatformCfg: 		name: MAX96712