External PPS not triggering fsync generator

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,

I am trying to trigger the camera from external PPS. Currently I am able to ensure that PPS signal is fed and NVPPS_GETEVENT is detecting it.

From the driver code I am setting it into NVPPS_MODE_TIMER NVPPS_TSC_NSEC mode. I am not running PTP4L at the moment.

Here is my DTS

tsc_sig_gen@c6a0000 {
    compatible = "nvidia,tegra234-cdi-tsc";
    ranges = <0x0 0x0 0xc6a0000 0x10000>;
    reg = <0x0 0xc6a0000 0x0 0x18>;
    #address-cells = <1>;
    #size-cells = <1>;
    status = "okay";

    gen0: generator@380 {
        reg = <0x380 0x80>;
        freq_hz = <10>;
        duty_cycle = <25>;
        offset_ms = <0>;
        status = "okay";
    };

    gen1: generator@400 {
        reg = <0x400 0x80>;
        freq_hz = <10>;
        duty_cycle = <25>;
        offset_ms = <0>;
        status = "okay";
    };

    gen2: generator@480 {
        reg = <0x480 0x80>;
        freq_hz = <10>;
        duty_cycle = <25>;
        offset_ms = <0>;
        status = "okay";
    };

    gen3: generator@500 {
        reg = <0x500 0x80>;
        freq_hz = <10>;
        duty_cycle = <25>;
        offset_ms = <0>;
        status = "okay";
    };
};

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

I will also add the logs of running nvsipl as well as driveworks camera sample here. Could you please help me understand why I don’t see the trigger to camera? I get 0 fps in nvsipl_camera application and timeout in dw camera application.

nvsipl_log.txt (33.8 KB)
dw_log.txt (15.7 KB)

Thanks !!
Jishnu

Since you’re using the Quanta IMX728 camera module (HZKJ_IMX728_ES2_V2_120FOV) and it’s supported by Quanta, have you confirmed with them if they’ve verified fsync with the camera module?
This could provide efficient clarification.

Hi @VickNV

I spoke to Quanta. So they say if we could verify that the external trigger is reaching the deserialiser or the MFP2 pin then they could help us if the camera isn’t responding. As long as the trigger signal reaches the deserialiser they are confident camera should function since internally generated fysnc is working.

So can you help us understand if there is a way to verify this trigger is reaching the pin. Can we print or read some pin value? This will help us debug ahead and coordinate with Quanta if needed.

Thanks!!
Jishnu

Any updates?

Per the following note (from Heterogenous Frame Synchronization | NVIDIA Docs), only newer systems support this feature. Could you double-check which board you’re using?

Note: This function requires hardware support, which is available on P3710-10-a04, p3710-10-s05, p3710-12-a04, and p3710-12-s05. Refer to DRIVE Platform Supported Boards for the board information.

Hi @VickNV

I could find below from the logs of flashing 6.0.8.1.

Found matching board id p3710-10-s05 in 940-63710-0010-200 sku

I believe this is compatible. How do we debug ahead?

Is there a way to verify “if we could verify that the external trigger is reaching the deserialiser or the MFP2 pin then they could help us if the camera isn’t responding.” ?

Thanks!!
Jishnu

Thank you for confirming the compatibility.

I’ll check your questions with our team and get back to you as soon as possible.

In the meantime, could you please provide details regarding any modifications you’ve made based on 6.0.8.1? Additionally, sharing the command and output of “nvsipl_camera” would be helpful for further investigation.

After reviewing this topic again, I noticed you already provided the command below. However, it doesn’t utilize the related options mentined in Heterogenous Frame Synchronization.

 sudo ./nvsipl_camera -c HZKJ_IMX728_ES2_V2_120FOV_CPHY_x4  -m "0001 0 0 0 " -sR012 -D '0 0 0 0'  -v 4

Hi @VickNV

My target was to use driveworks and not nvsipl app. Nevertheless I understand the point you are referring to. I will try to run as per the document example and share the results. Let me re try and I will share newer logs. Meanwhile if there are more debug points that would be helpful especially since I am using driveworks sensor camera app.

Thanks!!
Jishnu

Hello @VickNV

Were you able to get some info on how I can tap on “if we could verify that the external trigger is reaching the deserialiser or the MFP2 pin then they could help us if the camera isn’t responding.” ? Any possible way to tap or print the values. We would like to know if the external trigger did create any Frame sync signal.

