Lane Swizzle to remap CSI lanes on Orin Nano

Hello NVIDIA community.

We are working with an NVIDIA Jetson Orin Nano receiving a video stream where the CSI lanes are incorrectly mapped. Incoming data lanes are not correctly mapped to the data lanes in CAM1 port in the Orin Nano. To solve this issue we used the lane swizzle register to make the Orin software stack interpret them differently.

NVCSI_PHY_0_NVCSI_CIL_LANE_SWIZZLE_CTRL_#

On csi5_fops driver we modified the brick_config’s lane swizzle attribute to modify the mapping when on NVCSI_PORT_C. We changed this value to NVCSI_LANE_SWIZZLE_B0B1A0A1. This seems to have worked since v4l2-ctl is now getting a video stream and we were able to get some frames that make sense. The issue is that there are still some buffers being dropped:

v4l2-ctl -d /dev/video0 --set-fmt-video=width=620,height=512,pixelformat=0 --stream-mmap
<<<<<< 30.10 fps, dropped buffers: 27
<<<<< 30.10 fps, dropped buffers: 25
<<<<<< 30.10 fps, dropped buffers: 25
<<<<<< 30.10 fps, dropped buffers: 24
<<<<<< 30.10 fps, dropped buffers: 26
<<<<<<< 30.10 fps, dropped buffers: 19
<<<<< 30.10 fps, dropped buffers: 36
<<< 30.10 fps, dropped buffers: 4

The main question is:

Does lane swizzling introduce any interference into the stream? Could it affect the stream in any way, such as video timing or signal integrity?

Best regards,

Cristian Hidalgo
Embedded SW Engineer at RidgeRun
Contact us: support@ridgerun.com
Developers wiki: https://developer.ridgerun.com/
Website: www.ridgerun.com

— 🤖 This is an automated AI response. I’m here to help, but please verify important details! —

To address the issue of lane swizzling introducing interference into the stream on the Jetson Orin Nano, we need to consider how lane swizzling affects the video stream. Lane swizzling is a technique used to remap the CSI lanes to ensure correct data interpretation by the Orin Nano’s software stack.

According to the provided context, modifying the brick_config’s lane swizzle attribute in the csi5_fops driver to NVCSI_LANE_SWIZZLE_B0B1A0A1 for NVCSI_PORT_C has allowed the system to interpret the CSI lanes correctly, enabling v4l2-ctl to receive a video stream. However, there are still dropped buffers observed during streaming.

The context does not explicitly state that lane swizzling introduces interference into the stream in terms of video timing or signal integrity. Instead, it suggests that the modification has successfully allowed the system to receive a meaningful video stream, albeit with some dropped buffers.

Dropped buffers, as indicated by the v4l2-ctl output, could be due to various factors such as bandwidth limitations, processing power, or other system resource constraints, rather than the lane swizzling itself. The Jetson Orin Nano’s performance, the specific camera module used, and the settings for the video stream (e.g., resolution, frame rate) can all impact the system’s ability to handle the video stream without dropping buffers.

To minimize dropped buffers, optimizing system settings, ensuring adequate resources for video processing, and possibly adjusting the video stream settings (e.g., lowering the resolution or frame rate) could be necessary. However, the provided context does not offer specific guidance on how lane swizzling might affect the stream beyond enabling correct lane interpretation.

In summary, while lane swizzling is crucial for correctly interpreting the CSI lanes on the Jetson Orin Nano, the context provided does not clearly indicate that it introduces interference into the stream. Instead, it highlights the importance of this technique in enabling the reception of a meaningful video stream, with the dropped buffers likely attributable to other system or resource limitations.

For further optimization or troubleshooting of the video streaming performance, including the issue of dropped buffers, consulting the Jetson Orin Nano documentation or seeking support from NVIDIA or the developer community might provide more detailed insights and solutions tailored to the specific hardware and software configurations in use.

— We support team will also look into your issue to have further suggestions soon. please stay tuned. —

hello cristian.hidalgo,

no, lane swizzling itself should not introduce interference into the stream. lane swizzling is just a remapping of which physical lane carries which logical lane.