CN114500627A - Method, device and equipment for remotely accessing serial port equipment and storage medium - Google Patents

Method, device and equipment for remotely accessing serial port equipment and storage medium Download PDF

Info

Publication number
CN114500627A
CN114500627A CN202111619552.7A CN202111619552A CN114500627A CN 114500627 A CN114500627 A CN 114500627A CN 202111619552 A CN202111619552 A CN 202111619552A CN 114500627 A CN114500627 A CN 114500627A
Authority
CN
China
Prior art keywords
serial port
network
conversion module
port conversion
accessed
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202111619552.7A
Other languages
Chinese (zh)
Inventor
林青
胡绍谦
汤震宇
曹翔
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
NR Electric Co Ltd
NR Engineering Co Ltd
Original Assignee
NR Electric Co Ltd
NR Engineering Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by NR Electric Co Ltd, NR Engineering Co Ltd filed Critical NR Electric Co Ltd
Priority to CN202111619552.7A priority Critical patent/CN114500627A/en
Publication of CN114500627A publication Critical patent/CN114500627A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/14Session management
    • H04L67/141Setup of application sessions

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Data Exchanges In Wide-Area Networks (AREA)

Abstract

The application discloses a method, a device, equipment and a storage medium for remotely accessing a serial device, wherein the method comprises the following steps: determining a second network and serial port conversion module connected with the accessed serial port equipment based on the access requirement; establishing a network link between the second network and the serial port conversion module; sending access data to the second network-to-serial port conversion module through the network link, so that the second network-to-serial port conversion module forwards the access data to the accessed serial port device; and receiving response data of the accessed serial port equipment forwarded by the second network and the serial port conversion module through the network link. Therefore, the first electronic device at the remote end communicates with the second network and the serial port conversion module at the factory station end through network link, and the second network and the serial port conversion module are used for forwarding the access data of the first electronic device at the remote end and the serial port data of the accessed serial port device, so that remote access to the accessed serial port device is realized.

Description

