January 10, 2025

Design of wireless monitoring system based on embedded platform Windows CE 5.0...

0 Preface

Traditional video surveillance systems are mainly based on analog signal surveillance systems and digital surveillance systems based on plug-in cards. Among them, the analog signal monitoring system has a large amount of wiring engineering, consumes a lot of storage media, and is very cumbersome to query and obtain evidence; the digital monitoring system based on the plug-in card is completed by a PC and an image capture card, and the cost of the system is high. The machine needs to be guarded and cannot be used in harsh environments. In the field of video surveillance, how to make information transmission faster, more stable, farther away, lower system cost, volume, and power consumption are the primary issues facing current technology R&D personnel.

This paper proposes an embedded Windows CE5. O's wireless video surveillance system. It solves the problems of high cost, large volume, limited transmission distance, large power consumption, and inconvenient installation of traditional video surveillance systems. The design of the system will provide a new idea, method and technical route for wireless video surveillance; it has broad application prospects in the field of wireless video such as security, remote education, remote video conferencing, and medical systems.

l Introduction to the overall hardware block diagram of the system

The hardware system of the wireless monitoring system based on embedded WinCE5.0 is mainly composed of embedded terminal and server-side PC. The microprocessor of the embedded terminal platform chooses the S3C2440 based on the ARM9T20 core. The S3C2440 has a wealth of interfaces. The camera interface is connected to the CMOS camera, and the serial port is connected to the GPRS transmitter module; the server side is mainly a PC and GPRS receiver Module. The whole block diagram is shown in 1.

Detailed design of wireless monitoring system based on embedded platform Windows CE 5.0

The system first uses the S3C2440 microprocessor to control the CMOS camera to collect image data. After compression and encoding, the compressed data is transmitted through the GPRS wireless transmitting module. The PC on the server side receives the data through the GPRS receiving module and uses the corresponding application. The program decodes the video data and displays it on the screen. The core control board of the embedded terminal platform with S3C2440 microprocessor is shown in Figure 2.

Detailed design of wireless monitoring system based on embedded platform Windows CE 5.0

2 System expansion interface design

2.1 Camera interface design

The image acquisition chip used in the camera is the OV9650 image sensor. The image sensor has a 10-bit data interface and a standard SCCB interface. It is packaged in CSP-28 and is small in size.

The chip supports RGB (4: 2: 2), YUV (4: 2: 2), YCrCb (4: 2: 2) three data output formats, built-in 138 device control registers, addresses from Ox00 to Ox8A, through SCCB interface can easily set the sensor window size, gain, white balance correction, exposure control, saturation, hue and other parameters. Contains the image sensor OV9650 camera module as shown in Figure 3.

S3C2440 has a dedicated camera interface. The CPU can be directly connected to the CMOS image sensor. When the 0V9650 output data format is 8-bit YUV, the data lines D2 ~ D9 (D9 is MSB bit, D2 is LSB bit); The output data format is 10-bit RGB, using data lines D0~D9 (D9 is MSB bit, D0 is LSB bit), this system uses YUV format. The camera module is connected with the Camera interface of S3C2440, and the circuit diagrams are shown in Figure 4 to Figure 6.

Detailed design of wireless monitoring system based on embedded platform Windows CE 5.0

Which uses TI's level conversion chip 74LVC4245, is a dual power level shifter, the level shift is carried out inside. 5 V end uses 5 V power as VDD_CAM, and 3.3 V end uses 3.3 V as VCC33. The dual power supply can ensure that the output swing of the two ports can reach the full power supply amplitude.

2.2 Interface design of GPRS module

S3C2440 has 3 UART channels. Use one of the channels to design the serial port to connect to the GPRS module. Because of the UART controller that S3C2440 comes with, it makes hardware development and software design relatively simple. However, the high and low level signals defined by the RS 232 standard are completely different from the high and low level signals defined by the circuit of a general microcontroller system. For example, the standard logic "1" of the S3C2440 system corresponds to levels 2 to 3 V, standard logic "O" corresponds to 0~4 V level. Obviously, it is completely different from the level signal described in the RS 232 standard. To communicate between the two, the signal level must be converted. The commonly used level conversion chips are MAX232, MAX3221 and MAX324.3. The specific design circuit is shown in Figure 7 and Figure 8.

Detailed design of wireless monitoring system based on embedded platform Windows CE 5.0

