Data sharing method and device and port replicator
By obtaining the protocol data of the host interface and sending calling instructions, the port replicator controls the host to enter the data sharing operating mode, which solves the problem that the port replicator cannot meet the data transmission between different hosts and realizes data sharing between hosts.
Patent Information
- Application Number
- CN202310348158.7
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-04-03
- Publication Date
- 2024-10-15
AI Technical Summary
The existing port replicator cannot meet the data transmission requirements between different hosts during operation.
By obtaining the protocol data of the host interface, it is determined whether there are at least two host connections, and a calling instruction is sent to the connected host to control it to enter the data sharing operating mode, thereby realizing data sharing between hosts.
When at least two hosts are connected, the port replicator can control the host to enter the data sharing operation mode to meet the data transmission needs between hosts and solve the problem that the port replicator cannot meet the data transmission between different hosts during operation.
Smart Images

Figure CN118779262A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of computer technology, and in particular to a data sharing method, device and port replicator. Background Art
[0002] The switchable host (Keyboard Video Mouse, KVM) is based on multi-host switching technology. With the help of a set of keyboards, monitors or mice, it can complete the switching control of multiple hosts (which can be servers or computers, etc.). It has many advantages such as saving space, reducing costs, facilitating management and improving work efficiency. It is widely used in information control centers, call centers, securities / financial trading systems, bank data centers, industrial control environments, teaching environments, testing centers and other fields.
[0003] However, during the operation of the switchable host, different hosts are connected to the port replicator only through switching instructions, and different hosts work independently, which cannot meet the use requirements of data transmission between different hosts. Summary of the invention
[0004] Based on this, it is necessary to provide a data sharing method, device and port replicator to solve the problem that the port replicator cannot meet the use requirements of data transmission between different hosts during operation.
[0005] In a first aspect, the present application provides a data sharing method, applied to a port replicator, comprising: obtaining protocol data of a host interface; determining, based on the protocol data, whether there are at least two hosts respectively connected to the host interface; if there are at least two hosts respectively connected to the host interface, sending a call instruction to each host connected to the host interface to control each host connected to the host interface to enter a data sharing operation mode; wherein, when the at least two hosts are both in a communication connection state or a charge and discharge connection state, the at least two hosts enter the data sharing operation mode; and controlling data sharing between the at least two hosts according to a data sharing request between the at least two hosts.
[0006] In the above data sharing method, the port replicator is provided with a host interface, and by acquiring the protocol data at the host interface, it is detected whether there are at least two hosts connected to the host interface respectively. If there are at least two hosts connected to the host interface respectively, that is, at least two hosts are in a communication connection state or a charge and discharge connection state, then by issuing a call instruction to the host connected to the host interface, at least two hosts connected to the host interface are controlled to enter a data sharing operation mode, thereby realizing data sharing between at least two hosts connected to the host interface according to the data sharing request between the at least two hosts. Through this scheme, the port replicator can control the corresponding hosts to enter a data sharing operation mode when at least two hosts connected to the host interface are connected, and realize data sharing operations between the hosts, thereby solving the problem that the port replicator cannot meet the use requirements of data transmission between different hosts during operation.
[0007] In a second aspect, the present application provides a data sharing device, applied to a port replicator, comprising: a protocol data acquisition module, used to acquire protocol data of a host interface; a connection analysis module, used to determine whether there are at least two hosts connected to the host interface respectively based on the protocol data; a shared operation control module, used to send a call instruction to each host connected to the host interface respectively if there are at least two hosts connected to the host interface respectively, so as to control each host connected to the host interface to enter a data sharing operation mode; wherein, when the at least two hosts are both in a communication connection state or a charge and discharge connection state, the at least two hosts enter the data sharing operation mode; a data sharing module, used to control data sharing between the at least two hosts according to a data sharing request between the at least two hosts.
[0008] In a third aspect, the present application provides a port replicator, comprising a host interface and a controller, wherein the host interface is used to connect to at least one externally connected host, the host interface is connected to the controller, and the controller is used to execute the steps of any of the above-mentioned data sharing methods. BRIEF DESCRIPTION OF THE DRAWINGS
[0009] Figure 1 This is a schematic diagram of a first direction of an application scenario of a data sharing method in an embodiment of the present application;
[0010] Figure 2 A schematic diagram of a second direction of an application scenario of a data sharing method in an embodiment of the present application;
[0011] Figure 3 This is a flow chart of a data sharing method in an embodiment of the present application;
[0012] Figure 4 This is a flow chart of a data sharing method in another embodiment of the present application;
[0013] Figure 5 This is a schematic diagram of a connection detection process in an embodiment of the present application;
[0014] Figure 6 This is a flow chart of a data sharing method in another embodiment of the present application;
[0015] Figure 7 This is a flow chart of a data sharing method in another embodiment of the present application;
[0016] Figure 8 This is a schematic diagram of the structure of a data sharing device in an embodiment of the present application;
[0017] Fig. 9 This is a schematic diagram of the structure of a port replicator in an embodiment of the present application;
[0018] Fig.10 This is a schematic diagram of the controller structure in one embodiment of the present application. DETAILED DESCRIPTION
[0019] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0020] The data sharing method provided in the embodiment of the present application can be applied to Figure 1 and Figure 2 In the application environment shown in the figure. The port replicator (Dock) 102 is provided with at least one expansion interface (usually provided on the back of the port replicator 102, i.e. Figure 1 ) and at least one host interface (usually provided on the front side of the port replicator 102, i.e. Figure 2 As shown in FIG. 1 , the host 104 is connected to the port replicator 102 through the host interface, and the expansion interface is used to access the port devices (Down facing port devices, DFPs), such as a mouse, a keyboard, a mobile power supply or a display, etc. The specific type and quantity are not limited, and can be selected in combination with actual needs and the number of expansion interfaces. The specific type of the host 104 is not unique, and can be a personal computer or a server, etc. At the same time, the hosts 104 connected to the port replicator 102 can be hosts of the same type or hosts of different types, and there is no specific limitation. Similarly, the number of hosts 104 connected to the port replicator 102 is not specifically limited, and can be selected in combination with the actual use scenario or the number of host interfaces.
[0021] During operation, the port replicator 102 can switch different hosts 104 to start operation and control different hosts 104 to start working. The specific types of the host interface and the expansion interface are not unique. In a more detailed embodiment, the host interface and the expansion interface can be set to USB (Universal Serial Bus) interfaces. Further, in a more detailed embodiment, the host interface can also be set to USB_C (also known as USB Type-C) interface.
[0022] In one embodiment, Figure 3 As shown, a data sharing method is provided, which is applied to Figure 1 The port replicator in FIG. 1 is used as an example to illustrate the method, which includes step 302, step 304, step 306 and step 308.
[0023] Step 302, obtaining protocol data of the host interface.
[0024] Specifically, protocol data is data generated when a host and a host interface are connected and interact according to a communication protocol. The port replicator has a communication protocol detection function. When a host is connected to the host interface, it can be detected by the port replicator and the corresponding protocol data can be obtained. Therefore, the data sharing method provided by the present application is implemented based on the existence of a host connected to the host interface. If there is no host connected to the host interface, the steps of the data sharing method of the present application will not be executed.
[0025] It is understandable that the specific type of protocol data is not unique. In one embodiment, according to the different functions that the host needs to implement, the protocol data includes communication protocol data and charging and discharging protocol data. It should be noted that the protocol detection method of the port replicator is not unique, and different settings can be made in combination with actual needs. For example, in a more detailed embodiment, the port replicator has a PD (Power Delivery) protocol detection function.
[0026] Step 304: Determine whether there are at least two hosts connected to the host interface respectively according to the protocol data.
[0027] Specifically, the connection between the host and the host interface includes at least one of a charging and discharging connection and a communication connection. The charging and discharging connection is the connection between the host and the host interface to realize the charging or discharging function, and the communication connection is the connection between the host and the host interface to realize the data interaction function. After obtaining the protocol data generated by the host connected to the host interface, the port replicator will analyze the protocol data to determine whether there are at least two hosts connected to the host interface respectively. If there are at least two hosts connected to the host interface, it is considered that there is a need for data sharing between the hosts at this time, and the port replicator will control each connected host to enter the data sharing operation mode.
[0028] It can be understood that, in one embodiment, determining whether there are at least two hosts connected to the host interface respectively specifically includes: determining whether there are at least two hosts connected to the host interface for communication respectively. In the solution of this embodiment, after obtaining the protocol data of the host interface, the protocol data is analyzed to determine whether the host connected at this time is a charging and discharging connection or a communication connection. If at least two hosts are connected to the host interface for communication, it is considered that at least two hosts are connected to the host interface respectively.
[0029] In another embodiment, determining whether there are at least two hosts connected to the host interface respectively may further include: determining whether there are at least two hosts connected to the host interface for charging and discharging respectively. In the solution of this embodiment, when analyzing whether the host connected at this time is connected for charging and discharging or for communication according to the protocol data, if there are at least two hosts connected to the port replicator for charging and discharging, it is also considered that there are at least two hosts connected to the host interface respectively.
[0030] Further, in other embodiments, determining whether there are at least two hosts respectively connected to the host interface may also include: determining whether there are at least two hosts respectively connected to the host interface for communication or for charging and discharging, that is, when there is at least one host connected to the host interface for charging and discharging, and there is at least one host connected to the host interface for communication, the port replicator also considers that at least two hosts are respectively connected to the host interface.
[0031] Step 306: If there are at least two hosts respectively connected to the host interface, a call instruction is sent to each host connected to the host interface to control each host connected to the host interface to enter a data sharing operation mode.
[0032] Specifically, when at least two hosts are in a communication connection state or a charge-discharge connection state, at least two hosts enter a data sharing operation mode, which is a mode in which data can be exchanged with the port replicator, data can be transmitted to the port replicator, or data forwarded by the port replicator can be received.
[0033] In the solution of this embodiment, no matter at least two hosts connected to the host interface are in a charging and discharging connection state, or at least two hosts connected to the host interface are in a communication connection state, or at least one of the at least two hosts connected to the host interface is in a charging and discharging connection state and at least one is in a communication connection state, the port replicator will send a call instruction to each connected host respectively to control each host connected to the port replicator to enter a data sharing operation mode, thereby meeting the real-time data sharing requirements of each host connected to the host interface.
[0034] Step 308: Control data sharing between at least two hosts according to the data sharing request between at least two hosts.
[0035] Specifically, the data sharing request is a request signal sent by the host to the port replicator when there is a data sharing demand. After each host connected to the host interface enters the data sharing operation mode, in order to ensure reliable and orderly data sharing, the port replicator will combine the data sharing requests sent by each host and control the transmission of the required shared data between different hosts, thereby realizing data sharing between at least two hosts.
[0036] In the above data sharing method, the port replicator is provided with a host interface, and by acquiring the protocol data at the host interface, it is detected whether there are at least two hosts connected to the host interface. If there are at least two hosts connected to the host interface, that is, at least two hosts are in a communication connection state or a charge and discharge connection state, then by issuing a call instruction to the host connected to the host interface, at least two hosts connected to the host interface are controlled to enter a data sharing operation mode, thereby realizing data sharing between at least two hosts connected to the host interface according to the data sharing request between at least two hosts. Through this scheme, the port replicator can control the corresponding hosts to enter a data sharing operation mode when at least two hosts connected to the host interface are connected, and realize data sharing operations between hosts, thereby solving the problem that the port replicator cannot meet the use requirements of data transmission between different hosts during operation.
[0037] See also Figure 4 In one embodiment, step 304 includes step 402 and step 404 .
[0038] Step 402: Determine the number of hosts connected to the host interface and the amount of communication protocol data according to the protocol data.
[0039] Step 404: If the number of hosts is two or more, and the number of communication protocol data is two or more, it is determined that there are at least two hosts respectively connected to the host interface.
[0040] Specifically, the scheme of this embodiment is explained by taking the case where at least two hosts connected to the host interface are in a communication connection state, and it is considered that there are at least two hosts connected to the host interface. The port replicator is provided with multiple host interfaces, each of which can be connected to a corresponding host. When the host is connected to the host interface, it can communicate with the host interface using a corresponding communication protocol, thereby generating a protocol data. Therefore, the port replicator can determine the number of hosts connected to the host interface according to the number of protocol data generated at the host interface. For example, the port replicator obtains two protocol data, which indicates that the number of hosts currently connected to the host interface is two.
[0041] After acquiring the protocol data, this solution first analyzes the number of hosts connected to the host interface in combination with the protocol data. When the number of hosts connected to the host interface is more than two, that is, when the number of hosts connected to the host interface is greater than or equal to two, it is considered that there is a basis for data sharing. After that, the protocol data will be further combined to perform an analysis on whether there are at least two hosts communicating with the host interface.
[0042] When the port replicator detects the number of hosts connected to the host interface in a communication connection mode, the specific detection method is not unique. In the scheme of this embodiment, it can be implemented by detecting the type of protocol data. The protocol data may include communication protocol data and charge-discharge protocol data. The communication protocol data is the data obtained by the host interface after the host with a data transmission function is connected to the host interface in a communication operation mode. The charge-discharge protocol data is the data obtained by the host interface after the host with an energy storage function is connected to the host interface in a charge-discharge operation mode. When the protocol data obtained by the port replicator is identified as communication protocol data, it means that the host is running in the communication operation mode and can realize data transmission and sharing. If the protocol data obtained by the port replicator is identified as charge-discharge protocol data, it means that the host is running in the charge-discharge mode and no data transmission or sharing is required.
[0043] If two or more communication protocol data are detected in the protocol data, it means that among the hosts connected to the host interface, there are more than two hosts that meet the data sharing conditions. At this time, the host corresponding to the communication protocol data can be controlled to enter the data sharing operation mode by calling the signal, so that each host can transmit and receive data with the port replicator, thereby realizing data sharing between the hosts through the port replicator.
[0044] In the above scheme, when the number of hosts accessing the host interface is two or more and the number of hosts accessing the host interface in a communication connection state is two or more, it is determined that there are at least two hosts respectively connected to the host interface, thereby realizing real-time data sharing of the hosts accessed in a communication connection state.
[0045] It can be understood that in another embodiment, when at least two hosts connected to the host interface are in a charging connection state, it is considered that there are at least two hosts connected to the host interface, and the specific setting can be made in combination with actual needs. Correspondingly, at this time, according to the protocol data, determining whether there are at least two hosts connected to the host interface respectively can also include: determining the number of hosts connected to the host interface and the number of charging and discharging protocol data according to the protocol data; if the number of hosts is two or more, and the number of charging and discharging protocol data is two or more, it is determined that there are at least two hosts connected to the host interface respectively.
[0046] It should be noted that in actual operation, the number of hosts connected to the port replicator may vary depending on the number of host interfaces of the port replicator or actual usage requirements. To achieve data sharing, the number of host interfaces must be at least two, and the number of hosts connected to the host interfaces must be at least two at the same time. Figure 5 In a more detailed embodiment, the number of hosts is two, and determining whether there are at least two hosts connected to the host interface includes: determining in turn whether the two hosts are both communicatively connected to the host interface; if the two hosts are both communicatively connected to the host interface, determining that there are at least two hosts connected to the host interface.
[0047] The solution of this embodiment is explained by assuming that the number of hosts connected to the host interface at the same time is two. In this case, in order to meet the data sharing condition, both hosts need to be connected to the host interface in a communication connection state, so that under the action of the call instruction, both hosts can enter the data sharing operation mode and realize data sharing between the hosts.
[0048] Please refer to Figure 4 In one embodiment, after step 402 , the method further includes step 406 .
[0049] Step 406: If the number of hosts is less than two or the number of communication protocol data is less than two, output a call prohibition message to control the data sharing program of the host connected to the host interface to run in the background.
[0050] Specifically, the prohibition call information is information for prohibiting the calling of the data sharing program related to data sharing in the host. On the basis that at least two hosts connected to the host interface are in the communication connection state, and at least two hosts are controlled to enter the data sharing operation mode, correspondingly, if the port replicator analyzes the received protocol data and the number of hosts connected to the host interface is less than two, or the number of hosts connected to the host interface in the communication connection state is less than two, the prohibition call information will be sent to the connected host, so as to control the data sharing program of the host connected to the host interface to run in the background.
[0051] It is understandable that the way in which the control host calls the application from the background to the foreground is not unique. In one embodiment, it can be implemented by a driver inside the control host, and the specifics are not limited.
[0052] The above scheme, when data sharing is not needed, outputs a prohibition call information to control the background operation of the host's data sharing program, effectively preventing the data sharing program from occupying additional host system resources, and also ensuring that when there is a need for data sharing, it can be awakened in time to enter the data sharing operation mode.
[0053] See also Figure 6 , in one embodiment, step 306 includes step 602 .
[0054] Step 602, sending a call instruction to each host connected to the host interface, so as to call the data sharing program of each host connected to the host interface to run in the foreground.
[0055] Specifically, the method of calling the instruction to control each host connected to the host interface to enter the data sharing mode is not unique. In the solution of this embodiment, the host is equipped with an application corresponding to data sharing. Before entering the data sharing operation mode, the application is in the background operation state. When the host receives the call instruction, it will turn the corresponding application into the foreground operation, thereby entering the data sharing operation mode.
[0056] Under the action of the call instruction sent by the port replicator, each host connected to the host interface starts the corresponding data sharing program, and then can transmit data to the port replicator, and obtain corresponding data from the port replicator. That is, when the data sharing program is started, the hosts connected to the host interface can transfer through the port replicator to achieve data sharing between the hosts.
[0057] In the above scheme, when there are at least two hosts connected to the host interface respectively, the data sharing programs of the hosts are called to the foreground to run by sending calling instructions to the hosts, thereby entering the data sharing operation mode, ensuring that any host connected to the host interface can respond in time when there is a data sharing demand.
[0058] See also Figure 7 , in one embodiment, step 308 includes step 702 .
[0059] Step 702: According to a data sharing request between at least two hosts, data sent by a host corresponding to the data transmission request is transmitted to a host corresponding to the data reception request via a data transmitter of the port replicator.
[0060] Specifically, the data sharing request includes a data transmission request and a data receiving request. The data transmission request is a request signal for the current host to request to transmit its own stored data to another host, and the data receiving request is a request signal for the current host to request to receive data sent by another host. After each host connected to the host interface enters the data sharing operation mode, any of the connected hosts will send a corresponding request signal to the port replicator when there is a need to transmit or receive data. Finally, the data transmitter transmits the required shared data between different hosts according to the received request signal, thereby realizing the data sharing function.
[0061] In the above scheme, after the host connected to the host interface enters the data sharing operation mode, the required shared data is transmitted between the corresponding hosts according to the data transmission request or data reception request of the host, thereby ensuring the accuracy of data sharing.
[0062] Furthermore, in one embodiment, if there are at least two hosts respectively connected to the host interface, the method further includes: controlling the data transmitter of the port replicator to be powered on and run.
[0063] Specifically, in the scheme of this embodiment, the port replicator is provided with a data transmitter. When only one host is connected to the host interface, or no host is connected to the host interface, the data transmitter is in a power-off state. When there are at least two hosts respectively connected to the host interface, the data transmitter will be powered on and controlled to start running.
[0064] It can be understood that the power-on control method of the data transfer is not unique. In a more detailed embodiment, the port replicator is provided with a power manager, which is arranged between the external power supply and the data transfer. The data transfer needs to be connected to the external power supply to start and run. When the power manager is disconnected, the data transfer is disconnected from the external power supply, and the data transfer is not started and run; and when the power manager is closed and turned on, the external power supply and the data transfer are connected, and the data transfer is started and run. Therefore, the port replicator can decide whether to turn on the power manager according to the detection result, thereby realizing the start and stop control of the data transfer. When the data transfer is turned on, the data transfer can send a call instruction to the host connected to the host interface, so as to call the data sharing related application of this type of host to the foreground to run, so as to enter the data sharing operation mode.
[0065] In the above scheme, when it is detected that at least two hosts are respectively connected to the host interface, the data transmitter of the port replicator is powered on and started to operate, so as to avoid power consumption caused by continuous operation of the data transmitter.
[0066] In order to facilitate understanding of the technical solution of the present application, the present application is explained below in conjunction with more detailed embodiments.
[0067] When there is no host connected to the host interface of the port replicator, the port replicator cannot obtain the protocol data. When there is a host connected to the host interface, the host communicates with the host interface using the corresponding protocol to generate protocol data. The port replicator determines the number of hosts connected to the host interface based on the amount of protocol data obtained. If the number of hosts is greater than or equal to two, it means that there is a basis for host data sharing at this time, and continues to perform the analysis operation of the number of hosts connected to the host interface according to the protocol data. If the number of hosts is less than two, it means that there is no basis for host data sharing. At this time, a call prohibition information will be output to the user or each host, so that the data sharing-related application in the connected host will not be started, or will not enter the foreground to run.
[0068] If there are at least two hosts that are connected to the host interface for communication according to the protocol data analysis, that is, the number of communication protocol data is greater than or equal to two, it means that the host meets the data sharing conditions at this time. Correspondingly, the port replicator will control the data transmission device to power on and run, and then the port replicator will send a call instruction to each host that is connected to the host interface for communication. Under the action of the call instruction, the driver corresponding to the data sharing related application in each host is started, and the data sharing related application that was originally running in the background or stopped running is driven to run in the foreground. Each host enters the data sharing operation mode, and data sharing operations can be realized between hosts through the port replicator. When any connected host has a data sharing demand, it only needs to send a data sharing request to the port replicator, and data can be transferred through the data transmission device of the port replicator to realize data sharing.
[0069] If there are no at least two hosts connected to the host interface according to the protocol data analysis, it means that the host does not meet the data sharing condition. At this time, the port replicator will output a prohibition call message to each host, so that the data sharing related application in the connected host will not be started or will not enter the foreground to run.
[0070] It should be understood that, although the steps in the flowcharts involved in the above embodiments are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps is not strictly limited in order, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above embodiments may include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the steps or stages in other steps.
[0071] Based on the same inventive concept, the embodiment of the present application also provides a data sharing device for implementing the data sharing method involved above. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme recorded in the above method, so the specific limitations in the one or more data sharing device embodiments provided below can refer to the limitations on the data sharing method above, and will not be repeated here.
[0072] In one embodiment, Figure 8 As shown, a data sharing device is provided, including: a protocol data acquisition module 802, a connection analysis module 804, a sharing operation control module 806 and a data sharing module 808.
[0073] The protocol data acquisition module 802 is used to acquire the protocol data of the host interface.
[0074] The connection analysis module 804 is used to determine whether there are at least two hosts connected to the host interface respectively according to the protocol data.
[0075] The shared operation control module 806 is used to send a call instruction to each host connected to the host interface if there are at least two hosts connected to the host interface respectively, so as to control each host connected to the host interface to enter a data sharing operation mode.
[0076] The data sharing module 808 is used to control data sharing between at least two hosts according to a data sharing request between at least two hosts.
[0077] In one embodiment, the connection analysis module 804 is also used to determine the number of hosts connected to the host interface and the amount of communication protocol data based on the protocol data; if the number of hosts is two or more, and the amount of communication protocol data is two or more, it is determined that there are at least two hosts connected to the host interface respectively.
[0078] In one embodiment, the connection analysis module 804 is also used to output a prohibition call message if the number of hosts is less than two or the number of communication protocol data is less than two, so as to control the background operation of the data sharing program of the host connected to the host interface.
[0079] In one embodiment, the shared operation control module 806 is further used to send a call instruction to each host connected to the host interface, so as to call the data sharing program of each host connected to the host interface to the foreground for execution.
[0080] The data sharing module 808 is further configured to transmit, according to a data sharing request between at least two hosts, data sent by a host corresponding to a data transmission request to a host corresponding to a data reception request through a data transfer device of the port replicator.
[0081] In one embodiment, the shared operation control module 806 is further configured to control the data transmission device of the port replicator to power on and operate if there are at least two hosts respectively connected to the host interface.
[0082] Each module in the above data sharing device can be implemented in whole or in part by software, hardware or a combination thereof. Each module can be embedded in or independent of a processor in a computer device in the form of hardware, or can be stored in a memory in a computer device in the form of software, so that the processor can call and execute operations corresponding to each module.
[0083] In the above-mentioned data sharing device, the port replicator is provided with a host interface, and by acquiring the protocol data at the host interface, it is detected whether there are at least two hosts connected to the host interface. If there are at least two hosts connected to the host interface, that is, at least two hosts are in a communication connection state or a charge-discharge connection state, then by issuing a call instruction to the host connected to the host interface, at least two hosts connected to the host interface are controlled to enter a data sharing operation mode, thereby realizing data sharing between at least two hosts connected to the host interface according to the data sharing request between at least two hosts. Through this scheme, the port replicator can control the corresponding hosts to enter a data sharing operation mode when at least two hosts connected to the host interface are connected, and realize data sharing operations between hosts, thereby solving the problem that the port replicator cannot meet the use requirements of data transmission between different hosts during operation.
[0084] See also Fig. 9 The present application provides a port replicator, including a host interface 902 and a controller 904, wherein the host interface 902 is used to connect to a host, the host interface 902 is connected to the controller 904, and the controller 904 is used to execute the steps of the above-mentioned data sharing method.
[0085] Specifically, the implementation of the data sharing method is as shown in the above embodiments and the accompanying drawings, which will not be repeated here. The above port replicator is provided with a host interface 902, and by acquiring the protocol data at the host interface 902, it is detected whether at least two hosts among the multiple hosts connected are connected to the host interface 902. If there are at least two hosts connected to the host interface 902, that is, at least two hosts are in a communication connection state or a charge and discharge connection state, then by issuing a call instruction to the host connected to the host interface 902, each host connected to the host interface 902 is controlled to enter a data sharing operation mode, thereby realizing data sharing between at least two hosts connected to the host interface 902 according to the data sharing request between at least two hosts. Through this solution, the port replicator can control the corresponding hosts to enter the data sharing operation mode when at least two hosts connected to the host interface 902 are connected, and realize the data sharing operation between the hosts, thereby solving the problem that the port replicator cannot meet the use requirements of data transmission between different hosts during operation.
[0086] See also Fig.10 In one embodiment, the controller 904 includes a host detector 906 and a data transmitter 908 , the host interface 902 (not shown) connects the host detector 906 and the data transmitter 908 , and the host detector 906 is connected to the data transmitter 908 .
[0087] Specifically, in the solution of this embodiment, the controller 904 used to execute the data sharing method includes two parts: a host detector 906 and a data transmitter 908. The host detector 906 is used to detect whether there is a data sharing basis (that is, whether there are at least two hosts) for the host connected to the host interface 902, and whether the data sharing condition is met (that is, whether there are at least two connected hosts). The data transmitter 908 is used to realize the data sharing function between different hosts, that is, to send a call instruction, and after each host enters the data sharing operation mode, transmit the data sent by the host to another host.
[0088] It can be understood that in a more detailed embodiment, in order to meet the protocol data identification function, the host detector 906 is a detector with a USB PD protocol detection function.
[0089] It should be noted that the specific type of the data transmission device 908 is not unique. In one embodiment, the data transmission device 908 can be set as a data transmission chip or a data sharing chip. The specific model is not limited as long as it can realize data transmission and the sending of call instructions.
[0090] In the above solution, the controller 904 is configured as two parts, namely, a host detector 906 and a data transmitter 908, which respectively implement different data sharing functions, thereby improving the data processing efficiency of the controller 904 and further improving the data sharing efficiency.
[0091] In one embodiment, see Fig.10 The host detector 906 includes a protocol detector 9061 and a processor 9062 . The protocol detector 9061 is connected to the host interface 902 . The protocol detector 9061 is connected to the processor 9062 . The processor 9062 is connected to the data transmitter 908 .
[0092] Specifically, in the scheme of this embodiment, the host detector 906 for detecting the connection between the host and the host interface 902 is set as a protocol detector 9061 and a processor 9062, wherein the protocol detector 9061 is used to detect the protocol data at the host interface 902 and send the detected protocol data to the processor 9062; or after detecting the protocol data at the host interface 902, it is combined with the protocol data model to detect whether there are at least two hosts connected to the host interface 902, and the detection result is sent to the processor 9062.
[0093] Correspondingly, the processor 9062 can detect whether there are at least two hosts connected to the host interface 902 in combination with the protocol data, and finally output a control signal to the data transmitter 908 according to the detection result, so as to control the operation of the data transmitter 908. Alternatively, the processor 9062 is used to send a control signal to the data transmitter 908 to control the start and stop of the data transmitter 908 according to the detection result sent by the protocol detector 9061.
[0094] It should be noted that the communication method between the protocol detector 9061 and the processor 9062 is not unique. In one embodiment, the protocol detector 9061 and the processor 9062 can communicate through an I2C (Inter-Integrated Circuit, two-wire serial bus) data channel. In another embodiment, the protocol detector 9061 can also communicate with the processor 9062 through a separate GPIO (General Purpose Input Output, general input and output) communication interface, and the specific selection can be made in combination with actual needs.
[0095] It is understandable that the specific type of the protocol detector 9061 is not unique, and in a more detailed embodiment, the protocol detector 9061 can be set as a PD control chip to implement the detection operation of the protocol data between the host and the host interface 902. Furthermore, the processor 9062 can also be set as an MCU (Micro controller unit).
[0096] In the above scheme, the protocol detector 9061 and the processor 9062 are set to jointly complete the function of the host detector 906, and the protocol detection and the host connection mode detection are respectively implemented in different parts, which can effectively improve the detection efficiency of the host connection mode detection.
[0097] Please refer to Fig.10 In one embodiment, the controller 904 further includes a power manager 909 , which is used to connect to an external power source, and the host detector 906 and the data transmitter 908 are respectively connected to the power manager 909 .
[0098] Specifically, the power manager 909 is arranged between the external power supply and the data transmitter 908, and the data transmitter 908 needs to be connected to the external power supply to start running. When the power manager 909 is disconnected, the data transmitter 908 is disconnected from the external power supply, and the data transmitter 908 is not started running; and when the power manager 909 is closed and turned on, the external power supply and the data transmitter 908 are connected, and the data transmitter 908 is started running. Therefore, the host detector 906 can decide whether to turn on the power manager 909 according to the detection result, so as to realize the start and stop control of the data transmitter 908. When the data transmitter 908 is turned on, the data transmitter 908 can send a call instruction to the host connected to the host interface 902, so as to call the data sharing related application of this type of host to the foreground to run, so as to enter the data sharing operation mode.
[0099] Further, in a more detailed embodiment, the host detector 906 includes a protocol detector 9061 and a processor 9062. Accordingly, the processor 9062 is connected to the data transmitter 908 through the power manager 909. In the scheme of this embodiment, the processor 9062 can control the power manager 909 to turn on or off by outputting high and low level signals, thereby realizing the start and stop control of the data transmitter 908.
[0100] For example, when the processor 9062 analyzes the protocol data and finds that there are at least two hosts connected to the host interface 902, a high-level signal is output to the power manager 909, and the power manager 909 starts to run, so that the external power is transmitted to the data transmitter 908, and the data transmitter 908 starts to run and sends a call instruction to the corresponding host. When the processor 9062 analyzes the protocol data and finds that there are not at least two hosts connected to the host interface 902, a low-level signal is output to the power manager 909, and the power manager 909 is turned off. At this time, the external power cannot be transmitted to the data transmitter 908, and the data transmitter 908 will not start to run, and will not send a call instruction to the host.
[0101] It should be noted that the specific type of the power manager 909 is not unique, and the power manager 909 may be different depending on the type of the external power source and the type of the data transmitter 908. For example, in a more detailed embodiment, the power manager 909 may be set as a DC-DC converter, a rectifier, etc.
[0102] In order to facilitate understanding of the technical solution of the present application, the present application is explained below in conjunction with a more detailed embodiment. In the solution of this embodiment, the port replicator includes a protocol detector 9061 , a processor 9062 , a power manager 909 and a data transmitter 908 .
[0103] When a host is connected to the host interface 902, the protocol detector 9061 acquires relevant protocol data, and analyzes the number of hosts currently connected to the host interface 902 in combination with the acquired protocol data. If the number of hosts is greater than or equal to two, the number of hosts connected to the host interface 902 is analyzed according to the protocol data; if the number of hosts is less than two, the detection result is transmitted to the processor 9062, and the processor 9062 outputs a low-level signal to control the power manager 909 to shut down, so that the data transmitter 908 is in a stopped state. Correspondingly, at this time, the processor 9062 can also output a prohibition call information to the user or each host to ensure that the data sharing-related applications in each host will not be started, or will not enter the foreground to run.
[0104] After the protocol detector 9061 analyzes the protocol data and finds that there are at least two hosts connected to the host interface 902, it will transmit the detection result to the processor 9062. The processor 9062 outputs a high-level signal to the power manager 909 according to the detection result, and controls the power manager 909 to start, so that the data transmitter 908 starts to run. After the data transmitter 908 is turned on, it sends a call instruction to each host connected to the host interface 902, so that the application programs related to data sharing that were originally running in the background or stopped in the host are turned to the foreground to run, and the host enters the data sharing operation mode, and the data sharing operation can be realized between the hosts through the data transmitter 908.
[0105] After the protocol detector 9061 analyzes the protocol data and finds that there are no at least two hosts connected to the host interface 902, it will transmit the detection result to the processor 9062. At this time, the processor 9062 will output a low-level signal to control the power manager 909 to shut down, so that the data transmitter 908 is in a stopped state. Correspondingly, at this time, the processor 9062 can also output a prohibition call information to the user or each host to ensure that the data sharing-related applications in each host will not be started or will not enter the foreground to run.
[0106] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0107] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.
Claims
1. A data sharing method, characterized in that: Applies to port replicators, including: Get the protocol data of the host interface; Determining, according to the protocol data, whether there are at least two hosts connected to the host interface respectively; If there are at least two hosts respectively connected to the host interface, a call instruction is sent to each host connected to the host interface to control each host connected to the host interface to enter a data sharing operation mode; wherein, when the at least two hosts are in a communication connection state or a charge and discharge connection state, the at least two hosts enter the data sharing operation mode; According to a data sharing request between the at least two hosts, data sharing between the at least two hosts is controlled.
2. The data sharing method according to claim 1, characterized in that: The determining, according to the protocol data, whether at least two hosts are respectively connected to the host interface comprises: Determining the number of hosts connected to the host interface and the amount of communication protocol data according to the protocol data; If the number of the hosts is two or more, and the number of the communication protocol data is two or more, it is determined that there are at least two hosts respectively connected to the host interface.
3. The data sharing method according to claim 2, characterized in that: After determining the number of hosts connected to the host interface and the number of communication protocol data according to the protocol data, the method further comprises: If the number of the hosts is less than two or the number of the communication protocol data is less than two, a call prohibition message is output to control the background operation of the data sharing program of the host connected to the host interface.
4. The data sharing method according to any one of claims 1 to 3, characterized in that: The sending of a call instruction to each host connected to the host interface to control each host connected to the host interface to enter a data sharing operation mode includes: A calling instruction is sent to each host connected to the host interface to call the data sharing program of each host connected to the host interface to the foreground for execution.
5. The data sharing method according to any one of claims 1 to 3, characterized in that: The step of controlling the data sharing between the at least two hosts according to the data sharing request between the at least two hosts comprises: According to the data sharing request between the at least two hosts, the data sent by the host corresponding to the data transmission request in the data sharing request is transmitted to the host corresponding to the data receiving request in the data sharing request through the data transmission device of the port replicator.
6. The data sharing method according to any one of claims 1 to 3, characterized in that: If there are at least two hosts respectively connected to the host interface, the method further includes: The data transmission device of the port replicator is controlled to be powered on and run.
7. A data sharing device, characterized in that: Applies to port replicators, including: A protocol data acquisition module, used to acquire protocol data of a host interface; A connection analysis module, used for determining whether there are at least two hosts connected to the host interface respectively according to the protocol data; A shared operation control module, for sending a call instruction to each host connected to the host interface if there are at least two hosts respectively connected to the host interface, so as to control each host connected to the host interface to enter a data sharing operation mode; wherein, when the at least two hosts are both in a communication connection state or a charge and discharge connection state, the at least two hosts enter the data sharing operation mode; The data sharing module is used to control the data sharing between the at least two hosts according to the data sharing request between the at least two hosts.
8. A port replicator, characterized in that: It comprises a host interface and a controller, wherein the host interface is used to connect to at least one external host, the host interface is connected to the controller, and the controller is used to execute the steps of the data sharing method according to any one of claims 1 to 6.
9. The port replicator according to claim 8, characterized in that: The controller comprises a host detector and a data transmitter, the host interface connects the host detector and the data transmitter, and the host detector is connected to the data transmitter.
10. The port replicator according to claim 9, characterized in that: The host detector comprises a protocol detector and a processor, wherein the protocol detector is connected to the host interface, the protocol detector is connected to the processor, and the processor is connected to the data transmitter; And / or, the controller further includes a power manager, the power manager is used to connect to an external power source, and the host detector and the data transmitter are respectively connected to the power manager.
Citation Information
Patent Citations
Method and device for data sharing between equipments
CN105022705A
External equipment sharing device and sharing method, display equipment, and computer equipment
CN114003298A
Equipment, method and system for realizing equipment interconnection
CN1704917A
Data sharing control device and system with multiple communication protocol interfaces
CN203289478U
Computer system
CN217932698U