Method, device and equipment for remotely accessing serial device and storage medium
Technical Field
The invention relates to the power system technology, in particular to a method, a device, equipment and a storage medium for remotely accessing serial equipment.
Background
The existing devices such as measurement and control devices, protection devices and auxiliary devices in substations and power plants are serial port devices, the communication and data interaction in the substations are realized in a serial port communication mode, and the serial ports cannot be networked and have no remote communication and access functions, so that the remote access, debugging and maintenance of the serial port devices such as the measurement and control devices, the protection devices and the auxiliary devices at the station ends cannot be realized.
Disclosure of Invention
In order to solve the foregoing technical problem, embodiments of the present application are expected to provide a method, an apparatus, a device, and a storage medium for remotely accessing a serial device.
The technical scheme of the application is realized as follows:
in a first aspect, a method for remotely accessing a serial device is provided, and is applied to a second electronic device, and the method includes:
determining a second network and serial port conversion module connected with the accessed serial port equipment based on the access requirement;
establishing a network link between the second network and the serial port conversion module; sending an access request to the second network-to-serial port conversion module through the network link, so that the second network-to-serial port conversion module forwards the access data to the accessed serial port device;
receiving response data of the accessed serial port equipment forwarded by the second network and serial port conversion module through the network link; and the response data is the data sent by the accessed serial port equipment responding to the access data.
In the foregoing solution, the determining, based on the access requirement, the second network and serial port conversion module connected to the accessed serial port device includes: determining a first serial port parameter of the accessed serial port equipment based on the access requirement; and determining a second network and serial port conversion module corresponding to the first serial port parameter based on the mapping relation between the serial port parameter and the second network and serial port conversion module.
In the foregoing solution, the mapping relationship includes: the mapping relation between the serial port parameters and the Internet communication protocol IP of the network and serial port conversion module; the establishing of the network link with the second network and the serial port conversion module comprises the following steps: and establishing a network link between the second network and the serial port conversion module based on the IP of the second network and the serial port conversion module.
In the above scheme, the method further comprises: sending a starting instruction to the second network and serial port conversion module through the network link so that the second network and serial port conversion module opens a first serial port connected between the second network and serial port conversion module and the accessed serial port device; the first serial port is used for realizing serial port communication between the second network and serial port conversion module and the accessed serial port equipment.
In the above scheme, the method further comprises: and sending a closing instruction to the second network and serial port conversion module through the network link so that the second network and serial port conversion module closes the first serial port.
In the foregoing solution, the first electronic device includes: a first network and serial port conversion module; wherein the method comprises the following steps: controlling the first network and serial port conversion module to establish a network link with the second network and serial port conversion module; controlling the first network and serial port conversion module to send access data to the second network and serial port conversion module through the network link; and controlling the first network and serial port conversion module to receive response data transmitted by the accessed serial port equipment and forwarded by the second network and serial port conversion module through the network link.
In the foregoing solution, the first electronic device further includes: a serial port virtual module; wherein the method further comprises: controlling the serial port virtual module to configure a virtual serial port based on the access requirement; and controlling the serial port virtual module to receive the access data through the virtual serial port and forwarding the access data to the first network and serial port conversion module.
In a second aspect, a method for remotely accessing a serial device is provided, and is applied to a second electronic device, where the second electronic device includes a second network and serial port conversion module, and the method includes:
controlling the second network and the serial port conversion module to establish a network link with the first electronic equipment;
controlling the second network and serial port conversion module to receive the access data of the first electronic device through the network link and forwarding the access data to the accessed serial port device;
and controlling the second network and serial port conversion module to receive the response data of the accessed serial port equipment and forwarding the response data to the first electronic equipment through the network link.
In the above scheme, the method further comprises: controlling the second network and serial port conversion module to receive a starting instruction sent by the first electronic device through the network link; and controlling the second network and serial port conversion module to open the first serial port connected with the accessed serial port equipment based on the opening instruction.
In the above scheme, the method further comprises: receiving a closing instruction sent by the first electronic equipment through the network link; and based on the closing instruction, controlling the second network and serial port conversion module to close the first serial port connected with the accessed serial port equipment.
In the foregoing solution, the first electronic device includes: a first network and serial port conversion module; wherein the method comprises the following steps: controlling the second network and the serial port conversion module to establish a network link with the first network and the serial port conversion module; controlling the second network and serial port conversion module to receive the access data sent by the first network and serial port conversion module through the network link, and forwarding the access data to the accessed serial port device; and controlling the second network and serial port conversion module to receive the response data of the accessed serial port equipment and forwarding the response data to the first network and serial port conversion module through the network link.
In a third aspect, a first apparatus for remotely accessing a serial device is provided, where the first apparatus is applied to a first electronic device, and the apparatus includes:
the first processing module is used for determining a second network and serial port conversion module connected with the accessed serial port equipment based on the access requirement;
the first establishing module is used for establishing a network link between the second network and the serial port conversion module;
the first processing module is further configured to send an access request to the second network-to-serial port conversion module through the network link, so that the second network-to-serial port conversion module forwards the access data to the accessed serial port device;
the first processing module is further configured to receive, through the network link, response data of the accessed serial device forwarded by the second network and serial port conversion module; and the response data is the data sent by the accessed serial port equipment responding to the access data.
In a fourth aspect, a second apparatus for remotely accessing a serial device is provided, which is applied to a second electronic device, where the second electronic device includes a second network and serial port conversion module, and the apparatus includes:
the second establishing module is used for controlling the second network and the serial port conversion module to establish network link with the first electronic equipment;
the second processing module is used for controlling the second network and serial port conversion module to receive the access data of the first electronic device through the network link and forward the access data to the accessed serial port device;
the second processing module is further configured to control the second network and serial port conversion module to receive response data of the accessed serial port device, and forward the response data to the first electronic device through the network link.
In a fifth aspect, an electronic device is provided, the device comprising: a processor and a memory configured to store a computer program operable on the processor, wherein the processor is configured to perform the steps of the aforementioned method when executing the computer program.
In a sixth aspect, a computer storage medium is provided, on which a computer program is stored, wherein the computer program, when executed by a processor, implements the steps of the aforementioned method.
The application discloses a method for remotely accessing a serial device, which comprises the following steps: determining a second network and serial port conversion module connected with the accessed serial port equipment based on the access requirement; establishing a network link between the second network and the serial port conversion module; sending access data to the second network-to-serial port conversion module through the network link, so that the second network-to-serial port conversion module forwards the access data to the accessed serial port device; and receiving response data of the accessed serial port equipment forwarded by the second network and the serial port conversion module through the network link. Therefore, the first electronic device at the remote end communicates with the second network and the serial port conversion module at the factory station end through network link, and the second network and the serial port conversion module are used for forwarding the access data of the first electronic device at the remote end and the serial port data of the accessed serial port device, so that remote access to the accessed serial port device is realized.
Drawings
Fig. 1 is a first flowchart of a method for remotely accessing a serial device in an embodiment of the present application;
fig. 2 is a second flowchart of a method for remotely accessing a serial device in an embodiment of the present application;
fig. 3 is a third flowchart of a method for remotely accessing a serial device according to an embodiment of the present application;
fig. 4 is a schematic diagram illustrating a first electronic device accessing a factory station-side serial port device according to an embodiment of the present application;
FIG. 5 is a first block diagram of the remote site and the station site according to the embodiment of the present disclosure;
FIG. 6 is a second schematic diagram of the remote site and the plant site according to the embodiment of the present application;
fig. 7 is a schematic structural diagram of a first apparatus for remotely accessing a serial device in an embodiment of the present application;
fig. 8 is a schematic structural diagram of a second apparatus for remotely accessing a serial device in an embodiment of the present application;
fig. 9 is a schematic structural diagram of an electronic device in an embodiment of the present application.
Detailed Description
So that the manner in which the features and elements of the present embodiments can be understood in detail, a more particular description of the embodiments, briefly summarized above, may be had by reference to embodiments, some of which are illustrated in the appended drawings.
Fig. 1 is a first flowchart of a method for remotely accessing a serial device in an embodiment of the present application. The method is applied to first electronic equipment, and the first electronic equipment can be remote electronic equipment. For example, in practical application, the remote end may be a scheduling master station, a centralized control center, an operation and maintenance center, a photovoltaic booster station, a master control room, and the like. The method is used for realizing the access of the serial devices of the factory station end at the remote end. For example, in practical applications, the remote end may be a substation, a power plant, a converter station, a new energy power distribution terminal, or the like.
As shown in fig. 1, the method for remotely accessing a serial device may specifically include:
step 101: determining a second network and serial port conversion module connected with the accessed serial port equipment based on the access requirement;
here, the accessed serial device is a serial device of a station end that needs to be accessed, such as a measurement and control device, a protection device, an auxiliary device, and the like. The access requirement is used for indicating the accessed serial port equipment. In practical application, the access requirement includes serial parameters of the accessed serial device, such as baud rate and verification mode. Here, the second network and serial port conversion module is a module of the remote end, and is connected with the accessed serial port device through a serial port.
For example, in some embodiments, the determining, based on the access requirement, the second network and serial port conversion module connected to the accessed serial port device includes: determining a first serial port parameter of the accessed serial port equipment based on the access requirement; and determining a second network and serial port conversion module corresponding to the first serial port parameter based on the mapping relation between the serial port parameter and the second network and serial port conversion module.
Illustratively, accessing the first serial port parameter of the serial port device includes: baud rate, check mode, etc.
Illustratively, in practical applications, the mapping relationship includes: and the mapping relation between the serial port parameters and the Internet communication protocol IP of the second network and the serial port conversion module. For example, in practical applications, the IP of the second network to serial port conversion module may be an existing allocated network IP resource at the factory site or a newly allocated IP resource. For example, the allocated network IP resource may be a communication prefix IP of the information protection system or an outbound communication IP of the information protection substation.
Step 102: establishing a network link between the second network and the serial port conversion module;
here, the network link is a network link between the first electronic device and the second network and the serial port conversion module, and the first electronic device and the second network and the serial port conversion module perform information interaction through the network link.
It should be noted that the second network and serial port conversion module may further communicate with the first network and serial port conversion module in the first electronic device. For example, in some embodiments, the network link may be a network link between a first network and serial port conversion module and a second network and serial port conversion module in the first electronic device.
For example, in practical applications, the network link may be implemented based on an existing object communication network, such as an existing power system network, such as a power system dispatching data network, an integrated data network, and a dedicated line, or implemented by building a network from a remote location to a substation or a power plant and establishing a physical network communication path from the remote location to the substation.
Illustratively, in some embodiments, the mapping comprises: the mapping relation between the serial port parameters and the Internet communication protocol IP of the network and serial port conversion module; the establishing of the network link with the second network and the serial port conversion module comprises the following steps: and establishing a network link between the second network and the serial port conversion module based on the IP of the second network and the serial port conversion module.
Illustratively, in some embodiments, the method further comprises: sending a starting instruction to the second network and serial port conversion module through the network link so that the second network and serial port conversion module opens a first serial port connected between the second network and serial port conversion module and the accessed serial port device; the first serial port is used for realizing serial port communication between the second network and serial port conversion module and the accessed serial port equipment.
Here, the opening instruction is used for instructing the second network and serial port conversion module to open and access the first serial port between the serial port devices. For example, in practical application, the start instruction includes a serial parameter of the accessed serial device, so that the second network-to-serial conversion module determines the first serial port between itself and the accessed serial device based on the serial parameter.
Illustratively, in some embodiments, after the access is finished, the method further includes turning off the first serial port to reduce power consumption. Illustratively, the method further comprises: and sending a closing instruction to the second network and serial port conversion module through the network link so that the second network and serial port conversion module closes the first serial port.
Step 103: sending access data to the second network-to-serial port conversion module through the network link, so that the second network-to-serial port conversion module forwards the access data to the accessed serial port device;
here, the access data is data that needs to be sent to the accessed serial device, and is used for realizing access to the accessed serial device. For example, in some embodiments, the access data includes a first serial parameter of the accessed serial device, which is used to instruct the second network to serial conversion module to determine the accessed serial device based on the serial parameter. Here, the second network and the serial port conversion module forward the access data to the accessed serial port device through serial port communication.
Step 104: receiving response data of the accessed serial port equipment forwarded by the second network and serial port conversion module through the network link; and the response data is the data sent by the accessed serial port equipment responding to the access data.
Here, the response data is data sent by the accessed serial port device in response to the access of the first electronic device. And realizing remote access of the first electronic equipment to the accessed serial port equipment based on the access data and the response data.
Illustratively, in some embodiments, the first electronic device includes: a first network and serial port conversion module; the method comprises the following steps: controlling the second network and the serial port conversion module to establish a network link with the first network and the serial port conversion module; controlling the second network and serial port conversion module to receive the access data sent by the first network and serial port conversion module through the network link and forward the access data to the accessed serial port device; and controlling the second network and serial port conversion module to receive the response data of the accessed serial port equipment and forwarding the response data to the first network and serial port conversion module through the network link.
Here, the network link is a network link between the first network and serial port conversion module in the first electronic device and the second network and serial port conversion module at the factory station side.
For example, in some embodiments, the access data is data sent by a serial port type communication module, such as access data sent by a serial port access module. The first network and serial port conversion module is a conversion module in the first electronic device, and is used for converting the access data sent by the serial port communication type module and sending the access data to the second network and serial port conversion module at the factory station end through network link.
Here, the execution subject of steps 101 to 104 may be a processor of the first electronic device.
According to the technical scheme, the first electronic device at the remote end communicates with the second network and serial port conversion module at the factory station end through network link, so that the second network and serial port conversion module sends access data to the accessed serial port device, response data sent by the accessed serial port device is forwarded to the first electronic device, and remote access of the first electronic device to the accessed serial port device can be achieved.
To further illustrate the object of the present application, based on the embodiments of the present application, another method for remotely accessing a serial device is provided, where the method is applied to a first electronic device, where the first electronic device includes: the first network and serial port conversion module and the serial port virtual module.
Fig. 2 is a second flow chart of the method for remotely accessing a serial device in the embodiment of the present application, and as shown in fig. 2, the method for remotely accessing a serial device may specifically include:
step 201: controlling the serial port virtual module to configure a virtual serial port based on the access requirement;
the serial port virtual module is used for configuring a virtual serial port, and communication with the serial port communication type access module is achieved based on the virtual serial port. Here, the access requirement includes serial parameters of the accessed serial device, such as baud rate and verification mode. For example, in practical applications, the access requirement may be directly stored on the serial port virtual module.
Illustratively, the serial port virtual module virtualizes the serial port and the communication parameters of the accessed serial port device by binding the serial port parameters of the accessed serial port device to the virtual serial port.
Step 202: controlling the serial port virtual module to receive the access data through the virtual serial port and forwarding the access data to the first network and serial port conversion module;
here, the received access data is the access data sent by the access module after the virtual serial port is opened.
The method further comprises the following steps: and controlling the serial port virtual module to send the access requirement and the received access data to the first network and serial port conversion module.
Step 203: the first network and serial port conversion module is controlled to determine a second network and serial port conversion module connected with the accessed serial port device based on the access requirement;
for example, in some embodiments, the access requirement may further include, in addition to the serial parameter of the accessed serial device, an IP of the second network and serial conversion module connected to the accessed serial device.
Specifically, the first network and serial port conversion module is controlled to determine the IP and port network parameters of the second network and serial port conversion module to be connected according to the access requirement, and the serial port parameters of the serial port virtual module are obtained.
Step 204: controlling the first network and serial port conversion module to establish a network link with the second network and serial port conversion module;
specifically, the first network and serial port conversion module is controlled to remotely initiate network link with the second network and serial port conversion module from the first network and serial port conversion module based on the IP and port network parameters of the second network and serial port conversion module, wherein in the network link, the first network and serial port conversion module is a client, and the second network and serial port conversion module is a server.
Step 205: controlling the first network and serial port conversion module to send a starting instruction to the second network and serial port conversion module through the network link, so that the second network and serial port conversion module opens a first serial port connected between the second network and serial port conversion module and the accessed serial port device;
the first serial port is used for realizing serial port communication between the second network and serial port conversion module and the accessed serial port equipment.
Illustratively, the first network-to-serial port conversion module is controlled to send an opening instruction to the second network-to-serial port conversion module by using a network communication protocol based on the acquired serial port parameters, so that the second network-to-serial port conversion module responds to the opening instruction, opens the serial port connected between the second network-to-serial port conversion module and the accessed serial port device, and returns a serial port opening result to the first network-to-serial port conversion module.
For example, in some embodiments, after the access is finished, the method further includes turning off the first serial port to reduce power consumption. Illustratively, the method further comprises: and sending a closing instruction to the second network and serial port conversion module through the network link so that the second network and serial port conversion module closes the first serial port.
Step 206: controlling the first network and serial port conversion module to send access data to the second network and serial port conversion module through the network link, so that the second network and serial port conversion module forwards the access data to the accessed serial port device;
here, the access data is data that needs to be sent to the accessed serial device, and is used for realizing access to the accessed serial device. For example, in some embodiments, the access data includes a first serial parameter of the accessed serial device, and the first serial parameter is used to instruct the second network to serial conversion module to determine the accessed serial device based on the serial parameter. In some embodiments, accessing the data further comprises: and forwarding the instruction and the message data. The forwarding instruction is used for instructing the second network and serial port conversion module to forward the message data to the accessed device. Here, the second network and the serial port conversion module forward the message data to the accessed serial port device through serial port communication.
Illustratively, in some embodiments, the method further comprises: and the control serial port virtual module receives the access data sent by the access module after the virtual serial port is opened. Here, the access module may be an existing serial access module.
For example, in practical applications, the access module may be disposed on the first electronic device, and may also be disposed on other electronic devices on the remote end. For example, in some embodiments, the first electronic device may include two sub-devices, and the first network and serial port conversion module and the serial port virtual module may be respectively disposed on different sub-devices.
Step 207: the first network and serial port conversion module is controlled to receive response data transmitted by the accessed serial port device and forwarded by the second network and serial port conversion module through the network link, and the response data is forwarded to the serial port virtual module;
here, the response data is data sent by the accessed serial port device in response to the access of the first electronic device. And realizing remote access of the first electronic equipment to the accessed serial port equipment based on the access data and the response data.
Step 208: and the control serial port virtual module forwards the received response data to the access module.
Here, the execution subject of steps 201 to 208 may be a processor of the first electronic device.
According to the technical scheme, the first electronic device comprising the serial port virtual module and the first network and serial port conversion module is constructed, and the network link between the first electronic device and the second network and serial port conversion module of the plant station end is established, so that the serial port access module can remotely access the plant station end serial port device by accessing the virtual serial port in the first electronic device.
Corresponding to the method for remotely accessing the serial device applied to the first electronic device in the above embodiment, a method for remotely accessing the serial device applied to the second electronic device is provided. The second electronic device may be an electronic device at a plant site. For example, in practical applications, the remote end may be a substation, a power plant, a converter station, a new energy power distribution terminal, or the like.
In this embodiment, the second electronic device includes: and the second network and serial port conversion module. For example, in practical applications, the second network and serial port conversion module may be deployed on an existing outbound communication device at a station end of a plant, such as a telecontrol device, a security substation, an online monitoring integrated processing unit, a synchronous vector measurement concentrator, and the like, and the second network and serial port conversion module may also be deployed on a proprietary station end device, such as a remote communication serial port mapping device.
Fig. 3 is a third flow chart of the method for remotely accessing a serial device in the embodiment of the present application, and as shown in fig. 3, the method for remotely accessing a serial device may specifically include:
step 301: controlling the second network and the serial port conversion module to establish a network link with the first electronic equipment;
the second network and serial port conversion module is connected with the accessed serial port device of the station side through a serial port. For example, in practical application, the second network and the serial port conversion module are connected to the same serial bus through an existing serial bus or a reconnected serial bus in a station side (such as a substation or a power plant) and an accessed serial port device (such as a serial port device for measurement and control, protection, an auxiliary device, and the like) to form a serial access bus in the station. The second network and serial port conversion module can determine the serial port between the second network and the accessed serial port device according to the serial port parameter of the accessed serial port device.
Illustratively, in some embodiments, the method further comprises: the method comprises the steps of receiving a network link establishing request sent by first electronic equipment, and establishing a network link with the first electronic equipment based on the network link establishing request.
For example, in some embodiments, controlling the second network and the serial port conversion module to establish a network link with the first electronic device includes: and controlling the second network and the serial port conversion module to establish a network link with the first network and the serial port conversion module in the first electronic equipment.
For example, in practical applications, the network link may be a TCP/IP communication link between the first electronic device and the second network and serial port conversion module, which is established based on the IP of the second network and serial port conversion module. For example, in practical applications, the IP of the second network and serial port conversion module may be an existing allocated IP resource of the network at the factory site or an IP resource obtained through reallocation. The allocated network IP resource can be a communication preposition IP of the information protection system or an outbound communication IP of the information protection substation.
For example, in practical application, the network link may be implemented based on an existing object communication network, such as an existing power system network, such as a power system dispatching data network, an integrated data network, and a dedicated line, or implemented by building a network from a remote location to a substation or a power plant and establishing a physical network communication path from the remote location to a plant end.
Illustratively, in some embodiments, the method further comprises: controlling the second network and serial port conversion module to receive a starting instruction sent by the first electronic device through the network link; and controlling the second network and serial port conversion module to open the first serial port connected with the accessed serial port equipment based on the opening instruction. The first serial port is used for realizing serial port communication between the second network and serial port conversion module and the accessed serial port equipment.
Illustratively, in some embodiments, the method further comprises: receiving a closing instruction sent by the first electronic equipment through the network link; and based on the closing instruction, controlling the second network and serial port conversion module to close the first serial port connected with the accessed serial port equipment.
Step 302: controlling the second network and serial port conversion module to receive the access data of the first electronic device through the network link and forwarding the access data to the accessed serial port device;
here, the access data is data that needs to be sent to the accessed serial device, and is used for realizing access to the accessed serial device. For example, in some embodiments, the access data includes a first serial parameter of the accessed serial device, and the first serial parameter is used to instruct the second network to serial conversion module to determine the accessed serial device based on the serial parameter. In some embodiments, accessing the data further comprises: and forwarding the instruction and the message data. The forwarding instruction is used for instructing the second network and serial port conversion module to forward the message data to the accessed device. Here, the second network and the serial port conversion module forward the message data to the accessed serial port device through serial port communication.
Step 303: and controlling the second network and serial port conversion module to receive the response data of the accessed serial port equipment and forwarding the response data to the first electronic equipment through the network link.
Here, the execution subject of steps 301 to 303 may be a processor of the second electronic device.
According to the technical scheme, information interaction between the second network and the serial port conversion module in the second electronic device and the first electronic device is achieved through network link, the second network and the serial port conversion module are controlled to send access data to the accessed serial port device, response data sent by the accessed serial port device are forwarded to the first electronic device, and remote access of the first electronic device to the accessed serial port device can be achieved.
The following further describes remote access of the first electronic device to the serial device at the factory station end in the present application. For example, fig. 4 is a schematic diagram of a first electronic device accessing a factory-side serial port device in an embodiment of the present application. As shown in fig. 4, the first electronic device is located at the remote end, is connected to the access module, and includes a serial port virtual module and a first network and serial port conversion module; the serial port virtual module is connected with the serial port conversion module through the access module and the first network; the first network and serial port conversion module in the first electronic device communicates with the second network and serial port conversion module at the factory station end through network link, and the second network and serial port conversion module is also connected with the accessed serial port device. The second network and serial port conversion module can be used for constructing second electronic equipment.
For example, in some embodiments, the access module, the serial port virtual module, and the first network and serial port conversion module may be disposed on the same physical entity on the remote end, such as on the same computer.
For example, the access module, the serial port virtual module and the first network and serial port conversion module at the remote end may be implemented on a remote computer with an existing system, such as a communication front-end computer of an electric Energy Management System (EMS), a protection information management system, a primary device online monitoring system (cpm), a Wide Area Monitoring System (WAMS), and the like; the access module, the serial port virtual module and the first network and serial port conversion module of the remote end can also be deployed on a special computer, such as a remote maintenance workstation.
For example, the second network and serial port conversion module may be deployed on an existing outbound communication device at a station end of a plant, such as a telecontrol device, a credit protection substation, an online monitoring integrated processing unit, a synchronous vector measurement concentrator, and other communication devices, and the second network and serial port conversion module may also be deployed on a proprietary station end device of the plant, such as a remote communication serial port mapping device.
Illustratively, the network link can be realized based on the existing object communication network, such as the existing network of the power system, such as a power system dispatching data network, a comprehensive data network, a private line, and the like; or a network from a remote place to a transformer substation or a power plant is built, and a network communication physical path from the remote place to a station end is built to realize the display.
Fig. 5 is a first structural diagram of a remote end and a station end in an embodiment of the present application. As shown in fig. 5, the modules of the remote end and the plant end are both deployed on the existing device, so that the remote direct debugging and maintenance of the serial port device in the plant can be realized under the condition of the existing scheduling network structure, the existing network IP resources and the existing serial bus connection, and no additional cost is added. Fig. 6 is a schematic diagram of a second structure of the remote end and the plant end in the embodiment of the present application, which uses a new network structure and new network IP resources. It should be noted that the schematic structures of the remote end and the plant end are not limited to the structures in fig. 5 and 6. The remote end, the plant station end and the network link are combined in different ways to form a new structure. In fig. 5 and 6, the second network and serial port conversion module may be used to construct the second electronic device.
Fig. 7 is a schematic structural diagram of a first apparatus for remotely accessing a serial device in an embodiment of the present application, and illustrates an apparatus for implementing a method for remotely accessing a serial device, where the first apparatus 70 is applied to a first electronic device, and specifically includes:
the first processing module 701 is configured to determine, based on an access requirement, a second network and serial port conversion module connected to an accessed serial port device;
a first establishing module 702, configured to establish a network link with the second network and the serial port conversion module;
the first processing module 701 is further configured to send an access request to the second network to serial port conversion module through the network link, so that the second network to serial port conversion module forwards the access data to the accessed serial port device;
the first processing module 701 is further configured to receive, through the network link, response data of the accessed serial device forwarded by the second network and serial port conversion module; and the response data is the data sent by the accessed serial port equipment responding to the access data.
In some embodiments, the first processing module 701 is configured to determine a first serial parameter of the accessed serial device based on the access requirement; and determining a second network and serial port conversion module corresponding to the first serial port parameter based on the mapping relation between the serial port parameter and the second network and serial port conversion module.
In some embodiments, the mapping relationship comprises: the mapping relation between the serial port parameters and the Internet communication protocol IP of the network and serial port conversion module; the first establishing module 702 is configured to establish a network link with the second network and the serial port conversion module based on the IP of the second network and the serial port conversion module.
In some embodiments, the first processing module 701 is further configured to send an open instruction to the second network-to-serial port conversion module through the network link, so that the second network-to-serial port conversion module opens a first serial port connected between the second network-to-serial port conversion module and the accessed serial port device; the first serial port is used for realizing serial port communication between the second network and serial port conversion module and the accessed serial port equipment.
In some embodiments, the first processing module 701 is further configured to send a closing instruction to the second network-to-serial port conversion module through the network link, so that the second network-to-serial port conversion module closes the first serial port.
In some embodiments, the first electronic device comprises: a first network and serial port conversion module; the first establishing module 702 is configured to control the first network and serial port conversion module to establish a network link with the second network and serial port conversion module; the first processing module 701 is configured to control the first network-to-serial port conversion module to send access data to the second network-to-serial port conversion module through the network link; the first processing module 701 is further configured to control the first network-to-serial port conversion module to receive, through the network link, response data sent by the accessed serial port device and forwarded by the second network-to-serial port conversion module.
In some embodiments, the first electronic device further comprises: a serial port virtual module; the first processing module 701 is further configured to control the serial port virtual module to configure a virtual serial port based on the access requirement; and controlling the serial port virtual module to receive the access data through the virtual serial port and forwarding the access data to the first network and serial port conversion module.
Fig. 8 is a schematic structural diagram of a composition of a second apparatus for remotely accessing a serial device in an embodiment of the present application, and illustrates an implementation apparatus of a method for remotely accessing a serial device, where the second apparatus 80 is applied to a second electronic device, and specifically includes:
a second establishing module 801, configured to control the second network and the serial port conversion module to establish a network link with the first electronic device;
the second processing module 802 is configured to control the second network and serial port conversion module to receive the access data of the first electronic device through the network link, and forward the access data to the accessed serial port device;
the second processing module 802 is further configured to control the second network and serial port conversion module to receive response data of the accessed serial port device, and forward the response data to the first electronic device through the network link.
In some embodiments, the second processing module 802 is further configured to control the second network and serial port conversion module to receive, through the network link, a start instruction sent by the first electronic device; and controlling the second network and serial port conversion module to open a first serial port connected with the accessed serial port equipment based on the opening instruction.
In some embodiments, the second processing module 802 is further configured to receive a shutdown instruction sent by the first electronic device through the network link; and controlling the second network and serial port conversion module to close the first serial port connected with the accessed serial port device based on the closing instruction.
In some embodiments, the first electronic device comprises: a first network and serial port conversion module; the second establishing module 801 is configured to control the second network and serial port conversion module to establish a network link with the first network and serial port conversion module; the second processing module 802 is configured to control the second network and serial port conversion module to receive the access data sent by the first network and serial port conversion module through the network link, and forward the access data to the accessed serial port device; the second processing module 802 is further configured to control the second network to serial port conversion module to receive the response data of the accessed serial port device, and forward the response data to the first network to serial port conversion module through the network link.
Based on the hardware implementation of each unit in the device for remotely accessing the serial device, the embodiment of the application further provides an electronic device. Fig. 9 is a schematic structural diagram of an electronic device in an embodiment of the present application. As shown in fig. 9, the apparatus 90 includes: a processor 901 and a memory 902 configured to store a computer program capable of running on the processor;
wherein the processor 901 is configured to execute the steps of the methods in the previous embodiments when running the computer program.
Of course, in actual practice, as shown in fig. 9, the various components of the device for remotely accessing serial devices are coupled together by bus system 903. It is understood that the bus system 903 is used to enable communications among the components. The bus system 903 includes a power bus, a control bus, and a status signal bus in addition to a data bus. For clarity of illustration, however, the various buses are labeled as the bus system 903 in FIG. 9.
In practical applications, the processor may be at least one of an Application Specific Integrated Circuit (ASIC), a Digital Signal Processing Device (DSPD), a Programmable Logic Device (PLD), a Field Programmable Gate Array (FPGA), a controller, a microcontroller, and a microprocessor. It is understood that the electronic devices for implementing the above processor functions may be other devices, and the embodiments of the present application are not limited in particular.
The Memory may be a volatile Memory (volatile Memory), such as a Random-Access Memory (RAM); or a non-volatile Memory (non-volatile Memory), such as a Read-Only Memory (ROM), a flash Memory (flash Memory), a Hard Disk (HDD), or a Solid-State Drive (SSD); or a combination of the above types of memories and provides instructions and data to the processor.
In an exemplary embodiment, the present application further provides a computer readable storage medium, such as a memory including a computer program, which is executable by a processor of an electronic device to perform the steps of the foregoing method.
It is to be understood that the terminology used herein is for the purpose of describing particular embodiments only and is not intended to be limiting of the application. As used in this application and the appended claims, the singular forms "a", "an", and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise. It should also be understood that the term "and/or" as used herein refers to and encompasses any and all possible combinations of one or more of the associated listed items. The expressions "having", "may have", "include" and "contain", or "may include" and "may contain" in this application may be used to indicate the presence of corresponding features (e.g. elements such as values, functions, operations or components) but does not exclude the presence of additional features.
It is to be understood that although the terms first, second, third, etc. may be used herein to describe various information, such information should not be limited to these terms. These terms are only used to distinguish one type of information from another, and are not necessarily used to describe a particular order or sequence. For example, first information may also be referred to as second information, and similarly, second information may also be referred to as first information, without departing from the scope of the present invention. The technical solutions described in the embodiments of the present application can be arbitrarily combined without conflict. In the several embodiments provided in the present application, it should be understood that the disclosed method, apparatus, and device may be implemented in other ways. The above-described embodiments are merely illustrative, and for example, the division of a unit is only one logical function division, and there may be other division ways in actual implementation, such as: multiple units or components may be combined, or may be integrated into another system, or some features may be omitted, or not implemented. In addition, the coupling, direct coupling or communication connection between the components shown or discussed may be through some interfaces, and the indirect coupling or communication connection between the devices or units may be electrical, mechanical or other forms.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed on a plurality of network units; some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, all functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may be separately regarded as one unit, or two or more units may be integrated into one unit; the integrated unit may be implemented in the form of hardware, or in the form of hardware plus a software functional unit.
The above description is only for the specific embodiments of the present application, but the scope of the present application is not limited thereto, and any person skilled in the art can easily conceive of the changes or substitutions within the technical scope of the present application, and shall be covered by the scope of the present application.

