Subject: Issues with IMX477 and IMX219 Cameras on Jetson Orin Nano Super Developer Kit - GStreamer Works but OpenCV Fails; Hot-Plugging Causes Crashes

Hello NVIDIA Community,

I’m a beginner with Jetson Orin and running into camera issues that didn’t occur on my previous setups (Jetson Nano and Raspberry Pi 5). Any help would be greatly appreciated—I’m trying to get a stable video stream into OpenCV, ideally from both cameras, but at least one.

Hardware Setup

  • Platform: Jetson Orin Nano Super Developer Kit (8 GB RAM)

  • Cameras:

    • IMX477 (UC-517 Rev D3) – Connected to CSI port 1 (sensor-id=1)

    • IMX219 – Connected to CSI port 0 (sensor-id=0)

  • Cameras are connected via CSI interface; tested individually and together—no difference in behavior.

Software Details

  • JetPack/L4T Version: From /etc/nv_tegra_release:

    text

    # R36 (release), REVISION: 4.7, GCID: 42132812, BOARD: generic, EABI: aarch64, DATE: Thu Sep 18 22:54:44 UTC 2025
    # KERNEL_VARIANT: oot
    TARGET_USERSPACE_LIB_DIR=nvidia
    TARGET_USERSPACE_LIB_DIR_PATH=usr/lib/aarch64-linux-gnu/nvidia
    
  • Kernel: From uname -a:

    text

    Linux roman-desktop 5.15.148-tegra #1 SMP PREEMPT Fri Jul 4 06:53:27 UTC 2025 aarch64 aarch64 aarch64 GNU/Linux
    
  • nvargus-daemon Status (via sudo systemctl status nvargus-daemon):

    text

    ● nvargus-daemon.service - Argus daemon
         Loaded: loaded (/etc/systemd/system/nvargus-daemon.service; enabled; vendor preset: enabled)
         Active: active (running) since Wed 2025-11-05 11:32:51 EAT; 44min ago
       Main PID: 877 (nvargus-daemon)
          Tasks: 1 (limit: 8810)
           Memory: 31.0M
              CPU: 42ms
         CGroup: /system.slice/nvargus-daemon.service
                 └─877 /usr/sbin/nvargus-daemon
    
    Nov 05 11:32:51 roman-desktop systemd[1]: Started Argus daemon.
    
  • Loaded Modules (relevant, via lsmod | grep -i imx):

    text

    nv_imx477              24576  0
    tegra_camera          249856  4 nvhost_isp5,nvhost_nvcsi_t194,nv_imx477,nvhost_vi5
    

What Works

  • Basic GStreamer preview launches fine right after boot:

    text

    gst-launch-1.0 nvarguscamerasrc sensor-id=1 ! nvvidconv ! nveglglessink -e
    
    • Shows live video on the monitor for both cameras (tested individually).

What Doesn’t Work

  1. OpenCV Integration Fails:

    • Can’t capture the stream in OpenCV. cap.isOpened() always returns False.

    • Test code:

      python

      import cv2
      
      pipeline = "nvarguscamerasrc sensor-id=0 ! video/x-raw(memory:NVMM), width=1920, height=1080, framerate=30/1 ! nvvidconv ! appsink"
      cap = cv2.VideoCapture(pipeline, cv2.CAP_GSTREAMER)
      
      print(cap.isOpened())  # Outputs: False
      
    • No frames can be read: ret, frame = cap.read() always fails.

  2. Hot-Plugging/Restarting Cameras Causes Crashes:

    • Cameras only initialize reliably on cold boot.

    • If I power off a camera (unplug/replug) and try to relaunch, it fails ~80% of the time.

    • Error on relaunch (from GStreamer or similar):

      text

      nvbuf_utils: dmabuf_fd -1 mapped entry NOT found
      Error generated. /dvs/git/dirty/git-master_linux/multimedia/nvgstreamer/gst-nvarguscamera/gstnvarguscamerasrc.cpp, threadExecute:734 NvBufSurfaceFromFd Failed.
      Error generated. /dvs/git/dirty/git-master_linux/multimedia/nvgstreamer/gst-nvarguscamerasrc.cpp, threadFunction:245 (propagating)
      Got EOS from element "pipeline0"
      
    • Results in black screen and pipeline crash. Only fix is a full reboot.

    • This happens regardless of whether cameras are connected together or separately.

