Difference between revisions of "NVIDIA Jetson Orin Nano/Camera Sensors Support/IMX708"

From RidgeRun Developer Connection
Jump to: navigation, search
(Created page with "<noinclude> {{NVIDIA Jetson Orin Nano/Head|next=|metakeywords=|metadescription=}} </noinclude> This wiki provides information about enabling the Raspberry Pi Camera V2.1 (IMX...")
 
 
(29 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 +
 
<noinclude>
 
<noinclude>
 
{{NVIDIA Jetson Orin Nano/Head|next=|metakeywords=|metadescription=}}
 
{{NVIDIA Jetson Orin Nano/Head|next=|metakeywords=|metadescription=}}
 
</noinclude>
 
</noinclude>
  
This wiki provides information about enabling the Raspberry Pi Camera V2.1 (IMX219) driver on the Jetson Orin Nano developer kit. The information provided was tested on:
+
 
 +
 
 +
This wiki provides information about the IMX708 camera sensor driver developed by RidgeRun. The information provided was tested on:
 
<pre>
 
<pre>
* JetPack: 5.1.1
+
* Jetson Orin Nano developer kit from NVIDIA
* Jetson Linux: 35.3.1
+
* JetPack version: 5.1.1
* One IMX219 Rapsberry Pi camera module V2.1
+
* Linux for Tegra version: 35.3.1
 +
* 1x IMX708 Rapsberry Pi Camera Module V3
 
</pre>
 
</pre>
 
The Raspberry Pi Camera V2.1 camera module (IMX219) is compatible with the Jetson Orin Nano developer kit from NVIDIA. The camera module can be attached to the Orin Nano developer kit using an adapter to convert the 15-pin MIPI CSI output of the camera module to the 22-pin MIPI CSI camera input of the Orin Nano. The converter can look like the following images:
 
  
 
{| class="wikitable" style="margin: auto;"
 
{| class="wikitable" style="margin: auto;"
|[[File:Cable conv.jpg|thumb| center | 200px | Figure 1: Adapter cable [https://www.arducam.com/wp-content/uploads/2020/02/strock-15mm-Pi-Zero-Cable-one-end-copy.png Arducam 38mm 15 to 22 pin]]]
+
|[[File:IMX708-ORIN-NANO.jpg|thumb| center | 500px | Figure 1: Raspberry Pi 3 Camera Module 3 connected to a NVIDIA® Jetson Orin Nano™]]  
|[[File:Module conv2.jpg|thumb| center | 400px | Figure 2: Adapter module [https://www.arducam.com/wp-content/uploads/2020/02/Compute-Module-camera-adapter_1.png Compute Module camera adapter]]]
 
 
|}
 
|}
  
In order to enable the driver support, you need to run a Python script that comes with JetPack 5.1.1 under release L4T 35.3.1. The script can be executed with the following command:
 
<pre>
 
sudo /opt/nvidia/jetson-io/jetson-io.py
 
</pre>
 
  
Then, a menu will appear. Follow the options below in order to enable the IMX219 support for two cameras:
+
=Raspberry Pi Camera Module 3 & driver features=
 +
The Raspberry Pi Camera V3 camera module (IMX708) is compatible with the Jetson Orin Nano developer kit from NVIDIA. The IMX708 is a cost-effective camera module capable of capturing a resolution higher than 4K. Table 1 shows a few interesting characteristics of the camera module. The driver developed by RidgeRun has the specifications shown in Table 2. If you need to extend the driver to meet your project needs, feel free to [https://www.ridgerun.com/contact contact us].
  
<pre>
 
-> Configure Jetson 24pin CSI Connector
 
-> Configure for compatible hardware
 
-> Camera IMX219 Dual
 
-> Save pin changes
 
-> Save and reboot to reconfigure pins
 
</pre>
 
  
After the board is rebooted, you can try to run the following command:
+
{| class="wikitable" style="margin: auto;"
 +
|+ Table 1: Raspberry Pi Module 3 specs
 +
|-
 +
! Parameter !! Description
 +
|-
 +
| Image sensor || IMX708
 +
|-
 +
| Optical Size || 1/2.43(7.4mm sensor diagonal)
 +
|-
 +
| Number of effective pixels || Height = 4608, Width = 2592 <br>
 +
|-
 +
| Pixel Size || 1.4μm × 1.4μm
 +
|-
 +
| Interface || MIPI CSI-2 Interface
 +
|-
 +
| Shutter Type || Rolling Shutter
 +
|-
 +
| Color Filter || Color
 +
|-
 +
| Minimun Focus Distance || 5 cm
 +
|-
 +
| Binning Support || Yes
 +
|-
 +
| HDR Support || Yes
 +
|-
 +
| Auto-Focus (PDAF) || Yes
 +
|}
  
<pre>
 
v4l2-ctl --set-fmt-video=width=1920,height=1080,pixelformat=RG10 --stream-mmap --stream-count=300 -d /dev/video0
 
</pre>
 
  
This command will start streaming from camera port 0 (cam0). If you want to check the camera port 1 (cam1), change the video device to video1. After running the command you must see the next output in your terminal window:
+
<br>
 
+
{| class="wikitable" style="margin: auto;"
<pre>
+
|+ Table 2: Driver specs
<<<<<<<<<<<<<<<<<<<<<<< 21.19 fps
+
|-
<<<<<<<<<<<<<<<<<<<<< 21.19 fps
+
! Parameter !! Description
<<<<<<<<<<<<<<<<<<<<< 21.19 fps
+
|-
<<<<<<<<<<<<<<<<<<<<< 21.19 fps
+
| Pixel Depth || RAW10
<<<<<<<<<<<<<<<<<<<<< 21.19 fps
+
|-
<<<<<<<<<<<<<<<<<<<<<< 21.19 fps
+
| Resolution || 4608 x 2592
<<<<<<<<<<<<<<<<<<<<< 21.19 fps
+
|-
<<<<<<<<<<<<<<<<<<<<< 21.19 fps
+
| Framerate || 14.35
<<<<<<<<<<<<<<<<<<<<< 21.19 fps
+
|}
<<<<<<<<<<<<<<<<<<<<< 21.19 fps
 
<<<<<<<<<<<<<<<<<<<<<< 21.19 fps
 
<<<<<<<<<<<<<<<<<<<<< 21.19 fps
 
<<<<<<<<<<<<<<<<<<<<< 21.19 fps
 
<<<<<<<<<<<<<<<<<<<<< 21.19 fps
 
</pre>
 
 
 
At this point you should be able to capture successfully.
 
  
  
=Known issues=
+
You can use V4L2 or GStreamer to capture using the RidgeRun driver. Figure 2 below is a screenshot of the video obtained using the following GStreamer pipeline on the Orin Nano:
Before enabling the IMX219 support with the jetson-io.py tool, you may find out that if you connect the camera to the development board it will be recognized by the kernel and the driver loaded. You can verify this by running the dmesg command and grepping the keyword “imx219”. You will find the “bound” message for both ports (in case you have connected both cameras at the same time).
 
 
 
 
<pre>
 
<pre>
[  694.226388] imx708 9-001a: tegracam sensor driver:imx708_v2.0.6
+
nvidia@ubuntu:~$ GST_DEBUG="GST_TRACER:7" GST_TRACERS="framerate" gst-launch-1.0 nvarguscamerasrc sensor_id=1 -e ! 'video/x-raw(memory:NVMM),width=4608,height=2592,framerate=14/1, format=NV12' ! nvvidconv ! x264enc tune=zerolatency insert-vui=true pass=quant quantizer=32 speed-preset=ultrafast bitrate=5000 ! mpegtsmux ! filesink location=output_office_cam1.mp4
[  694.527906] tegra-camrtc-capture-vi tegra-capture-vi: subdev imx708 9-001a bound
 
[  694.529755] imx708 10-001a: tegracam sensor driver:imx708_v2.0.6
 
[  694.834263] tegra-camrtc-capture-vi tegra-capture-vi: subdev imx708 10-001a bound
 
 
</pre>
 
</pre>
  
Even though the driver is bound, if you try to check the video capabilities by running:
+
{| class="wikitable" style="margin: auto;"
 
+
|[[File:IMX708-ORIN-NANO-VIDEO.gif|thumb| center | 500px | Figure 2: Raspberry Pi 3 Camera Module 3 recording (4608x2592@14.35fps)]]
<pre>
+
|}
v4l2-ctl --all
 
</pre>
 
  
The process will get stuck without showing you any kind of information (you can stop this command using ctrl+c). You will see the following error if you try to capture:
 
  
<pre>
+
= Installation Instructions =  
[  394.042165] bwmgr API not supported                                                                   
 
[  396.722887] tegra-camrtc-capture-vi tegra-capture-vi: uncorr_err: request timed out after 2500 ms                   
 
[  396.735648] tegra-camrtc-capture-vi tegra-capture-vi: err_rec: attempting to reset the capture channel             
 
[  396.745787] (NULL device *): vi_capture_control_message: NULL VI channel received                                   
 
[  396.753540] t194-nvcsi 13e40000.host1x:nvcsi@15a00000: csi5_stream_close: Error in closing stream_id=0, csi_port=
 
[  396.764228] (NULL device *): vi_capture_control_message: NULL VI channel received                                   
 
[  396.771968] t194-nvcsi 13e40000.host1x:nvcsi@15a00000: csi5_stream_open: VI channel not found for stream- 0 vc- 0   
 
[  396.782756] tegra-camrtc-capture-vi tegra-capture-vi: err_rec: successfully reset the capture channel
 
</pre>
 
 
 
This is due to an error in the way the device tree is being configured. To fix this, you will need to run the jetson-io.py tool and enable the IMX219 camera support.
 
  
 +
Please refer to [https://developer.ridgerun.com/wiki/index.php/Raspberry_Pi_Camera_Module_3_IMX708_Linux_driver_for_Jetson this guide] to have a complete guide to install the driver in the Jetson Orin Nano. We widely recommend reading the whole guide in order to get a better understanding on what is the installation guide flow. Once you have read the wiki, consult the [https://developer.ridgerun.com/wiki/index.php/Raspberry_Pi_Camera_Module_3_IMX708_Linux_driver_for_Jetson Index] and visit the exact section you need.
  
 
<noinclude>
 
<noinclude>
 
{{NVIDIA Jetson Orin Nano/Foot||}}
 
{{NVIDIA Jetson Orin Nano/Foot||}}
 
</noinclude>
 
</noinclude>
 +
 +
{{ContactUs}}
 +
 +
[[Category:Jetson]][[Category:Jetson V4L2 Drivers]][[Category:Sony]]

Latest revision as of 10:22, 8 August 2023



  Index  


Nvidia-preferred-partner-badge-rgb-for-screen.png





This wiki provides information about the IMX708 camera sensor driver developed by RidgeRun. The information provided was tested on:

* Jetson Orin Nano developer kit from NVIDIA
* JetPack version: 5.1.1
* Linux for Tegra version: 35.3.1
* 1x IMX708 Rapsberry Pi Camera Module V3
Figure 1: Raspberry Pi 3 Camera Module 3 connected to a NVIDIA® Jetson Orin Nano™


Raspberry Pi Camera Module 3 & driver features

The Raspberry Pi Camera V3 camera module (IMX708) is compatible with the Jetson Orin Nano developer kit from NVIDIA. The IMX708 is a cost-effective camera module capable of capturing a resolution higher than 4K. Table 1 shows a few interesting characteristics of the camera module. The driver developed by RidgeRun has the specifications shown in Table 2. If you need to extend the driver to meet your project needs, feel free to contact us.


Table 1: Raspberry Pi Module 3 specs
Parameter Description
Image sensor IMX708
Optical Size 1/2.43(7.4mm sensor diagonal)
Number of effective pixels Height = 4608, Width = 2592
Pixel Size 1.4μm × 1.4μm
Interface MIPI CSI-2 Interface
Shutter Type Rolling Shutter
Color Filter Color
Minimun Focus Distance 5 cm
Binning Support Yes
HDR Support Yes
Auto-Focus (PDAF) Yes



Table 2: Driver specs
Parameter Description
Pixel Depth RAW10
Resolution 4608 x 2592
Framerate 14.35


You can use V4L2 or GStreamer to capture using the RidgeRun driver. Figure 2 below is a screenshot of the video obtained using the following GStreamer pipeline on the Orin Nano:

nvidia@ubuntu:~$ GST_DEBUG="GST_TRACER:7" GST_TRACERS="framerate" gst-launch-1.0 nvarguscamerasrc sensor_id=1 -e ! 'video/x-raw(memory:NVMM),width=4608,height=2592,framerate=14/1, format=NV12' ! nvvidconv ! x264enc tune=zerolatency insert-vui=true pass=quant quantizer=32 speed-preset=ultrafast bitrate=5000 ! mpegtsmux ! filesink location=output_office_cam1.mp4
Figure 2: Raspberry Pi 3 Camera Module 3 recording (4608x2592@14.35fps)


Installation Instructions

Please refer to this guide to have a complete guide to install the driver in the Jetson Orin Nano. We widely recommend reading the whole guide in order to get a better understanding on what is the installation guide flow. Once you have read the wiki, consult the Index and visit the exact section you need.



  Index  




RidgeRun Resources

Quick Start Client Engagement Process RidgeRun Blog Homepage
Technical and Sales Support RidgeRun Online Store RidgeRun Videos Contact Us

OOjs UI icon message-progressive.svg Contact Us

Visit our Main Website for the RidgeRun Products and Online Store. RidgeRun Engineering informations are available in RidgeRun Professional Services, RidgeRun Subscription Model and Client Engagement Process wiki pages. Please email to support@ridgerun.com for technical questions and contactus@ridgerun.com for other queries. Contact details for sponsoring the RidgeRun GStreamer projects are available in Sponsor Projects page. Ridgerun-logo.svg
RR Contact Us.png