Serial port server and communication system
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- 广东鸿钧微电子科技有限公司
- Filing Date
- 2023-01-10
- Publication Date
- 2026-08-07
AI Technical Summary
然而,当设备(比如,用户电脑)无以太网及接口时,则无法访问串口服务器
[0028] The serial port server and communication system provided in this application include a USB interface, an Ethernet interface, a USB data processing and parsing unit, an Ethernet protocol parsing unit, and a first switch unit. The USB interface is electrically connected to the first switch unit via the USB data processing and parsing unit, and the Ethernet interface is electrically connected to the first switch unit via the Ethernet protocol parsing unit. The first switch unit is used to determine whether the first target interface currently connected to the first device is a USB interface or an Ethernet interface, and then connects to the determined first target interface to enable the first device to communicate with the serial port server through the first target interface. In this way, the uplink port actually used by the serial port server can be automatically switched to either a USB interface or an Ethernet interface, allowing the device to access the serial port server via Ethernet or USB, thereby avoiding the situation where the device cannot access the serial port server when it has a USB interface but no Ethernet interface.
Smart Images

Figure CN115934618B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of communication technology, and more specifically, to a serial port server and communication system. Background Technology
[0002] like Figure 1 As shown, current serial port servers typically use an Ethernet interface for uplink and an RS232 interface for downlink. The serial port server can be remotely accessed via Ethernet to obtain device information, such as log information printed by the device. Therefore, the existing solution uses the Ethernet interface as the uplink data transmission port, which is suitable for accessing remote serial devices. However, when the device (e.g., a user's computer) lacks an Ethernet interface, it cannot access the serial port server. Summary of the Invention
[0003] This application provides a serial port server and communication system that can automatically switch the uplink port to a USB interface or an Ethernet interface, enabling devices to access the serial port server via Ethernet or USB, thereby avoiding the situation where devices cannot access the serial port server when they have a USB interface but no Ethernet interface.
[0004] The embodiments of this application can be implemented as follows:
[0005] In a first aspect, this application provides a serial port server, which includes: a USB interface, an Ethernet interface, a USB data processing and parsing unit, an Ethernet protocol parsing unit, and a first switch unit.
[0006] The USB interface is electrically connected to the first switching unit through the USB data processing and parsing unit;
[0007] The Ethernet interface is electrically connected to the first switching unit through the Ethernet protocol parsing unit;
[0008] The first switch unit is used to determine the first target interface currently connected to the first device and to connect to the first target interface so that the first device can communicate with the serial port server through the first target interface, wherein the first target interface is the USB interface or the Ethernet interface.
[0009] In an optional implementation, the first switching unit defaults to the first target interface being a USB interface.
[0010] The Ethernet protocol parsing unit is used to provide a first voltage signal to the first switching unit when a device is detected connected to the Ethernet interface;
[0011] When the first switching unit detects the first voltage signal, it determines that the first target interface is the Ethernet interface.
[0012] In an optional implementation, the serial port server further includes a serial port unit, which includes a serial port.
[0013] The USB data processing and parsing unit, the Ethernet protocol parsing unit, and the serial port unit are detachably disposed within the serial port server, wherein the number of output channels of the USB data processing and parsing unit and the Ethernet protocol parsing unit is the same as the number of serial ports of the same type in the serial port unit.
[0014] In an optional implementation, the serial port server further includes a TTL-to-RS232 unit, the serial port unit including an RS232 interface.
[0015] The TTL to RS232 converter is electrically connected to the first switch unit and the RS232 interface. It is used to convert the TTL level signal sent by the first switch unit into an RS232 level signal, and send the converted RS232 level signal to the device connected to the RS232 interface via the RS232 interface. It is also used to convert the RS232 level signal sent by the device connected to the RS232 interface into a TTL level signal, and send the converted TTL level signal to the first switch unit.
[0016] In an optional implementation, the serial port unit further includes a TTL interface.
[0017] The TTL interface is electrically connected to the first switching unit, enabling the device to communicate with the serial port server through the TTL interface.
[0018] In an optional implementation, the serial port server further includes a level conversion unit.
[0019] The level conversion unit is electrically connected to the first switch unit and the TTL interface, and is used to convert the TTL level signal of the device connected to the TTL interface to the TTL level signal of the serial port server.
[0020] In an optional implementation, the serial port server further includes a second switch unit.
[0021] The second switching unit is electrically connected to the TTL to RS232 unit and the level conversion unit, and is used to determine the second target interface currently connected to the second device, and to connect to the second target interface so that the second device can communicate with the serial port server through the second target interface, wherein the second target interface is the RS232 interface or the TTL interface.
[0022] In an optional implementation, the second switching unit defaults to the RS232 interface as the second target interface.
[0023] The TTL interface is also used to provide a first voltage signal to the second switching unit when a device is connected;
[0024] When the second switching unit detects the first voltage signal, it determines that the second target interface is the TTL interface.
[0025] In an optional implementation, the RS232 interface is an RJ45 interface or a DB9 interface, and / or the TTL interface is a Phoenix terminal or an IDC interface.
[0026] Secondly, this application provides a communication system, which includes a first device, a second device, and a serial port server as described in any of the foregoing embodiments.
[0027] The first device communicates with the second device through the serial port server, wherein the first device is connected to the USB interface or Ethernet interface of the serial port server.
[0028] The serial port server and communication system provided in this application include a USB interface, an Ethernet interface, a USB data processing and parsing unit, an Ethernet protocol parsing unit, and a first switch unit. The USB interface is electrically connected to the first switch unit via the USB data processing and parsing unit, and the Ethernet interface is electrically connected to the first switch unit via the Ethernet protocol parsing unit. The first switch unit is used to determine whether the first target interface currently connected to the first device is a USB interface or an Ethernet interface, and then connects to the determined first target interface to enable the first device to communicate with the serial port server through the first target interface. In this way, the uplink port actually used by the serial port server can be automatically switched to either a USB interface or an Ethernet interface, allowing the device to access the serial port server via Ethernet or USB, thereby avoiding the situation where the device cannot access the serial port server when it has a USB interface but no Ethernet interface. Attached Figure Description
[0029] To more clearly illustrate the technical solutions of the embodiments of this application, the accompanying drawings used in the embodiments will be briefly introduced below. It should be understood that the following drawings only show some embodiments of this application and should not be regarded as a limitation of the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0030] Figure 1 This is a schematic diagram of an existing serial port server;
[0031] Figure 2 One of the block diagrams of a serial port server provided in an embodiment of this application;
[0032] Figure 3 A second block diagram of a serial port server provided in an embodiment of this application;
[0033] Figure 4 A third block diagram of a serial port server provided in an embodiment of this application;
[0034] Figure 5 A fourth block diagram of a serial port server provided in an embodiment of this application;
[0035] Figure 6 Fifth block diagram of a serial port server provided in an embodiment of this application;
[0036] Figure 7 A block diagram of a serial port server provided in an embodiment of this application;
[0037] Figure 8 This is a block diagram of a communication system provided in an embodiment of this application.
[0038] Icons: 10 - Communication System; 100 - Serial Server; 110 - USB Interface; 120 - USB Data Processing and Parsing Unit; 130 - Ethernet Interface; 140 - Ethernet Protocol Parsing Unit; 150 - First Switching Unit; 160 - Second Switching Unit; 170 - Serial Port Unit; 171 - RS232 Interface; 173 - TTL Interface; 180 - TTL to RS232 Unit; 190 - Level Conversion Unit; 200 - First Device; 300 - Second Device. Detailed Implementation
[0039] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. The components of the embodiments of this application described and shown in the accompanying drawings can generally be arranged and designed in various different configurations.
[0040] Therefore, the following detailed description of the embodiments of this application provided in the accompanying drawings is not intended to limit the scope of the claimed application, but merely to illustrate selected embodiments of the application. All other embodiments obtained by those skilled in the art based on the embodiments of this application without inventive effort are within the scope of protection of this application.
[0041] It should be noted that similar labels and letters in the following figures indicate similar items. Therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures.
[0042] In the description of this application, it should be noted that if terms such as "upper," "lower," "inner," or "outer" indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings, or the orientation or positional relationship commonly used when the product of the invention is in use, they are only for the convenience of describing this application and simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation, and therefore should not be construed as a limitation on this application. Furthermore, if terms such as "first" or "second" appear, they are only used to distinguish descriptions and should not be construed as indicating or implying relative importance.
[0043] In the description of this application, it should also be noted that, unless otherwise expressly specified and limited, the terms "set up," "install," "connect," and "link" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral connection; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; and they can refer to the internal connection of two components. Those skilled in the art can understand the specific meaning of the above terms in this application based on the specific circumstances.
[0044] It should be noted that, where there is no conflict, the features in the embodiments of this application can be combined with each other.
[0045] Please refer to Figure 2 , Figure 2 This is one of the block diagrams of a serial port server 100 provided in an embodiment of this application. In this embodiment, the serial port server 100 may include: a USB interface 110, a USB data processing and parsing unit 120, an Ethernet interface 130, an Ethernet protocol parsing unit 140, and a first switch unit 150.
[0046] The USB interface 110 is electrically connected to the first switch unit 150 through the USB data processing and parsing unit 120, and the Ethernet interface 130 is electrically connected to the first switch unit 150 through the Ethernet protocol parsing unit 140. The USB data processing and parsing unit 120 is used to parse data packets received through the USB interface 110, extract valid data, and send the valid data to the first switch unit 150; it can also be used to package data sent by the first switch unit 150 and then send it through the USB interface 110. Similarly, the Ethernet protocol parsing unit 140 is used to parse data packets received through the Ethernet interface 130, extract valid data, and send the valid data to the first switch unit 150; it can also be used to package data sent by the first switch unit 150 and then send it through the Ethernet interface 130. The Ethernet interface 130 can be, but is not limited to, an RJ45 interface.
[0047] Optionally, the first switch unit 150 can also be electrically connected to other devices within the serial port server 100, so that the serial port server 100 can communicate with the devices connected to the USB interface 110 or the Ethernet interface 130. The first switch unit 150 can also be electrically connected to other devices, thereby enabling the devices connected to the USB interface 110 or the Ethernet interface 130 to communicate with the devices connected to the first switch unit 150 via the serial port server 100.
[0048] The first switch unit 150 is used to determine whether the first target interface currently connected to the first device is the USB interface 110 or the Ethernet interface 130, and then connects to the determined first target interface so that the first device can communicate with the serial port server 100 through the first target interface.
[0049] That is, when the first device is connected to the USB interface 110, the first switching unit 150 is connected to the USB data processing and parsing unit 120, so that data is transmitted from the USB interface 110 through the USB data processing and parsing unit 120 to the first switching unit 150, or data is transmitted from the first switching unit 150 sequentially through the USB data processing and parsing unit 120 and the USB interface 110. When the first device is connected to the Ethernet interface 130, the first switching unit 150 is connected to the Ethernet protocol parsing unit 140, so that data is transmitted from the Ethernet interface 130 through the Ethernet protocol parsing unit 140 to the first switching unit 150, or data is transmitted from the first switching unit 150 sequentially through the Ethernet protocol parsing unit 140 and the Ethernet interface 130.
[0050] The specific method by which the first switching unit 150 determines whether the first target interface is the USB interface 110 or the Ethernet interface 130 can be set according to actual needs and is not specifically limited here. The first device refers to any device connected to the USB interface 110 or the Ethernet interface 130, specifically determined by the actual application scenario, such as a user computer.
[0051] Most devices today (such as computers) support USB interfaces. The serial server 100 provided in this embodiment adds a USB data processing and parsing unit 120 and a USB interface 110, enabling serial data to be uploaded to the first device via USB. In this embodiment, the uplink port actually used by the serial server 100 can be automatically switched to either a USB interface or an Ethernet interface, allowing the device to access the serial server via Ethernet or USB, thus avoiding the situation where the device cannot access the serial server when it has a USB interface but no Ethernet interface.
[0052] Optionally, as a possible implementation, the first switch unit 150 defaults to the first target interface being the USB interface 110, meaning the input source of the first switch unit 150 is USB by default, and the first switch unit 150 is defaulted to being connected to the USB interface 110. The Ethernet protocol parsing unit 140 is further configured to provide a first voltage signal to the first switch unit 150 when it detects that a device is connected to the Ethernet interface 130, i.e., the first device is connected to the Ethernet interface 130. The first voltage signal can be a high-level signal or a low-level signal, determined by actual requirements, and is used to indicate that the first device is connected to the Ethernet interface 130. When the first switch unit 150 detects the first voltage signal, it can determine that the first target interface is the first Ethernet interface 130.
[0053] For example, if the default input source of the first switching unit 150 is the USB data processing and parsing unit 120, such as Figure 3 As shown, the Ethernet protocol parsing unit 140 provides an ETH_LINK signal to the first switching unit 150. When a user wants to access the network remotely via Ethernet, they can connect the first device to the Ethernet interface 130. After detecting that the first device is connected to the Ethernet interface 130, the Ethernet protocol parsing unit 140 can pull the ETH_LINK signal low, thereby causing the first switching unit 150 to automatically switch the input source to the Ethernet protocol parsing unit 140, thus enabling remote Ethernet access.
[0054] It is understandable that the first switch unit 150 can also be set to default the first target interface to the Ethernet interface 130. When the USB data processing and parsing unit 120 detects that a device is connected to the USB interface 110, it provides a signal to the first switch unit 150 to indicate that a device is connected to the USB interface 110, so that the first switch unit 150 determines that the first target interface is the USB interface 110 at this time, and then connects to the USB interface 110.
[0055] Please refer to Figure 4 , Figure 4 This is a third block diagram of the serial port server 100 provided in this embodiment. In this embodiment, the serial port server 100 may further include a serial port unit 170, which includes at least one serial port for connecting to a serial port device, thereby enabling the first device to communicate with the serial port device through the serial port server 100.
[0056] Furthermore, the inventors of this application have discovered that the Ethernet protocol parsing unit and RS232 interface in current serial servers are fixed and non-replaceable, resulting in a fixed number of downlink ports supported by the current serial server, preventing the expansion of ports on the same device. To address this issue, in this embodiment, the USB data processing and parsing unit 120, the Ethernet protocol parsing unit 140, and the serial port unit 170 are detachably disposed within the serial server 100. That is, the USB data processing and parsing unit 120, the Ethernet protocol parsing unit 140, and the serial port unit 170 can be replaced accordingly. The number of output channels of the USB data processing and parsing unit 120 and the Ethernet protocol parsing unit 140 is the same as the number of serial ports of the same type in the serial port unit 170.
[0057] The number of downlink interfaces in this application depends on the capabilities of the USB data processing parsing unit 120 and the Ethernet protocol parsing unit 140. If the user needs one serial port, the parsing unit can be configured to output one port. If the user needs 16 serial ports, the parsing unit can be configured to output 16 ports. Correspondingly, the number of serial ports of the same type in the serial port unit 170 is configured.
[0058] That is, for example, the current serial server 100 includes one type of serial port, and the number of such serial ports is 1. The output of the USB data processing and parsing unit 120 and the Ethernet protocol parsing unit 140 is 1 channel. If the user needs 16 serial ports, the USB data processing and parsing unit 120 and the Ethernet protocol parsing unit 140 with 1 channel output can be replaced with USB data processing and parsing unit 120 and Ethernet protocol parsing unit 140 with 16 channels output, respectively; and the serial port unit 170 including 1 serial port can be replaced with a serial port unit 170 with 16 channels output.
[0059] If the current serial port server 100 includes two types of serial ports, and the quantity of each type of serial port is 1, then in the above replacement, the serial port unit 170 needs to be replaced with a serial port unit 170 that includes two types of serial ports, and the quantity of each type of serial port is 16. For example, if the serial port unit 170 includes an RS232 interface and a TTL interface, then the replaced serial port unit 170 will include 16 RS232 interfaces and 16 TTL interfaces.
[0060] In addition, the inventors of this application have also discovered through research that the downlink data port of the existing solution is RS232, while the voltage level of the device connected to the downlink data port (such as the single board being debugged) is basically TTL level. Therefore, in actual use, a special cable needs to be connected to the serial port server to convert RS232 to TTL, which results in a large number of cables needing to be connected during application.
[0061] Please refer to Figure 5 , Figure 5 This is a fourth block diagram of the serial port server 100 provided in this embodiment. To address the aforementioned issue of requiring an external dedicated cable, in this embodiment, the serial port server 100 may further include a TTL-to-RS232 unit 180, where the serial port in the serial port unit 170 includes an RS232 interface. The TTL-to-RS232 unit 180 is electrically connected to the first switch unit 150 and the RS232 interface 171, and is used to convert the TTL level signal sent by the first switch unit 150 into an RS232 level signal, and send the converted RS232 level signal to the device connected to the RS232 interface via the RS232 interface 171; and to convert the RS232 level signal sent by the device connected to the RS232 interface 171 into a TTL level signal, and send the converted TTL level signal to the first switch unit 150. Thus, no external dedicated cable is required to convert RS232 to TTL.
[0062] Optionally, in this embodiment, the serial port in the serial port unit 170 may further include a TTL interface 173. The TTL interface 173 is electrically connected to the first switching unit 150, enabling the device to communicate with the serial port server 100 through the TTL interface 173. Thus, the serial port server 100 provided in this embodiment can output RS232 level signals and TTL level signals, making the serial port server 100 more widely applicable, while eliminating the need for additional connection cables.
[0063] Since CPU voltage levels may differ between different devices, to avoid this difference affecting signal transmission, in this embodiment, the serial port server 100 may further include a level conversion unit 190. The level conversion unit 190 is electrically connected to the first switch unit 150 and the TTL interface 173, and is used to convert the TTL level signal of the device connected to the TTL interface 173 to the TTL level signal of the serial port server 100. That is, after any device connects its I / O power supply to a designated power pin of the TTL interface 173, the level conversion unit 190 can convert the device's CPU I / O level to the standard level of the serial port server, or convert the standard level of the serial port server to the CPU's I / O level.
[0064] In this embodiment, the serial port server 100 may further include a second switch unit 160 for switching between RS232 and TTL data sources. The second switch unit 160 is electrically connected to the TTL-to-RS232 unit 180 and the level conversion unit 190, and is used to determine whether the second target interface currently connected to the second device is the RS232 interface 171 or the TTL interface 173, and then connect to the determined second target interface so that the second device can communicate with the serial port server 100 through the second target interface.
[0065] That is, when the second device is connected to the RS232 interface 171, the second switching unit 160 is connected to the TTL to RS232 unit 180 to enable data transmission between the second switching unit 160 and the RS232 interface 171. When the second device is connected to the TTL interface 173, the second switching unit 160 is connected to the level conversion unit 190 to enable data transmission between the second switching unit 160 and the TTL interface 173.
[0066] The specific method by which the second switching unit 160 determines whether the second target interface is the RS232 interface 171 or the TTL interface 173 can be set according to actual needs and is not specifically limited here. The second device refers to any device connected to the RS232 interface 171 or the TTL interface 173, specifically determined by the actual application scenario, such as a debugging device.
[0067] Optionally, as a possible implementation, the second switching unit 160 defaults to the RS232 interface 171 as the second target interface, that is, the data source of the second switching unit 160 is defaulted to an RS232 data source, meaning that the second switching unit 160 is defaulted to being connected to the RS232 interface 171. The TTL interface 173 is also used to provide a first voltage signal to the second switching unit 160 when a device is connected, the first voltage signal indicating that a device is connected to the RS232 interface 171. When the second switching unit 160 detects the first voltage signal, it determines that the second target interface is the TTL interface.
[0068] For example, if the default data source for the second switching unit 160 is RS232, such as Figure 6 As shown, when a device is connected to the TTL interface 173, the UART PRESENT signal sent from the TTL interface 173 to the second switching unit 160 will be pulled low, thereby causing the second switching unit 160 to switch the data source to TTL.
[0069] It is understandable that the second switch unit 160 can also be set to default the second target interface as the TTL interface 173. When a device is connected to the RS232 interface 171, a signal can be provided to the second switch unit 160 to indicate that a device is connected to the RS232 interface 171, so that the second switch unit 160 determines that the second target interface is the RS232 interface 171 at this time, and then connects to the RS232 interface 171.
[0070] Optionally, in this embodiment, the USB data processing and parsing unit 120 and the Ethernet protocol parsing unit 140 can be implemented using chips, modules, or other methods. The first switch unit 150 and the second switch unit 160 can be implemented using MUX (analog switch) or other methods. The TTL to RS232 unit 180 and the level conversion unit 190 can be implemented using a chip solution, a module solution, or other solutions. The first switch unit 150, the second switch unit 160, the TTL to RS232 unit 180, and the level conversion unit 190 can support multiple outputs. The RS232 interface 171 can adopt connector forms such as RJ45 or DB9, i.e., it can be an RJ45 interface or a DB9 interface, etc. The TTL interface 173 can be a Phoenix connector or an IDC interface (Insulation Displacement Connector), etc.
[0071] In this embodiment, the serial server 100 integrates a USB interface 110, an Ethernet interface 130, a USB data processing and parsing unit 120, and an Ethernet protocol parsing unit 140. This enables the uplink input port to support both USB and Ethernet. The ETH_LINK signal is used to automatically switch between the USB interface 110 and the Ethernet interface 130 as the current uplink input port, thus preventing the device from being unable to access the serial server when it has a USB interface but no Ethernet interface. The downlink section integrates a second switch unit 160, an RS232 interface 171, and a TTL interface 173, enabling the downlink output port to support both RS232 and TTL. The UART PRESENT signal is used to automatically switch data output between RS232 and TTL, i.e., to automatically switch the used downlink output port. Furthermore, the USB data processing and parsing unit 120, the Ethernet protocol parsing unit 140, and the serial port unit 170 can be replaced according to actual downlink port requirements, thereby meeting the actual number of serial ports needed. Therefore, this embodiment provides a modular, adaptive serial server with multiple interfaces.
[0072] The following is based on Figure 7 For example, the working modes and usage of the aforementioned serial port server 100 are described below. Figure 7 In the serial server 100 shown, the first switch unit 150 is implemented using MUX1, and the second switch unit 160 is implemented using MUX2.
[0073] 1. USB to RS232 converter
[0074] The user connects their computer's USB port to the serial server 100 and the debugging device to the RS232 CONNECT. In this case, the data transmission path is: USB data processing and parsing unit → MUX1 → MUX2 → TTL TO RS232 → RS232 CONNECT. Since the data is bidirectional, another possible data transmission path is: TTL TO RS232 → MUX2 → MUX1 → USB data processing and parsing unit → USB interface. In other words, the USB-to-RS232 converter enables communication between the computer connected to the USB port and the debugging device connected to the RS232 interface.
[0075] 2. USB to TTL
[0076] The user connects their computer's USB port to the serial server 100 and the debugging device to the TTL CONNECT. In this case, the data transmission path is: USB data processing and parsing unit → MUX1 → MUX2 → LEVEL SHIFT → TTLCONNECT. Since the data is bidirectional, the data transmission path also includes: LEVEL SHIFT → MUX2 → MUX1 → USB data processing and parsing unit → USB interface. In other words, the USB-to-TTL mode is used to enable communication between the computer connected to the USB port and the debugging device connected to the TTL interface.
[0077] 3. Ethernet to RS232 conversion
[0078] The user connects their computer's Ethernet port to the serial server 100 and the debugging device to the RS232CONNECT. In this case, the data transmission path is: Ethernet protocol parsing unit → MUX1 → MUX2 → TTL TO RS232 → RS232CONNECT. Since the data is bidirectional, another possible data transmission path is: TTL TO RS232 → MUX2 → MUX1 → Ethernet protocol parsing unit → Ethernet interface. In other words, the Ethernet-to-RS232 converter is used to enable communication between the computer connected to the Ethernet port and the debugging device connected to the RS232 interface.
[0079] 4. Ethernet to TTL
[0080] The user connects the computer's Ethernet port to the serial server 100 and the debugging device to the TTL CONNECT. In this case, the data transmission path is: Ethernet data processing and parsing unit → MUX1 → MUX2 → LEVEL SHIFT → TTLCONNECT. Since the data is bidirectional, the data transmission path also includes: LEVEL SHIFT → MUX2 → MUX1 → Ethernet protocol parsing unit → Ethernet interface. That is, the Ethernet-to-RS232 converter is used to enable communication between the computer connected to the Ethernet port and the debugging device connected to the TTL interface.
[0081] Please refer to Figure 8 , Figure 8 This is a block diagram of a communication system 10 provided in an embodiment of this application. This application also provides a communication system 10, which includes a first device 200, a second device 300, and a serial port server 100. The first device 200 communicates with the second device 300 through the serial port server 100. The first device 200 is connected to either a USB interface 110 or an Ethernet interface 130 of the serial port server 100.
[0082] In summary, this application provides a serial port server and communication system. The serial port server includes a USB interface, an Ethernet interface, a USB data processing and parsing unit, an Ethernet protocol parsing unit, and a first switch unit. The USB interface is electrically connected to the first switch unit through the USB data processing and parsing unit, and the Ethernet interface is electrically connected to the first switch unit through the Ethernet protocol parsing unit. The first switch unit is used to determine whether the first target interface currently connected to the first device is a USB interface or an Ethernet interface, and then connects to the determined first target interface so that the first device can communicate with the serial port server through the first target interface. In this way, the uplink port actually used by the serial port server can be automatically switched to either a USB interface or an Ethernet interface, allowing the device to access the serial port server via Ethernet or USB, thereby avoiding the situation where the device cannot access the serial port server when it has a USB interface but no Ethernet interface.
[0083] The above description is merely a specific embodiment of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the technical scope disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
Claims
1. A serial port server, characterized in that, The serial port server includes: a USB interface, an Ethernet interface, a USB data processing and parsing unit, an Ethernet protocol parsing unit, a first switch unit, a second switch unit, a TTL to RS232 converter unit, and a serial port unit, wherein the serial port unit includes an RS232 interface and a TTL interface. The USB interface is electrically connected to the first switching unit through the USB data processing and parsing unit; The Ethernet interface is electrically connected to the first switching unit through the Ethernet protocol parsing unit; The first switch unit is used to determine the first target interface currently connected to the first device and to connect to the first target interface so that the first device can communicate with the serial port server through the first target interface, wherein the first target interface is the USB interface or the Ethernet interface; The first switching unit is electrically connected to the second switching unit; The RS232 interface is electrically connected to the second switching unit through the TTL to RS232 converter; The TTL interface is electrically connected to the second switching unit, enabling the device to communicate with the serial port server through the TTL interface; The second switch unit is used to determine the second target interface currently connected to the second device and to connect to the second target interface so that the second device can communicate with the serial port server through the second target interface, wherein the second target interface is the RS232 interface or the TTL interface.
2. The serial port server according to claim 1, characterized in that, The first switch unit assumes that the first target interface is a USB interface. The Ethernet protocol parsing unit is used to provide a first voltage signal to the first switching unit when a device is detected connected to the Ethernet interface; When the first switching unit detects the first voltage signal, it determines that the first target interface is the Ethernet interface.
3. The serial port server according to any one of claims 1-2, characterized in that, The serial port unit includes a serial port. The USB data processing and parsing unit, the Ethernet protocol parsing unit, and the serial port unit are detachably disposed within the serial port server, wherein the number of output channels of the USB data processing and parsing unit and the Ethernet protocol parsing unit is the same as the number of serial ports of the same type in the serial port unit.
4. The serial port server according to claim 3, characterized in that, The TTL to RS232 converter is used to convert the TTL level signal sent by the first switching unit into an RS232 level signal, and send the converted RS232 level signal to the device connected to the RS232 interface via the RS232 interface. It is also used to convert the RS232 level signal sent by the device connected to the RS232 interface into a TTL level signal, and send the converted TTL level signal to the first switching unit.
5. The serial port server according to claim 4, characterized in that, The serial port server also includes a level conversion unit. The level conversion unit is electrically connected to the first switch unit and the TTL interface, and is used to convert the TTL level signal of the device connected to the TTL interface to the TTL level signal of the serial port server.
6. The serial port server according to claim 5, characterized in that, The second switching unit is electrically connected to the TTL interface via the level conversion unit.
7. The serial port server according to claim 6, characterized in that, The second switching unit defaults to the RS232 interface as the second target interface. The TTL interface is also used to provide a first voltage signal to the second switching unit when a device is connected; When the second switching unit detects the first voltage signal, it determines that the second target interface is the TTL interface.
8. The serial port server according to claim 4, characterized in that, The RS232 interface is an RJ45 interface or a DB9 interface, and / or the TTL interface is a Phoenix terminal or an IDC interface.
9. A communication system, characterized in that, The communication system includes a first device, a second device, and a serial port server as described in any one of claims 1-8. The first device communicates with the second device through the serial port server, wherein the first device is connected to the USB interface or Ethernet interface of the serial port server.
Citation Information
Patent Citations
Method for multiplexing USB interface and Ethernet interface and related products
CN109240963A
Terminal server, implementation method of terminal server and electronic equipment
CN114567684A
Data communication server
CN203535551U
Data transmission board and system based on hardware simulation accelerator
CN218162477U