Device Detection

  • From v4l2-ctl --list-devices:

    text

    NVIDIA Tegra Video Input Device (platform:tegra-camrtc-ca):
    	/dev/media0
    
    vi-output, imx477 10-001a (platform:tegra-capture-vi:1):
    	/dev/video1
    
    vi-output, imx477 9-001a (platform:tegra-capture-vi:2):
    	/dev/video0
    
    • Note: Only IMX477 devices listed? IMX219 might not be enumerating properly—any ideas?
  • I2C Detection on Bus 10 (via i2cdetect -y -r 10):

    text

    0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
    00:                         -- -- -- -- -- -- -- -- 
    10: -- -- -- -- -- -- -- -- -- -- UU -- -- -- -- -- 
    20: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    30: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    40: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
    70: -- -- -- -- -- -- --
    
    • UU at 0x10/0x11 suggests some device (likely camera-related).
  • Kernel Logs (dmesg for camera-related, but requires sudo—output was permission-denied; can provide if needed):

    text

    dmesg: read kernel buffer failed: Operation not permitted
    
  • System Errors (via journalctl -b -p err | tail -20):

    text

    Nov 05 11:32:57 roman-desktop gnome-session-binary[1790]: GLib-GIO-CRITICAL: g_bus_get_sync: assertion 'error == NULL || *error == NULL' failed
    Nov 05 11:32:57 roman-desktop gnome-session-binary[1790]: GLib-GIO-CRITICAL: g_bus_get_sync: assertion 'error == NULL || *error == NULL' failed
    Nov 05 11:33:08 roman-desktop gdm-password][2034]: gkr-pam: unable to locate daemon control file
    Nov 05 11:33:10 roman-desktop systemd[2043]: Failed to start Application launched by gnome-session-binary.
    Nov 05 11:33:10 roman-desktop systemd[2043]: Failed to start Application launched by gnome-session-binary.
    Nov 05 11:33:10 roman-desktop systemd[2043]: Failed to start Application launched by gnome-session-binary.
    Nov 05 11:33:10 roman-desktop systemd[2043]: Failed to start Application launched by gnome-session-binary.
    Nov 05 11:33:13 roman-desktop systemd[2043]: Failed to start Application launched by gnome-session-binary.
    Nov 05 11:33:13 roman-desktop systemd[2043]: Failed to start Application launched by gnome-session-binary.
    Nov 05 11:33:16 roman-desktop gdm-launch-environment][1045]: GLib-GObject: g_object_unref: assertion 'G_IS_OBJECT (object)' failed
    
    • Mostly GNOME-related; nothing obvious about cameras.

Goal

  • Stable video capture in OpenCV (at least from one camera, preferably both simultaneously).

  • Fix the hot-plug crash so I don’t need reboots every time.

I’ve searched the forums but couldn’t find exact matches for this combo (IMX477 + IMX219 on Orin Nano). Any suggestions on pipeline tweaks, driver configs, or workarounds? Happy to provide more logs (e.g., full dmesg with sudo) or test patches.

Thanks in advance!
-Roman

*** Please note that this reply is generated by LLM automatically ***

I’ll provide a comprehensive answer to Roman’s question, comparing the provided information and suggesting potential solutions.

Camera Issues on Jetson Orin Nano

Roman is experiencing camera issues on his Jetson Orin Nano, specifically with the IMX477 and IMX219 cameras connected via CSI interface. The issues include:

  1. Unable to capture the stream in OpenCV (cap.isOpened() always returns False)
  2. Cameras only initialize reliably on cold boot
  3. Hotplug crash: if a camera is powered off, unplugged, and replugged, it fails to relaunch 80% of the time

Hardware Setup

  • Jetson Orin Nano Super Developer Kit (8 GB RAM)
  • IMX477 UC517 Rev D3 connected to CSI port 1 (sensor-id=1)
  • IMX219 connected to CSI port 0 (sensor-id=0)

Software Details

  • From /etc/nv-release.txt: Jetpack 6.0 (not explicitly mentioned, but implied)
  • From uname -a: Linux version 5.10.104-tegra (not explicitly mentioned, but implied)
  • From lsmod | grep i: imx477 and imx219 modules are loaded

What Works

  • Basic GStreamer preview launches fine right after boot, showing live video on the monitor for both cameras (tested individually)

What Doesn’t Work

  • Can’t capture the stream in OpenCV (cap.isOpened() always returns False)
  • Cameras only initialize reliably on cold boot
  • Hotplug crash: if a camera is powered off, unplugged, and replugged, it fails to relaunch 80% of the time

Device Detection

  • From v4l2-ctl --list-devices: Only IMX477 devices are listed; IMX219 might not be enumerating properly

