CN110765048B - Serial port and network port self-adaptive system, electronic equipment and signal processing method - Google Patents

Serial port and network port self-adaptive system, electronic equipment and signal processing method Download PDF

Info

Publication number
CN110765048B
CN110765048B CN201911057470.0A CN201911057470A CN110765048B CN 110765048 B CN110765048 B CN 110765048B CN 201911057470 A CN201911057470 A CN 201911057470A CN 110765048 B CN110765048 B CN 110765048B
Authority
CN
China
Prior art keywords
signal
relay
pin
serial
ethernet
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.)
Active
Application number
CN201911057470.0A
Other languages
Chinese (zh)
Other versions
CN110765048A (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.)
Maipu Communication Technology Co Ltd
Original Assignee
Maipu Communication 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 Maipu Communication Technology Co Ltd filed Critical Maipu Communication Technology Co Ltd
Priority to CN201911057470.0A priority Critical patent/CN110765048B/en
Publication of CN110765048A publication Critical patent/CN110765048A/en
Application granted granted Critical
Publication of CN110765048B publication Critical patent/CN110765048B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/38Information transfer, e.g. on bus
    • G06F13/382Information transfer, e.g. on bus using universal interface adapter
    • G06F13/385Information transfer, e.g. on bus using universal interface adapter for adaptation of a particular data processing system to different peripheral devices
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/38Information transfer, e.g. on bus
    • G06F13/40Bus structure
    • G06F13/4004Coupling between buses
    • G06F13/4022Coupling between buses using switching circuits, e.g. switching matrix, connection or expansion network
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2213/00Indexing scheme relating to interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F2213/0002Serial port, e.g. RS232C
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F2213/00Indexing scheme relating to interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F2213/38Universal adapter
    • G06F2213/3808Network interface controller

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Mathematical Physics (AREA)
  • Computer Hardware Design (AREA)
  • Dc Digital Transmission (AREA)

Abstract

The application provides a serial port and network port self-adaptive system, an electronic device and a signal processing method, wherein the serial port and network port self-adaptive system comprises an interface connector, a serial port device and an Ethernet port device which are connected with the interface connector, and the serial port device and the Ethernet port device multiplex signal pins of the interface connector; the serial port device and the Ethernet port device are in communication connection with the controller. When the serial port device detects a serial port signal, a first state signal is sent to the controller, so that the controller controls the first relay to only keep the communication channel of the serial port device communicated; and when the Ethernet port device detects the Ethernet signal, sending a second state signal to the controller, so that the controller controls the first relay to only keep the communication channel of the Ethernet port device connected. The multiplexing of the Ethernet port and the serial port is realized, the functional integrity of the equipment is ensured, the space utilization rate of the equipment is improved, and the problem of how to arrange the Ethernet port and the serial port on small-size equipment or equipment with ultrahigh network port density is solved.

Description

