Changes

Jump to navigation Jump to search
6,613 bytes added ,  11:37, 10 January 2022
no edit summary
Line 2: Line 2:     
<big><big><big><big>veye5_mipi_i2c.sh user guide</big></big></big></big>
 
<big><big><big><big>veye5_mipi_i2c.sh user guide</big></big></big></big>
 +
===Overview===
 +
This script is an open source program to configure the camera module by direct access to i2c registers.
 +
 +
Applicable models: VEYE-MIPI-IMX335
 +
 +
===veye5_mipi_i2c.sh help===
 +
Usage:  ./veye_mipi_i2c.sh [-r/w] [-f] function name -p1 param1 -p2 param2 -b bus
 +
 +
options:
 +
 +
-r                       read
 +
 +
-w                       write
 +
 +
-f [function name]       function name
 +
 +
-p1 [param1]      param1 of each function
 +
 +
-p2 [param1]    param2 of each function
 +
 +
-b [i2c bus num]  i2c bus number
 +
 +
-d [i2c addr]   i2c addr if not default 0x3b
 +
====i2c bus====
 +
[http://wiki.veye.cc/index.php/VEYE_CS_Camera_for_Jetson_TX2#Video_Control_Toolkits_Manual bus number on jetson platform]
 +
====Format description====
 +
The part in  square brackets [param] in the following code indicates the variable.
 +
====Details====
 +
====manufacturer====
 +
<code>./veye5_mipi_i2c.sh -r -f manufacturer</code>
 +
 +
Read manufacturer information, always returns:
 +
 +
Manufacturer is VEYE
 +
=====model=====
 +
<code>./veye5_mipi_i2c.sh -r -f model</code>
 +
 +
Read the device model, for example: VEYE_MIPI_IMX335
 +
=====version=====
 +
<code>./veye5_mipi_i2c.sh -r -f version</code>
 +
 +
Reads the version number, for example:
 +
 +
control version is 01.03 , isp version 01.00
 +
=====timestamp=====
 +
<code>./veye5_mipi_i2c.sh -r -f timestamp</code>
 +
 +
Gets the time in milliseconds calculated from the moment the module starts up, incremented cyclically.
 +
=====factoryparam=====
 +
<code>./veye5_mipi_i2c.sh -w -f factoryparam</code>
 +
 +
All parameters revert to their default values.
 +
=====paramsave=====
 +
<code>./veye5_mipi_i2c.sh -w -f paramsave</code>
 +
 +
Save parameters. After all parameters are modified, this command must be executed for the parameters to be saved in flash and no longer lost when power off.
 +
=====reboot=====
 +
<code>./veye5_mipi_i2c.sh -w -f reboot</code>
 +
 +
reboot the camera.
 +
=====errcode=====
 +
<code>./veye5_mipi_i2c.sh -r -f errcode</code>
 +
 +
Get the camera error code. It should be 0 normally.
 +
=====i2caddr=====
 +
<code>./veye5_mipi_i2c.sh -w -f i2caddr -p1 [new i2caddr] -d [old i2c addr]</code>
 +
 +
<code>./veye5_mipi_i2c.sh -r -f i2caddr -d [current i2c addr]</code>
 +
 +
The camera i2c address,run '''paramsave''' and '''reboot'''  to takes effect .
 +
=====i2cport=====
 +
<code>./veye5_mipi_i2c.sh -w -f i2cport -p1 [i2c port]</code>
 +
 +
<code>./veye5_mipi_i2c.sh -r -f i2cport</code>
 +
 +
The camera i2c port,run '''paramsave''' and '''reboot'''  to takes effect .
 +
{| class="wikitable"
 +
!value
 +
!description
 +
|-
 +
|0x00
 +
|use i2c port on FFC cable
 +
|-
 +
|0x01
 +
|use alternate i2c port
 +
|}
 +
=====daynightmode=====
 +
<code>./veye5_mipi_i2c.sh -w -f daynightmode -p1 [0,2]</code>
 +
 +
<code>./veye5_mipi_i2c.sh -r -f daynightmode</code>
 +
 +
Day and night mode configuration
 +
{| class="wikitable"
 +
!value
 +
!description
 +
|-
 +
|0x00
 +
|Color mode
 +
|-
 +
|0x01
 +
|White and Black mode
 +
|-
 +
|0x02
 +
|Trigger mode
 +
|}
 +
=====ircutdir=====
 +
<code>./veye5_mipi_i2c.sh -w -f ircutdir -p1 [0,1]</code>
 +
 +
<code>./veye5_mipi_i2c.sh -r -f ircutdir</code>
 +
 +
Controls whether the IRCUT control pin level reverse.
 +
{| class="wikitable"
 +
!value
 +
!description
 +
|-
 +
|0x00
 +
|Default direction
 +
|-
 +
|0x01
 +
|Reverse IRCUT control pin level
 +
|}
 +
=====irtrigger=====
 +
<code>./veye5_mipi_i2c.sh -w -f irtrigger -p1 [0,1]</code>
 +
 +
<code>./veye5_mipi_i2c.sh -r -f irtrigger</code>
 +
 +
Trigger signal high and low level configuration in ''Trigger mode''.
 +
{| class="wikitable"
 +
!value
 +
!description
 +
|-
 +
|0x00
 +
|Low level for black and white mode, high level for color mode.
 +
|-
 +
|0x01
 +
|Low level for color mode, high level for black and white mode.
 +
|}
 +
=====sensor_reg=====
 +
<code>./veye5_mipi_i2c.sh -r -f sensor_reg -p1 [sensor reg addr]</code>
 +
 +
Read sensor register.
 +
=====videomode=====
 +
<code>./veye5_mipi_i2c.sh -w -f videomode -p1 [video mode]</code>
 +
 +
<code>./veye5_mipi_i2c.sh -r -f videomode</code>
 +
 +
Camera resolution configuration.
 +
{| class="wikitable"
 +
!value
 +
!description
 +
|-
 +
|0x01
 +
|2592x1944@20fps
 +
|-
 +
|0x02
 +
|2592x1944@12.5fps
 +
|-
 +
|0x03
 +
|2560x1440@25fps
 +
|-
 +
|0x04
 +
|2560x1440@30fps
 +
|}
 +
=====test_pattern=====
 +
<code>./veye5_mipi_i2c.sh -w -f test_pattern -p1 [test_enable] -p2 [type]</code>
 +
 +
<code>./veye5_mipi_i2c.sh -r -f test_pattern</code>
 +
 +
Image test mode configuration.
 +
=====awb_mode=====
 +
<code>./veye5_mipi_i2c.sh -w -f awb_mode -p1 [0,1]</code>
 +
 +
<code>./veye5_mipi_i2c.sh -r -f awb_mode</code>
 +
 +
AWB mode configuration.
 +
{| class="wikitable"
 +
!value
 +
!description
 +
|-
 +
|0x00
 +
|auto
 +
|-
 +
|0x01
 +
|oneset,write once to trigger a white balance operation
 +
|}
 +
=====antiflicker=====
 +
<code>./veye5_mipi_i2c.sh -w -f antiflicker -p1 [0,1]</code>
 +
 +
<code>./veye5_mipi_i2c.sh -r -f antiflicker</code>
 +
 +
Whether the anti-flicker function is on or not.
 +
=====agc_max=====
 +
<code>./veye5_mipi_i2c.sh -w -f agc_max -p1 [0,0xf]</code>
 +
 +
<code>./veye5_mipi_i2c.sh -r -f agc_max</code>
 +
 +
The upper limit of the auto gain function.
 +
=====ae_target=====
 +
<code>./veye5_mipi_i2c.sh -w -f ae_target -p1 [0,0x64]</code>
 +
 +
<code>./veye5_mipi_i2c.sh -r -f ae_target</code>
 +
 +
The target brightness of the automatic exposure.
 +
=====ae_speed=====
 +
<code>./veye5_mipi_i2c.sh -w -f ae_speed -p1 [0,0x64]</code>
 +
 +
<code>./veye5_mipi_i2c.sh -r -f ae_speed</code>
 +
 +
The adjustment speed of automatic exposure.
 +
=====agc_speed=====
 +
<code>./veye5_mipi_i2c.sh -w -f agc_speed -p1 [0,0x64]</code>
 +
 +
<code>./veye5_mipi_i2c.sh -r -f agc_speed</code>
 +
 +
The adjustment speed of auto gain.
 +
=====exp_val=====
 +
<code>./veye5_mipi_i2c.sh -r -f exp_val</code>
 +
 +
Current exposure value.
 +
=====agc_val=====
 +
<code>./veye5_mipi_i2c.sh -r -f agc_val</code>
 +
 +
Current gain value.
 +
=====mshutter=====
 +
<code>./veye5_mipi_i2c.sh -w -f mshutter -p1 [0,0x0B]</code>
 +
 +
<code>./veye5_mipi_i2c.sh -r -f mshutter</code>
 +
 +
Whether manual exposure is on and manual exposure configuration.
 +
 +
<nowiki>#</nowiki>0,auto; others, manual value
 +
=====mirrormode=====
 +
<code>./veye5_mipi_i2c.sh -w -f mirrormode -p1 [0,0x03]</code>
 +
 +
<code>./veye5_mipi_i2c.sh -r -f mirrormode</code>
 +
 +
Video flip configuration.
 +
{| class="wikitable"
 +
!value
 +
!description
 +
|-
 +
|0x00
 +
|Normal
 +
|-
 +
|0x01
 +
|Mirror
 +
|-
 +
|0x02
 +
|V-flip
 +
|-
 +
|0x03
 +
|Mirror and V-flip
 +
|}
 +
=====denoise_2d=====
 +
<code>./veye5_mipi_i2c.sh -w -f denoise_2d -p1 [0,0x3]</code>
 +
 +
<code>./veye5_mipi_i2c.sh -r -f denoise_2d</code>
 +
 +
2D noise reduction intensity.
 +
=====denoise_3d=====
 +
<code>./veye5_mipi_i2c.sh -w -f denoise_3d -p1 [0,0x3]</code>
 +
 +
<code>./veye5_mipi_i2c.sh -r -f denoise_3d</code>
 +
 +
3D noise reduction intensity.
 +
=====sharppen=====
 +
<code>./veye5_mipi_i2c.sh -w -f sharppen -p1 [0,0x0f]</code>
 +
 +
<code>./veye5_mipi_i2c.sh -r -f sharppen</code>
 +
 +
Sharpening intensity configuration.
 +
{| class="wikitable"
 +
!value
 +
!description
 +
|-
 +
|0x00
 +
|close
 +
|-
 +
|0x09
 +
|low
 +
|-
 +
|0x0B
 +
|middle
 +
|-
 +
|0x0C
 +
|high
 +
|}<br />

Navigation menu