Network camera design based on Intel PXA255 platform

xiaoxiao2021-03-17  187

Abstract: With the widespread application of network and multimedia technology, digital network video has developed rapidly. In particular, the traditional analog video surveillance signal is converted into a digital video signal, and an existing IP network is used to design an inexpensive universal network video surveillance device that is not limited to the distance to become a new hotspot. This article proposes a design based on the application requirements in this respect. The implementation platform of this program is based on Intel PXA255 embedded hardware platform and software platform based on embedded Linux, using advanced MPEG-4 coding standards. Finally, a network camera that can directly access the Ethernet of the Ethernet with real-time video capture compression and transmission functions. Keywords: PXA255 Linux MPEG-4 Network Camera Streaming Media Technology 1 System Overview This program is designed for real-time video acquisition, processing and transmission systems based on IP networks. The entire system is implemented on an embedded hardware and hardware architecture, and there is no need to assist in the universal purpose video app, such as video surveillance and network video conferencing. 1.1 Hardware System Overview The entire system is implemented in the Intel PXA255 evaluation platform SITSANG (SITSANG board) except for the camera. The Sitsang board is equipped with a large number of hardware resources in PXA255, in which the Ethernet controller and USB HOST controllers in the communication interface are particularly important in this system. The SITSANG board uses the Standard Microsystems LAN91C96 Ethernet controller, which is connected to the network via U52, supports 10MB / s mode of IEEE802.3. The SITSANG board uses Philips ISP1161 as a USB HOST controller, using a USB HOST interface to connect the SITSANG board to the video capture camera. The Ethernet controller and the USB HOST controller passes the data bus transceiver (74LVCH32245) and the address, the data bus driver (74LVCH32244) is connected to the PXA255. The entire hardware system is shown in Figure 1. 1.2 Software System Overview The entire system software is built on the embedded Linux. The embedded Linux kernel used by the SITSANG board is compiled and compiled after patching Patch-2.4.19-SITSANG2 on Linux-2.4.19 kernel. The file system used by the SITSANG board is a JFFS2 file system for Flash's unbuffered mechanism. The file system contains applications, modules, configuration files, graphics interfaces, and libraries. The SITSANG board uses a graphical interface system based on Qt / Embedded. The acquisition, compression, and transmission of the video signal are based on the graphical interface and the embedded Linux kernel. The entire software system is shown in Figure 2. 2 System Design System Design Goals is to design a work on SITSANG / Intel PXA255 and aqi, a built-in video web server, an MPEG-4 coding standard, supports network image of related network transport protocols. The design of the system can be divided into the following: * Embedded Linux kernel portation and compile, file system and graphical interface system installation; * Designed based on embedded Linux video acquisition module; * Video image compression module design * Design of network video stream service module based on embedded Linux. 2.1 Linux kernel, graphical interface system and file system installation 2.1.1 Customization of embedded Linux kernel works in the set of embedded Linux kernels on the SITSANG board Similar to the development steps of other embedded platforms, with certain general purpose Sex, so it will not be detailed here, but pay attention to two points. 1 After decompressing the Linux kernel source code, it is assumed that the source code is Linux-2.4.19.sar.gz, you need to hit the SITSANG board for the source code:% gzip-dc patch-2.4.19-sitsang2.gz | Patch -p0.

