CN108282545A - A kind of self-defined reallocating method of serial port and device - Google Patents

A kind of self-defined reallocating method of serial port and device Download PDF

Info

Publication number
CN108282545A
CN108282545A CN201711437368.4A CN201711437368A CN108282545A CN 108282545 A CN108282545 A CN 108282545A CN 201711437368 A CN201711437368 A CN 201711437368A CN 108282545 A CN108282545 A CN 108282545A
Authority
CN
China
Prior art keywords
serial
equipment
address
serial equipment
port
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.)
Granted
Application number
CN201711437368.4A
Other languages
Chinese (zh)
Other versions
CN108282545B (en
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.)
Beijing Aerospace Measurement and Control Technology Co Ltd
Original Assignee
Beijing Aerospace Measurement and Control Technology 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 Beijing Aerospace Measurement and Control Technology Co Ltd filed Critical Beijing Aerospace Measurement and Control Technology Co Ltd
Priority to CN201711437368.4A priority Critical patent/CN108282545B/en
Publication of CN108282545A publication Critical patent/CN108282545A/en
Application granted granted Critical
Publication of CN108282545B publication Critical patent/CN108282545B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L61/00Network arrangements, protocols or services for addressing or naming
    • H04L61/50Address allocation
    • H04L61/5053Lease time; Renewal aspects
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L61/00Network arrangements, protocols or services for addressing or naming
    • H04L61/50Address allocation
    • H04L61/5038Address allocation for local use, e.g. in LAN or USB networks, or in a controller area network [CAN]

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Computer And Data Communications (AREA)

Abstract

The invention discloses a kind of self-defined reallocating method of serial port and device, the re-matching device includes serial equipment allocation unit, serial equipment access control unit, serial equipment address resolution unit.The serial bus of serial equipment is accessed re-match device first by the method, device is distinguish multiple serial equipments distribution address of access, send serial equipment address lookup data, it re-matches device and cuts off serial equipment regular path, the corresponding serial equipment of parsing inquiry Address Recognition, and its address is returned to by the serial ports, computer is according to the serial port of return address, the correspondence of serial port and serial equipment is established, modification serial port is self-defined, restores serial equipment regular path.The present invention can recognize that identical serial equipment, and establish the correspondence of serial port and equipment, and change the serial port of all serial equipments automatically, solves computer operating system and is difficult to serial port and the correspondence of equipment this technical problem.

Description

