introduction
In the engineering application of LED display screen, the display screen generally needs to be well configured, debugged, lit and tested before leaving the factory. Otherwise, due to the limitations of on-site conditions, these works are difficult to carry out. During debugging and program testing, communication can be carried out through serial port and network port. With the popularization of network and the improvement of speed, network communication mode is adopted by more users, that is, users communicate with the display screen through hub or network direct connection. Through the hub, PC and display screen IP can not be in the same network segment; When the network is directly connected, the IP addresses of the PC and the display screen must be in the same network segment. No matter which method is adopted, the IP addresses of the two must be known in order to communicate. However, in the debugging process, due to too many LED control cards, too long placement time or configuration by different people, sometimes users may not know the IP address of the display screen, so it is difficult to carry out work. In addition, the factory configured IP address may not be the same as the field installed IP address, and the field installed display screen IP address has different IP address segments due to different users. In this way, in the debugging process, it is necessary to repeatedly modify the IP address of the display screen or PC, which brings a lot of workload. Therefore, based on these problems in the application, some users put forward whether the network direct connection can be adopted. The network communication between PC and LED display screen can be realized without knowing the IP address of LED display screen and modifying the IP of PC, so that users can debug LED display screen more conveniently. Through market research, some software claim to realize the direct connection of LED display network, but the specific implementation is not satisfactory, such as stability, reliability and timeliness. After research, this paper proposes a new method of network direct connection, which can solve these problems and make users debug the display screen conveniently, reliably and efficiently.
1. Main functional requirements analysis and model constructionFor the network direct connection, the hardware is shown in Figure 1. Connect the PC and the display screen with the network direct connection, and then manually set their IP addresses in the same network segment to communicate.
However, in this way, if the IP address of the display screen is not known in advance, it will be difficult to communicate. In order to realize the direct communication between PC and display screen without knowing the IP address of display screen, it can be solved with the help of DHCP service principle: that is, set the LED display screen as the DHCP server with a fixed IP address, set the PC network card as the way to automatically obtain the IP address, and automatically configure the network card IP address of PC through the DHCP service function, In this way, the network connection channel is established. Some developers use this method to realize network direct connection, but this method has some problems: first, because UDP communication is not connected, its communication reliability is poor and easy to fail; Second, it can only be completed through the system of the operating system. Without intervention, users cannot set timeout. Sometimes the waiting time is too long, up to 60 seconds; Third, DHCP is a fixed IP mode, which is obviously not very good in practical application; Fourth, when exiting the system, the original network card configuration information of the PC cannot be restored.
Based on this, after research, this paper proposes a new network direct connection method, which can realize the functions of network direct connection, automatic acquisition of IP address and saving and recovery of PC network card configuration information, overcome the shortcomings of the current implementation method and improve the performance of reliability, stability and timeliness. Its system model is shown in Figure 2, and the main functions and workflow are as follows:
(1) When starting the system, retrieve and access all network cards of PC, and save their network card configuration information for recovery when exiting the system; (2) Start the network direct connection process; (3) Broadcast IP address request packet; (4) Return IP address packet; (5) Unpack, obtain the IP address of PC and LED display screen, and set the IP address of PC; (6) Return the IP address of LED display screen, close the direct network connection, and complete the establishment of communication channel; (7) After establishing the communication channel between PC and LED display screen, the display screen can be read / write parameters, send programs, switch screen and other communication control operations; (8) When exiting the system, restore the original state of the PC network card according to (1) the saved network card configuration information.
In the above process, (2) to (6) are the core processes. It simulates DHCP service, realizes PC broadcast request IP address, obtains and sets PC IP address, uploads LED display IP address, and completes the establishment of network direct connection channel. It is a necessary step for network direct connection operation; (1) And (8) are the operations of saving PC network card configuration information and restoring network card configuration information when starting and exiting the system; (7) It is the general operation of display screen control after completing the network direct connection channel. This paper focuses on the first two.
Bao’an District Shenzhen City, China
+86 189 3806 5764