UVC (USB Video Class) 支援在 Jetson TK1 R21.2 預設為啟動, UVC 裝置會被 uvcvideo 驅動程式褂載並建立 /dev/video0 裝置.

ubuntu@tegra-ubuntu:~$ dmesg

[ 2512.723098] usb 1-1: new high-speed USB device number 39 using tegra-ehci
[ 2512.866683] usb 1-1: New USB device found, idVendor=046d, idProduct=080f
[ 2512.866754] usb 1-1: New USB device strings: Mfr=0, Product=0, SerialNumber=2
[ 2512.866799] usb 1-1: SerialNumber: C8050680
[ 2512.874740] uvcvideo: Found UVC 1.00 device <unnamed> (046d:080f)
[ 2512.921181] input: UVC Camera (046d:080f) as /devices/platform/tegra-ehci.2/usb1/1-1/1-1:1.0/input/input7

可透過 VLC 測試.

UVC_VLC_PLAY.jpg  

 

對於非 UVC 的 USB 攝影機, 可先確認是否為 GSPCA (linuxtv.org/wiki/index.php/Gspca) 所支援, 如 SN9C20X 系列 USB 攝影機.

ubuntu@tegra-ubuntu:~$ lsusb
Bus 001 Device 038: ID 0c45:627b Microdia PC Camera (SN9C201 + OV7660)

必需開啟 USB_GSPCA 核心配置. (參考核心原始檔 drivers/media/usb/gspca/*)

diff --git a/arch/arm/configs/tegra12_defconfig b/arch/arm/configs/tegra12_defconfig
index f4432b7..3d82bd7 100644
--- a/arch/arm/configs/tegra12_defconfig
+++ b/arch/arm/configs/tegra12_defconfig
@@ -332,6 +332,8 @@ CONFIG_MEDIA_SUPPORT=y
 CONFIG_MEDIA_CAMERA_SUPPORT=y
 CONFIG_MEDIA_USB_SUPPORT=y
 CONFIG_USB_VIDEO_CLASS=y
+CONFIG_USB_GSPCA=y
+CONFIG_USB_GSPCA_SN9C20X=y
 CONFIG_V4L_PLATFORM_DRIVERS=y
 # CONFIG_TEGRA_RPC is not set
 CONFIG_TEGRA_NVAVP=y

 

 

文章標籤
創作者介紹
創作者 版大 的頭像
版大

嵌入式系統

版大 發表在 痞客邦 留言(0) 人氣()