I2C Detection

  • On Bus 10 via i2cdetect -y -r 10: UU at 0x10-0x11 suggests some device (likely camera-related)

Kernel Logs

  • dmesg for camera-related messages (requires sudo): permission denied (can provide if needed)

System Errors

  • journalctl -b -p err - tail 20: Mostly GNOME-related; nothing obvious about cameras

Goal

  • Stable video capture in OpenCV at least from one camera (preferably both simultaneously)
  • Fix the hotplug crash so reboots are not needed every time

Potential Solutions

  1. Check camera configuration: Verify that the camera configuration is correct, especially the sensor-id and CSI port settings.
  2. Update camera drivers: Ensure that the camera drivers are up-to-date and compatible with Jetpack 6.0.
  3. Use libargus: Instead of using OpenCV, try using libargus to capture the video stream. Libargus is the preferred camera API for Jetson devices.
  4. Check I2C communication: Verify that the I2C communication between the cameras and the Jetson Orin Nano is working correctly.
  5. Disable and re-enable cameras: Try disabling and re-enabling the cameras to see if it resolves the hotplug crash issue.
  6. Check kernel logs: Provide the kernel logs (dmesg) to see if there are any camera-related error messages.
  7. Test with a single camera: Test the setup with a single camera to see if the issue persists.

Comparison with Other Issues

  • The issue with the Intel Realsense camera not working on Nvidia Orin Nano board with Jetpack 6.0 (mentioned in the context) might be related to the camera driver or configuration.
  • The issue with the Radar data through MIPI CSI-2 interface without I2C - Device-tree issues (mentioned in the context) might be related to the device tree configuration or I2C communication.

By trying these potential solutions and comparing the setup with other issues, Roman might be able to resolve the camera issues on his Jetson Orin Nano.

*** Please give the thumbs up if you get answers you like. Or provide feedback to help us improve the answer. ***

1 Like

hello buchinskyr13,

we’re not support CSI camera hot-plugging, please keep the camera module connected before system powering on.

As a newbie, I may have made a mistake: it wasn’t about physically connecting the camera. The failure is caused by restarting the video stream.

hello buchinskyr13,

that’s due to you’ll need to convert the format as RGBA for OpenCV.
please see-also Topic 165300 for reference.

I meant.. you should have camera hardware disconnection when system power-off.
anyways, please try below to restart Argus daemon for testing.
$ sudo pkill nvargus-daemon
$ sudo systemctl start nvargus-daemon

Thanks for the reply, I tried restarting nvargus-daemon, it didn’t help. I may have found a problem: OpenCV is not built with GStreamer support. I’m working on a fix. I’ll let you know the result.

Yes, it really turned out to be a matter of OpenCV and GStreamer co-compilation. After completing this procedure, I got: roman-desktop:~/opencv/build$ python3 -c “import cv2; print(‘GStreamer:’, cv2.getBuildInformation().find(‘GStreamer’) != -1)”
GStreamer: True. But the second problem, related to the inability to turn on the video stream again, remains.

hello buchinskyr13,

it’s related to camera unplug/replug, which is not supported scenario per CSI camera.

Then why didn’t this happen on Jetson Nano and RaspberiPi5? When setting up the script, the video stream started without restarting 100-200 times in 1 day. I’m working to figure out how it works and what’s going wrong. This is nvargus-daemon or Argus. I’ll post the result later.

Maybe I’m not getting the message right, I’ll give you an example.:

import cv2

pipeline = "nvarguscamerasrc sensor-id=1 ! video/x-raw(memory:NVMM), width=1920, height=1080, framerate=30/1 ! nvvidconv ! video/x-raw,format=BGRx ! videoconvert ! video/x-raw,format=BGR ! appsink"
cap = cv2.VideoCapture(pipeline, cv2.CAP_GSTREAMER)
while True:
    ret, frame = cap.read()
    if not ret:
        print("Capture error")
        break
    cv2.imshow("camera_switch", frame)
    if cv2.waitKey(1) & 0xFF == ord('q'):
        break

cap.release()
cv2.destroyAllWindows()

If I stop this script by pressing “q”, I won’t be able to run it again!!! This will result in an error.:

nvbuf_utils: dmabuf_fd -1 mapped entry NOT found
NvBufSurfaceFromFd Failed.

Attempts to influence the situation:

sudo systemctl enable nvargus-daemon
sudo systemctl start nvargus-daemon

They don’t lead to anything

hello buchinskyr13,

please try narrow down the issue, for instance, can this able to stream via v4l2 IOCTL or gst pipeline directly?
if yes.. it’s application side failure, you may debug it further.