Claims (15)

1. A method for remotely accessing a serial device is applied to a first electronic device, and is characterized by comprising the following steps:
determining a second network and serial port conversion module connected with the accessed serial port equipment based on the access requirement;
establishing a network link between the second network and the serial port conversion module; sending access data to the second network-to-serial port conversion module through the network link, so that the second network-to-serial port conversion module forwards the access data to the accessed serial port device;
receiving response data of the accessed serial port equipment forwarded by the second network and serial port conversion module through the network link; and the response data is the data sent by the accessed serial port equipment in response to the access data.
2. The method of claim 1, wherein determining the second network to serial port conversion module connected to the accessed serial port device based on the access requirement comprises:
determining a first serial port parameter of the accessed serial port equipment based on the access requirement;
and determining a second network and serial port conversion module corresponding to the first serial port parameter based on the mapping relation between the serial port parameter and the second network and serial port conversion module.
3. The method of claim 2,
the mapping relationship comprises: the mapping relation between the serial port parameters and the Internet communication protocol IP of the network and serial port conversion module;
the establishing of the network link with the second network and the serial port conversion module comprises the following steps:
and establishing a network link between the second network and the serial port conversion module based on the IP of the second network and the serial port conversion module.
4. The method of claim 1, further comprising:
sending a starting instruction to the second network and serial port conversion module through the network link so that the second network and serial port conversion module opens a first serial port connected between the second network and serial port conversion module and the accessed serial port device;
the first serial port is used for realizing serial port communication between the second network and serial port conversion module and the accessed serial port equipment.
5. The method of claim 4, further comprising:
and sending a closing instruction to the second network and serial port conversion module through the network link so that the second network and serial port conversion module closes the first serial port.
6. The method of claim 1, wherein the first electronic device comprises: a first network and serial port conversion module; wherein the content of the first and second substances,
the method comprises the following steps:
controlling the first network and serial port conversion module to establish a network link with the second network and serial port conversion module;
controlling the first network and serial port conversion module to send access data to the second network and serial port conversion module through the network link;
and controlling the first network and serial port conversion module to receive response data transmitted by the accessed serial port device and forwarded by the second network and serial port conversion module through the network link.
7. The method of claim 6, wherein the first electronic device further comprises: a serial port virtual module; wherein the method further comprises:
controlling the serial port virtual module to configure a virtual serial port based on the access requirement;
and controlling the serial port virtual module to receive the access data through the virtual serial port and forwarding the access data to the first network and serial port conversion module.
8. A method for remotely accessing a serial port device is applied to a second electronic device, and the second electronic device comprises a second network and serial port conversion module, and the method comprises the following steps:
controlling the second network and the serial port conversion module to establish a network link with the first electronic equipment;
controlling the second network and serial port conversion module to receive the access data of the first electronic device through the network link and forwarding the access data to the accessed serial port device;
and controlling the second network and serial port conversion module to receive the response data of the accessed serial port equipment and forwarding the response data to the first electronic equipment through the network link.
9. The method of claim 8, further comprising:
controlling the second network and serial port conversion module to receive a starting instruction sent by the first electronic device through the network link;
and controlling the second network and serial port conversion module to open the first serial port connected with the accessed serial port equipment based on the opening instruction.
10. The method of claim 9, further comprising:
receiving a closing instruction sent by the first electronic equipment through the network link;
and based on the closing instruction, controlling the second network and serial port conversion module to close the first serial port connected with the accessed serial port equipment.
11. The method of claim 8, wherein the first electronic device comprises: a first network and serial port conversion module; wherein the content of the first and second substances,
the method comprises the following steps:
controlling the second network and the serial port conversion module to establish a network link with the first network and the serial port conversion module;
controlling the second network and serial port conversion module to receive the access data sent by the first network and serial port conversion module through the network link, and forwarding the access data to the accessed serial port device;
and controlling the second network and serial port conversion module to receive the response data of the accessed serial port equipment and forwarding the response data to the first network and serial port conversion module through the network link.
12. A first device for remotely accessing a serial device is applied to a first electronic device, and is characterized by comprising:
the first processing module is used for determining a second network and serial port conversion module connected with the accessed serial port equipment based on the access requirement;
the first establishing module is used for establishing a network link between the second network and the serial port conversion module;
the first processing module is further configured to send access data to the second network-to-serial port conversion module through the network link, so that the second network-to-serial port conversion module forwards the access data to the accessed serial port device;
the first processing module is further configured to receive, through the network link, response data of the accessed serial device forwarded by the second network and serial port conversion module; and the response data is the data sent by the accessed serial port equipment responding to the access data.
13. A second device for remotely accessing a serial port device is applied to a second electronic device, and is characterized in that the second electronic device comprises a second network and serial port conversion module,
the device comprises:
the second establishing module is used for controlling the second network and the serial port conversion module to establish network link with the first electronic equipment;
the second processing module is used for controlling the second network and serial port conversion module to receive the access data of the first electronic device through the network link and forward the access data to the accessed serial port device;
the second processing module is further configured to control the second network and serial port conversion module to receive response data of the accessed serial port device, and forward the response data to the first electronic device through the network link.
14. An electronic device, characterized in that the device comprises: a processor and a memory configured to store a computer program capable of running on the processor,
wherein the processor is configured to perform the steps of the method of any one of claims 1-11 when executing the computer program.
15. A computer-readable storage medium, on which a computer program is stored which, when being executed by a processor, carries out the steps of the method of any one of claims 1 to 11.
CN202111619552.7A 2021-12-27 2021-12-27 Method, device and equipment for remotely accessing serial port equipment and storage medium Pending CN114500627A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111619552.7A CN114500627A (en) 2021-12-27 2021-12-27 Method, device and equipment for remotely accessing serial port equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111619552.7A CN114500627A (en) 2021-12-27 2021-12-27 Method, device and equipment for remotely accessing serial port equipment and storage medium