A kind of self-defined reallocating method of serial port and device
Technical field
The invention belongs to serial communication field, it is related to a kind of self-defined reallocating method of serial port and device.
Background technology
The serial port of serial equipment would generally become with the port of connection equipment and the variation of computer operating system Change, meanwhile, for multiple identical serial equipments, computer operating system is difficult to the correspondence of serial port and equipment, These are uncertain so that the application for serial ports needs to change therewith, brings greater inconvenience to application.
Invention content
In view of this, a kind of self-defined reallocating method of serial port of present invention offer and device, to solve current serial equipment Applying upper inconvenience.
The invention is realized by the following technical scheme:
A kind of self-defined re-matching device of serial port, including:
Serial equipment allocation unit distributes different addresses for multiple serial equipments to access;
Serial equipment address resolution unit, for the address lookup data that analytical Calculation machine is sent, according to serial equipment The corresponding serial equipment of Address Recognition of location allocation unit distribution, and the address date of the serial equipment is sent back into computer;
Serial equipment access control unit, for controlling cutting for serial equipment normal communication state and address lookup state It changes.
A kind of self-defined reallocating method of serial port, includes the following steps:
Step 1:The serial bus of serial equipment accesses serial equipment allocation unit, serial equipment allocation unit Different addresses is distributed to multiple serial equipments of access;
Step 2:Computer sends serial equipment address lookup data to serial equipment address resolution unit;
Step 3:Serial equipment access control unit cuts off serial equipment regular path;
Step 4:Serial equipment address resolution unit parses address lookup data, identifies corresponding serial equipment, and pass through The serial ports returns to its address;
Step 5:Computer establishes the correspondence of serial port and serial equipment according to the serial port of return address;
Step 6:It is self-defined serial port that computer changes serial port according to correspondence;
Step 7:Serial equipment access control unit restores serial equipment regular path.
Further, when multiple serial equipments access, step 1-7 is repeated, multiple serial ports are changed using batch processing.
Advantageous effect of the present invention:
The present invention can recognize that identical serial equipment, and establish the correspondence of serial port and equipment, and change all strings The serial port of jaws equipment, solves that computer operating system is difficult to serial port and the correspondence of equipment this technology is asked Topic.
Specific implementation mode
The present invention is described in detail below.
A kind of self-defined re-matching device of serial port of the present invention, including:
Allocation unit:Each equipment is given to distribute address first, this is the basis of all operations.
Computer sends address lookup data.This data contains the address information of equipment.
Access control unit:Serial equipment has 2 working conditions, and one is used for normal communication, and one is used for address lookup. When computer sends address lookup data, which can place a device in inquiry state.
Address resolution unit:When equipment is in inquiry state, resolution unit parses address information, by the ground of corresponding equipment Location data send back computer by the equipment.
Include 2 identical serial equipment A, B in the present embodiment.A, the serial ports of B in a computer be respectively COM12, COM15.A/B and COM12/COM15 correspondences are unknown.The equipment is as the self-defined re-matching dress of serial port provided by the present invention Set and method implement object.
Implementation is as follows:
Step 1:The serial bus access of serial equipment A, B re-match device, and address is respectively 0A, 0B;
Step 2:Computer sends the address lookup data A5A5 01 of serial equipment A by control interface to re-matching device 0A.Wherein 01 indicates that this group of data are querying command, and 0A indicates the serial equipment that inquiry address is 0A.
Step 3:It re-matches device and cuts off serial equipment A, B regular path;
Step 4:Re-match 01 0A of device parsing data A5A5, and by the serial ports of device A to computer transmission data 0A;
Step 5:Computer inquires the data that COM12 and COM15 are received respectively, receives then being established with A equipment pair for 0A It should be related to.If COM12 receives 0A, then A equipment corresponds to COM12;
Step 6:The step of repeating front, establishes B device and the correspondence of COM15;
Step 7:Using the corresponding serial ports of batch processing modification A and B.If COM12 is changed to COM7, COM15 is changed to COM8.It repaiies Change rear A and correspond to COM7, B corresponds to COM8.
Step 8:Re-match the regular path that device restores serial equipment A, B.
In conclusion the above is merely preferred embodiments of the present invention, being not intended to limit the scope of the present invention. All within the spirits and principles of the present invention, any modification made, equivalent replacement, improvement etc. should be included in the present invention's Within protection domain.

Claims (3)

1. a kind of self-defined re-matching device of serial port, which is characterized in that including:
Serial equipment allocation unit distributes different addresses for multiple serial equipments to access;
Serial equipment address resolution unit, for the address lookup data that analytical Calculation machine is sent, according to serial equipment address point The corresponding serial equipment of Address Recognition with unit distribution, and the address date of the serial equipment is sent back into computer;
Serial equipment access control unit, the switching for controlling serial equipment normal communication state and address lookup state.
2. a kind of self-defined reallocating method of serial port, which is characterized in that include the following steps:
Step 1:The serial bus of serial equipment accesses serial equipment allocation unit, the docking of serial equipment allocation unit The multiple serial equipments entered distribute different addresses;
Step 2:Computer sends serial equipment address lookup data to serial equipment address resolution unit;
Step 3:Serial equipment access control unit cuts off serial equipment regular path;
Step 4:Serial equipment address resolution unit parses address lookup data, identifies corresponding serial equipment, and pass through the string Jaws equipment returns to its address;
Step 5:Computer establishes the correspondence of serial port and serial equipment according to the serial port of return address;
Step 6:It is self-defined serial port that computer changes serial port according to correspondence;
Step 7:Serial equipment access control unit restores serial equipment regular path.
3. a kind of self-defined reallocating method of serial port as described in claim 1, which is characterized in that when multiple serial equipments access When, step 1-7 is repeated, multiple serial ports are changed using batch processing.
CN201711437368.4A 2017-12-26 2017-12-26 Serial port number user-defined reconfiguration method and device Active CN108282545B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201711437368.4A CN108282545B (en) 2017-12-26 2017-12-26 Serial port number user-defined reconfiguration method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201711437368.4A CN108282545B (en) 2017-12-26 2017-12-26 Serial port number user-defined reconfiguration method and device

