USB 端口有两种形式;主机是总线的控制器,可以在 PC 和设备上找到,也可以在 Linux 中找到一个小工具(静态相机中常见的一个版本,端口可以在连接时切换类型,称为 USB on the go)。一个主机端口可以连接到多个小工具端口(通过集线器)。主机在很大程度上控制着作为奴隶运行的小工具。两种端口类型的硬件非常不同,许多嵌入式内核包含每种类型控制器的示例。Linux 内核包含 OHCI EHCI 和 UHCI 主机控制器硬件的主机驱动程序和各种协议驱动程序(打印机、键盘等)。对于某些设备类型,USB 组织已实施标准协议,因此您无需
If you want your device to talk to a PC host you will need to implement a device/gadget interface, there is far greater variety in hardware designs for the other end of the cable, but you should find the Linux kernel supports a selection of the more common ones.
The gadget directory also includes a selection of protocol drivers as well. One trick that could save a lot of work would be to configure your device to appear as a USB network interface, this avoids writing a lot of low level stuff and you can take advantage of the network diagnostic tools and the USB layer is abstracted out of your application on both ends. This even works with a Windows host without needing to write custom Windows drivers (XP only supports the Microsoft RNDIS USB protocol and the Windows driver is buggy and can hang on disconnects but the kernel includes a RNDIS wrapper and this solution can be made to work well).
I wasn't sure from your question is the video source was an independent USB device in which case it will need a separate USB host port on your device or if it was supplied by the host.
Get your self set of kernel sources and study the USB gadget directory, also download the USB specifications from USB.org You will want to understand chapters 8 9 10 11 as they explain what happens once a host detects a gadget and also the concept of endpoints. Mindshare did USB book that was a ok as a quick introduction to USB.