Difference between revisions of "Matrix - CAM500B"
(→连接H3开发板使用) |
(→Connect CAM500B to H3 Based Boards) |
||
Line 81: | Line 81: | ||
===Connect CAM500B to NanoPi M1=== | ===Connect CAM500B to NanoPi M1=== | ||
+ | * NanoPi M1 works with CAM500B | ||
[[File:NanoPi-M1-cam500a.jpg|frameless|500px|NanoPi-M1-cam500a]] <br> | [[File:NanoPi-M1-cam500a.jpg|frameless|500px|NanoPi-M1-cam500a]] <br> | ||
===Connect CAM500B to NanoPi NEO Air=== | ===Connect CAM500B to NanoPi NEO Air=== | ||
+ | * NanoPi NEO Air works with CAM500B | ||
[[File:NanoPi-AIR-cam500b.jpg|frameless|500px|NanoPi-AIR-cam500b]] <br> | [[File:NanoPi-AIR-cam500b.jpg|frameless|500px|NanoPi-AIR-cam500b]] <br> |
Revision as of 07:59, 27 December 2016
Contents
1 Introduction
- The CAM500B module uses Omni Vision’s QSXGA CMOS OV5640 module. It has DVP parallel output interface and supports up to 2592 x 1944 photographing and 720P@30fps video recording. It has automatic image control functions: AFC, AWB and AEC etc.
- The CAM500B uses a cell phone camera. This camera’s focal length is 2.7mm. Its aperture is 2.8. Its viewing angle is 66 degree.
2 Features
- 5MP (2592 x 1944) photographing, 720P@30fps video recording
- Focal length: 2.7mm, Aperture: 2.8, Viewing angle: 66 degree
- Automatic image control functions: AFC, AWB and AEC etc
- 24 PIN FPC interface including DVC parallel output, 3.3V power, I2C and GPIO
3 Connect CAM500B to S5P4418/S5P6818 Boards
- If your 4418/6818 based board runs Android5.1 and it is connected to FriendlyElec's LCD or an HDMI monitor after Android is fully loaded click on the "Camera" icon and the application will be started. You can take pictures or record videos.
- Under Debian/Ubuntu a camera utility "nanocams" is available for previewing 40 frames and picture taking.You can try it by following the commands below:
sudo nanocams -p 1 -n 40 -c 4 -o IMG001.jpg
For more details about the usage of the nanocams run "nanocams -h". You can get its source code from our git hub:
git clone https://github.com/friendlyarm/nexell_linux_platform.git
3.1 Connect CAM500B to NanoPi M2
- NanoPi M2 works with CAM500B
3.2 Connect CAM500B to NanoPi 2
- NanoPi 2 works with CAM500B.
3.3 Connect CAM500B to NanoPi 2 Fire
- NanoPi 2 Fire works with CAM500B.
3.4 Connect CAM500B to NanoPC-T2
- NanoPC-T2 works with CAM500B
3.5 Connect CAM500B to Smart4418
- Smart4418 works with CAM500B
3.6 Connect CAM500B to NanoPi M3
- NanoPi M3 works with CAM500B
3.7 Connect CAM500B to NanoPC-T3
- NanoPC-T3 works with CAM500B
4 Connect CAM500B to H3 Based Boards
Boot Debian, connect your H3 based board to a network, log into the board as root and run "mjpg-streamer":
cd /root/mjpg-streamer make ./start.sh
The mjpg-streamer application is an open source video steam server. After it is successfully started the following messages will be popped up:
i: Using V4L2 device.: /dev/video0 i: Desired Resolution: 1280 x 720 i: Frames Per Second.: 30 i: Format............: YUV i: JPEG Quality......: 90 o: www-folder-path...: ./www/ o: HTTP TCP port.....: 8080 o: username:password.: disabled o: commands..........: enabled
In our case the board's IP address was 192.168.1.230. We typed 192.168.1.230:8080 in a browser and were able to view the images taken from the camera's. Here is what you would expect to observe:
The mjpg-streamer soft-encodes data with libjpeg and you can hard-encode its data with ffmpeg which will greatly increase CPU's efficiency and speed up data encoding:
ffmpeg -t 30 -f v4l2 -channel 0 -video_size 1280x720 -i /dev/video0 -pix_fmt nv12 -r 30 -b:v 64k -c:v cedrus264 test.mp4
By default it records a 30-second video. Typing "q" stops video recording. After recording is stopped a test.mp4 file will be generated.
4.1 Connect CAM500B to NanoPi M1
- NanoPi M1 works with CAM500B
4.2 Connect CAM500B to NanoPi NEO Air
- NanoPi NEO Air works with CAM500B