3 customization of operating system platform

Windows CE is a highly modular embedded operating system. Because of this, users customize the operating system to meet specific requirements. If you customize the Windows CE operating system for your own embedded devices, you must create, build, and run And a series of operations such as OS release. In the wireless video surveillance system, according to the functional requirements, the process of using Platform Builder 5.0 to customize the system is as follows:

(1) Import the BSP development kit. Since Samsung's S3C2440 based on the ARM920T core is used, the SMDK2440 under the SMDK2440 file is found in the BSP package. CEC file to import it. Open "Platform Builder 5.0" and select "Manage Catalog Features" under the "File" menu, as shown in Figure 9. Click "Import" in the pop-up dialog box and browse to smdk2440 under the SMDK2440 file. cec file and import it.

Detailed Design of Wireless Monitoring System Based on Embedded Platform Windows CE 5.0

(2) Create a project. According to the requirements of the WinCE wireless monitoring system, the appropriate components are selected to achieve this in the process of customizing the system. The components included are: MFC components that support application development and related components that support the network.

(3) Compile the project: Click the menu "Build OS" → "Sysgen" to start compiling the project.

(4) Download the runtime image and start after successful debugging. After successful compilation, nk will be generated under the directory WinCES00PBWorkspacestestlRelDirsmdk2 440_ARMV4I_Release. bin and nk. nb0 and other files, will nk. nb0 is downloaded to the hardware platform to run.

4 Driver development

4.1 The development of camera driver

Camera driver development is a difficult point in the design, but also a key part. Since the video data collected by the camera can be treated as a data stream, the driver of the camera will be developed using a streaming interface method.

(1) Open the previously customized operating system project in Platform Builder, and then create a new WIN32 DLL project, add 2 C++ source files, namely: camera. cpp and IIc. cpp, where camer-a. cpp contains the driver's entry function DLLMain (); the prefix of the driver is "CIS", IIc. cpp contains functions for configuring camera-related registers through the ICC interface.

(2) According to the previous hardware circuit and the working sequence of the OV9650 chip, the OV9650 is initialized by writing the CIS_Init function of the stream interface. Mainly include the following 3 steps: call InterrupTIniTIalize (SYSINTR_CAM, CameraEvent, NULL, 0) function to notify the system registration interruption; call CreateEvent () function to create a CameraEvent event; call CreateThread () function to create a CameraThread thread. Call the WaitForSingleObject (CameraEvent, Dis-play TIme) function in the Camera Capture Thread service function to wait for the Camera Event event to occur. This event is triggered by the SYSINTR_CAM interrupt associated with it. In addition, other stream interface functions (CIS_IOControl, etc.) can also be implemented in a similar way.

(3) Write the DLL export function definition file. DEF. . The DEF file defines the DLL export function class table. . DEF files can be edited with normal notepad, and the suffix name is changed to. Just DEF, about the camera driver. The contents of the DEF file are as follows:

Detailed design of wireless monitoring system based on embedded platform Windows CE 5.0

(4) Configure the registry for the driver. On the platform. Add the following registration items in reg:

Detailed design of wireless monitoring system based on embedded platform Windows CE 5.0

After the camera driver development is completed, the application program is written and displayed on the touch screen of the embedded terminal, as shown in Figure 10. First, create a window for displaying images through the CreateWindow API function, and then create a thread for the callback function CaptureThreadProc. In the callback function, according to different operations, different message values ​​are sent to the operating system to process image reading and display. The test result is shown in Figure 11.

Detailed Design of Wireless Monitoring System Based on Embedded Platform Windows CE 5.0

4.2 Serial port driver development

In Windows CE, the serial port driver implementation has a fixed model, based on the stream-driven model, using a layered structure. The development steps of the serial port driver are the same as those of the camera driver development above. The key is to realize the stream interface function. Because of the layered structure here, the code of the MDD layer can refer to the source code provided by Microsoft in %WINCEROOT%\PUBUC\COMMON In the directory \OAK\DRIVERS\SERIAL\COMMDD2, the codes in the PDD layer are hardware-related codes and need to be written for different devices. The code in the MDD layer calls the code in the PDD layer to implement specific hardware operations. The structure of the serial port driver is shown in Figure 12.

Detailed design of wireless monitoring system based on embedded platform Windows CE 5.0

5 Development of PC monitoring center program

