我用v3s驱动ov7740,它明明显示识别出来了。就是没法用ffmpeg和fswebcam 来拍照 报错都大同小异
`# ffmpeg -f v4l2 -input_format rawvideo -video_size 320x240 -i /dev/video0 -fram
es 1 image.jpg
ffmpeg version 3.4.2 Copyright (c) 2000-2018 the FFmpeg developers
built with gcc 6.4.0 (Buildroot 2018.02.1)
configuration: --enable-cross-compile --cross-prefix=/opt/buildroot-2018.02.1/output/host/bin/arm-buildroot-linux-gnueabihf- --sysroot=/opt/buildroot-2018.02.1/output/host/arm-buildroot-linux-gnueabihf/sysroot --host-cc='/opt/buildroot-2018.02.1/output/host/bin/ccache /usr/bin/gcc' --arch=arm --target-os=linux --disable-stripping --pkg-config=/opt/buildroot-2018.02.1/output/host/bin/pkg-config --disable-static --enable-shared --prefix=/usr --enable-avfilter --disable-version3 --enable-logging --enable-optimizations --disable-extra-warnings --enable-avdevice --enable-avcodec --enable-avformat --enable-network --disable-gray --enable-swscale-alpha --disable-small --enable-dct --enable-fft --enable-mdct --enable-rdft --disable-crystalhd --disable-dxva2 --enable-runtime-cpudetect --disable-hardcoded-tables --disable-mipsdsp --disable-mipsdspr2 --disable-msa --enable-hwaccels --disable-cuda --disable-cuvid --disable-nvenc --disable-avisynth --disable-frei0r --disable-libopencore-amrnb --disable-libopencore-amrwb --disable-libcdio --disable-libdc1394 --disable-libgsm --disable-libilbc --disable-libvo-amrwbenc --disable-symver --disable-doc --enable-gpl --enable-nonfree --enable-ffmpeg --disable-ffplay --disable-ffserver --disable-avresample --disable-ffprobe --disable-postproc --disable-swscale --enable-indevs --enable-alsa --enable-outdevs --enable-pthreads --enable-zlib --disable-bzlib --disable-libfdk-aac --enable-gnutls --disable-openssl --disable-libopenh264 --disable-vaapi --disable-vdpau --disable-mmal --disable-omx --disable-omx-rpi --disable-libopencv --disable-libopus --disable-libvpx --disable-libass --disable-libbluray --disable-librtmp --disable-libmp3lame --disable-libmodplug --disable-libspeex --disable-libtheora --disable-libwavpack --disable-iconv --enable-libfreetype --disable-fontconfig --disable-libopenjpeg --disable-libx264 --disable-libx265 --disable-x86asm --disable-mmx --disable-sse --disable-sse2 --disable-sse3 --disable-ssse3 --disable-sse4 --disable-sse42 --disable-avx --disable-avx2 --enable-armv6 --enable-vfp --enable-neon --disable-altivec --extra-libs=-latomic --enable-pic --cpu=cortex-a7
libavutil 55. 78.100 / 55. 78.100
libavcodec 57.107.100 / 57.107.100
libavformat 57. 83.100 / 57. 83.100
libavdevice 57. 10.100 / 57. 10.100
libavfilter 6.107.100 / 6.107.100
libswresample 2. 9.100 / 2. 9.100
[video4linux2,v4l2 @ 0x64050] ioctl(VIDIOC_G_PARM): Inappropriate ioctl for device
[video4linux2,v4l2 @ 0x64050] Time per frame unknown
[video4linux2,v4l2 @ 0x64050] ioctl(VIDIOC_STREAMON): Invalid argument
/dev/video0: Invalid argument
# v4l2-ctl --list-devices
sun6i-csi (platform:csi):
/dev/video0
# v4l2-ctl -d /dev/video0 --all
Driver Info (not using libv4l2):
Driver name : sun6i-video
Card type : sun6i-csi
Bus info : platform:csi
Driver version: 5.2.0
Capabilities : 0x84200001
Video Capture
Streaming
Extended Pix Format
Device Capabilities
Device Caps : 0x04200001
Video Capture
Streaming
Extended Pix Format
Priority: 2
Video input : 0 (camera: ok)
Format Video Capture:
Width/Height : 320/240
Pixel Format : 'YU12'
Field : None
Bytes per Line : 480
Size Image : 115200
Colorspace : Raw
Transfer Function : Default (maps to None)
YCbCr/HSV Encoding: Default (maps to ITU-R 601)
Quantization : Default (maps to Limited Range)
Flags :
#
最近编辑记录 Xiaoci (2023-08-30 14:09:15)
离线
这两个指令的输出贴一下?
media-ctl --print-topology dmesg | grep ov7740
怀疑 v4l2 subdev 没加载
# media-ctl --print-topology
Failed to enumerate /dev/media0 (-2)
# dmesg | grep ov7740
# media-ctl --print-topology
Failed to enumerate /dev/media0 (-2)
#
离线
这两个指令的输出贴一下?
media-ctl --print-topology dmesg | grep ov7740
怀疑 v4l2 subdev 没加载
我用dmesg看了一下好像ov7740没写到内核里面去我再去试试
离线
这两个指令的输出贴一下?
media-ctl --print-topology dmesg | grep ov7740
怀疑 v4l2 subdev 没加载
我设备树用
clock-names = "xclk";
dmesg | grep ov7740 会提示
# dmesg | grep ov7740
[ 0.935117] ov7740 1-003c: OV7740: fail to get xvclk: -2
[ 0.940560] ov7740: probe of 1-003c failed with error -2
我把设备树改成
clock-names = "xvclk";
我在用dmesg | grep ov7740
它就什么都没提示
我设备树代码
&csi1 {
status = "okay";
pinctrl-names = "default";
pinctrl-0 = <&csi1_clk &csi1_8bit>;
port {
csi1_ep: endpoint {
remote-endpoint = <&ov7740_0>;
hsync-active = <0>;
vsync-active = <1>;
bus-width = <8>;
pclk-sample = <1>;
};
};
};
&i2c1 {
pinctrl-0 = <&i2c1_pins>;
pinctrl-names = "default";
clock-frequency = <400000>;
status = "okay";
ov7740: camera@3c {
compatible = "ovti,ov7740";
reg = <0x3c>;
pinctrl-names = "default";
pinctrl-0 = <&csi1_mclk_pin>;
clocks = <&ccu CLK_CSI1_MCLK>;
clock-names = "xvclk";
port {
ov7740_0: endpoint {
remote-endpoint = <&csi1_ep>;
};
};
};
};
&ohci0 {
status = "okay";
};
&ehci0 {
status = "okay";
};
最近编辑记录 Xiaoci (2023-08-31 23:46:54)
离线
请问楼主有没有驱动ov系列摄像头的教程啊,f1c200s想驱动ov5640不知道咋下手,论坛有demo没得积分下不了😂😂
看看v3s的参考一下我成功自己点亮了ov2640
离线