Serial port and network port self-adaptive system, electronic equipment and signal processing method
Technical Field
The application relates to the technical field of communication, in particular to a serial port and network port self-adaptive system, electronic equipment and a signal processing method.
Background
Serial ports often cannot be placed on small-volume devices or devices with ultra-high mesh density. The serial port is usually discarded or placed inside the device. Both of these approaches make the maintenance of the device in a field application environment very inconvenient. How to arrange ethernet port and serial ports simultaneously on equipment of small volume or super high network port density to guarantee the functional integrality of equipment, improve equipment space utilization just becomes a problem that awaits a urgent need to be solved.
Disclosure of Invention
An object of the embodiments of the present application is to provide a serial port and network port adaptive system, an electronic device, and a signal processing method, so as to implement simultaneous layout of an ethernet port and a serial port, ensure functional integrity of the device, and improve space utilization of the device.
The embodiment of the application provides a serial port and net gape self-adaptation system, includes: the device comprises an interface connector, a serial port device, an Ethernet port device, a first relay and a controller; wherein:
the interface connector comprises a signal pin; the first relay is used for connecting the signal pin with the serial port device and the Ethernet port device respectively; the serial port device and the Ethernet port device multiplex the signal pin;
the serial port device and the Ethernet port device are in communication connection with the controller;
the serial port device is used for sending a first state signal to the controller when the signal pin is communicated with the serial port device and the signal transmitted by the signal pin is detected to be a serial port signal;
the Ethernet port device is used for sending a second state signal to the controller when the signal pin is communicated with the Ethernet port device and the signal transmitted by the signal pin is detected to be an Ethernet signal;
the controller is in communication connection with the first relay and is used for controlling the first relay to keep the signal pin connected with the communication path of the serial port device and disconnect the signal pin from the communication path of the Ethernet port device when the first state signal is received; and when the second state signal is received, controlling the first relay to keep the communication path between the signal pin and the Ethernet port device connected and disconnect the communication path between the signal pin and the serial port device.
In the implementation process, the interface connector connects the signal pin thereof with the serial port device and the ethernet port device through the first relay, so that the signal pin can be output to the serial port device and/or the ethernet port device after receiving an externally input signal. And the serial port device can judge whether the serial port signal is the serial port signal after receiving the signal, and then when the signal is the serial port signal, inform the controller, make the first relay of controller control make interface connector only communicate with the serial port device to guarantee that the serial port signal is effectively handled by the serial port device. Similarly, the ethernet port device may determine whether the signal is an ethernet signal after receiving the signal, and then notify the controller when the signal is the ethernet signal, so that the controller controls the first relay to enable the interface connector to be only communicated with the ethernet port device, thereby ensuring that the ethernet signal is effectively processed by the ethernet port device. Therefore, two functions of the Ethernet port and the serial port are realized through one interface connector, the functional integrity of the equipment is ensured, the space utilization rate of the equipment is improved, and the problem of how to arrange the Ethernet port and the serial port on small-size equipment or equipment with ultrahigh network port density is solved.
In addition, in this application embodiment, serial port device and the signal needle of the multiplexing interface connector of ethernet mouth device, same signal needle both can be used for exporting ethernet signal, can be used for exporting serial signals again, has greatly promoted the utilization ratio of the signal needle of interface connector to the overall arrangement space has further been practiced thrift.
Further, the first relay is a single-pole double-throw relay; the controller is further configured to control the single-pole double-throw relay to periodically communicate the signal pin with the serial port device and the ethernet port device, respectively, when the first status signal is not received and the second status signal is not received.
In the implementation process, when the controller does not receive the first state signal or the second state signal, the controller controls the single-pole double-throw relay to periodically communicate the signal pin with the serial port device and the ethernet port device respectively, so that the interface connector can be periodically input into the serial port device and the ethernet port device, and the signal received by the interface connector can be identified by the serial port device or the ethernet port device when the signal is the serial port signal or the ethernet signal, thereby ensuring the practicability and reliability of the scheme of the application.
Further, the ethernet port device includes an ethernet isolator and an ethernet port chip; the Ethernet port chip is connected with the first relay through the Ethernet isolator.
In the implementation process, the Ethernet isolator is arranged between the first relay and the Ethernet port chip, so that the signal transmitted to the Ethernet port chip by the first relay is isolated by the Ethernet isolator, the signal input to the Ethernet port chip is prevented from being distorted, and the reliability of the scheme of the embodiment of the application is improved.
Further, the Ethernet isolator comprises an alternating current coupling capacitor and an Ethernet port transformer; the alternating current coupling capacitor is connected with the first relay, the alternating current coupling capacitor is connected with the Ethernet port transformer in series, and the Ethernet port transformer is connected with the Ethernet port chip.
In the implementation process, the Ethernet isolator is composed of an alternating current coupling capacitor and an Ethernet port transformer which are connected in series, and the Ethernet port transformer is used for isolating interference signals so as to prevent the signals input to the Ethernet port chip from being distorted; and the alternating current coupling capacitor is connected in series in front of the Ethernet port transformer, so that when the Ethernet port transformer is connected with an opposite terminal device and an opposite terminal serial port is connected to a local terminal Ethernet port chip, a loop formed by the opposite terminal Ethernet port is prevented from being short-circuited, and the opposite terminal serial port is prevented from being burnt.
Further, the serial port device comprises a serial port chip and a current limiting resistor; and an output pin of the serial port chip is connected with the first relay through the current-limiting resistor.
In practical applications, the center taps of the ethernet port transformer are usually connected together. In the implementation process, when the ethernet port of the opposite terminal is connected to the interface connector and the first relay just connects the interface connector with the serial port chip, the pins 4 and 5 of the interface connector are connected to the reference ground signal of the serial port chip, and the transformer center taps of the ethernet ports of the opposite terminals are connected to each other, so that the pins 1, 2, 3, 6, 7 and 8 of the interface connector of the local terminal are all connected to the reference ground signal through the pins 4 and 5, and the serial port chip of the local terminal receives the reference ground signal which is the signal on RXD, DSR and CTS, and does not receive the effective serial port signal. TXD, DTR and RTS signals sent by the serial port chip are connected to a reference ground signal through a current-limiting resistor, so that the situation that a loop formed by the serial port chip and an opposite-end Ethernet port is short-circuited to burn the serial port chip at the local end is avoided.
Further, the serial port device comprises a serial port chip and a second relay; an input pin of the serial port chip is connected with the first relay, and an output pin of the serial port chip is connected with the second relay; the second relay is connected with the first relay and is in communication connection with the controller; the controller is further configured to control the second relay to connect a communication path between the first relay and an output pin of the serial port chip when the first state signal is received, and control the second relay to disconnect the communication path between the first relay and the output pin of the serial port chip when the first state signal is not received.
In the practical application process, if the center taps of the ethernet port transformer are not connected together but are normally connected with the ethernet port chip, the serial port chip sends a serial port sending signal and then becomes a serial port receiving signal through the loop of the opposite terminal equipment, so that a detection error occurs in the serial port chip. In the implementation process, when the controller receives the first state signal (namely, when the serial port chip receives the serial port signal), the second relay is controlled to communicate the first relay with the output pin of the serial port chip, so that the serial port chip can output the serial port sending signal, and the second relay is enabled to disconnect the first relay from the output pin of the serial port chip at ordinary times. In practical application, when the serial port chip of the local terminal receives the serial port signal of the opposite terminal, the serial port signal does not loop back the signal sent by the local terminal, so that the serial port chip receives the serial port signal, the opposite terminal is the serial port, the second relay is controlled to communicate the first relay with the output pin of the serial port chip, the serial port chip outputs the serial port sending signal, the serial port receiving signal looped back by the equipment of the opposite terminal cannot be received, and the effect of preventing the output signal from flowing back can be achieved.
Further, the interface connector is an RJ45 connector;
when the first relay connects the RJ45 connector with the Ethernet port device, the 1 st signal pin of the RJ45 connector is connected with the MDI1+ pin of the Ethernet port device through the first relay, the 2 nd signal pin is connected with the MDI 1-pin of the Ethernet port device through the first relay, the 3 rd signal pin is connected with the MDI2+ pin of the Ethernet port device through the first relay, the 6 th signal pin is connected with the MDI 2-pin of the Ethernet port device through the first relay, the 4 th signal pin is connected with the MDI3+ pin of the Ethernet port device through the first relay, the 5 th signal pin is connected with the MDI 3-pin of the Ethernet port device through the first relay, and the 7 th signal pin is connected with the MDI4+ pin of the Ethernet port device through the first relay, the 8 th signal pin is connected with an MDI 4-pin of the Ethernet port device through the first relay;
when the RJ45 connector is communicated with the serial device through the first relay, the 1 st signal pin is connected with an RTS pin of the serial device through the first relay, the 2 nd signal pin is connected with a DTR pin of the serial device through the first relay, the 3 rd signal pin is connected with a TXD pin of the serial device through the first relay, the 4 th signal pin and/or the 5 th signal pin are/is connected with a reference ground signal, the 6 th signal pin is connected with an RXD pin of the serial device through the first relay, the 7 th signal pin is connected with a DSR pin of the serial device through the first relay, and the 8 th signal pin is connected with a CTS pin of the serial device through the first relay.
In the implementation process, the interface connector selects an RJ45 connector, and 8 signal pins of the RJ45 connector are respectively connected to corresponding pins of the ethernet port device and the serial port device according to the connection relationship by multiplexing 8 signal pins of the RJ45 connector, the definition sequence of the signal pins of the RJ45 connector and the pins of the ethernet device conforms to the standard definition of the RJ45 connector, the ethernet port supports 1000M, and the serial port supports interconnection of 7 signal lines, thereby conforming to the current mainstream ethernet signal requirement and the serial port requirement.
Further, the interface connector is an RJ45 connector;
when the first relay communicates the RJ45 connector with the Ethernet port device, a 1 st signal pin of the RJ45 connector is connected with an MDI1+ pin of the Ethernet port device through the first relay, a 2 nd signal pin is connected with an MDI 1-pin of the Ethernet port device through the first relay, a 3 rd signal pin is connected with an MDI2+ pin of the Ethernet port device through the first relay, and a 6 th signal pin is connected with an MDI 2-pin of the Ethernet port device through the first relay;
when the RJ45 connector is communicated with the serial port device through the first relay, the 3 rd signal pin is connected with a TXD pin of the serial port device through the first relay, the 4 th signal pin is connected with an RXD pin of the serial port device through the first relay, and the 5 th signal pin or the 6 th signal pin is connected with a reference ground signal.
In the implementation process, the interface connector selects an RJ45 connector, the definition sequence of the signal pins of the RJ45 connector and the pins of the ethernet device conforms to the standard definition of the RJ45 connector, the ethernet port supports 100M, and the serial port supports interconnection of 3 signal lines, thereby conforming to the current mainstream ethernet signal requirement and the serial port requirement.
An embodiment of the present application further provides an electronic device, including: the shell and any serial port and network port self-adaptive system; the serial port and network port self-adaptive system is arranged in the shell, an opening is reserved on the shell, and the interface connector of the serial port and network port self-adaptive system is exposed through the opening.
In the electronic equipment, two functions of the Ethernet port and the serial port are realized through one interface connector, the functional integrity of the electronic equipment is ensured, the space utilization rate of the electronic equipment is improved, and the electronic equipment can be small-size equipment or equipment with ultrahigh network port density.
The embodiment of the present application further provides a signal processing method, which is applied to any one of the serial port and network port adaptive systems or electronic devices, and includes:
when receiving a signal sent by opposite-end equipment, the interface connector sends the signal to a device which is communicated with the interface connector at present; the device comprises a serial port device and an Ethernet port device;
when the device which is communicated with the interface connector at present is the serial port device, the serial port device detects the signal, and when the signal is detected to be the serial port signal, a first state signal is sent to the controller;
when the device currently communicated with the interface connector is the Ethernet port device, the Ethernet port device detects the signal, and when the signal is detected to be an Ethernet signal, a second state signal is sent to the controller;
when the controller receives the first state signal, the controller controls the first relay to keep the communication between the signal pin and the communication channel of the serial port device and disconnect the signal pin and the communication channel of the Ethernet port device; and when the second state signal is received, controlling the first relay to keep the signal pin connected with the communication path of the Ethernet port device and disconnect the signal pin from the communication path of the serial port device.
In the implementation process, two functions of the Ethernet port and the serial port are realized through one interface connector, the functional integrity of the electronic equipment is ensured, the space utilization rate of the electronic equipment is improved, and the problem of how to arrange the Ethernet port and the serial port on small-size equipment or equipment with ultrahigh network port density is solved.
In addition, in this application embodiment, serial port device and the signal needle of the multiplexing interface connector of ethernet mouth device, same signal needle both can be used for exporting ethernet signal, can be used for exporting serial signals again, has greatly promoted the utilization ratio of the signal needle of interface connector.
Further, when the first relay in the serial port and network port adaptive system of the electronic device is a single-pole double-throw relay, the signal processing method further includes: and when the controller does not receive the first state signal and does not receive the second state signal, the controller controls the single-pole double-throw relay to periodically communicate the signal pin with the serial port device and the Ethernet port device respectively.
In the implementation process, when the controller does not receive the first state signal or the second state signal, the controller controls the single-pole double-throw relay to periodically communicate the signal pin with the serial port device and the ethernet port device respectively, so that the interface connector can be periodically input into the serial port device and the ethernet port device, and the signal received by the interface connector can be identified by the serial port device or the ethernet port device when the signal is the serial port signal or the ethernet signal, thereby ensuring the practicability and reliability of the scheme of the application.
Further, when the serial device includes a serial chip and a second relay, the signal processing method further includes: when the controller receives the first state signal, the controller controls the second relay to communicate the first relay with the output pin of the serial port chip; and when the controller does not receive the first state signal, the controller controls the second relay to disconnect the first relay from the output pin of the serial port chip.
In the implementation process, the controller controls the second relay to communicate the first relay with the output pin of the serial port chip when receiving the first state signal, so that the serial port chip can output a serial port sending signal, and the second relay disconnects the first relay from the output pin of the serial port chip at ordinary times, thereby achieving the effect of preventing the output signal from flowing back.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings that are required to be used in the embodiments of the present application will be briefly described below, it should be understood that the following drawings only illustrate some embodiments of the present application and therefore should not be considered as limiting the scope, and that those skilled in the art can also obtain other related drawings based on the drawings without inventive efforts.
Fig. 1 is a schematic diagram of a basic structure of a serial port and network port adaptive system according to an embodiment of the present disclosure;
fig. 2 is a schematic diagram of a connection structure between an interface connector and a chip, where an ethernet port supporting a 1000M rate and a serial port interconnected by 7 signal lines are implemented according to an embodiment of the present application;
fig. 3 is a schematic diagram of a connection structure between an interface connector and a chip, where an ethernet port supporting a 100M rate and a serial port interconnected by using 3 signal lines are implemented according to an embodiment of the present application;
fig. 4 is a schematic structural diagram of a serial port and network port adaptive system provided with an ethernet isolator according to an embodiment of the present application;
fig. 5 is a schematic structural diagram of a specific serial port and network port adaptive system provided in the embodiment of the present application;
fig. 6 is a schematic structural diagram of another specific serial port and network port adaptive system provided in the embodiment of the present application;
fig. 7 is a flowchart illustrating a signal processing method according to an embodiment of the present application.
Detailed Description
The technical solutions in the embodiments of the present application will be described below with reference to the drawings in the embodiments of the present application.
The first embodiment is as follows:
referring to fig. 1, a schematic structural diagram of a serial port and network port adaptive system provided in the embodiment of the present application includes: interface connector, serial port device, ethernet mouth device, first relay and controller. Wherein:
the interface connector is used for receiving signals such as Ethernet signals and serial port signals sent by opposite-end equipment. In the embodiment of the present application, the interface connector may be a dupont connector, such as an RJ45 connector.
It is to be understood that the interface connector has a plurality of signal pins, which are connected to respective pins of the serial port device and the ethernet port device through the first relay. In the embodiment of the application, each signal pin of the interface connector can be reused by the serial port device and the ethernet port device, so that each signal pin can be more fully utilized to support a higher-speed ethernet port and more serial ports with interconnected signal lines. The following description will be given by way of example of the interface connector being an RJ45 connector.
Before the example description, some basic knowledge of serial ports and ethernet ports is introduced for understanding. Digital circuitry often uses serial and ethernet ports in RS232 (standardized 232) level format. The serial port is used for issuing configuration information and monitoring the running state of the equipment; the ethernet port is used for data traffic transmission. The Ethernet port supports 1000M rate and is interconnected by 8 signal lines. The 8 signals are MID1+, MDI1-, MDI2+, MDI2-, MDI3+, MDI3-, MDI4+, MDI 4-. These 8 signals are both input signals and output signals. Currently, there are ethernet ports supporting 100M rate, and the ethernet ports supporting 100M rate are interconnected by 4 signal lines, where the 4 signals are MID1+, MDI1-, MDI2-, and MDI 2-. These 4 signals are both input signals and output signals. The serial port is in an RS232 level format and is interconnected by at least 3 signal lines. These 3 signals are TXD, RXD, GND. And at least 7 signal lines or 9 signal lines are adopted for interconnection of the serial ports with the flow control supporting function in part. Taking 7 signals as an example, TXD, DTR, RTS are output signals, RXD, CTS, DSR are input signals, and the remaining GND is a reference ground signal.
The first relay can be regarded as a switch, is connected with the controller, and can control the connection and disconnection of the interface connector and the serial port device and the communication path between the interface connector and the Ethernet port device under the instruction of the controller. In the embodiment of the present application, the controller may be a CPU (Central Processing Unit/Processor) or a Programmable Logic Device (such as a CPLD (Complex Programmable Logic Device), an FPGA (Field-Programmable Gate Array), or a single chip microcomputer).
In order to implement an ethernet port supporting 1000M speed and a serial port supporting 7 signal lines for a current control function, when the interface connector is an RJ45 connector, as shown in fig. 2, when the RJ45 connector is connected to an ethernet port device by a first relay, a 1 st signal pin of the RJ45 connector may be connected to an MDI1+ pin of the ethernet port device by the first relay, a 2 nd signal pin may be connected to an MDI 1-pin of the ethernet port device by the first relay, a 3 rd signal pin may be connected to an MDI2+ pin of the ethernet port device by the first relay, a 6 th signal pin may be connected to an MDI 2-pin of the ethernet port device by the first relay, a 4 th signal pin may be connected to an MDI3+ pin of the ethernet port device by the first relay, a 5 th signal pin may be connected to an MDI 3-pin of the ethernet port device by the first relay, the 7 th signal pin can be connected with an MDI4+ pin of the Ethernet port device through the first relay, and the 8 th signal pin can be connected with an MDI 4-pin of the Ethernet port device through the first relay.
And when first relay communicates the RJ45 connector with serial devices, the 1 st signal needle of RJ45 connector can be connected with the RTS pin of serial devices through first relay, the 2 nd signal needle can be connected with the DTR pin of serial devices through first relay, the 3 rd signal needle can be connected with the TXD pin of serial devices through first relay, the 4 th signal needle and/or the 5 th signal needle can insert reference ground signal, the 6 th signal needle can be connected with the RXD pin of serial devices through first relay, the 7 th signal needle can be connected with the DSR pin of serial devices through first relay, the 8 th signal needle can be connected with the CTS pin of serial devices through first relay.
It should be understood that an ethernet port supporting 100M rate and a serial port interconnected by 3 signal lines can also be implemented by using the solution of the present application.
Referring to fig. 3, when the first relay connects the RJ45 connector with the ethernet port device, the 1 st signal pin of the RJ45 connector may be connected with the MDI1+ pin of the ethernet port device through the first relay, the 2 nd signal pin may be connected with the MDI 1-pin of the ethernet port device through the first relay, the 3 rd signal pin may be connected with the MDI2+ pin of the ethernet port device through the first relay, and the 6 th signal pin may be connected with the MDI 2-pin of the ethernet port device through the first relay;
and when first relay communicates the RJ45 connector with the serial devices, when first relay communicates the RJ45 connector with the serial devices, the 3 rd signal needle of RJ45 connector can be connected with the TXD pin of serial devices through first relay, the 4 th signal needle can be connected with the RXD pin of serial devices through first relay, the 5 th signal needle or the 6 th signal needle can insert reference ground signal.
It should be understood that the above-mentioned implementation manners of fig. 2 and fig. 3 are only two possible implementation manners illustrated in the embodiment of the present application, and in practical applications, other possible connection structures may also be adopted, for example, referring to a connection manner of a serial device in fig. 2 and a connection manner of an ethernet port device in fig. 3, to implement a serial port that supports an ethernet port with a rate of 100M and is interconnected by 7 signal lines that support a flow control function, or referring to a connection manner of a serial device in fig. 3 and a connection manner of an ethernet port device in fig. 2, to implement an ethernet port with a rate of 1000M and a serial port that is interconnected by 3 signal lines, and the like.
In the embodiment of the application, the definition sequence between each signal pin of the RJ45 connector and the pin of the ethernet device conforms to the standard definition of the RJ45 connector, and the definition of the serial port signal can be adjusted flexibly and properly. And other non-standard interface connectors are used, so that the connection sequence between each signal pin of the interface connector and the Ethernet device and the serial device can be defined at will.
In the embodiment of the application, the serial port device is connected with the controller. The serial port device sends a first state signal to the controller when the signal pin of the interface connector is communicated with the serial port device and the signal transmitted by the signal pin is detected to be a serial port signal. Similarly, the ethernet port device is also connected to the controller, and the ethernet port device sends a second status signal to the controller when the signal pin of the interface connector is connected to the ethernet port device and it is detected that the signal transmitted from the signal pin is an ethernet signal.
It should be noted that the ethernet signal is a differential signal, and in the 1000M rate mode, the differential level is between 600mV and 900 mV; in the 100M rate mode, the differential level is between 800mV and 1050mV, and the amplitude of the Ethernet signal level is small. The serial port signal is RS232 level, the effective logic 1 level of the RS232 is-3V to-15V, and the logic 0 level is +3V to + 15V. Because the Ethernet signal and the serial port signal have different level characteristics, the Ethernet port device can only detect the Ethernet signal, and the serial port device can only detect the effective serial port signal.
In this embodiment, the ethernet port device includes an ethernet port chip, and the ethernet port chip collects and detects a signal transmitted from the interface connector in real time, and when the transmitted signal is detected to be an ethernet signal, a link (link) may be established, and a second status signal (e.g., a status signal indicating that the link is successful) may be output to the controller. In the embodiment of the present application, the ethernet port chip may adopt an ethernet PHY (Physical Layer) chip (e.g., BCM54616S, 88E1111 chip, etc.). In the embodiment of the present application, the ethernet port chip may send the status to the controller through 1 GPIO (General-purpose input/output) signal. Or the state is sent to the controller by a MIIM (Medium Independent Interface Management) bus or an SPI (Serial Peripheral Interface) bus.
In this embodiment, the serial device includes a serial chip, the serial chip (for example, a chip such as an ICL 3243) detects a signal transmitted from the interface connector in real time, and when it is detected that the transmitted signal level is a valid RS232 level, the status pin (# invalid) outputs a status signal of a logic high level (i.e., a first status signal) to the controller, and the first status signal indicates that the serial signal is valid.
In the embodiment of the application, the controller can be connected with the first relay through the control signal line so as to output a corresponding control signal and realize on-off control of the first relay. In the embodiment of the application, after the serial port device receives the serial port signal, in order to ensure the serial port device to continuously process the serial port signal, the controller is required to control the first relay to keep the communication channel between the interface connector and the serial port device connected; similarly, after the ethernet port device receives the ethernet signal, in order to ensure the ethernet signal can be continuously processed by the ethernet port device, the controller is required to control the first relay to maintain the communication channel between the interface connector and the ethernet port device. In practical application, after the serial port device receives the serial port signal, if the signal is still transmitted to the ethernet port device, or after the ethernet port device receives the ethernet signal, the signal is still transmitted to the serial port device, which may cause mutual interference between the serial port device and the ethernet port device, and thus the signal may not be correctly processed. And when the controller receives a second state signal transmitted by the Ethernet port device, the controller controls the first relay to keep the signal pin communicated with the communication channel of the Ethernet port device and disconnect the signal pin from the communication channel of the serial port device.
It is worth noting that, in the embodiment of the present application, in order to ensure that the signal received by the interface connector can be effectively transmitted to the serial port device and the ethernet port device for detection, the first relay may adopt a double-pole relay (two pole-keepers of the double-pole relay respectively perform on-off control, in a practical example, two single-pole single-throw relays may be selected as one double-pole relay), and the double poles of the double-pole relay respectively control on-off of the interface connector and the serial port device, and on-off of the interface connector and the ethernet port device. When the controller does not receive the first state signal and the second state signal, the controller outputs a control signal to control the two poles of the first relay to be closed, so that the signals received by the interface connector can be transmitted to the serial port device and the Ethernet port device at the same time. And after the serial port device detects the serial port signal and outputs a first state signal to the controller, the controller controls the first relay to disconnect the knife and the contact of the communication path between the interface connector and the Ethernet port device. Correspondingly, after the ethernet port device detects the ethernet signal and outputs the second state signal to the controller, the controller controls the first relay to disconnect the knife and the contact of the communication path between the interface connector and the serial port device.
In an implementation manner of the embodiment of the application, the serial device may continuously output the first state signal to the controller after receiving the serial signal, and stop outputting the first state signal to the controller after detecting that the received signal is changed from the serial signal to the non-serial signal, so that the controller controls the knife and the contact of the communication path between the interface connector and the ethernet port device to be in contact with each other again after stopping receiving the first state signal, so that the communication path between the interface connector and the ethernet port device is communicated. In addition, in another implementation manner of the embodiment of the present application, the serial device may output a first state signal to the controller once after receiving the serial signal, and output a signal indicating that the serial signal is invalid to the controller after detecting that the received signal changes from the serial signal to a non-serial signal, so that the controller controls the first relay to re-contact a knife and a contact of a communication path between the interface connector and the ethernet port device, so as to communicate the communication path between the interface connector and the ethernet port device. Similarly, in an implementation manner of the embodiment of the present application, the ethernet port device may continuously output the second status signal to the controller after receiving the ethernet signal, and stop outputting the second status signal to the controller after detecting that the received signal changes from the ethernet signal to a non-ethernet signal, so that the controller controls the second relay to re-contact the blade and the contact for controlling the communication path between the interface connector and the serial port device after stopping receiving the second status signal, so as to communicate the communication path between the interface connector and the serial port device. In addition, in another implementation manner of the embodiment of the present application, the ethernet port device may output a second status signal to the controller once after receiving the ethernet signal, and output a signal indicating that the ethernet signal is received completely to the controller after detecting that the received signal changes from the ethernet signal to a non-ethernet signal, so that the controller controls the second relay to re-contact the blade and the contact for controlling the communication path between the interface connector and the serial port device, so as to communicate the communication path between the interface connector and the serial port device.
It should be noted that, in this embodiment of the application, in order to ensure that the signal received by the interface connector can be effectively transmitted to the serial device and the ethernet port device for detection, the first relay may also be implemented by using a single-pole double-throw relay. At this time, when the controller does not receive the first state signal and does not receive the second state signal, the controller controls the first relay to periodically communicate the signal pin with the serial port device and the ethernet port device respectively, so that the signal of the interface connector is periodically input into the serial port device and the ethernet port device for detection. It should be noted that, at this time, in order to ensure that the controller has enough time to fix the conducting direction of the first relay to the path corresponding to the detected signal after the signal is detected as the serial port signal or the ethernet signal, the switching period t of the first relay may be set to be greater than the time from the time when the serial port device or the ethernet port device receives the signal transmitted from the interface connector to the time when the controller sends a corresponding control instruction to the first relay according to the state signal fed back by the serial port device or the ethernet port device.
In this embodiment, referring to fig. 4, the ethernet port device may include an ethernet isolator and an ethernet port chip, where the ethernet isolator is disposed between the first relay and the ethernet port chip, and the ethernet port chip is connected to the first relay through the ethernet isolator, so as to isolate a signal transmitted from the interface connector through the ethernet isolator, prevent distortion of a signal input to the ethernet port chip, and improve reliability of the solution of the embodiment of the present application.
In the embodiment of the present application, the ethernet isolator may include an ac coupling capacitor and an ethernet port transformer. The alternating current coupling capacitor is connected with the first relay, the alternating current coupling capacitor is connected with the Ethernet port transformer in series, and the Ethernet port transformer is connected with the Ethernet port chip. Thus, the Ethernet port transformer is used for realizing the isolation of interference signals so as to prevent the distortion of signals input to the Ethernet port chip; and the alternating current coupling capacitor is connected in series in front of the Ethernet port transformer, so that when the Ethernet port transformer is connected with an opposite terminal device and an opposite terminal serial port is connected to a local terminal Ethernet port chip, a loop formed by the opposite terminal Ethernet port is prevented from being short-circuited, and the opposite terminal serial port is prevented from being burnt.
It should be noted that, in a possible implementation manner of the embodiment of the present application, the serial device may include a serial chip and a current limiting resistor, and an output pin of the serial chip is connected to the first relay through the current limiting resistor, for example, as shown in fig. 5. It should be understood that in practical applications, the center taps of the ethernet port transformer are typically connected together. In the above feasible embodiment, when the ethernet port of the opposite terminal is connected to the interface connector, and the first relay just connects the interface connector with the serial port chip, since the 4 th and 5 th pins of the interface connector are connected to the reference ground signal of the serial port chip, and since the transformer center taps of the ethernet ports of the opposite terminals are connected to each other, the 1 st, 2 nd, 3 rd, 6 th, 7 th and 8 th pins of the interface connector of the local terminal are all connected to the reference ground signal through the 4 th and 5 th pins, and at this time, the serial port chip of the local terminal receives the signals on RXD, DSR and CTS as the reference ground signal, and the serial port chip does not receive the "valid serial port signal". TXD, DTR and RTS signals sent by the serial port chip are connected to a reference ground signal through a current-limiting resistor, so that the situation that a loop formed by the serial port chip and an opposite-end Ethernet port is short-circuited to burn the serial port chip at the local end is avoided.
In another possible implementation manner of the embodiment of the present application, as shown in fig. 6, the serial device may also include a serial chip and a second relay, where an input pin of the serial chip is connected to the first relay, and an output pin of the serial chip is connected to the second relay. The second relay is connected with the first relay and is in communication connection with the controller, when the controller receives the first state signal, the second relay is controlled to communicate the first relay with the output pin of the serial port chip, and when the first state signal is not received, the second relay is controlled to disconnect the first relay from the output pin of the serial port chip. It should be noted that, in practical application, when the local serial port chip receives the serial port signal of the opposite end, it is indicated that the opposite end is already a serial port, and the serial port does not loop back the signal sent by the local end, therefore, in this practical implementation, when the serial port chip receives the serial port signal, it is indicated that the opposite end is a serial port, at this time, the second relay is controlled to communicate the first relay with the output pin of the serial port chip, the serial port chip outputs the serial port sending signal, and the serial port receiving signal of the loop back of the opposite end device is not received, so that the effect of preventing the output signal from flowing back can be achieved. At this time, there is no requirement for connecting the center taps of the ethernet port transformer of the end device.
It should be noted that, in a scenario where a serial port signal is determined when a signal is accessed by the interface connector, an engineer may fix the controller to control the first relay to connect the communication path between the serial port device and the interface connector, and disconnect the communication path between the ethernet port device and the interface connector. With the structure shown in fig. 6, it is also necessary to control the second relay to be turned on. Similarly, when the scenario of the ethernet signal is clear of the signal accessed by the interface connector, the engineer may control the first relay to connect the communication path between the ethernet port device and the interface connector and disconnect the communication path between the serial port device and the interface connector by the fixed controller.
It is worth noting that, in the embodiment of the present application, the serial port and network port adaptive system may be disposed in an electronic device, for example, may be disposed on a small-sized device or a device with an ultra-high network port density, so as to solve the problem that in the related art, a serial port often cannot be placed on a small-sized device or a device with an ultra-high network port density, and the serial port needs to be discarded or placed inside an internal device.
It should be noted that, when the serial port and network port adaptive system is arranged in the electronic device, an opening should be left on the housing of the electronic device, so that after the serial port and network port adaptive system is arranged in the housing, the interface connector can be exposed through the opening, thereby ensuring that the interface connector obtains signals.
In the embodiment of the present application, a signal processing method is further provided, which may be applied to the serial port and internet port adaptive system described in the embodiment of the present application, or to an electronic device provided with the system. The signal processing method can be seen in fig. 7, and includes:
s701: when receiving the signal sent by the opposite terminal equipment, the interface connector sends the signal to the device which is currently communicated with the interface connector.
S702: when the device currently communicated with the interface connector is a serial device, the serial device detects a signal, and when the signal is detected to be a serial signal, a first state signal is sent to the controller, and the process goes to step S703.
S703: and controlling the first relay to keep the communication between the signal pin and the communication path of the serial port device and disconnect the signal pin and the communication path of the Ethernet port device.
S704: when the device currently connected to the interface connector is an ethernet port device, the ethernet port device detects a signal, and when the signal is detected to be an ethernet signal, sends a second status signal to the controller, and goes to step S705.
S705: and controlling the first relay to keep the signal pin connected with the communication path of the Ethernet port device and disconnect the signal pin from the communication path of the serial port device.
It should be noted that the specific flow of the signal processing method provided in the embodiment of the present application is adapted to the specific structure of the serial port and network port adaptive system described above, and the specific structure of the serial port and network port adaptive system has slight differences, and the signal processing flow thereof has certain differences with respect to the adaptability.
Illustratively, when the first relay in the serial port and network port adaptive system of the electronic device is a single-pole double-throw relay, the signal processing method further includes: and when the controller does not receive the first state signal and the second state signal, the controller controls the first relay to periodically communicate the signal pin with the serial port device and the Ethernet port device respectively. When the serial device comprises the serial chip and the second relay, the signal processing method further comprises the following steps: when the controller receives the first state signal, the controller controls the second relay to communicate the first relay with the output pin of the serial port chip; and when the controller does not receive the first state signal, the controller controls the second relay to disconnect the first relay from the output pin of the serial port chip.
The signal processing method adapted to the specific structure of the different serial port and network port adaptive systems may refer to the description about the serial port and network port adaptive systems, and the functions of each component and the flow direction of the signals are obtained, which are not described herein again.
According to the serial port and network port self-adaptive system, the electronic equipment and the signal processing method provided by the embodiment of the application, the interface connector connects the signal pin of the interface connector with the serial port device and the Ethernet port device respectively through the first relay, so that the signal pin can be output to the serial port device and/or the Ethernet port device after receiving an externally input signal. And the serial port device can judge whether the serial port signal is the serial port signal after receiving the signal, and then when the signal is the serial port signal, inform the controller, make the first relay of controller control make interface connector only communicate with the serial port device to guarantee that the serial port signal is effectively handled by the serial port device. Similarly, the ethernet port device may determine whether the signal is an ethernet signal after receiving the signal, and then notify the controller when the signal is the ethernet signal, so that the controller controls the first relay to enable the interface connector to be only communicated with the ethernet port device, thereby ensuring that the ethernet signal is effectively processed by the ethernet port device. Therefore, two functions of the Ethernet port and the serial port are realized through one interface connector, the functional integrity of the equipment is ensured, the space utilization rate of the equipment is improved, and the problem of how to arrange the Ethernet port and the serial port on small-size equipment or equipment with ultrahigh network port density is solved.
Example two:
in this embodiment, based on the first embodiment, a case where the first relay is a single-pole double-throw relay is taken as an example to further illustrate the present application.
Referring to fig. 6, the serial port and network port adaptive system includes an interface connector, an 8-channel first relay, an ethernet isolator, an ethernet port chip, a second relay, a serial port chip and a controller. The interface connector is an RJ45 connector and is connected with a first relay, and the first relay is respectively connected with the Ethernet isolator, the input pin of the serial port chip and the second relay and is controlled by the controller. The Ethernet port chip is respectively connected with the Ethernet isolator and the controller. The serial port chip is connected with the controller, and the output pin is connected with the second relay. The second relay is in a disconnected state by default and is switched on after receiving a control signal of the controller.
When the relay is used, if the first relay is connected with the RJ45 connector and the Ethernet port chip, at the moment, a 1 st signal pin of the RJ45 connector is connected with an MDI1+ pin of the Ethernet port chip, a 2 nd signal pin is connected with an MDI 1-pin of the Ethernet port chip, a 3 rd signal pin is connected with an MDI2+ pin of the Ethernet port chip, a 6 th signal pin is connected with an MDI 2-pin of the Ethernet port chip, a 4 th signal pin is connected with an MDI3+ pin of the Ethernet port chip, a 5 th signal pin is connected with an MDI 3-pin of the Ethernet port chip, a 7 th signal pin is connected with an MDI4+ pin of the Ethernet port chip, and an 8 th signal pin is connected with an MDI 4-pin of the Ethernet port chip.
If what first relay switched on is RJ45 connector and serial ports chip, and the second relay switches on, the 1 st signal needle of RJ45 connector is connected with the RTS pin of serial ports chip this moment, the 2 nd signal needle is connected with the DTR pin of serial ports chip, the 3 rd signal needle is connected with the TXD pin of serial ports chip, the reference ground signal is inserted to 4 th signal needle and/or 5 th signal needle, the 6 th signal needle is connected with the RXD pin of serial ports chip, the 7 th signal needle is connected with the DSR pin of serial ports chip, the 8 th signal needle is connected with the CTS pin of serial ports chip.
Thus, the 1 st to 8 th signal pins of the RJ45 connector are multiplexed by the serial port chip and the ethernet port chip, and the 1000M ethernet signal and the flow control function are supported. The sequence of definition between each signal pin and the pin of the ethernet chip conforms to the standard definition of the RJ45 connector.
The controller controls the first relay to conduct the interface connector with the serial port chip or the Ethernet port chip periodically by default. And the period t is greater than the time from the serial port chip or the Ethernet port chip receiving the signal transmitted by the interface connector to the controller sending a corresponding control instruction to the first relay according to the state signal fed back by the serial port chip or the Ethernet port chip.
After receiving the signal of the opposite terminal device, the interface connector transmits the signal into the currently conducted chip.
The serial port chip detects the level of the received signal. If any 1 signal level meets the RS232 level requirement, the serial port signal sends a serial port valid signal to the controller. The controller controls the first relay to keep the RJ45 connector and the serial port chip connected after receiving the serial port effective signal, and controls the second relay to be connected.
The ethernet port chip detects the level of the received signal. If the signal level is between 600mV and 900mV, a link is established and a signal is sent to the controller indicating the successful status of the link. And after receiving the signal, the controller controls the first relay to keep the RJ45 connector and the Ethernet port chip conducted.
Through the scheme of the embodiment of the application, multiplexing of the Ethernet port and the serial port is realized, so that the serial port and the Ethernet port can be simultaneously supported in equipment with higher density or equipment with smaller volume, the Ethernet port can support 1000M rate transmission, the performance requirement of the equipment is met, and the maintainability of the equipment is improved.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus and method may be implemented in other ways. The above-described embodiments of the apparatus are merely illustrative, and for example, the division of the units is only one logical division, and there may be other divisions when actually implemented, and for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection of devices or units through some communication interfaces, and may be in an electrical, mechanical or other form.
In addition, units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, 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.
Furthermore, the functional modules in the embodiments of the present application may be integrated together to form an independent part, or each module may exist separately, or two or more modules may be integrated to form an independent part.
In this document, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions.
In this context, a plurality means two or more.
The above description is only an example of the present application and is not intended to limit the scope of the present application, and various modifications and changes may be made by those skilled in the art. Any modification, equivalent replacement, improvement and the like made within the spirit and principle of the present application shall be included in the protection scope of the present application.

Claims (13)

1. A serial port and network port self-adaptive system is characterized by comprising: the device comprises an interface connector, a serial port device, an Ethernet port device, a first relay and a controller; wherein:
the interface connector comprises a signal pin; the first relay is used for connecting the signal pin with the serial port device and the Ethernet port device respectively; the serial port device and the Ethernet port device multiplex the signal pin;
the serial port device and the Ethernet port device are in communication connection with the controller;
the serial port device is used for sending a first state signal to the controller when the signal pin is communicated with the serial port device and the signal transmitted by the signal pin is detected to be a serial port signal;
the Ethernet port device is used for sending a second state signal to the controller when the signal pin is communicated with the Ethernet port device and the signal transmitted by the signal pin is detected to be an Ethernet signal;
the controller is in communication connection with the first relay and is used for controlling the first relay to keep the signal pin connected with the communication path of the serial port device and disconnect the signal pin from the communication path of the Ethernet port device when the first state signal is received; and when the second state signal is received, controlling the first relay to keep the communication path between the signal pin and the Ethernet port device connected and disconnect the communication path between the signal pin and the serial port device.
2. The serial port and network port adaptive system according to claim 1, wherein the first relay is a single-pole double-throw relay;
the controller is further configured to control the single-pole double-throw relay to periodically communicate the signal pin with the serial port device and the ethernet port device, respectively, when the first status signal is not received and the second status signal is not received.
3. The serial port and network port adaptive system according to claim 1, wherein the ethernet port device comprises an ethernet isolator and an ethernet port chip;
the Ethernet port chip is connected with the first relay through the Ethernet isolator.
4. The serial and network port adaptive system according to claim 3, wherein the Ethernet isolator comprises an AC coupling capacitor and an Ethernet port transformer; the alternating current coupling capacitor is connected with the first relay, the alternating current coupling capacitor is connected with the Ethernet port transformer in series, and the Ethernet port transformer is connected with the Ethernet port chip.
5. The serial port and network port adaptive system according to claim 1, wherein the serial port device comprises a serial port chip and a current limiting resistor;
and an output pin of the serial port chip is connected with the first relay through the current-limiting resistor.
6. The serial port and network port adaptive system according to claim 1, wherein the serial port device comprises a serial port chip and a second relay;
an input pin of the serial port chip is connected with the first relay, and an output pin of the serial port chip is connected with the second relay;
the second relay is connected with the first relay and is in communication connection with the controller;
the controller is further configured to control the second relay to connect a communication path between the first relay and an output pin of the serial port chip when the first state signal is received, and control the second relay to disconnect the communication path between the first relay and the output pin of the serial port chip when the first state signal is not received.
7. The serial and network port adaptation system of any of claims 1-6, wherein the interface connector is an RJ45 connector;
when the first relay connects the RJ45 connector with the Ethernet port device, the 1 st signal pin of the RJ45 connector is connected with the MDI1+ pin of the Ethernet port device through the first relay, the 2 nd signal pin is connected with the MDI 1-pin of the Ethernet port device through the first relay, the 3 rd signal pin is connected with the MDI2+ pin of the Ethernet port device through the first relay, the 6 th signal pin is connected with the MDI 2-pin of the Ethernet port device through the first relay, the 4 th signal pin is connected with the MDI3+ pin of the Ethernet port device through the first relay, the 5 th signal pin is connected with the MDI 3-pin of the Ethernet port device through the first relay, and the 7 th signal pin is connected with the MDI4+ pin of the Ethernet port device through the first relay, the 8 th signal pin is connected with an MDI 4-pin of the Ethernet port device through the first relay;
when the RJ45 connector is communicated with the serial device through the first relay, the 1 st signal pin is connected with an RTS pin of the serial device through the first relay, the 2 nd signal pin is connected with a DTR pin of the serial device through the first relay, the 3 rd signal pin is connected with a TXD pin of the serial device through the first relay, the 4 th signal pin and/or the 5 th signal pin are/is connected with a reference ground signal, the 6 th signal pin is connected with an RXD pin of the serial device through the first relay, the 7 th signal pin is connected with a DSR pin of the serial device through the first relay, and the 8 th signal pin is connected with a CTS pin of the serial device through the first relay.
8. The serial and network port adaptation system of any of claims 1-6, wherein the interface connector is an RJ45 connector;
when the first relay communicates the RJ45 connector with the Ethernet port device, a 1 st signal pin of the RJ45 connector is connected with an MDI1+ pin of the Ethernet port device through the first relay, a 2 nd signal pin is connected with an MDI 1-pin of the Ethernet port device through the first relay, a 3 rd signal pin is connected with an MDI2+ pin of the Ethernet port device through the first relay, and a 6 th signal pin is connected with an MDI 2-pin of the Ethernet port device through the first relay;
when the RJ45 connector is communicated with the serial port device through the first relay, the 3 rd signal pin is connected with a TXD pin of the serial port device through the first relay, the 4 th signal pin is connected with an RXD pin of the serial port device through the first relay, and the 5 th signal pin or the 6 th signal pin is connected with a reference ground signal.
9. An electronic device, comprising: a housing and the serial and network port adaptation system of any of claims 1-8;
the serial port and network port self-adaptive system is arranged in the shell, an opening is reserved on the shell, and the interface connector of the serial port and network port self-adaptive system is exposed through the opening.
10. A signal processing method applied to the serial and internet port adaptation system according to any one of claims 1 to 8 or the electronic device according to claim 9, comprising:
when receiving a signal sent by opposite-end equipment, the interface connector sends the signal to a device which is communicated with the interface connector at present; the device comprises a serial port device and an Ethernet port device;
when the device which is communicated with the interface connector at present is the serial port device, the serial port device detects the signal, and when the signal is detected to be the serial port signal, a first state signal is sent to the controller;
when the device currently communicated with the interface connector is the Ethernet port device, the Ethernet port device detects the signal, and when the signal is detected to be an Ethernet signal, a second state signal is sent to the controller;
when the controller receives the first state signal, the controller controls the first relay to keep the communication between the signal pin and the communication channel of the serial port device and disconnect the signal pin and the communication channel of the Ethernet port device; and when the second state signal is received, controlling the first relay to keep the signal pin connected with the communication path of the Ethernet port device and disconnect the signal pin from the communication path of the serial port device.
11. The signal processing method of claim 10, wherein when the first relay in the serial and network port adaptation system is a single-pole double-throw relay, the signal processing method further comprises:
and when the controller does not receive the first state signal and does not receive the second state signal, the controller controls the single-pole double-throw relay to periodically communicate the signal pin with the serial port device and the Ethernet port device respectively.
12. The signal processing method of claim 10, wherein when the serial device includes a serial chip and a second relay, the signal processing method further comprises:
when the controller receives the first state signal, the controller controls the second relay to communicate the first relay with the output pin of the serial port chip;
and when the controller does not receive the first state signal, the controller controls the second relay to disconnect the first relay from the output pin of the serial port chip.
13. The signal processing method of claim 11, wherein when the serial device includes a serial chip and a second relay, the signal processing method further comprises:
when the controller receives the first state signal, the controller controls the second relay to communicate the first relay with the output pin of the serial port chip;
and when the controller does not receive the first state signal, the controller controls the second relay to disconnect the first relay from the output pin of the serial port chip.
CN201911057470.0A 2019-10-31 2019-10-31 Serial port and network port self-adaptive system, electronic equipment and signal processing method Active CN110765048B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201911057470.0A CN110765048B (en) 2019-10-31 2019-10-31 Serial port and network port self-adaptive system, electronic equipment and signal processing method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201911057470.0A CN110765048B (en) 2019-10-31 2019-10-31 Serial port and network port self-adaptive system, electronic equipment and signal processing method

Publications (2)

Publication Number Publication Date
CN110765048A CN110765048A (en) 2020-02-07
CN110765048B true CN110765048B (en) 2021-05-18

Family

ID=69335083

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201911057470.0A Active CN110765048B (en) 2019-10-31 2019-10-31 Serial port and network port self-adaptive system, electronic equipment and signal processing method

Country Status (1)

Country Link
CN (1) CN110765048B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112367567B (en) * 2020-11-09 2023-06-09 Oppo广东移动通信有限公司 Communication apparatus
CN112333562B (en) * 2020-11-09 2023-06-13 Oppo广东移动通信有限公司 Communication apparatus
CN112202018B (en) * 2020-11-09 2022-05-06 Oppo广东移动通信有限公司 Communication device
CN112379660B (en) * 2020-11-13 2022-02-18 英博超算(南京)科技有限公司 UART for automobile automatic driving domain controller and debugging system and method

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN202019366U (en) * 2011-04-26 2011-10-26 傲视恒安科技(北京)有限公司 Line multiplexing device for transmitting serial bus data by multiplexing Ethernet
CN103345459A (en) * 2013-06-05 2013-10-09 福建星网锐捷通讯股份有限公司 Switching method and switching circuit based on multiplexing of multiple-processor serial ports on single board

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102164070B (en) * 2010-10-08 2014-04-02 华为技术有限公司 Switchboard and network port and serial port multiplexing method thereof
CN202374297U (en) * 2011-12-22 2012-08-08 成都欣点科技有限公司 Serial port and Ethernet interface multiplexing structure
CN103118143B (en) * 2013-01-22 2015-07-08 北京傲天动联技术股份有限公司 Multiplex circuit of serial interface and Ethernet interface
US9391924B2 (en) * 2014-07-25 2016-07-12 Innovasic, Inc. Ethernet interface module
CN107291646B (en) * 2016-04-11 2021-04-16 中兴通讯股份有限公司 Network port and serial port multiplexing device and single board

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN202019366U (en) * 2011-04-26 2011-10-26 傲视恒安科技(北京)有限公司 Line multiplexing device for transmitting serial bus data by multiplexing Ethernet
CN103345459A (en) * 2013-06-05 2013-10-09 福建星网锐捷通讯股份有限公司 Switching method and switching circuit based on multiplexing of multiple-processor serial ports on single board

Also Published As

Publication number Publication date
CN110765048A (en) 2020-02-07

Similar Documents

Publication Publication Date Title
CN110765048B (en) Serial port and network port self-adaptive system, electronic equipment and signal processing method
FI113420B (en) Intelligent control device for vehicle power distribution
US8531942B2 (en) Communication system having a master/slave structure
CN101610192B (en) Communication slave, bus cascading method and system
KR20010022619A (en) Redundant communications in a protective relay
CN112579492A (en) Connection method of universal serial bus hub device with different types of connection ports
CN103684845A (en) Network backup device and network system with same
CN111427824B (en) Serial port communication circuit
CN107749798B (en) Communication network system, shunt device and method for accessing bidirectional transmission network
CN108292998B (en) Bus coupling unit and bus system with bus coupling unit
CN112995070B (en) Double-card switching system and method
CN110768815B (en) Method for switching signal lines and solar system
CN113220614B (en) Method, system and medium for self-adaptive management of I2C and I3C devices
CN112422175B (en) Cascade device
CN103905235A (en) Interface configuration method and apparatus, network transmission device, and communication system
CN114095462B (en) Fault-tolerant method and system for SRIO communication system of radar processor
US20070204088A1 (en) Modularized circuit board bus connection control method and system
CN110663226A (en) Status signal output
CN115242576A (en) Additional communication in a standardized outlet of a bidirectional interface between a first and a second communication device
CN113806273B (en) Fast peripheral component interconnect data transfer control system
US7543044B2 (en) Automatic configuration system
CN108650101B (en) Data transmission method and equipment
CN219018833U (en) Gigabit network card and gigabit network equipment
JP3773368B2 (en) Node connection method
CN215300646U (en) Bypass control device

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