Publications (2)

Publication Number Publication Date
CN108282545A true CN108282545A (en) 2018-07-13
CN108282545B CN108282545B (en) 2020-12-01

Family

ID=62802358

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201711437368.4A Active CN108282545B (en) 2017-12-26 2017-12-26 Serial port number user-defined reconfiguration method and device

Country Status (1)

Country Link
CN (1) CN108282545B (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2003337786A (en) * 2002-05-21 2003-11-28 Victor Co Of Japan Ltd Serial interface device
CN1835464A (en) * 2005-03-16 2006-09-20 联想(北京)有限公司 Method and system of communicating via bluetooth serial port
US8621129B2 (en) * 2010-12-09 2013-12-31 Intel Corporation Method and apparatus to reduce serial bus transmission power
CN103838699A (en) * 2013-11-28 2014-06-04 深圳市创智成科技股份有限公司 Pluggable multifunctional mobile financial terminal and port number fixing method of pluggable multifunctional mobile financial terminal
CN104811359A (en) * 2015-04-10 2015-07-29 深圳市元征科技股份有限公司 Serial port communication method and terminal

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2003337786A (en) * 2002-05-21 2003-11-28 Victor Co Of Japan Ltd Serial interface device
CN1835464A (en) * 2005-03-16 2006-09-20 联想(北京)有限公司 Method and system of communicating via bluetooth serial port
US8621129B2 (en) * 2010-12-09 2013-12-31 Intel Corporation Method and apparatus to reduce serial bus transmission power
CN103838699A (en) * 2013-11-28 2014-06-04 深圳市创智成科技股份有限公司 Pluggable multifunctional mobile financial terminal and port number fixing method of pluggable multifunctional mobile financial terminal
CN104811359A (en) * 2015-04-10 2015-07-29 深圳市元征科技股份有限公司 Serial port communication method and terminal

Also Published As

Publication number Publication date
CN108282545B (en) 2020-12-01

Similar Documents

Publication Publication Date Title
EP3229421B1 (en) Media access control address forwarding table transmission control method, apparatus, and system
CN102307246B (en) Based on the secure communication among virtual machines protection system of cloud computing
US9525648B2 (en) Method for acquiring physical address of virtual machine
SG11201800101YA (en) Packet processing method in cloud computing system, host, and system
US20150095505A1 (en) Resolving network address conflicts
CN105262685A (en) Message processing method and message processing device
US20170026274A1 (en) Method for processing packet in network, forwarding device, and packet processing system
CN104468568A (en) Virtual machine security isolation method
US20180234339A1 (en) Communication device, communication system, and communication method
CN102055641A (en) Distribution method for virtual local area network and related device
CN103678676A (en) IP library processing method and system
CN106790795A (en) A kind of method of controlling antenna and electronic equipment
CN101483657A (en) Implementation method and system for same side private network device access by private user
CN108282545A (en) A kind of self-defined reallocating method of serial port and device
CN104333612A (en) Network address translation method and device
CN102437928B (en) Communication method capable of self-adaptively switching between two speeds of CAN (Controller Area Network) bus
CN109981725B (en) Communication method across security domains, server and readable storage medium
CN103428305A (en) Network equipment batch upgrading method
CN100454825C (en) Static user access network control method based on MAC address
CN113497765B (en) Method and device for route management, electronic equipment and storage medium
CN105245465A (en) Flow control system and method of switch
CN106302201A (en) Flow control methods, equipment and system
CN204887031U (en) Network operator self-adaptive intelligent DNS device
CN204498144U (en) A kind of Virtual network operator multiple exit based on Campus Network selects equipment
CN105099732B (en) A kind of methods, devices and systems identifying abnormal IP traffic

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
GR01 Patent grant
GR01 Patent grant