The monitoring center is the core part of the wireless video monitoring system, which is responsible for managing the entire system and displaying the monitored images. In this paper, the application program of the monitoring center realizes the functions of real-time monitoring, timing recording, and capturing. In the development of the monitoring program in the system, C# language and WIN32 API are used at the same time, the event-based programming method of C# language is used to design the program graphic interface, and the API function in the VFW interface is used to design the reading of the underlying image data based on the message mechanism. And display. The API functions in this system mainly come from the VFW software toolkit. VFW (Video for Windows) provides a series of application programming interfaces (APIs) through which users can easily realize general functions such as video capture, video editing, and video playback, and can also use callback functions to develop more complex video applications. Its characteristic is that when playing video, no special hardware equipment is required, and the application is flexible, which can meet the needs of video application development. The program debugging and running effect of the monitoring center is shown in Figure 13.

Detailed design of wireless monitoring system based on embedded platform Windows CE 5.0

6 Research on Video Compression Coding and Transmission Theory

6.1 Research on video compression coding

Images and videos contain a huge amount of information, and their transmission and storage require a wide bandwidth. Multimedia video data must be compressed before wireless transmission. The commonly used digital compression technology mainly includes H. 261 compression coding, JPEG for computer still image compression and MPEG digital compression technology for moving image compression and H. 263 and H. 264 compression coding technology. MPEG-4 adopts a new generation of video coding technology. For the first time in the history of video coding, it expands the coding object from image frame to any shape video object with practical significance, thus realizing the transformation from pixel-based traditional coding to object and content-based The transformation of modern coding has led the development trend of a new generation of intelligent image coding.

Because the MPEG-4 compression coding system is relatively complicated, the paper will focus on the research of MPEG-4 compression coding technology, analyze its source code of compression coding on PC, and lay the foundation for future transplantation on ARM and other embedded devices. The flow of MlPEG-4 encoding for a frame of image is shown in Figure 14.

Detailed design of wireless monitoring system based on embedded platform Windows CE 5.0

Compile the source code of the open source MPEG-4 XVID model to generate an xvidcore. dIl file, call related functions in the library during application development, the program execution process is shown in Figure 15. Among them, the program is tested on the PC, firstly read the video data from the camera, and then perform MPEG-4 encoding.

Detailed design of wireless monitoring system based on embedded platform Windows CE 5.0

6.2 Research on wireless transmission

GPRS adopts wireless IP technology based on packet transmission mode, transmits data at a high speed in an effective way, and supports the most widely used IP protocol and X. 25 protocol, the transmission rate is up to 117 KB/s, so the video data can be transmitted through GPRS module after being compressed by MPEG-4. In this transmission process, the communication connection establishment, data transmission and other operations are all realized through the TCP/IP network API and Socket interface. The entire wireless transmission effect is shown in Figure 16.

7 Conclusion

The wireless monitoring system based on Windows CE5.0 involves computer programming technology, embedded technology, video coding, wireless transmission and other aspects of knowledge. A lot of work has been done in this topic, and the test results have achieved the expected purpose of the paper. The embedded terminal platform has the characteristics of small size, low power consumption, fast running speed, and clear collected images. The design of the monitoring center program also has a friendly human-computer interaction interface, which realizes timing monitoring, video recording, and photographing functions. In terms of video compression and wireless transmission, the feasibility of the method is theoretically studied, and specific solutions are proposed, which lay a solid foundation for further improving the system in the future.

Small Solar Panel

Our Sunket also has a multi-busbar small module production line specializing in the production of small panels for more than ten years.

From 158.75mm 5BB to 182mm 10BB to 210mm 12BB, from 10W to 400W has been fully covered. In addition, our certificates are complete.


Smaller solar panels can be used in many different ways: as a phone charger, for RVs and during camping trips, and for small off-grid solar projects. If you're looking to save money by offsetting your home energy use with a Solar Power System, small panels likely won't get the job done.


Solar panels may be worth it for smaller roofs if you install a system that uses more efficient solar panels, such as monocrystalline solar panels, as they generate more power using less space. The ideal roof slope for solar panels is between 30 degrees and 45 degrees.

Small Solar Panel, Customized Solar Panel, Small Size Solar Panel, Small Size PV Module, Customized PV Module

Wuxi Sunket New Energy Technology Co.,Ltd , https://www.sunketsolar.com