C779-Software: Difference between revisions
No edit summary |
Replace <comments/> with <comment-streams /> |
||
| (15 intermediate revisions by 2 users not shown) | |||
| Line 4: | Line 4: | ||
The Raspberry Pi Foundation has updated several versions recently; | The Raspberry Pi Foundation has updated several versions recently; | ||
The use guide of C779/C790/X630 depends on the official Raspberry Pi OS version you are using. Different versions have different usage methods. If you have some questions, please contact us and attach the osversion you are using.(<span style="color:red;">Email: support@geekworm.com</span>) | The use guide of [[C779]]/[[C790]]/[[X630]] depends on the official Raspberry Pi OS version you are using. Different versions have different usage methods. If you have some questions, please contact us and attach the osversion you are using.(<span style="color:red;">Email: support@geekworm.com</span>) | ||
You can refer to [https://www.raspberrypi.org/forums/viewtopic.php?f=38&t=281972 Raspberry pi official forum post] | You can refer to [https://www.raspberrypi.org/forums/viewtopic.php?f=38&t=281972 Raspberry pi official forum post] | ||
| Line 18: | Line 18: | ||
sudo apt-get upgrade | sudo apt-get upgrade | ||
2. Enable camera module (the camera is enabled by default in Raspberry pi Bullseys OS) | 2. Enable camera module (the camera is enabled by default in Raspberry pi '''Bullseys/Bookworm''' OS) | ||
sudo raspi-config | sudo raspi-config | ||
Navigate to ''''Interfacing Options'''' and hit Enter. Now select the ''''Camera'''' option, and hit the Enter key to enable it. Select “Finish” and select to '''reboot''' your Raspberry Pi. | Navigate to ''''Interfacing Options'''' and hit Enter. Now select the ''''Camera'''' option, and hit the Enter key to enable it. Select “Finish” and select to '''reboot''' your Raspberry Pi. | ||
[NOTE] reboot is important!! | '''[NOTE]''' reboot is important!! | ||
3. Edit /boot/config.txt (that will need sudo) | 3. Edit /boot/config.txt (that will need sudo) | ||
sudo nano /boot/config.txt | sudo nano /boot/firmware/config.txt | ||
Add the line: | Add the line: | ||
dtoverlay=tc358743 | dtoverlay=tc358743 | ||
Add the line if your | Add the line if your CSI module supports audio also like '''C790''' | ||
dtoverlay=tc358743-audio | dtoverlay=tc358743-audio | ||
please append the | please append the following setting if (and only if) you have a device such as the Auvidea B102 that supports the 22pin connector with all 4 lanes wired out(such as [[X1300]]), and are using a Compute Module with the CAM1 connector that also has all 4 lanes wired up, you can use | ||
dtoverlay=tc358743,4lane=1 | dtoverlay=tc358743,4lane=1 | ||
| Line 41: | Line 40: | ||
pi@raspberrypi:~ $ dmesg | grep cma | pi@raspberrypi:~ $ dmesg | grep cma | ||
[ 0.000000] cma: Reserved 256 MiB at 0x000000001ec00000 | [ 0.000000] cma: Reserved 256 MiB at 0x000000001ec00000 | ||
If it reports less than 96MB assigned to CMA, then | If it reports less than 96MB assigned to CMA, then please '''''/boot/firemare/cmdline.txt''''' as following: | ||
cma=96M | sudo nano /boot/firmware/cmdline.txt | ||
to the start of the line. | then add <code>cma=96M</code> to the start of the line. | ||
5. Reboot. | |||
sudo reboot | |||
If all is well you should get a /dev/video0 device, and "v4l2-ctl --list-devices" will tell you that it is provided by Unicam. | |||
After connecting all the cables, power on the Raspberry Pi, the C779/C790 indicator light is normally green, and after opening the Raspberry Pi terminal, enter the following command: | After connecting all the cables, power on the Raspberry Pi, the C779/C790 indicator light is normally green, and after opening the Raspberry Pi terminal, enter the following command: | ||
pi@raspberrypi:~ $ ls /dev/video0 | |||
/dev/video0 | |||
<pre> | <pre> | ||
pi@ | pi@geekworm:~ $ v4l2-ctl --list-devices | ||
bcm2835-codec-decode (platform:bcm2835-codec): | bcm2835-codec-decode (platform:bcm2835-codec): | ||
/dev/video10 | /dev/video10 | ||
| Line 56: | Line 58: | ||
/dev/video12 | /dev/video12 | ||
/dev/video18 | /dev/video18 | ||
/dev/ | /dev/video31 | ||
bcm2835-isp (platform:bcm2835-isp): | bcm2835-isp (platform:bcm2835-isp): | ||
| Line 63: | Line 65: | ||
/dev/video15 | /dev/video15 | ||
/dev/video16 | /dev/video16 | ||
/dev/video20 | |||
/dev/video21 | |||
/dev/video22 | |||
/dev/video23 | |||
/dev/media0 | /dev/media0 | ||
/dev/media2 | |||
unicam (platform:fe801000.csi): | unicam (platform:fe801000.csi): | ||
/dev/video0 | /dev/video0 | ||
/dev/ | /dev/media4 | ||
/dev/ | |||
rpi-hevc-dec (platform:rpi-hevc-dec): | |||
/dev/video19 | |||
/dev/media3 | |||
bcm2835-codec (vchiq:bcm2835-codec): | |||
/dev/media1 | |||
</pre> | </pre> | ||
| Line 147: | Line 160: | ||
should now reflect the resolution detected. | should now reflect the resolution detected. | ||
8. | 8. Test video recording | ||
v4l2-ctl --verbose -d /dev/video0 --set-fmt-video=width=1280,height=720,pixelformat='RGB3' --stream-mmap=4 --stream-skip=3 --stream-count=2 --stream-to=csitest.yuv --stream-poll | |||
The above command will capture frames and save to /home/pi (filename: csitest.yuv) | |||
v4l2-ctl - | |||
9. To play the YUV file on Raspberry Pi OS desktop, use FFplay. (Run the following command on local terminal window, Not work if executing the command from SSH). | |||
ffplay -f rawvideo -video_size 1280x720 -pixel_format bgr24 csitest.yuv | |||
'''If you have other tutorials, please leave them in the comments.''' | |||
<!--增加评论功能! --> | <!--增加评论功能! --> | ||
< | <comment-streams id="main" /> | ||
[[Category:Product Manual]] | |||
[[Category:Raspberry pi]] | |||
[[Category:Knowledge]] | |||