Difference between revisions of "iMX6 TinyRex HDMI Input"

From Voipac Wiki
Jump to navigation Jump to search
(Created page with "Category:iMX6 TinyRex Development kit Category:iMX6 TinyRex Peripherals <!-- --> <div style="float:right">__TOC__</div> A powerful HDMI Input feature on iMX6 TinyRex...")
 
Line 49: Line 49:
 
Resolutions up to 720P are automatically detected.
 
Resolutions up to 720P are automatically detected.
  
=== Performance ===
+
== Gstreamer ==
 +
=== Capture single JPEG picture ===
 +
<syntaxhighlight lang="bash">
 +
gst-launch-1.0 v4l2src device="/dev/video0" num-buffers=1 ! video/x-raw,width=1280,height=720,framerate=30/1 ! videoconvert ! jpegenc ! filesink location=sampleadv_1280_720.jpeg
 +
</syntaxhighlight>
 +
 
 +
=== Video preview ===
 +
<syntaxhighlight lang="bash">
 +
gst-launch-1.0 v4l2src device="/dev/video0" ! video/x-raw,width=1280,height=720,framerate=30/1 ! videoconvert ! autovideosink
 +
</syntaxhighlight>
 +
 
 +
=== Video encode ===
 +
<syntaxhighlight lang="bash">
 +
gst-launch-1.0 v4l2src device="/dev/video0" num-buffers=1000 ! video/x-raw,width=1280,height=720,framerate=30/1 ! videoconvert ! queue ! vpuenc_h264 ! matroskamux ! filesink location=sample.mkv sync=false
 +
</syntaxhighlight>
 +
 
 +
== Performance ==
 
{| class="wikitable"
 
{| class="wikitable"
 
! Resolution !! FPS !! Module !! Command !! Notes
 
! Resolution !! FPS !! Module !! Command !! Notes
Line 71: Line 87:
 
| 800x600|| >=48|| Pro|| gst-launch-1.0 v4l2src device="/dev/video0" ! videoconvert ! autovideosink|| Connected monitor 1920x1080, Booting from SD
 
| 800x600|| >=48|| Pro|| gst-launch-1.0 v4l2src device="/dev/video0" ! videoconvert ! autovideosink|| Connected monitor 1920x1080, Booting from SD
 
|}
 
|}
<syntaxhighlight lang="bash">
 
</syntaxhighlight>
 
 
<syntaxhighlight lang="bash">
 
</syntaxhighlight>
 

Revision as of 15:00, 14 March 2021

A powerful HDMI Input feature on iMX6 TinyRex Development kit is achieved by using ADV7610 HDMI Receiver chip. Detection, modes of operation and essential commands are described here.

Note: These examples uses Linux kernel version 4.1.

Kernel detection

...
adv7610_video: HDMI receiver adv7610 is found
...

I2C detection

HDMI receiver chip is connected via I2C3. The most important address for a correct detection is 0x4c.

root@imx6-tinyrexmax:~# i2cdetect -y 2
     0  1  2  3  4  5  6  7  8  9  a  b  c  d  e  f
00:          -- -- -- -- -- -- -- -- -- -- -- -- -- 
10: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
20: -- -- UU -- -- -- UU -- -- -- -- -- -- -- -- -- 
30: -- -- UU -- UU -- UU -- -- -- -- -- -- -- UU -- 
40: UU -- -- -- -- -- -- -- -- -- -- -- UU -- -- -- 
50: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
60: -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- 
70: -- -- -- -- -- -- -- --

Listing modules

root@imx6-tinyrexmax:~# lsmod
Module                  Size  Used by
mxc_v4l2_capture       27624  2
ipu_bg_overlay_sdc      5385  1 mxc_v4l2_capture
ipu_still               2331  1 mxc_v4l2_capture
ipu_prp_enc             5903  1 mxc_v4l2_capture
ipu_csi_enc             3904  1 mxc_v4l2_capture
ipu_fg_overlay_sdc      6130  1 mxc_v4l2_capture
ov5647_camera_mipi_int    30566  0
adv7610_video           6373  0
v4l2_int_device         2872  4 ov5647_camera_mipi_int,adv7610_video,ipu_csi_enc,mxc_v4l2_capture
mxc_dcic                6528  0

Resolution settings

Resolutions up to 720P are automatically detected.

Gstreamer

Capture single JPEG picture

gst-launch-1.0 v4l2src device="/dev/video0" num-buffers=1 ! video/x-raw,width=1280,height=720,framerate=30/1 ! videoconvert ! jpegenc ! filesink location=sampleadv_1280_720.jpeg

Video preview

gst-launch-1.0 v4l2src device="/dev/video0" ! video/x-raw,width=1280,height=720,framerate=30/1 ! videoconvert ! autovideosink

Video encode

gst-launch-1.0 v4l2src device="/dev/video0" num-buffers=1000 ! video/x-raw,width=1280,height=720,framerate=30/1 ! videoconvert ! queue ! vpuenc_h264 ! matroskamux ! filesink location=sample.mkv sync=false

Performance

Resolution FPS Module Command Notes
1920x1080 =12 Ultra gst-launch-1.0 v4l2src device="/dev/video0" ! videoconvert ! autovideosink Connected monitor 1920x1080, Booting from SATA
1920x1080 >=17 Max gst-launch-1.0 v4l2src device="/dev/video0" ! videoconvert ! autovideosink Connected monitor 1920x1080, Booting from NFS
1920x1080 >=17 Pro gst-launch-1.0 v4l2src device="/dev/video0" ! videoconvert ! autovideosink Connected monitor 1920x1080, Booting from SD
1280x720 >=29 Ultra gst-launch-1.0 v4l2src device="/dev/video0" ! videoconvert ! autovideosink Connected monitor 1920x1080, Booting from SD
1280x720 >=29 Max gst-launch-1.0 v4l2src device="/dev/video0" ! videoconvert ! autovideosink Connected monitor 1920x1080, Booting from NFS
1280x720 >=29 Pro gst-launch-1.0 v4l2src device="/dev/video0" ! videoconvert ! autovideosink Connected monitor 1920x1080, Booting from SD
800x600 >=48 Ultra gst-launch-1.0 v4l2src device="/dev/video0" ! videoconvert ! autovideosink Connected monitor 1920x1080, Booting from SD
800x600 >=48 Max gst-launch-1.0 v4l2src device="/dev/video0" ! videoconvert ! autovideosink Connected monitor 1920x1080, Booting from NFS
800x600 >=48 Pro gst-launch-1.0 v4l2src device="/dev/video0" ! videoconvert ! autovideosink Connected monitor 1920x1080, Booting from SD