2 When using make menuconfig custom kernel, be careful to allow the kernel to support the camera of the USB interface, the specific steps are: Select MultiMedia Devices → Video for Linux in the formulation menu, which makes the kernel configured video4linux to program the video acquisition device. Interface; Select USB Support → USB MultiMedia Devices → USB OV511 Camera Support in the menu, which enters the driver support for the USB digital camera using the OV511 interface chip in the kernel. 2.1.2 Compilation of the graphical interface system and installation of the SITSANG board is based on the QT / Embedded graphical interface system. QT / Embedded compiles are mainly divided into three steps: 1 Compile QT / X11, QT / X11 is running IBM is compatible with standard Linux this, which is mainly to provide graphical compilation environments and its applications for QT / Embedded and its applications; 2 Compile QT / Embedded, Qt / Embedded is a graphical interface system running on embedded Linux platform. And the application provides a series of libraries; 3 compile QTOPIA, compiling the graphical interface system based on embedded Linux platform and the application based on the function library provided by QT / X11 and QT / Embedded program. 2.1.3 The installation of the file system is used as a non-lost storage device on the embedded platform. As a log type file system, JFFS2 is directly written to non-volatile memory, without using buffering mechanisms such as EXT2, so that the user's information is protected at any time. Use mkfs.jffs2 directly to generate a JFFS2 file system on the SITSANG board. 2.2 Design of the embedded Linux video acquisition module is in the kernel customization and compilation phase of embedded Linux, which has already joined the video image acquisition program for the Video4Linux module and the OV511 device, so the video image acquisition program under Linux can pass the video4linux module. The compilation interface (API) is supplied from the OV511 device. 1 Load USB and OV511 Device Drive Modules and load the VIDEO4Linux module. Use commands separately: ModProbe USBCOR, MODPROBE USB-UHCI, ModProbe Vodeodev, and Modprobe Ov511. After loading, video device file / dev / video0 will generate, in order to coordinate with the VIDEO4Linux module, use the LN-S / DEV / VIDEO0 / DEV / VIDEO to the VideO4Linux module to establish a connection with the physical video device VIDEO0. 2 Use the API provided by the Video4Linux module to design the video capture program. Video4Linux module's video acquisition interface device is / dev / video, the acquisition is open to this interface device and scan it to find the data you need.

Here will briefly introduce the main API function provided by the Video4Linux module: vidicgcap function Returns the performance parameters of the video acquisition device by data structure video_capability; vidiocsfbuf function uses the data structure VIDEO_BUFFER device acquisition device's frame buffer parameters, if the device does not support frame buffet, this call Invalid; vidioCGWIN function uses data structural video_window to acquire window parameters, use parameter 1 Call VidiocCapture to start video signal acquisition, use parameter 0 to end acquisition; vDioCGCHAN functions are used to query different collection channels (including audio channels), use data structure Video_Channel Returns the channel properties; vidiocspict functions use the data structure video_picture to get the properties of the capture image frame, compare the palette parameters of the image frame; the read function reads the next frame image of the acquisition channel, read The image format and size are determined by the VIDIOCSPICT functions described earlier and the VIDIOCGWIN function, which define these API functions and data structures in the header file . The workflow of the entire video acquisition module is shown in Figure 3. 2.3 Design of Video Image Compression Module The video image acquired by the video acquisition module needs to be transmitted on Ethernet. In order to improve transmission efficiency, it is necessary to compress the original video image to compress the original video image. The system uses advanced MPEG-4 standards to compress the video image, in several open source MPEG-4 encoding software, select XVIDCORE as a core algorithm in the video image compression module in this system. XVID is an efficient and portable encoding software, and the current version is XVIDCORE-1.0.1. XVID supports Simple Profile and Advanced Profile, supports I / PFRAMES, B-Frames, Interlaacing, and GMC to perform PMVFAST and EPZS operational estimates in diamonds and square modes, which are currently more popular MPEG-4 encoding software. Cross-compilation for XVIDCORE-1.0.1 is relatively simple, and has the following main steps. 1 decompress XVIDCORE source code: TAR-ZXVF XVIDCORE-1.0.1.tar; 2 Set Environment Variables: Export Xvidcore = "THE PATH OF XVIDCORE"; CD $ xvidcore / build / generic; 3 Generate makefile: ./ Configure-Host = localhostbuild = arm-linux-gcc; 4 Compile source code: make; make install; 5 will cross-compile the generated library file libXVIDCORE.SO. * Copy to the lib sub-directory of the cross-compiler work directory, the library file is system Other modules provide a programming interface. 2.4 Network Video Flow Services Module Design Based on Embedded Linux 2.4.3 Flow Video Protocol 2.4.1 Operation of Linux Circuit Data In this design, the data exists in the form of stream data in the entire system, the Linux kernel is Flow data provides a standard programming interface that provides a full-duplex channel from the external device to the user process from the external device. In this passage, the processing module of the data is that the video compression module designed by the user is dynamically loaded as an optional intermediate member, which is such a middle piece.

转载请注明原文地址:https://www.9cbs.com/read-129522.html

New Post(0)