This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
products:sbc:vim4:add-ons:new-vim4-mipi-camera [2023/09/10 01:36] hyphop [Get Frames via Mediactl API] |
products:sbc:vim4:add-ons:new-vim4-mipi-camera [2024/05/18 03:13] (current) nick [Record video via gstreamer] |
||
---|---|---|---|
Line 3: | Line 3: | ||
{{indexmenu_n> | {{indexmenu_n> | ||
- | ====== New VIM4 MIPI Camera Usage ====== | + | ====== New VIM4 MIPI camera usage ====== |
+ | |||
+ | <WRAP important > | ||
+ | There are two [[../ | ||
+ | </ | ||
===== Linux ===== | ===== Linux ===== | ||
- | ==== Upgrade | + | ==== Upgrade |
Please follow the [[products: | Please follow the [[products: | ||
- | ==== Enable | + | ==== Enable |
- | If you want to use the MIPI camera, you need to enable it in [[products: | + | If you want to use the MIPI camera, you need to enable it in [[products: |
+ | [[gh> | ||
* Add '' | * Add '' | ||
* Add '' | * Add '' | ||
- | Enable '' | + | Enable '' |
``` | ``` | ||
$ cat / | $ cat / | ||
Line 25: | Line 31: | ||
``` | ``` | ||
- | Enable '' | + | Enable '' |
``` | ``` | ||
$ cat / | $ cat / | ||
Line 33: | Line 39: | ||
And then reboot to take effect. | And then reboot to take effect. | ||
- | ==== Video Node ==== | + | ==== Video node ==== |
The video node is ''/ | The video node is ''/ | ||
- | ==== Get Frames | + | ==== Record video via gstreamer |
- | Test source code: [[gh>numbqq/v4l2_media_test]] | + | <WRAP important |
+ | Only for 5.15 kernel. | ||
+ | </ | ||
+ | |||
+ | |||
+ | Record video and perform '' | ||
+ | |||
+ | ```shell | ||
+ | gst-launch-1.0 -e v4l2src device=/ | ||
+ | |||
+ | ``` | ||
+ | |||
+ | Record video and perform '' | ||
+ | |||
+ | |||
+ | ```shell | ||
+ | gst-launch-1.0 -e v4l2src device=/ | ||
+ | |||
+ | ``` | ||
+ | |||
+ | ==== Get Frames via Mediactl API ==== | ||
- | Download and build the test source code: | + | Download and build the test source code: [[gh> |
<tabbox 5.4 kernel> | <tabbox 5.4 kernel> | ||
Line 77: | Line 103: | ||
Preview the file: | Preview the file: | ||
- | ```shell | + | <WRAP important > |
- | $ ffplay -f rawvideo -pixel_format nv21 -video_size 3840x2160 / | + | It doesn' |
+ | </ | ||
+ | |||
+ | ```shell | ||
+ | $ ffplay -f rawvideo -pixel_format nv12 -video_size 3840x2160 / | ||
``` | ``` | ||
+ | |||
===== Android ===== | ===== Android ===== | ||
WIP: | WIP: | ||