I will try share output of Heterogenous Frame Synchronization using nvsipl_camera app asap. I couldn’t catch hold of orin last 2 days.

Thanks!!
Jishnu

@VickNV Stuck with the same problem. Waiting for a solution.

Hi @VickNV

I tried running the nvsipl_camera app as following command:
sudo ./nvsipl_camera -c HZKJ_IMX728_ES2_V2_120FOV_CPHY_x4 -m “1000 0 0 0” -sR -v 4 -D ‘2 2 2 2 2 2 2 2 2 2 2 2 2 2 2 2’ -U ‘10 a c’ --nvsci

Below is the result of that. I get 0 frames.
nvsipl_log.txt (82.7 KB)

I got above command with reference to below links

Currently, I see that the gpio is triggered. My interrupt list is showing increments with every pulse that is fed.
335: 1047 0 0 0 0 0 0 0 0 0 0 0 c2f0000.gpio 29 Edge nvpps_isr

My dmesg looks as below:
nvidia@tegra-ubuntu:~$ sudo dmesg | grep gpio
[sudo] password for nvidia:
[ 0.199990] input: gpio-keys as /devices/platform/gpio-keys/input/input0
[ 1.380195] nvpps c6a0104.nvpps: gpio_pin(509)
[ 1.380234] nvpps c6a0104.nvpps: gpio_to_irq(335)
[ 1.388033] nvethernet 2310000.ethernet: failed to get phy reset gpio error: -2
[ 1.393967] nvethernet 6810000.ethernet: failed to get phy reset gpio error: -2
[ 1.401517] nvethernet 6910000.ethernet: failed to get phy reset gpio error: -2
[ 1.411907] nvethernet 6a10000.ethernet: failed to get phy reset gpio error: -2
[ 1.420219] nvethernet 6b10000.ethernet: failed to get phy reset gpio error: -2
[ 193.619529] cdi-mgr sipl_devblk_0: cdi_mgr_gpio_intr_wait: wait_event_interruptible failed -512
[ 259.112981] cdi-mgr sipl_devblk_0: cdi_mgr_gpio_intr_wait: wait_event_interruptible failed -512

This seems to be th reason deserialiser may not be triggered. But I am unaware what am i doing wrong.

Can you please suggest some steps to resolve this issue?

@SivaRamaKrishnaNV Any inputs from your end would also be really helpful. I am stuck on this issue from a long time.

Hi @VickNV @SivaRamaKrishnaNV

This feature of syncing external trigger to internal fsync trigger is a feature within the purview of Nvidia?

Can you please help me here to understand how to get the external trigger trigger the camera?

Thanks!!
Jishnu

As mentioned in my post (NvMedia NvSIPL not entering Hetrogeneous Frame sync mode - #7 by VickNV), it appears that the correct deserializer driver was not used based on the provided log file. I recommend checking this with Quanta.

Hi @VickNV

Sorry but I am a bit confused. Is heterogeneous Frame sync and NvPPS related? Quanta agreed about the missing implementation for Heterogeneous Frame sync. But they said NvPPS should work irrespective. Its something you may be able to help me resolve. I think Configuration for running NVPPS GPIO mode this question is the relevant question to ask for NvPPS case. As I understand from @SivaRamaKrishnaNV NvPPS may not exactly trigger the camera. it may only help align.

Now open question is

  1. what is the device tree configuration for this ie is frame-sync group enabled? Or will it work with internal clock and no frame-sync is required?
  2. Some info on how NvPPS helps us align and do correction of the timestamp

Thanks for all the help!!
Jishnu

PPS is only 1Hz. Camera Frame Sync is usually 30Hz. Their frequency are different.

nVidia Orin PDK doesn’t support link the PPS input GPIO to Camera Frame Sync Pin (Output to Camera module).
This is not relative with Camera module design, it is NV platform’s design limitation. (Implementation)

You could try to register a gpio driver for PPS input (nvpps driver also need to customize to sharing the GPIO), when it got the interrupt, it will trigger the camera framesync gpio. But it is software implementation, the latency is TBC. It depends on how precise you need to sync the Lida and Camera. BTW, this implemenation also only supports 1Hz trigger. Or you should customermize the driver to meet your request.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.