Design of Remote Liquid Level Monitoring System Based on Ethernet

With the development of network communication technology, Ethernet is increasingly used in the field of industrial control. The remote monitoring system based on Ethernet realizes the effective integration of remote monitoring, control and management [2]. Use the remote monitoring system to monitor the industrial production process through the network, timely understand the site information, and make quick decisions.

The key technology of remote control is how to solve the network access problem of industrial field devices. At present, there are two main methods: one is to use PC to collect data through PC port (such as RS232, USB interface) or data acquisition card and provide network interface [3], this method uses powerful PC software support It is easy to realize the network communication function, but the PC port resources are limited, the cost of the dedicated acquisition card is high, and it is difficult to promote; the other is to use the embedded system to realize network access in the field. The embedded system has low power consumption and small size. Low cost, high reliability, and strong real-time performance are suitable for use in industrial control sites.
This paper combines embedded technology and network technology, realizes network communication function in the field by using embedded system to transmit liquid level signal and control signal in real time, and realizes remote communication with field embedded system through socket programming on client PC. In order to achieve monitoring of the remote level.

1 Remote liquid level monitoring system structure

The structure of the remote liquid level monitoring system designed in this paper is shown in Figure 1: Among them, the processor chip adopts ARM microprocessor S3C44B0X; S3C44B0X comes with 8 10-bit ADCs for A/D conversion to collect liquid level data, which is realized by extending DAC0832 D/A conversion to output control amount; S3C44B0X connects 10M Ethernet card RTL8019AS, provides hardware interface for network function; μC/OS-II is ported to S3C44B0X, provides operating system support, facilitates application development and the whole system Management; embedded TCP/IP protocol stack LwIP is ported to μC/OS-II platform to realize software processing of network data, thereby providing network communication function for embedded system; remote PC client login to embedded system server Real-time interaction of data at both ends through Ethernet.

Figure 1 Structure diagram of remote liquid level monitoring system

2 Hardware introduction and design

Samsung's S3C44B0X microprocessor chip uses ARM's 16/32-bit ARM7TDMI RISC-based CPU core, clocked at 66MHz, and provides a wealth of peripheral functions by extending a range of general-purpose peripheral components. Its storage system has 8 banks, each with 32MB of storage space, which is allocated by 8 chips of nGCS0-7. In the design scheme used in this paper, nGCS0 is connected to Flash chip AM29LV160DB, starting address 0x00000000, size is 2MB, nGCS6 is connected to SDRAM chip HY57V641620ET-7, starting address is 0x0c000000, size is 8MB, nGCS3 is connected to RTL8019AS, starting address is 0x06000000.
RTL8019AS is a highly integrated full-duplex Ethernet controller that can simultaneously transmit and receive 10Mbps. It supports 8-bit, 16-bit data bus and 8 interrupt request lines. It supports automatic detection of UTP, AUI and BNC. Built-in 16K SRAM for data buffering, 256B paging structure, you can allocate the size and position of paging for sending and receiving, generally the first 12 pages for sending buffer, the last 52 pages for receiving buffer; hardware Self-contained transceiver CRC check, FIFO logic queue, etc., reduce the workload of the main CPU to process network data. S3C44B0X's operation on RTL8019AS mainly focuses on the reading and writing of network card registers and the processing of SRAM in network card.

3 software design

3.1 Server-based programming based on embedded system
3.1.1 Migration of μC/OS-II on S3C44B0X The embedded operating system μC/OS-II can run on various types of microprocessors with small core, high efficiency, and high modularity and portability. Sexuality supports multi-task real-time scheduling. After expansion, it can support network functions and graphical interfaces, making application development easier and more functional. Before using μC/OS-II, it should be ported to S3C44B0X. The porting work mainly includes three aspects [4]:
(1) Set the code related to the processor and compiler, including the definition of a series of data types, open interrupt macros, turn off the implementation of interrupt macros, define the growth direction of the stack;
(2) Write six operating system-related functions in C language: OSTaskStkInit() initializes the stack structure of the task, and five hook functions OSTaskDelHook(), OSTaskSwHook(), OSTaskStatHook(), OSTImeHook(), OSTaskCreateHook();
(3) Write four processor-related functions in assembly language: run the highest priority ready task function OSStartHighRdy(), task-level task switching function OS_TASK_SW(), interrupt level task switching function OSIntCtxSw(), clock beat Service function OSTIckISR().
3.1.2 Implementation of TCP/IP Protocol Stack on μC/OS-II
LwIP (Light-weight IP) is an open source TCP/IP protocol stack developed by Adam Dunkels of Sweden InsTItute of Computer Science [5]. LwIP reduces the main functions of TCP/IP protocol. The use of RAM makes it suitable for use in low-end embedded systems.
The LwIP protocol stack has been designed to separate all parts related to hardware, operating system, compiler, etc., and placed in the /src/arch directory. Therefore, the implementation of LwIP on μC/OS-II is to modify the files in this directory [6].
(1) The parts related to the CPU and the compiler are mainly the definitions of the data length, the high and low order of the words, etc. in the cc.h, cpu.h, and peRF.h files, which should be related to the parameters of the μC/OS-II. The definition is consistent. In addition, in general, the structure struct of C language is 4-byte aligned, but when processing data packets, LwIP uses the length of different data in the structure to read the corresponding data, so it must be Use the _packed keyword when defining structs to let the compiler abort the byte alignment of the struct.
(2) Operating system-related parts

VAPEAK GRAND Vape

VAPEAK GRAND Vape is so convenient, portable, and small volume, you just need to take them
out of your pocket and take a puff, feel the cloud of smoke, and the fragrance of fruit surrounding you. It's so great.
We are the distributor of the ovns & vapeak vape brand, we sell ovns disposable vape,ovns vape kit, ovns juul compatible refillable pod, and so on.
We are also China's leading manufacturer and supplier of Disposable Vapes puff bars, disposable vape kit, e-cigarette
vape pens, and e-cigarette kit, and we specialize in disposable vapes, e-cigarette vape pens, e-cigarette kits, etc.

vapeak grand vape bar,vapeak grand vape box,vapeak grand vape disposable,vapeak grand vape pen,vapeak grand vape mod kit

Ningbo Autrends International Trade Co.,Ltd. , https://www.vapee-cigarettes.com