李 东,陈 烁,田劲东,等.USB 2.0工业相机的图像采集鲁棒性研究[J].深圳大学学报理工版,2016,(05):525-530.[doi:10.3724/SP.J.1249.2016.05525 ]
Li Dong,Chen Shuo,Tian Jindong,et al.The robustness of image capture of USB 2.0 industrial camera[J].Journal of Shenzhen University Science and Engineering,2016,(05):525-530.[doi:10.3724/SP.J.1249.2016.05525 ]
USB 2.0工业相机的图像采集鲁棒性研究

深圳大学光电工程学院,广东深圳 518060

集成电路技术; 通用串行总线2.0; 现场可编程门阵列; 工业相机; 帧同步; 先入先出队列; 非归零反向编码; 鲁棒性

The robustness of image capture of USB 2.0 industrial camera
Li Dong, Chen Shuo, Tian Jindong, and Tian Yong

Li Dong, Chen Shuo, Tian Jindong, and Tian YongCollege of Optoelectronic Engineering, Shenzhen University, Shenzhen 518060, Guangdong Province, P.R.China

integrated circuit technology; universal serial bus 2.0; field programmable gate array; industrial camera; frame synchronization; first input first output; no return to zero inverse code; robustness

DOI: 10.3724/SP.J.1249.2016.05525

备注

针对通用串行总线(universal serial bus, USB)2.0工业相机传输带宽使用接近满载时,出现图像数据丢失现象进行深入分析,提出一个新的整体解决方案,包括3部分:利用帧校验的方式实现图像数据的帧同步,使系统具备容错校正机制; 添加数据缓存模块克服非实时操作系统轮询工作模式对数据传输的影响; 通过数据钳位的方式消除USB 2.0非归零反向编码方式对传输带宽的影响,保证传输带宽的稳定. 在此基础上,研制一款1 280×1 024@30 帧/s的USB 2.0工业相机. 实验结果表明,该相机传输速率可达39 Mbyte/s,实现了接近USB 2.0实际带宽上限的稳定传输,具备图像帧自动纠错功能,解决了传统方案里图像传输丢帧和图像错乱的问题.

Image data loss occurs when the universal serial bus(USB)2.0 transmission bandwidth is close to full load. In this paper, facts caused data loss are analyzed, and a new solution is put forward to avoid data loss for USB 2.0 industrial cameras. The new method includes three parts. Firstly, a frame check mode is established to guarantee image data frame synchronization, which creates a fault-tolerant correction mechanism in the system. Secondly, in order to overcome the influence of non-realtime operating system polling work mode, a data cache module is designed. Thirdly, a data-clamp mechanism is proposed to eliminate the effect on transmission bandwidth via a no return to zero inverse code transfer protocol of USB 2.0. With these steps, the USB 2.0 industrial camera achieves an image capture of 1 280×1 024@30 frame/s, close to the actual bandwidth limit of USB 2.0 with stability and the transmission rate of 39 Mbyte/s, and the problems of image data loss and disorder during transmission in traditional scheme are solved.

·