Line 413:
Line 413:
# Added support for trigger mode.
# Added support for trigger mode.
+
=== How to Use 4-Lane Mode ===
+
The following guide uses the Orin NX devkit as an example to introduce the configuration and usage of 4-lane mode.
+
+
==== Confirming Hardware Support for 4-Lane Mode ====
+
The Orin NX devkit and Orin Nano devkit each have two MIPI CSI-2 interfaces, but only CAM1 supports 4-lane mode.
+
+
Refer to the camera manual to confirm whether your camera supports 4-lane mode. At this stage, the following models support 4-lane mode:
+
+
* MV-MIPI-GMAX4002M
+
* RAW-MIPI-SC535M
+
* RAW-MIPI-AR0234M
+
+
For MV-MIPI-GMAX4002M, use the **ADP-MV1-V2** adapter board, which supports 4-lane mode.
+
+
==== Configuring the Camera for 4-Lane Mode ====
+
Use the following script to configure the camera to 4-lane mode and save the settings:
+
+
<code>./mv_mipi_i2c_new.sh -w lanenum 4 -b your_i2c_bus_number</code>
+
+
<code>./mv_mipi_i2c_new.sh -w paramsave -b your_i2c_bus_number</code>
+
+
==== Using the 4-Lane Mode DTB ====
+
We provide [https://github.com/veyeimaging/nvidia_jetson_veye_bsp/tree/master/dtbs/Orin/JetPack_6.2_Linux_JETSON_ORIN_TARGETS/orin_nx_nano DTS and DTB files for JetPack 6.2] as a sample. When [https://wiki.veye.cc/index.php/How_to_upgrade_the_Jetson_system_to_support_VEYE_cameras updating the Jetson operating system], ensure that the appropriate DTB is used.
+
+
For Orin NX devkit:
+
+
* If using '''MV-MIPI-GMAX4002M''' or '''RAW-MIPI-SC535M''', select:
+
+
<code>tegra234-p3767-camera-p3768-veye_mvcam-dual-4lane-cam1.dtbo</code>
+
+
* If using '''RAW-MIPI-AR0234M''', select:
+
+
<code>tegra234-p3767-camera-p3768-raw_ar0234m-dual-4lane-cam1.dtbo</code>
+
=== Support for trigger mode ===
+
The default driver for Jetson systems only supports video streaming mode. In its VI driver, the data reception function has a timeout mechanism. We have added a settable vi_time_out_disable option to dynamically turn this timeout mechanism on and off.
+
+
Refer to the following application example for specific applications.
+
+
=== Check system status ===
+
After system update, reboot the Jetson board.
+
+
During the Jetson system boot process, it detects the presence of cameras on all i2c buses and generates the /dev/videoX device node if it exists.
+
+
Execute the following command on the Jetson board to check if the camera is properly connected.
+
+
<code>dmesg | grep mvcam</code>
+
+
You can see the camera model and the camera version number probed.
+
+
A prompt as below indicates that the MV-MIPI-IMX178M camera is detected on the i2c-10 bus.
+
+
<code>mvcam 10-003b: camera is: MV-MIPI-IMX178M</code>
+
+
<code>mvcam 10-003b: firmware version: 0x1080103</code>
+
+
==== /dev/videoX node ====
+
The camera module is mapped as /dev/videoX device node in the Jetson system.
+
+
During the OS boot process, the cameras are detected in the order of the i2c bus. The X value is incremented from 0 according to the logical order of detection.
+
+
For instance, if only one camera is connected, X is 0 regardless of the location to which the hardware is connected. If 5 cameras are connected, X is [0-4] according to i2c bus from smallest to largest.
+
+
The v4l2-ctl command uses -d /dev/videoX to access different cameras.
+
+
In gstreamer, v4l2src can access different cameras by specifying device=/dev/videoX.
+
==='''State Detection and Environment Variable Configuration'''===
+
[https://github.com/veyeimaging/raspberrypi_v4l2/tree/main/mv_tools_rpi Here], we provide an <code>mv_probe.sh</code> script that automatically detects the connected camera and configures environment variables with its default model, width, height, frame rate, and other information.
+
+
Usage:
+
+
<code>source ./mv_probe.sh</code>
+
+
A typical output:
+
+
<code>$ source ./mv_probe.sh</code>
+
+
<code>The mvcam driver is loaded on i2c-10, but the camera is not detected!</code>
+
+
<code>Found veye_mvcam camera on i2c-11.</code>
+
+
<code>Setenv CAMERAMODEL = RAW-MIPI-SC535M</code>
+
+
<code>Setenv FPS = 49</code>
+
+
<code>Setenv HEIGHT = 2048</code>
+
+
<code>Setenv WIDTH = 2432</code>
+
+
You can verify the environment variable output using:
+
+
<code>echo $CAMERAMODEL</code>
+
+
Note that these environment variables are only valid for the current session.
+
+
'''Important Notes:'''
+
+
*This script requires the <code>mvcam</code> driver version '''1.1.06 or later'''.
+
*If your driver version is '''earlier than 1.1.06''' or you need to use different width, height, or frame rate values, refer to the camera module manual and manually configure the following environment variables. Otherwise, subsequent programs may not function correctly.
+
+
Example:
+
+
<code>export WIDTH=2432</code>
+
+
<code>export HEIGHT=2048</code>
+
+
<code>export FPS=50</code>
=== Description of raw data image format ===
=== Description of raw data image format ===
On TX2 and XAVIER, 10 bit depth and 12 bit depth raw data is stored in memory in a format that is not compliant with the V4L2 standard. We have extended the definition in the linux kernel to support this case.
On TX2 and XAVIER, 10 bit depth and 12 bit depth raw data is stored in memory in a format that is not compliant with the V4L2 standard. We have extended the definition in the linux kernel to support this case.
Line 487:
Line 593:
We recommend using [https://www.offminor.de/ vooya] as the player.
We recommend using [https://www.offminor.de/ vooya] as the player.
−
−
===== Support for trigger mode =====
−
The default driver for Jetson systems only supports video streaming mode. In its VI driver, the data reception function has a timeout mechanism. We have added a settable vi_time_out_disable option to dynamically turn this timeout mechanism on and off.
−
−
Refer to the following application example for specific applications.
−
−
=== Check system status ===
−
After system update, reboot the Jetson board.
−
−
During the Jetson system boot process, it detects the presence of cameras on all i2c buses and generates the /dev/videoX device node if it exists.
−
−
Execute the following command on the Jetson board to check if the camera is properly connected.
−
−
<code>dmesg | grep mvcam</code>
−
−
You can see the camera model and the camera version number probed.
−
−
A prompt as below indicates that the MV-MIPI-IMX178M camera is detected on the i2c-10 bus.
−
−
<code>mvcam 10-003b: camera is: MV-MIPI-IMX178M</code>
−
−
<code>mvcam 10-003b: firmware version: 0x1080103</code>
−
−
==== /dev/videoX node ====
−
The camera module is mapped as /dev/videoX device node in the Jetson system.
−
−
During the OS boot process, the cameras are detected in the order of the i2c bus. The X value is incremented from 0 according to the logical order of detection.
−
−
For instance, if only one camera is connected, X is 0 regardless of the location to which the hardware is connected. If 5 cameras are connected, X is [0-4] according to i2c bus from smallest to largest.
−
−
The v4l2-ctl command uses -d /dev/videoX to access different cameras.
−
−
In gstreamer, v4l2src can access different cameras by specifying device=/dev/videoX.
−
−
=== Configuring global variables ===
−
For the convenience of later descriptions, global variables are configured here according to the sensor size.
−
−
*MV-MIPI-IMX178M
−
−
<code>export WIDTH=3088</code>
−
−
<code>export HEIGHT=2064</code>
−
−
<code>export FPS=22</code>
−
−
*MV-MIPI-SC130M
−
−
<code>export WIDTH=1280</code>
−
−
<code>export HEIGHT=1024</code>
−
−
<code>export FPS=108</code>
−
−
*MV-MIPI-IMX296M
−
−
<code>export WIDTH=1440</code>
−
−
<code>export HEIGHT=1088</code>
−
−
<code>export FPS=60</code>
−
−
*MV-MIPI-IMX265M
−
−
<code>export WIDTH=2048</code>
−
−
<code>export HEIGHT=1544</code>
−
−
<code>export FPS=45</code>
−
−
*MV-MIPI-IMX264M
−
−
<code>export WIDTH=2432</code>
−
−
<code>export HEIGHT=2056</code>
−
−
<code>export FPS=28</code>
−
−
* MV-MIPI-IMX287M
−
−
<code>export WIDTH=704</code>
−
−
<code>export HEIGHT=544</code>
−
−
<code>export FPS=319</code>
−
−
*RAW-MIPI-SC132M
−
−
<code>export WIDTH=1080</code>
−
−
<code>export HEIGHT=1280</code>
−
−
<code>export FPS=120</code>
−
−
*RAW-MIPI-IMX462M
−
−
<code>export WIDTH=1920</code>
−
−
<code>export HEIGHT=1080</code>
−
−
<code>export FPS=60</code>
−
−
*RAW-MIPI-AR0234M
−
−
<code>export WIDTH=1920</code>
−
−
<code>export HEIGHT=1200</code>
−
−
<code>export FPS=60</code>
−
−
*RAW-MIPI-SC535M
−
−
<code>export WIDTH=2432</code>
−
−
<code>export HEIGHT=2048</code>
−
−
<code>export FPS=50</code>
−
−
=== How to Use 4-Lane Mode ===
−
The following guide uses the Orin NX devkit as an example to introduce the configuration and usage of 4-lane mode.
−
−
==== Confirming Hardware Support for 4-Lane Mode ====
−
The Orin NX devkit and Orin Nano devkit each have two MIPI CSI-2 interfaces, but only CAM1 supports 4-lane mode.
−
−
Refer to the camera manual to confirm whether your camera supports 4-lane mode. At this stage, the following models support 4-lane mode:
−
−
* MV-MIPI-GMAX4002M
−
* RAW-MIPI-SC535M
−
* RAW-MIPI-AR0234M
−
−
For MV-MIPI-GMAX4002M, use the **ADP-MV1-V2** adapter board, which supports 4-lane mode.
−
−
==== Configuring the Camera for 4-Lane Mode ====
−
Use the following script to configure the camera to 4-lane mode and save the settings:
−
−
<code>./mv_mipi_i2c_new.sh -w lanenum 4 -b your_i2c_bus_number</code>
−
−
<code>./mv_mipi_i2c_new.sh -w paramsave -b your_i2c_bus_number</code>
−
−
==== Using the 4-Lane Mode DTB ====
−
We provide [https://github.com/veyeimaging/nvidia_jetson_veye_bsp/tree/master/dtbs/Orin/JetPack_6.2_Linux_JETSON_ORIN_TARGETS/orin_nx_nano DTS and DTB files for JetPack 6.2] as a sample. When [https://wiki.veye.cc/index.php/How_to_upgrade_the_Jetson_system_to_support_VEYE_cameras updating the Jetson operating system], ensure that the appropriate DTB is used.
−
−
For Orin NX devkit:
−
−
* If using '''MV-MIPI-GMAX4002M''' or '''RAW-MIPI-SC535M''', select:
−
−
<code>tegra234-p3767-camera-p3768-veye_mvcam-dual-4lane-cam1.dtbo</code>
−
−
* If using '''RAW-MIPI-AR0234M''', select:
−
−
<code>tegra234-p3767-camera-p3768-raw_ar0234m-dual-4lane-cam1.dtbo</code>
=== v4l2-ctl Application examples ===
=== v4l2-ctl Application examples ===