Design of Intelligent Video Surveillance System Based on Open Source Software MJPG_Streamer

**Abstract:** In response to the high cost and long development cycle associated with digital video surveillance equipment, this paper introduces an embedded system based on the ARM+Linux platform. It leverages open-source software, specifically MJPG_Stream, to capture video images and transmit them over a TCP/IP network to a host computer for remote display. In addition, a target detection algorithm combining the three-frame difference method with background subtraction is proposed, enabling intelligent monitoring and control. Experimental results demonstrate that the system supports real-time remote monitoring and can quickly trigger voice alarms when an intruding object is detected. **1. Introduction** With the rapid advancement of computer technology, optoelectronics, digital image processing, embedded systems, and network communication, modern digital video surveillance has evolved from traditional analog systems. The global video surveillance market has seen significant growth, with projections showing an increase from $11.5 billion in 2008 to $37.7 billion by 2015, reflecting a compound annual growth rate of 20.4%. Surveillance cameras, servers, encoders, and related software have become central components of such systems. This paper presents an intelligent video surveillance system built on the ARM+Linux platform, utilizing open-source tools like MJPG_Stream to enable real-time online monitoring. A background-running target detection algorithm is also introduced, capable of triggering voice alarms upon detecting intrusions, making it suitable for specific monitoring scenarios. **2. System Hardware Platform** The system is built around the S3C2440 processor, supported by peripheral devices including Flash, SDRAM, an Ethernet card (DM9000), a sound card (UDA1341), and a CMOS camera (OV9650). The camera captures raw image frames, which are processed and compressed within the Linux environment before being transmitted over the network to a PC for display. The hardware architecture is illustrated in Figure 1. **3. Building the ARM+Linux Embedded Platform** To establish the embedded Linux system, the bootloader and Linux kernel must be properly configured. The process involves porting the bootloader source code, burning it into Flash via JTAG, and booting from Flash after cross-compilation on a PC. This includes compiling the Linux kernel image and root file system. Once completed, the system boots into the Linux environment. **3.1 Porting Network and Sound Card Drivers** The Ethernet card DM9000 driver is adapted by modifying the relevant kernel code to match its specific parameters. Similarly, the sound card UDA1341 driver is integrated using the standard audio programming model provided by the Linux kernel, allowing for easy configuration and use of functions such as `open()`, `read()`, and `ioctl()`. **3.2 Implementing the Voice Playback Function** After the sound card driver is successfully ported, a high-precision MP3 decoder called Madplay is installed. Madplay, based on the MAD algorithm, offers excellent decoding performance and is ideal for embedded environments. During migration, the zlib, libid3tag, and libmad libraries are compiled separately, followed by the compilation and installation of Madplay. This allows the system to play recorded audio files effectively. **4. Implementation of MJPG_Stream** MJPG_Stream is a free video streaming server that uses the V4L2 framework to capture and stream video over a TCP/IP network. It converts captured images into JPEG format and sends them to a host computer for display. **4.1 Porting MJPG_Stream** The CC compiler in all Makefiles is changed to `arm-linux-gcc` to ensure compatibility with the ARM platform. Key components include: - **Input_uvc.so**: Captures and compresses camera images into JPEG. - **Input_control.so**: Enables camera rotation and PTZ control for multi-angle monitoring. - **Output_http.so**: Provides a web-based video stream. - **Output_file.so**: Stores captured JPEG images for later retrieval. **4.2 Target Detection Algorithm** This paper proposes a hybrid approach combining the three-frame difference method and background subtraction. Unlike traditional methods like the Gaussian mixture model, this algorithm reduces computational complexity while maintaining accuracy on the ARM platform. The process involves: 1. Establishing a background model and extracting foreground targets. 2. Updating the background model in real time to adapt to lighting changes. 3. Using the three-frame difference technique to extract moving objects. 4. Fusing the results of background subtraction and three-frame difference to avoid hollow areas. 5. Applying morphological operations to clean up noise and fill gaps in the final image. **4.3 Testing the Monitoring Platform** On the Linux platform, the MJPG_Stream software is used to start the system. The PC can view the video stream either through the graphical interface or a web browser. When an object enters the scene, the system triggers a voice alarm using Madplay. The setup ensures automatic operation after Linux boots, as shown in Figure 5. **5. Conclusion** The MJPG_Stream-based video surveillance system described in this paper offers real-time performance, remote access, and a simple user interface, significantly reducing development time. It integrates voice alarm functionality without requiring additional hardware. Future work will focus on expanding the system’s capabilities, including PTZ control, pattern recognition, and tracking algorithms, to enhance its versatility and performance.

Passersby Counter

Passersby Counter,Outside Traffic Counter Waterproof For Auto Repair Shop,Outside Traffic Counter Waterproof For Public Space,Outside Traffic Waterproof For Shopping Mall

OP Retail (Suzhou) Technology Co., Ltd , https://www.opretailtech.com