Publications (1)

Publication Number Publication Date
CN114500627A true CN114500627A (en) 2022-05-13

Family

ID=81496914

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111619552.7A Pending CN114500627A (en) 2021-12-27 2021-12-27 Method, device and equipment for remotely accessing serial port equipment and storage medium

Country Status (1)

Country Link
CN (1) CN114500627A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116647547A (en) * 2023-05-26 2023-08-25 南京粒聚智能科技有限公司 Method and device for remote communication connection of industrial field device

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101216810A (en) * 2007-12-26 2008-07-09 广东威创视讯科技股份有限公司 Progress and serial equipment communicating method and its device
US20130114618A1 (en) * 2011-11-08 2013-05-09 Chin-Shun HSU System and method for transmitting serial data, and recording medium thereof
WO2015154588A1 (en) * 2014-08-19 2015-10-15 中兴通讯股份有限公司 Serial port information transmission method, single board device and common single board
CN107995019A (en) * 2016-10-27 2018-05-04 南京南瑞继保电气有限公司 Network equipment method and system are safeguarded in a kind of remote debugging based on virtual linkage
CN110958224A (en) * 2019-11-05 2020-04-03 郑州信大捷安信息技术股份有限公司 Remote serial port debugging system and method
CN113177016A (en) * 2021-05-25 2021-07-27 惠州Tcl移动通信有限公司 Serial port communication method, device, terminal equipment and storage medium

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101216810A (en) * 2007-12-26 2008-07-09 广东威创视讯科技股份有限公司 Progress and serial equipment communicating method and its device
US20130114618A1 (en) * 2011-11-08 2013-05-09 Chin-Shun HSU System and method for transmitting serial data, and recording medium thereof
WO2015154588A1 (en) * 2014-08-19 2015-10-15 中兴通讯股份有限公司 Serial port information transmission method, single board device and common single board
CN107995019A (en) * 2016-10-27 2018-05-04 南京南瑞继保电气有限公司 Network equipment method and system are safeguarded in a kind of remote debugging based on virtual linkage
CN110958224A (en) * 2019-11-05 2020-04-03 郑州信大捷安信息技术股份有限公司 Remote serial port debugging system and method
CN113177016A (en) * 2021-05-25 2021-07-27 惠州Tcl移动通信有限公司 Serial port communication method, device, terminal equipment and storage medium

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116647547A (en) * 2023-05-26 2023-08-25 南京粒聚智能科技有限公司 Method and device for remote communication connection of industrial field device
CN116647547B (en) * 2023-05-26 2023-10-13 南京粒聚智能科技有限公司 Method and device for remote communication connection of industrial field device

