**Abstract:**
In response to the high cost and long development cycle of digital video surveillance equipment, this paper presents an intelligent video surveillance system based on the ARM+Linux embedded platform. The system utilizes open-source software, specifically MJPG_Streamers, to capture and transmit video images over a TCP/IP network for remote display. To enhance the system's intelligence, a target detection algorithm combining the three-frame difference method with background subtraction is proposed. Experimental results demonstrate that the system supports real-time remote monitoring and can quickly trigger voice alarms when detecting intruding targets.
**1. Introduction**
In recent years, with the continuous advancement of computer technology, optoelectronics, digital image processing, embedded systems, and network communication, digital video surveillance has evolved into a highly integrated, networked, and intelligent solution, gradually replacing traditional analog systems. The global demand for video surveillance continues to grow, driving rapid market expansion. According to IMS Research, the global video surveillance market was valued at $11.5 billion in 2008 and is expected to reach $37.7 billion by 2015, reflecting a compound annual growth rate of 20.4%. Surveillance cameras, servers, encoders, and software remain the core components of modern video surveillance systems.
This paper introduces an intelligent video surveillance system built on an ARM+Linux embedded platform. It leverages the advantages of open-source operating systems and free software like MJPG_Streamers to achieve real-time online monitoring. Additionally, a background-running target detection algorithm is implemented, enabling intelligent control and voice alarm capabilities upon detecting intrusions. This system is particularly suitable for specific monitoring scenarios.
**2. System Hardware Platform**
The system is built around the S3C2440 processor, supported by peripheral devices such as 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 in 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 installed. The bootloader source code is transplanted and burned into Flash using the JTAG interface. After cross-compilation on a PC, the Linux image and root file system are loaded, allowing the system to boot into Linux.
**3.1 Network Interface Card and Sound Card Driver Porting**
The DM9000 Ethernet card driver is adapted by modifying the corresponding kernel code to match the device parameters. Similarly, the UDA1341 sound card driver is ported by adjusting the existing audio programming model in the Linux kernel, ensuring compatibility and ease of use.
**3.2 Implementation of Voice Playback Function**
After the sound card driver is successfully ported, a high-precision MP3 decoder called Madplay is transplanted. Madplay is ideal for embedded systems due to its excellent decoding performance and command-line interface. The required libraries—zlib, libid3tag, and libmad—are compiled separately before Madplay is built and deployed onto the system. Once installed, it enables playback of recorded audio files.
Following the completion of the embedded platform, tests were conducted using commands like `ifconfig` and `madplay`. As shown in Figure 2, the Linux system booted successfully, the network and sound card drivers were configured correctly, and the audio files could be played back using Madplay.
**4. MJPG_Streamers Function Implementation**
MJPG_Streamers is a free video streaming server that uses the V4L2 framework to capture and stream JPEG-encoded video over TCP/IP. It allows for efficient remote video transmission and is well-suited for embedded applications.
**4.1 MJPG_Streamers Porting**
The CC compiler in all Makefiles within the MJPG_Streamers source directory is changed to `arm-linux-gcc`, followed by compilation. Key components include:
- **Input_uvc.so**: Captures camera images and converts them from YUV to JPEG.
- **Input_control.so**: Controls camera rotation, supporting PTZ functionality for multi-angle monitoring.
- **Output_http.so**: Acts as a web server, delivering compressed JPEG images as HTTP streams.
- **Output_file.so**: Stores captured JPEG images in a specified folder for still image recording.
**4.2 Target Detection Algorithm Research**
The proposed algorithm combines the three-frame difference method and background subtraction to improve detection accuracy. Unlike traditional methods like the Gaussian mixture model, this approach reduces computational complexity while maintaining effectiveness on ARM platforms. The algorithm involves:
1. **Background Modeling**: Convert color images to grayscale, compute average pixel values over n frames to create a background model. Subtract the current frame from the background to extract foreground objects, then binarize using a threshold.
2. **Dynamic Background Update**: Adjust the background model in real-time based on changes in lighting conditions.
3. **Three-Frame Difference**: Use three consecutive frames to extract moving targets, reducing false positives caused by static noise.
4. **Fusion and Morphological Processing**: Combine results from background subtraction and three-frame difference, then apply median filtering and morphological operations to remove noise and fill gaps.
Simulation results on Visual C++ 2005 show that the algorithm effectively detects moving targets, eliminates cavities, and provides accurate results. When an intrusion is detected, the system triggers a voice alarm using Madplay.
**4.4 Monitoring Platform Test**
On the Linux platform, the monitoring system is initiated via command line. The PC displays video through MJPG_Streamers’ graphical interface or a web browser. During testing, the system successfully triggered voice alarms upon detecting intrusions. MJPG_Streamers was configured to run automatically after Linux startup, as shown in Figure 5.
**5. Conclusion**
The MJPG_Streamers-based video surveillance system designed in this paper offers real-time performance, remote monitoring, and simplified upper-level implementation. It integrates voice alarm features without requiring additional hardware, leveraging the ARM platform’s capabilities. Future work includes adding PTZ control, pattern recognition, and tracking algorithms to enhance the system’s functionality and applicability.
Store Inspection Analytics,Retail Audit Analytics For Retail Store,Retail Audit Analytics For Shopping Mall,Retail Audit Analytics For Restaurant
OP Retail (Suzhou) Technology Co., Ltd , https://www.opretailtech.com