Similar Documents

Publication Publication Date Title
US9729678B2 (en) Methods of processing data corresponding to a device that corresponds to a gas, water, or electric grid, and related devices and computer program products
US8332055B2 (en) Energy use control system and method
EP2283403B1 (en) System and method for implementing a power control application in a distributed control system using iec61850
CN104092312B (en) A kind of intelligent low-pressure Distribution Management System
CN105163364A (en) Intelligent device WiFi connection system and intelligent device WiFi connection method based on intelligent gateway
CN110971515A (en) Intelligent Internet of things gateway and Internet of things system based on same
CN101854083A (en) Adaptive device for realizing A/D conversion protocol of power equipment
CN107995019B (en) Method and system for remote debugging and maintaining network equipment based on virtual link
CN112039833A (en) Communication manager system and engineering configuration method
CN105573200A (en) Communication apparatus for wind power converter, and communication method
CN114500627A (en) Method, device and equipment for remotely accessing serial port equipment and storage medium
CN107947365A (en) A kind of measure and control device for supporting intelligent substation multi-compartment concentrated collection to control and centralized observing and controlling networking
CN103618617A (en) Method and system for carrying out PPPOE zero configuration service
CN108449403A (en) A kind of charge control method
CN102983988A (en) Equipment agent device and network management device
CN105187550A (en) Remote acquisition and communication system for power equipment data and method
CN103972983A (en) Inverter control system applied to microgrid and communication method of inverter control system applied to microgrid
CN110808904A (en) Building monitoring intelligent gateway based on OPC UA protocol
CN112332540B (en) Microgrid, and simulation device and method
CN112424759A (en) Secure mesh network system for data sharing and associated coupling and interface devices
CN205005087U (en) Long -range power equipment data acquisition communication system
CN203301526U (en) Centralized management system for conventional substation equipment agents based on IEC61850 standard
CN109599939A (en) Power supply monitoring system
US20130119770A1 (en) Network Architectures for Distributed Resource Management in Electric Power Systems
CN204316192U (en) A kind of switch group intelligent work system based on MAS

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination