A switching method of an auxiliary input device, an electronic device and a readable storage medium

By monitoring and transmitting input events from Android devices to Windows devices, keyboard and mouse crossover and backtracking events are enabled, solving the problem of cumbersome operation between tablets and computers and improving operational efficiency.

CN117687524BActive Publication Date: 2026-02-13HONOR DEVICE CO LTD
View PDF 6 Cites 0 Cited by

Patent Information

Application Number
CN202211070905.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-09-02
Publication Date
2026-02-13
Estimated Expiration
2042-09-02

AI Technical Summary

Technical Problem

Users need to frequently switch between the auxiliary input devices on tablets and computers, making the operation cumbersome.

Method used

By connecting an auxiliary input device, such as a mouse and keyboard, to a first electronic device running an Android system, input events are monitored and transmitted to a second electronic device running a Windows system, enabling mouse and keyboard crossover and crossover events, allowing the user to control the second electronic device through the auxiliary input device of the first electronic device.

Benefits of technology

It simplifies the user's input operations between different electronic devices, improves operational efficiency, and enables the second electronic device to assist the first electronic device in completing related tasks.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117687524B_ABST
    Figure CN117687524B_ABST
Patent Text Reader

Abstract

The application provides a switching method of an auxiliary input device, an electronic device and a readable storage medium, and relates to the technical field of auxiliary input; in the method, the auxiliary input device can be a keyboard and a mouse, the auxiliary input device is connected to a tablet computer, the tablet computer and a computer are in communication connection; a user controls the tablet computer through the keyboard and the mouse; when mouse operation causes a mouse cursor to move out of the edge of a screen, the tablet computer transmits input operation of the mouse and the keyboard to the computer, and input operation of the mouse and the keyboard connected to the tablet computer takes effect on the computer; after input operation of the mouse and the keyboard takes effect on the computer, when mouse operation causes a mouse cursor on the computer to move out of the edge of the screen, the computer sends key mouse back-through information to the tablet computer, and operation of the keyboard and the mouse continues to take effect on the tablet computer and does not take effect on the computer; through the method, the user can control the computer by using the auxiliary input device on the side of the tablet computer.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of auxiliary input, in particular to a switching method of auxiliary input device, an electronic device and a readable storage medium. BACKGROUND

[0002] With the increasing diversification of user needs, the types of electronic devices are also increasing. Tablet computers are more portable than computers and have larger screens than mobile phones, making them more suitable for handling various work, life and entertainment matters. Therefore, more and more users carry tablet computers for short trips.

[0003] However, the processing power of tablet computers is relatively weaker than that of computers, so in some use scenarios, computers are needed to assist tablet computers in handling some matters. Usually, users need to frequently operate back and forth between the auxiliary input devices (such as keyboards and mice) of the tablet computer and the auxiliary input devices (such as keyboards and mice) of the computer, resulting in cumbersome operation. SUMMARY

[0004] The present application provides a switching method of auxiliary input device, an electronic device and a readable storage medium, which allows a user to use the auxiliary input device of one electronic device to operate the present electronic device and another electronic device, so that the other electronic device assists the present electronic device in handling some matters.

[0005] To achieve the above-mentioned purpose, the present application adopts the following technical solutions:

[0006] In a first aspect, the present application provides a switching method of auxiliary input device, the auxiliary input device comprising a first mouse, the auxiliary input device being in communication connection with a first electronic device, the first electronic device being in communication connection with a second electronic device, the operating system of the first electronic device being an android system, and the operating system of the second electronic device being a windows system, the method comprising:

[0007] The first electronic device monitors a first input event, the first input event being an input event of the first mouse;

[0008] The first electronic device determines that the first input event is a first key-mouse traversal event, the first key-mouse traversal event being an event pre-set for sending an input event of the auxiliary input device having communication connection with the first electronic device to the second electronic device having communication connection with the first electronic device;

[0009] The first electronic device monitors a second input event, the second input event being an input event of the first mouse;

[0010] The first electronic device sends a second input event to the second electronic device, where the second input event is used to instruct the second electronic device to perform a screen operation corresponding to the second input event based on the second input event.

[0011] In the present application, an auxiliary input device can be connected to the first electronic device with an android system, which can include a mouse and also a keyboard. The input event of the keyboard and the mouse is triggered by the operation of the mouse connected to the first electronic device and is transmitted to the second electronic device (windows system). That is, after the first electronic device receives the input event of the auxiliary input device connected to the first electronic device, the input event is transmitted to the second electronic device and takes effect on the second electronic device. That is, the second electronic device is controlled by the auxiliary input device connected to the first electronic device to handle related matters. In this way, the first electronic device with an android system can be used as a master device and a master screen, and the second electronic device with a windows system can be used as an auxiliary device and an auxiliary screen. The user can control the second electronic device by using the auxiliary input device on the first electronic device, so that the second electronic device can assist the first electronic device to complete related work.

[0012] As an implementation manner of the first aspect, the first mouse crossing event is an event that a first mouse cursor displayed on a first display screen of the first electronic device moves out of the first display screen from an edge of a first side of the first display screen to the first side.

[0013] The present application provides a convenient way as a mouse crossing event. The user can control the second electronic device by the input operation of the auxiliary input device on the first electronic device through the movement of the mouse.

[0014] As another implementation manner of the first aspect, the first side is any one of an upper side, a lower side, a left side and a right side of the display screen.

[0015] In the present application, the mouse cursor moving out event of any side of the display screen is used as a mouse crossing event, which provides more application scenarios.

[0016] As another implementation manner of the first aspect, the first electronic device determining that the first input event is the first mouse crossing event includes:

[0017] The first electronic device obtains a first coordinate of the first mouse cursor on the first display screen in the first input event;

[0018] The first electronic device obtains first displacement information of the first mouse;

[0019] The first electronic device determines that the first input event is the first mouse crossing event according to the first coordinate and the first displacement information.

[0020] Since the information in the mouse movement event in the native flow in the electronic device of the android system is the coordinate of the mouse cursor, and does not include the movement information of the mouse, in the present application, the displacement information of the first mouse needs to be obtained additionally, which can be acquired by the first electronic device from the first mouse, and then the mouse input event is determined to be a key-mouse crossing event according to the coordinate of the mouse cursor and the displacement information of the mouse.

[0021] As another implementation form of the first aspect, the first electronic device determines, according to the first coordinate and the first displacement information, that the first input event is the first key-mouse crossing event, including:

[0022] The first electronic device determines that the first coordinate is an edge of the first side of the first display screen.

[0023] The first electronic device determines that the first displacement information after the first time indicates that the first mouse moves to the first side, wherein the first time is a time when the first mouse cursor in the first input event is located at the edge of the first side of the first display screen for the first time.

[0024] In the present application, when the mouse cursor on the first electronic device side moves to the edge of the first side, and the subsequent mouse displacement information indicates that the mouse continues to move to the first side, it can be determined that the current mouse input event is a key-mouse crossing event.

[0025] As another implementation form of the first aspect, after the first electronic device determines that the first input event is the first key-mouse crossing event, the method further includes:

[0026] The first electronic device sets the interception identifier to the first character, wherein when the interception identifier is the first character, the first electronic device does not perform a screen operation corresponding to the input event of the auxiliary input device connected to the first electronic device, and the auxiliary input device further includes a first keyboard.

[0027] In the present application, the interception identifier can be set, and the first electronic device determines whether the input operation of the auxiliary input device is effective on the first electronic device or is transmitted to the second electronic device to control the second electronic device based on the interception identifier.

[0028] As another implementation form of the first aspect, after the first electronic device monitors the second input event, the method further includes:

[0029] The first electronic device determines that the second input event is a mouse movement event.

[0030] The first electronic device acquires second displacement information associated with the second input event, and the second displacement information is displacement information of the first mouse between a start time and an end time of the second input event.

[0031] Correspondingly, the first electronic device sending the second input event to the second electronic device comprises:

[0032] The first electronic device sends the second displacement information associated with the second input event to the second electronic device.

[0033] In the present application, after determining to transmit the input event of the auxiliary input device of the first electronic device to the second electronic device, the input event monitored by the first electronic device will be transmitted to the second electronic device. Since the information in the mouse movement event of the first electronic device is the coordinate information of the mouse cursor, the mouse movement event of the second electronic device needs not only the coordinate information of the mouse cursor, but also the displacement information of the mouse, so the first electronic device needs to send the mouse movement event associated with the output event to the second electronic device.

[0034] As another implementation form of the first aspect, after the first electronic device sends the second input event to the second electronic device, the method further comprises:

[0035] The second electronic device receives the second displacement information sent by the first electronic device;

[0036] The second electronic device generates a first virtual input event according to the initial coordinate of the second mouse cursor and the second displacement information, the second mouse cursor being a mouse cursor on the second display screen of the second electronic device;

[0037] The second electronic device controls the second mouse cursor on the second display screen to move based on the first virtual input event.

[0038] In the present application, the information in the actual mouse movement event in the second electronic device comprises the current coordinate of the mouse cursor and the movement information of the mouse, and the second electronic device needs to determine the movement process of the mouse cursor on the screen according to the current coordinate of the mouse cursor and the movement information of the mouse, so the information sent by the first electronic device to the second electronic device is the displacement information of the mouse, and the second electronic device needs to obtain the initial coordinate of the mouse cursor on the second electronic device, which can be the current coordinate of the mouse cursor on the second electronic device, or a pre-set coordinate, for example, the center of the display screen of the second electronic device.

[0039] As another implementation form of the first aspect, after the first electronic device monitors the second input event, the method further comprises:

[0040] The first electronic device monitors a third input event, the third input event being an input event of the first mouse;

[0041] The first electronic device sends the third input event to the second electronic device;

[0042] The second electronic device determines that the third input event is a keyboard-mouse back-and-forth event, and the keyboard-mouse back-and-forth event is an event that is preset for canceling the auxiliary input device connected with the first electronic device from taking effect on the second electronic device;

[0043] The second electronic device sends the keyboard-mouse back-and-forth information to the first electronic device.

[0044] In the present application, the keyboard-mouse back-and-forth event can be set to cancel the auxiliary input device connected with the first electronic device from taking effect on the second electronic device, so that the auxiliary input device can take effect between the two electronic devices.

[0045] As another implementation manner of the first aspect, the keyboard-mouse back-and-forth event is an event that a second mouse cursor displayed on a second display screen of the second electronic device moves from an edge of a second side of the second display screen to the second side of the second display screen, and the second side is any one of an upper side, a lower side, a left side and a right side of the second display screen.

[0046] As another implementation manner of the first aspect, the third input event is associated with third displacement information, and the third displacement information is displacement information of the first mouse between a start time and an end time of the third input event.

[0047] The second electronic device determines that the third input event is a keyboard-mouse back-and-forth event, and the keyboard-mouse back-and-forth event is an event that is preset for canceling the auxiliary input device connected with the first electronic device from taking effect on the second electronic device;

[0048] The second electronic device obtains a second coordinate of the second mouse cursor on the second display screen before the third input event is received.

[0049] The second electronic device obtains a second coordinate of the second mouse cursor on the second display screen before the third input event is received.

[0050] The second electronic device determines that the predicted coordinate is located outside the edge of the second side of the second display screen.

[0051] In the present application, the displacement information associated with the third input event can be transmitted to the computer side as the third input event.

[0052] As another implementation manner of the first aspect, the second keyboard and the second mouse are connected to the second electronic device; and after the first electronic device determines that the first input event is the first keyboard-mouse back-and-forth event, the method further includes:

[0053] The first electronic device sends the keyboard-mouse back-and-forth information to the second electronic device.

[0054] The second electronic device receives the keyboard-mouse back-and-forth information sent by the first electronic device.

[0055] Correspondingly, after the second electronic device receives the keyboard-mouse back-and-forth information sent by the first electronic device, the method further includes:

[0056] The second electronic device receives a fifth input event, the fifth input event being an input event of the second keyboard or an input event of the second mouse;

[0057] In response to the fifth input event, the second electronic device sends the key-mouse back-through information to the first electronic device.

[0058] In the present application, diversified manners can also be provided to trigger the input operation of the auxiliary input device of the first electronic device not to take effect on the second electronic device.

[0059] As another implementation manner of the first aspect, after the first electronic device receives the key-mouse back-through information, the method further includes:

[0060] The first electronic device sets the interception identifier as the second character, where the first electronic device performs the screen operation corresponding to the input event of the auxiliary input device connected to the first electronic device when the interception identifier is the second character.

[0061] As another implementation manner of the first aspect, the auxiliary input device further includes a first keyboard, and after the first electronic device receives the key-mouse back-through information, the method further includes:

[0062] The first electronic device monitors a fourth input event, the fourth input event being an input event of the first mouse or an input event of the first keyboard;

[0063] The first electronic device performs the screen operation corresponding to the fourth input event based on the fourth input event.

[0064] As another implementation manner of the first aspect, the first electronic device and the third electronic device have a communication connection; and the method further includes:

[0065] The first electronic device monitors a sixth input event, the sixth input event being an input event of the first mouse;

[0066] The first electronic device determines that the sixth input event is a second key-mouse through event, the second key-mouse through event being an event that a first mouse cursor displayed on a first display screen of the first electronic device moves out of the first display screen from an edge of a third side of the first display screen to the third side, the third side being different from the first side;

[0067] The first electronic device monitors a seventh input event, the seventh input event being an input event of the first mouse;

[0068] The first electronic device sends the seventh input event to the third electronic device, where the seventh input event is used to instruct the third electronic device to perform the screen operation corresponding to the seventh input event based on the seventh input event.

[0069] In the present application, the first electronic device can also have a communication connection with a plurality of other electronic devices, and the key and mouse input events corresponding to different electronic devices can correspond to different sides of the display screen of the first electronic device, so that the scene when the first electronic device needs the assistance of a plurality of other electronic devices can be applied.

[0070] In a second aspect, an electronic device is provided, including a processor configured to execute a computer program stored in a memory to implement the steps performed by the first electronic device in the method of any one of the first aspect.

[0071] In a third aspect, a chip system is provided, including a processor coupled with a memory, and the processor executes a computer program stored in the memory to implement the steps performed by the first electronic device in the method of any one of the first aspect.

[0072] In a fourth aspect, a computer readable storage medium is provided, and the computer readable storage medium stores a computer program, and the computer program is executed by one or more processors to implement the steps performed by the first electronic device in the method of any one of the first aspect.

[0073] In a fifth aspect, the present application provides a computer program product, when the computer program product is run on a device, the device executes the steps performed by the first electronic device in the method of any one of the first aspect.

[0074] It can be understood that the beneficial effects of the above-mentioned second aspect to the fifth aspect can be referred to the related description in the first aspect, which will not be repeated here. BRIEF DESCRIPTION OF DRAWINGS

[0075] Figure 1 A hardware structure schematic diagram of an electronic device provided by an embodiment of the present application;

[0076] Figure 2 An application scenario schematic diagram of the switching method of the auxiliary input device provided by an embodiment of the present application;

[0077] Figure 3 A flowchart of the switching method of the auxiliary input device provided by an embodiment of the present application;

[0078] Figure 4 Another application scenario schematic diagram of the switching method of the auxiliary input device provided by an embodiment of the present application;

[0079] Figure 5 A flowchart of another switching method of the auxiliary input device provided by an embodiment of the present application;

[0080] Figure 6 For Figure 3The flowchart provided by the embodiment shown corresponds to a timing diagram.

[0081] Figure 7 For Figure 5 The flowchart provided by the embodiment shown corresponds to a timing diagram. DETAILED DESCRIPTION

[0082] In the following description, for the purposes of explanation, numerous specific details are set forth in order to thoroughly convey a thorough understanding of the embodiments of the application. It should be understood, however, that the embodiments of the application can be practiced in other embodiments that do not include all the specific details described.

[0083] It should be understood that the term "comprises" when used in this specification and the appended claims, specifies the presence of stated features, integers, steps, operations, elements, and / or components, but does not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and / or groups thereof.

[0084] It should also be understood that "one or more" of an element or aspect means that one, two, or more elements or aspects are present; "and / or" either refer to a relationship with an associative object or indicate that three cases can exist; for example, A and / or B can mean that A exists alone, A and B exist together, B exists alone; A, B can be singular or plural. The character " / " generally means that the associated objects are in an "or" relationship.

[0085] In addition, in the description of the specification and the appended claims, the terms "first", "second", "third", "fourth" and the like are only used to distinguish different descriptions, and cannot be understood as indicating or implying relative importance.

[0086] In the description of the specification, the reference to "one embodiment" or "some embodiments" and the like means that the specific features, structures or characteristics described in connection with the embodiment are included in one or more embodiments of the application. Therefore, the statements "in one embodiment", "in some embodiments", "in other some embodiments", "in other some embodiments" and the like appearing in different places in the specification are not necessarily all referring to the same embodiment, but mean "one or more but not all embodiments", unless otherwise specifically emphasized. The terms "include", "contain", "have" and their variants mean "include but not limited to", unless otherwise specifically emphasized.

[0087] The switching method of the auxiliary input device provided in the embodiments of the present application can be applied to electronic devices such as large-screen devices, tablet computers, mobile phones, notebook computers, ultra-mobile personal computers (UMPC), netbooks, personal digital assistants (PDA), and the like. The embodiments of the present application do not limit the specific type of the electronic device.

[0088] The auxiliary input device in the embodiments of the present application can be connected to the first electronic device, and the first electronic device and the second electronic device have a communication connection. The structure diagram of the first electronic device can refer to the structure diagram of the electronic device shown in Figure 1

[0089] Figure 1 A structure diagram of an electronic device is shown. The electronic device 100 can include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (USB) interface 130, a charge management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a loudspeaker 170A, a receiver 170B, a microphone 170C, a headset interface 170D, a sensor module 180, a key 190, a motor 191, a camera 193, a display screen 194, and a subscriber identification module (SIM) card interface 195, and the like. The sensor module 180 can include a pressure sensor 180A, a touch sensor 180K, and the like.

[0090] It can be understood that the structure shown in the embodiments of the present application does not constitute a specific limitation on the electronic device 100. In other embodiments of the present application, the electronic device 100 can include more or fewer components than shown, or combine certain components, or split certain components, or different component arrangements. The components shown can be implemented in hardware, software, or a combination of software and hardware.

[0091] ​The processor 110 can include one or more processing units, for example: the processor 110 can include an application processor (AP), a modem processor, a graphics processing unit (GPU), an image signal processor (ISP), a controller, a memory, a video codec, a digital signal processor (DSP), a baseband processor, and / or a neural-network processing unit (NPU), etc. Among them, different processing units can be independent devices, or can be integrated in one or more processors.

[0092] The controller can be the nerve center and command center of the electronic device 100. The controller can generate operation control signals according to instruction operation codes and timing signals, and complete the control of fetching and executing instructions.

[0093] The memory in the processor 110 can also be configured to store instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. The memory can save instructions or data that the processor 110 has just used or repeatedly uses. If the processor 110 needs to use the instructions or data again, it can be directly called from the memory. Avoiding repeated access reduces the waiting time of the processor 110, thereby improving the efficiency of the system.

[0094] The USB interface 130 is an interface conforming to the USB standard specification, and can be a Mini USB interface, a Micro USB interface, a USB Type C interface, etc. The USB interface 130 can be used to connect a charger to charge the electronic device 100, or to transmit data between the electronic device 100 and a peripheral device.

[0095] The external memory interface 120 can be used to connect an external memory card, such as a Micro SD card, to expand the storage capacity of the electronic device 100. The external memory card communicates with the processor 110 through the external memory interface 120 to realize the data storage function. For example, music, video, etc. Files are saved in the external memory card.

[0096] The internal memory 121 can be used to store computer executable program codes, which include instructions. The processor 110 performs various functional applications and data processing of the electronic device 100 by running the instructions stored in the internal memory 121. The internal memory 121 can include a program storage area and a data storage area. The program storage area can store an operating system and at least one application program (such as a sound playing function, an image playing function, etc.) required by a function.

[0097] In addition, the internal memory 121 can include a high-speed random access memory, and can also include a non-volatile memory, such as at least one magnetic disk storage device, a flash memory device, a universal flash storage (UFS), etc.

[0098] The charging management module 140 is configured to receive a charging input from a charger. The charger can be a wireless charger or a wired charger. In some embodiments of wired charging, the charging management module 140 can receive the charging input of the wired charger through the USB interface 130.

[0099] The power management module 141 is configured to connect the battery 142 and the charging management module 140 to the processor 110. The power management module 141 receives the input of the battery 142 and / or the charging management module 140 to supply power to the processor 110, the internal memory 121, the external memory, the display screen 194, the camera 193, and the wireless communication module 160, etc.

[0100] In other embodiments, the power management module 141 can also be arranged in the processor 110. In some other embodiments, the power management module 141 and the charging management module 140 can also be arranged in the same device.

[0101] The wireless communication function of the electronic device 100 can be realized through the antenna 1, the antenna 2, the mobile communication module 150, the wireless communication module 160, the modem processor, and the baseband processor, etc.

[0102] The antenna 1 and the antenna 2 are configured to transmit and receive electromagnetic wave signals. Each antenna in the electronic device 100 can be used to cover a single or multiple communication frequency bands. Different antennas can also be multiplexed to improve the utilization of the antennas. For example, the antenna 1 can be multiplexed as a diversity antenna of a wireless local area network. In some other embodiments, the antenna can be used in combination with a tuning switch.

[0103] The mobile communication module 150 can provide a solution for wireless communication including 2G / 3G / 4G / 5G, etc. applied to the electronic device 100. The mobile communication module 150 can include at least one filter, a switch, a power amplifier, a low noise amplifier (LNA), etc. The mobile communication module 150 can receive an electromagnetic wave by the antenna 1, and perform filtering, amplification, etc. on the received electromagnetic wave, and transfer the processed signal to the modem processor for demodulation. The mobile communication module 150 can also amplify a signal modulated by the modem processor, and radiate the signal as an electromagnetic wave through the antenna 1.

[0104] The wireless communication module 160 can provide a solution for wireless communication including wireless local area networks (WLAN) (e.g., wireless fidelity (Wi-Fi) network), Bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), infrared (IR) technology, etc. applied to the electronic device 100. The wireless communication module 160 can be one or more devices integrated with at least one communication processing module. The wireless communication module 160 receives an electromagnetic wave via the antenna 2, performs frequency modulation and filtering on the electromagnetic wave signal, and transmits the processed signal to the processor 110. The wireless communication module 160 can also receive a signal to be transmitted from the processor 110, perform frequency modulation and amplification on the signal, and radiate the signal as an electromagnetic wave through the antenna 2.

[0105] In some embodiments, the antenna 1 and the mobile communication module 150 of the electronic device 100 are coupled, and the antenna 2 and the wireless communication module 160 are coupled, so that the electronic device 100 can communicate with a network and other devices through wireless communication technology.

[0106] The electronic device 100 can implement an audio function through the audio module 170, the speaker 170A, the receiver 170B, the microphone 170C, the earphone interface 170D, the application processor, etc. For example, music playback, recording, etc.

[0107] The audio module 170 is used to convert a digital audio signal into an analog audio signal for output, and is also used to convert an analog audio input into a digital audio signal. The audio module 170 can also be used to encode and decode an audio signal. In some embodiments, the audio module 170 can be disposed in the processor 110, or part of the function modules of the audio module 170 can be disposed in the processor 110.

[0108] The speaker 170A, also called a "loudspeaker", is used to convert an audio electrical signal into a sound signal. The electronic device 100 can listen to music or listen to a hands-free call through the speaker 170A.

[0109] The receiver 170B, also called a "earpiece", is used to convert an audio electrical signal into a sound signal. When the electronic device 100 receives a call or a voice message, the user can listen to the voice by holding the receiver 170B close to the ear.

[0110] The microphone 170C, also called a "microphone", "voice microphone", is used to convert a sound signal into an electrical signal. When making a call or sending a voice message, the user can make a sound by holding the mouth close to the microphone 170C, and input the sound signal into the microphone 170C. The electronic device 100 can be provided with at least one microphone 170C. In other embodiments, the electronic device 100 can be provided with two microphones 170C, in addition to listening to voice messages, noise reduction functions can also be realized. In other embodiments, the electronic device 100 can also be provided with three, four or more microphones 170C, to realize the functions of collecting sound signals, noise reduction, and also to identify the source of the sound, realize the function of directional recording, etc.

[0111] The earphone interface 170D is used to connect a wired earphone. The earphone interface 170D can be a USB interface 130, or a 3.5mm open mobile terminal platform (OMTP) standard interface, a cellular telecommunications industry association of the USA (CTIA) standard interface.

[0112] The pressure sensor 180A is used to sense a pressure signal, and can convert the pressure signal into an electrical signal. In some embodiments, the pressure sensor 180A can be provided on the display screen 194. There are many types of pressure sensors 180A, such as resistance pressure sensors, inductance pressure sensors, and capacitance pressure sensors. The capacitance pressure sensor can include at least two parallel plates made of conductive material. When a force acts on the pressure sensor 180A, the capacitance between the electrodes changes. The electronic device 100 determines the intensity of the pressure according to the change in capacitance. When a touch operation acts on the display screen 194, the electronic device 100 detects the intensity of the touch operation according to the pressure sensor 180A. The electronic device 100 can also calculate the position of the touch according to the detection signal of the pressure sensor 180A.

[0113] Touch sensor 180K, also referred to as "touch panel". Touch sensor 180K can be disposed on display screen 194, and touch sensor 180K and display screen 194 together form a touch screen, also referred to as "touch panel". Touch sensor 180K is used to detect touch operations applied to or near the touch sensor 180K. The touch sensor can pass the detected touch operation to the application processor to determine the touch event type. Visual output related to the touch operation can be provided through display screen 194. In other embodiments, touch sensor 180K can also be disposed on the surface of electronic device 100, which is different from the position where display screen 194 is located.

[0114] Keys 190 include power on key, volume key, and the like. Keys 190 can be mechanical keys. They can also be touch keys. Electronic device 100 can receive key input and generate key signal input related to user settings and function control of electronic device 100.

[0115] Motor 191 can generate vibration prompts. Motor 191 can be used for incoming call vibration prompts, and also for touch vibration feedback.

[0116] Electronic device 100 implements display functions through GPU, display screen 194, and application processor, and the like. GPU is a microprocessor for image processing, connected to display screen 194 and application processor. GPU is used to perform mathematical and geometric calculations for graphics rendering. Processor 110 can include one or more GPUs that execute program instructions to generate or change display information.

[0117] Display screen 194 is used to display images, videos, and the like. In some embodiments, electronic device 100 can include 1 or N display screens 194, N being a positive integer greater than 1.

[0118] Camera 193 is used to capture still images or videos. In some embodiments, electronic device 100 can include 1 or N cameras 193, N being a positive integer greater than 1.

[0119] SIM card interface 195 is used to connect a SIM card. The SIM card can be inserted into or removed from SIM card interface 195 to achieve contact and separation with electronic device 100. Electronic device 100 can support 1 or N SIM card interfaces, N being a positive integer greater than 1.

[0120] The embodiment of the present application does not particularly limit the specific structure of the execution subject of the switching method of the auxiliary input device, as long as the code of the switching method of the auxiliary input device according to the embodiment of the present application can be run to process the switching method of the auxiliary input device according to the embodiment of the present application. For example, the execution subject of the switching method of the auxiliary input device according to the embodiment of the present application can be a functional module capable of calling and executing programs in an electronic device, or a processing device applied to an electronic device, for example, a chip.

[0121] At present, with the increasing and diversifying needs of users, the types of electronic devices used by users are also increasing, for example, users use computers to handle some work matters during working hours, and use tablets to handle entertainment matters during leisure time, and users use mobile phones as portable tools to handle work, life and entertainment matters.

[0122] Of course, the above-mentioned computer, tablet and mobile phone are only part of the electronic devices used by users, and the above-mentioned processing matters of the electronic devices are only an example. In actual application, users can also engage in other matters not listed above through the above-mentioned electronic devices.

[0123] In some scenarios, users need to use two or more electronic devices at the same time.

[0124] As an example, when using a computer, a user also needs to use a tablet at the same time. In order to facilitate operation, the computer can be used as a main screen device, and a communication connection is established between the computer and the tablet. The user can perform relevant operations on the computer through the keyboard and mouse connected to the computer. Through the pre-set keyboard and mouse traversal operation, the user can also perform relevant operations on the tablet through the keyboard and mouse connected to the computer. Of course, when the keyboard and mouse connected to the computer perform operations on the tablet, the pre-set keyboard and mouse back traversal operation can also be used to make the keyboard and mouse connected to the computer return to the computer again to perform operations.

[0125] However, in actual application, compared with a thick notebook computer, a tablet computer is more portable as a portable electronic device. Compared with a mobile phone with a small screen, a tablet computer is more beneficial to handle some work and study matters as a large-screen electronic device. Therefore, more and more people choose to use a tablet computer to handle some matters.

[0126] Currently, in order to facilitate users to carry the tablet computer to handle learning and work matters, a light keyboard and mouse are also provided for the tablet computer. Therefore, users tend to use the tablet computer and the light keyboard and mouse of the user. However, the processing capability of the tablet computer is not as good as that of the computer or the notebook computer. Therefore, in some application scenarios, the user needs to use the tablet computer as a main screen device, and uses the keyboard and mouse connected (wired or wireless) to the tablet computer to perform relevant operations on the tablet computer; when the computer or the notebook computer is needed to assist in handling matters, the keyboard and mouse connected to the tablet computer are transmitted to the computer (or the notebook computer) through the pre-set keyboard and mouse crossover operation, so as to operate on the computer (or the notebook computer), so that the computer assists in handling the relevant processing matters.

[0127] Referring to Figure 2 An application scenario of a switching method of an auxiliary input device provided by the embodiments of the present application.

[0128] In the application scenario, the tablet computer is taken as an example of the first electronic device, the tablet computer is taken as a main device and a main screen, the computer is taken as an example of the second electronic device, and the computer is taken as an auxiliary device and an auxiliary screen; the tablet computer and the computer have a communication connection, which can be a wireless connection or a wired connection.

[0129] As an example, the computer and the tablet computer are in the same wireless network environment, that is, the computer and the tablet computer are connected to the same wireless network.

[0130] As another example, when the tablet computer is inserted with a SIM card, the tablet computer can provide a wireless hotspot, and the computer is connected to the wireless hotspot of the tablet computer through a wireless module.

[0131] As another example, the tablet computer and the computer log in the same account, or the tablet computer and the computer belong to the electronic devices under the same account.

[0132] The embodiments of the present application do not limit the connection mode between the computer and the tablet computer.

[0133] In the scenario, the tablet computer is taken as a main device and a main screen, and is connected with a keyboard and a mouse. The keyboard and the mouse can be connected to the tablet computer through a wired or wireless mode. Of course, the tablet computer can be connected only with the mouse or connected with other auxiliary input devices.

[0134] As an example, there is a Bluetooth connection between the Bluetooth module on the tablet computer and the Bluetooth module on the keyboard and mouse.

[0135] Of course, the computer can also be connected with a keyboard and a mouse, in order to distinguish, the keyboard on one side of the tablet computer can be recorded as a first keyboard, and the mouse on one side of the tablet computer can be recorded as a first mouse. The keyboard on one side of the computer can be recorded as a second keyboard, and the mouse on one side of the computer can be recorded as a second mouse.

[0136] In the embodiment of the application, the operating system in the first electronic device can be an android system, of course, it can also be other operating systems arranged in a portable mobile electronic device, for example, an IOS operating system, and the operating system in the first electronic device is usually an operating system for a touch screen electronic device. Of course, the android system in the embodiment of the application is not limited to the android system, and can also be other operating systems improved on the basis of the android system, or operating systems based on the Linux kernel.

[0137] The operating system in the second electronic device can be a windows system, or an operating system improved on the basis of the windows system.

[0138] The user can perform some work, life, entertainment and other related matters on the tablet computer through the keyboard and mouse; when the computer is needed to assist the tablet computer to realize a certain function, the user triggers the operation of the keyboard and mouse on the computer to take effect through the preset keyboard and mouse traversal operation; of course, the user can also trigger the operation of the keyboard and mouse on the computer to restore to the tablet computer through the preset keyboard and mouse back operation.

[0139] In order to realize Figure 2 the application scenarios shown in the figure, the embodiment of the application provides a switching method of an auxiliary input device. In the method, the connection relationship among the tablet computer, the computer, the keyboard and the mouse refers to the scene schematic diagram shown in Figure 2 the figure, and the method can refer to the flow schematic diagram shown in Figure 3 the figure.

[0140] It should be noted that, in order to distinguish the input events of the mouse on the side of the tablet computer, the first, second, third, fourth and the like are used for distinction. That is, the first mouse input event, the second mouse input event (not indicating the input event of the second mouse), the third mouse input event and the fourth mouse input event in the embodiment of the application are all input events of the mouse on the side of the tablet computer.

[0141] S101, the tablet computer monitors the first mouse input event.

[0142] In the embodiment of the application, the tablet computer can always monitor input events, such as touch screen input events, mouse input events and keyboard input events.

[0143] The touch screen input event can be an event input by a user through a touch screen, for example, a gesture operation of the user on the touch screen, and the like.

[0144] The mouse input event can be an event input by a mouse, for example, a moving event of the mouse, a clicking event of the mouse, and the like.

[0145] The keyboard input event can be an event input by a keyboard, for example, a striking event of a physical key on the keyboard, and the like.

[0146] In the embodiment of the present application, the first mouse input event can be an event input by a user through a mouse to the tablet computer. For example, the moving event or the clicking event of the mouse listed above.

[0147] S102, after the tablet computer monitors the first mouse input event, the tablet computer feeds back the first mouse input event to a screen of the tablet computer; and the screen of the tablet computer generates a screen operation on the tablet computer based on the first mouse input event.

[0148] S103, the tablet computer determines that the first mouse input event is a first keyboard-mouse crossing event set in advance, and acquires a computer associated with the first keyboard-mouse crossing event matched with the first mouse input event.

[0149] In the embodiment of the present application, the keyboard-mouse crossing event can be an event set in advance for triggering an operation (input event) of a keyboard and mouse connected with the tablet computer to cross to a computer.

[0150] As an example, the crossing event can be an event that a mouse cursor moves out of an edge of a screen of the tablet computer. The edge can be set in advance, for example, an event that the mouse cursor moves out of the edge of the screen from a right side of the screen of the tablet computer can be set in advance as the crossing event. Of course, an event that the mouse cursor moves out of the edge of the screen from a left side, an upper side or a lower side of the screen of the tablet computer can also be set.

[0151] It should be noted that in actual application, due to the setting of the tablet computer, after the mouse cursor on the tablet computer moves to the edge of the screen, the mouse cursor can not actually move out of the screen, but continuously display at the edge of the screen.

[0152] Therefore, the keyboard-mouse crossing event in the embodiment of the present application is actually an event that a mouse cursor displayed on a display screen moves to an edge of a first side of the display screen, and the mouse continues to move to the first side. That is, the keyboard-mouse crossing event in the embodiment of the present application is an event that the mouse cursor moves out of the edge of the one side of the display screen if the mouse cursor strictly follows the mouse moving operation of the user.

[0153] In addition, since the computer also has a display screen, in order to distinguish, the display screen on the side of the tablet computer is recorded as a first display screen, and the mouse cursor on the first display screen is recorded as a first mouse cursor. The display screen on the side of the computer is recorded as a second display screen, and the mouse cursor on the second display screen is recorded as a second mouse cursor.

[0154] As another example, the tablet computer can establish the above-mentioned connection with multiple computers. Figure 2 The connection in the scene shown in the figure is that one tablet computer is the main computer and the main screen, and multiple computers are auxiliary computers and auxiliary screens. For details, refer to the scene schematic diagram shown in the figure. Figure 4

[0155] In this case, a corresponding keyboard and mouse traversal event can be set for each computer. For example, the first keyboard and mouse traversal event set for the first computer connected with the tablet computer is that the mouse cursor moves out of the screen edge from the left side of the tablet computer screen; the second keyboard and mouse traversal event set for the second computer connected with the tablet computer is that the mouse cursor moves out of the screen edge from the right side of the tablet computer screen; the third keyboard and mouse traversal event set for the third computer connected with the tablet computer is that the mouse cursor moves out of the screen edge from the upper side of the tablet computer screen; and the fourth keyboard and mouse traversal event set for the fourth computer connected with the tablet computer is that the mouse cursor moves out of the screen edge from the lower side of the tablet computer screen.

[0156] Of course, in actual application, one or more computers can be connected as auxiliary devices and auxiliary screens according to actual conditions; and one or more of the connected computers can be respectively set with keyboard and mouse traversal events.

[0157] In actual application, the keyboard and mouse traversal event corresponding to each computer can also be set by the user on the tablet computer for each computer separately, and the embodiments of the present application do not limit this.

[0158] As described above, when multiple computers are connected with the tablet computer, and the multiple computers are all set with different keyboard and mouse traversal events, if the first mouse input event is the pre-set keyboard and mouse traversal event, the computer associated with the keyboard and mouse traversal event matched with the first mouse input event needs to be obtained. The embodiments of the present application take the computer associated with the keyboard and mouse traversal event matched with the first mouse input event as the first computer as an example, that is, the first computer is one embodiment of the second electronic device.

[0159] As another embodiment of the present application, other input events can also be set as keyboard and mouse traversal events.

[0160] ​For example, some operation(s) on the keyboard can also be set as the key-mouse crossing event; of course, some gesture(s) on the touch screen can also be set as the key-mouse crossing event, and the embodiments of the present application do not limit this. The embodiments of the present application will take the operation of moving the mouse cursor on the side of the tablet computer out of the edge of the display screen on the side of the tablet computer as an example to describe the pre-set key-mouse crossing event.

[0161] S104, the tablet computer sends the key-mouse crossing information to the first computer.

[0162] S105, the first computer receives the key-mouse crossing information and configures the key-mouse information on the side of the first computer.

[0163] As an embodiment of the present application, the first computer configuring the key-mouse information on the side of the first computer can be: intercepting the keyboard input event of the keyboard connected to the first computer and the mouse input event of the mouse connected to the first computer; and taking the keyboard input event and the mouse input event received from the tablet computer as the virtual input event of the first computer.

[0164] As another embodiment of the present application, the first computer configuring the key-mouse information on the side of the first computer can also be: sending any keyboard input event of the keyboard connected on the side of the first computer and any mouse input event of the mouse connected on the side of the first computer to the tablet computer as the key-mouse crossing information. That is, after receiving any keyboard input event of the connected keyboard and any mouse input event of the connected mouse, the keyboard and the mouse on the side of the first computer will regain the control right of the first computer.

[0165] As an example, after S105, the computer receives a fifth input event, which is the input event of the keyboard on the side of the computer or the input event of the mouse on the side of the computer.

[0166] In response to the fifth input event, the computer sends the key-mouse crossing information to the tablet computer.

[0167] In actual application, the specific way can be set according to actual situation, and the embodiments of the present application do not limit this.

[0168] After steps S101 to S105, the crossing preparation of the keyboard input event and the mouse input event on the tablet computer has been completed. The following will take steps S106 to S108 as an example to describe how the tablet computer transmits the received keyboard input event or mouse input event to the first computer to control the first computer through the keyboard and the mouse on the side of the tablet computer.

[0169] S106, the tablet computer monitors the second mouse input event.

[0170] In the embodiment of the present application, since the tablet computer has completed the preparation of the input operation of the keyboard and the mouse to cross to the first computer, after the tablet computer monitors the second mouse input event, the tablet computer no longer feeds back the second mouse input event to the screen of the tablet computer, and the screen of the tablet computer naturally does not generate the screen operation corresponding to the second mouse input event.

[0171] In step S107, the tablet computer sends the second mouse input event to the first computer.

[0172] In step S108, the first computer executes the screen operation corresponding to the second input event according to the received second mouse input event.

[0173] The first computer has received the keyboard and mouse cross information in advance, so after the first computer receives the second mouse input event from the tablet computer, the second mouse input event is fed back to the screen of the first computer to take effect.

[0174] In the embodiment of the present application, steps S106 to S108 take the sending of the mouse input event to the first computer as an example, and in actual application, the keyboard input event monitored by the tablet computer also needs to be transmitted to the first computer to take effect on the first computer.

[0175] Of course, in actual application, after the keyboard input event and the mouse input event of the tablet computer are sent to the computer and take effect on the computer, the keyboard input event and the mouse input event may also need to be restored to the tablet computer subsequently. For details, refer to the flowchart shown in Figure 5 The flowchart is implemented on the basis of the flowchart shown in Figure 3 .

[0176] In step S201, the tablet computer monitors a third mouse input event.

[0177] In step S202, the tablet computer sends the third mouse input event to the first computer.

[0178] In step S203, the first computer determines that the received third mouse input event is a keyboard and mouse back cross event.

[0179] In the embodiment of the present application, the keyboard and mouse back cross event can be an event that is set in advance to trigger the input operation of the keyboard and the mouse connected with the tablet computer to be restored to control the tablet computer; that is, an event that sets the keyboard and the mouse connected with the tablet computer to take effect on the first computer.

[0180] As an example, the key-mouse penetration event can be an event that a mouse cursor on the first computer moves out of an edge of a screen of the computer. The edge can also be preset, for example, can be an event that the mouse cursor moves out of an edge of a screen of any side of the computer, or an event that the mouse cursor moves out of an edge of a screen of a certain side (for example, upper side, lower side, left side or right side) of the computer.

[0181] In actual application, the key-mouse penetration event can also be other events, for example, the input events of the keyboard connected with the first computer and the input events of the mouse connected with the first computer listed above.

[0182] In order to distinguish, the key-mouse penetration event from the tablet computer to the first computer is an event that a mouse cursor moves out of a first side of a screen of the tablet computer, and the key-mouse penetration event from the first computer to the tablet computer is an event that a mouse cursor moves out of a second side of a screen of the computer. Of course, if there is a second computer (third electronic device), the key-mouse penetration event from the tablet computer to the second computer is an event that a mouse cursor moves out of a third side of a screen of the computer, the first side and the second side can be opposite, and the first side and the third side are different.

[0183] In order to obtain better user experience, the screen of the computer can be used as an extended screen of the tablet computer in the embodiments of the present application. That is, the first side and the second side are opposite sides.

[0184] As an example of the first side and the second side, the key-mouse penetration event from the tablet computer to the computer can be an event that a mouse cursor moves out of a right edge of a screen of the tablet computer, and when the mouse cursor moves out of the right side of the screen of the tablet computer, the left side of the screen of the computer will display the mouse cursor; that is, it is equivalent to that the mouse cursor moves from the right side of the screen of the tablet computer to the left side of the screen of the computer. Of course, the vertical coordinate of the mouse cursor after penetrating to the computer can be calculated based on the difference between the parameters of the display screen of the tablet computer and the parameters of the display screen of the computer, and the vertical coordinate of the mouse cursor on the tablet computer before penetration.

[0185] Correspondingly, the key-mouse penetration event from the computer to the tablet computer can be an event that a mouse cursor moves out of a left edge of a screen of the computer, and when the mouse cursor moves out of the left side of the screen of the computer, the right side of the screen of the tablet computer will display the mouse cursor; that is, it is equivalent to that the mouse cursor moves from the left side of the screen of the computer to the right side of the screen of the tablet computer. Of course, the vertical coordinate of the mouse cursor after penetrating from the computer to the tablet computer can be calculated based on the difference between the parameters of the display screen of the tablet computer and the parameters of the display screen of the computer, and the vertical coordinate of the mouse cursor on the computer before penetration.

[0186] In this way, the screen on the computer is similar to the extended screen of the tablet computer, and the user has a better experience, and can switch between the screens of the tablet computer and the computer through the mouse operation.

[0187] Of course, the first, second, and the like in the embodiments of the present application are only used for differentiation, and the events (or other data information) related to the added computer can be added with a sequential number in front to distinguish them, and the present application will not be exemplified one by one.

[0188] S204, in the case that the first computer determines that the received third mouse input event is a keyboard and mouse back-through event, the keyboard and mouse back-through information is sent to the tablet computer.

[0189] S205, the tablet computer receives the keyboard and mouse back-through information, and configures the keyboard and mouse information of the tablet computer.

[0190] For example, the configuration of the keyboard and mouse information of the tablet computer can be that the input operation of the keyboard and mouse connected with the tablet computer is no longer sent to the first computer.

[0191] After steps S201 to S205, the preparation of the keyboard input event and the mouse input event on the tablet computer has been completed. That is, the keyboard input event and the mouse input event on the tablet computer are effective to the tablet computer, and no longer effective to the first computer.

[0192] S206, the tablet computer monitors the fourth mouse input event, wherein the fourth mouse input event is not a keyboard and mouse through event.

[0193] S207, the tablet computer performs a screen operation corresponding to the fourth input event based on the fourth input event.

[0194] Of course, steps S206 and S207 in the embodiments of the present application only take the mouse input event as an example, and in actual application, the keyboard input event monitored by the tablet computer is no longer transmitted to the first computer, but is effective on the tablet computer.

[0195] As another embodiment of the present application, if the tablet computer is also connected (wirelessly or by wire) with a second computer (third electronic device), the process of the keyboard and mouse through and back through between the tablet computer side and the second computer can refer to the description of the keyboard and mouse through and back through between the tablet computer and the first computer, which will be described briefly as follows:

[0196] The tablet computer monitors the sixth input event, which is the input event of the mouse connected with the tablet computer;

[0197] The tablet determines that the sixth input event is a second key-mouse crossing event, the second key-mouse crossing event being an event in which a mouse cursor displayed on a display screen of the tablet moves out of the display screen from an edge of a third side of the display screen to the third side;

[0198] The tablet monitors a seventh input event, the seventh input event being an input event of a mouse connected to the tablet;

[0199] The tablet sends the seventh input event to the second computer, wherein the seventh input event is used to instruct the second computer to perform a screen operation corresponding to the seventh input event based on the seventh input event.

[0200] In order to have a clearer understanding of the above-mentioned embodiments, first, modules in the tablet and modules in the computer in the switching method of the auxiliary input device provided by the embodiments of the present application are introduced.

[0201] In the embodiments of the present application, a FWK Input module is arranged in the tablet, wherein the FWK Input module is a module of the original android system and is used to monitor input events, the input events can be mouse input events, keyboard input events or touch screen input events, and the input events can take effect on the screen of the tablet.

[0202] As an embodiment of the present application, the FWK Input module of the original android system can be improved, and an interception identifier is arranged in the FWK Input module, when the interception identifier is 0 (an example of the second character), the input events monitored by the FWK Input module can take effect on the screen of the tablet; that is, when the interception identifier is the second character, the tablet performs a screen operation corresponding to the input events of the auxiliary input device (keyboard and mouse) connected to the tablet and does not send the input events to the computer connected to the tablet. When the interception identifier is 1 (an example of the first character), the input events monitored by the FWK Input module do not take effect on the screen of the tablet. That is, when the interception identifier is the first character, the tablet does not perform a screen operation corresponding to the input events of the auxiliary input device connected to the tablet, but sends the input events to the connected computer.

[0203] Of course, the interception identifier being "0" or "1" is only an example, and other ways or other characters can be used as the interception identifier in actual applications.

[0204] The embodiments of the present application do not limit the touch screen input events. The touch screen input events can always take effect without being affected by the interception identifier, or can be related to the specific characters of the interception identifier like the keyboard input events and the mouse input events.

[0205] The embodiment of the present application can also set a virtual input module in the tablet computer, and the virtual input module is used to determine whether the mouse input event monitored by the FWK Input module is a keyboard and mouse crossing event.

[0206] As another embodiment of the present application, when the tablet computer is connected with multiple computers, the virtual input module is used to store the keyboard and mouse crossing events corresponding to the multiple computers respectively. That is, the virtual input module is used to determine the computer associated with the keyboard and mouse crossing event matched with the mouse input event when the mouse input event currently received matches the keyboard and mouse crossing event.

[0207] The tablet computer is also provided with a Link module, and the Link module is used to communicate with the computer.

[0208] The computer of the embodiment of the present application is also provided with a Link module, and the Link module is used to communicate with the tablet computer.

[0209] The computer is also provided with an analysis module, and the analysis module is used to analyze the mouse input event and the keyboard input event of the tablet computer received by the computer.

[0210] The computer is also provided with a virtual drive, and the virtual drive is used to inject the keyboard operation and the mouse operation from the tablet computer into the windows system of the computer as the drive of the keyboard and the mouse of the tablet computer.

[0211] Of course, the computer can also have a keyboard and a mouse connected with the computer, and an actual drive corresponding to the keyboard and the mouse.

[0212] It should be noted that the functions of the modules in the above-mentioned one electronic device are only used for example, and in actual application, the functions of two or more modules in the same electronic device can be integrated in one module, or one module can be split into two or more modules to realize the same function. The division of the modules and the functions realized by each module in the embodiment of the present application are not limited.

[0213] The timing diagram of the switching method of the auxiliary input device provided by the embodiment of the present application will be described in detail below.

[0214] Referring to Figure 6 the timing diagram and Figure 3 the flowchart.

[0215] In the embodiment of the present application, after the tablet computer is powered on, the interception identifier in the FWK Input module is initialized to 0, so that the operation of the keyboard and the mouse on the tablet computer side takes effect on the tablet computer.

[0216] S301, the FWK Input module in the tablet computer monitors a first mouse input event.

[0217] S302, the FWK Input module in the tablet computer sends the first mouse input event to the screen of the tablet computer to take effect on the screen of the tablet computer.

[0218] After taking effect on the screen of the tablet computer, the screen of the tablet computer will generate a screen operation corresponding to the first mouse input event.

[0219] For example, mouse movement operation, mouse click on a certain virtual button displayed on the screen operation, etc.

[0220] S303, the FWK Input module in the tablet computer sends the first mouse input event to the virtual input module.

[0221] S304, the virtual input module in the tablet computer determines that the first mouse input event is a keyboard and mouse crossing event.

[0222] In the embodiments of the present application, the mouse movement event in the computer usually includes two parameters: the coordinate of the mouse cursor (before the mouse movement event takes effect) and the displacement of the mouse. The computer generates a mouse displacement event on the screen according to the coordinate of the mouse cursor (before the mouse movement event takes effect) and the displacement of the mouse. It can also be understood that the coordinate before the mouse movement event takes effect is the starting point of the movement of the mouse cursor, and the displacement of the mouse is the direction and distance of the movement of the mouse cursor from the starting point. Of course, the coordinate of the final position of the mouse cursor can be calculated according to the coordinate before the mouse movement event takes effect and the displacement of the mouse.

[0223] However, the screen of the tablet computer is usually a touch screen, and the system is an android system or a system improved based on the android system. The movement event of the mouse in the tablet computer includes the coordinate of the mouse cursor (the coordinate after the mouse movement event takes effect) or multiple coordinates of the mouse cursor changing over time. Therefore, it is not possible to determine whether the mouse cursor moves out of the edge of the screen by the parameters in the mouse movement event as in the computer.

[0224] For example, multiple coordinates of the mouse cursor in a movement event of the mouse, for example, multiple coordinates all carry a timestamp, and the mouse cursor moves according to the coordinates corresponding to the timestamp to generate a movement event of the mouse cursor on the screen.

[0225] In theory, the multiple coordinates (or two coordinates) in a mouse movement event in the tablet computer can determine the moving direction of the mouse or the mouse cursor, so that whether the mouse cursor moves out of the edge of the screen can be determined according to the coordinates of the mouse cursor in a mouse event.

[0226] However, the coordinate of the mouse cursor in the mouse event of the tablet computer is the real coordinate of the mouse cursor on the screen of the tablet computer. Therefore, when the mouse cursor on the tablet computer moves to the edge of the screen, the parameter in the mouse moving event is the coordinate of the edge even if the mouse continues to move beyond the edge. Therefore, the tablet computer cannot determine whether the mouse moves beyond the edge of the screen according to the mouse moving event. Of course, the tablet computer cannot determine whether the current mouse input event is the key-mouse crossing event according to the mouse moving event when the key-mouse crossing event is related to the mouse cursor moving beyond the edge of the screen.

[0227] To solve the problem, the mouse connected to the tablet computer can report the moving direction and the moving distance of the mouse according to an embodiment of the present application. That is, a parameter associated with the displacement information of the mouse is added in the mouse moving event.

[0228] In this way, the parameters in the mouse input event are unified for the tablet computer and the computer, and the parameters include the coordinate of the mouse cursor and the displacement of the mouse. The actual displacement of the mouse can be converted into the screen displacement of the mouse cursor.

[0229] For example, the tablet computer obtains the first coordinate of the mouse cursor in the first mouse input event. The first mouse input event includes a plurality of first coordinates of the mouse cursor. The tablet computer determines that the first coordinate is located at the edge of the first side of the first display screen (the display screen of the tablet computer). The tablet computer determines the first time when the mouse cursor is located at the edge of the first side of the first display screen for the first time in the first mouse input event. The tablet computer determines that the displacement information of the mouse (the mouse on the side of the tablet computer) after the first time indicates that the mouse moves to the first side. In this case, it can be determined that the first mouse input event is the key-mouse crossing event.

[0230] Of course, in actual application, each mouse moving event on the side of the tablet computer can only include the coordinate of the mouse cursor after moving. In this case, the displacement information of the mouse between the start time and the end time of each mouse moving event is obtained as the information associated with each mouse moving event. If the coordinate of the mouse cursor after moving in the last mouse moving event and the coordinate of the mouse cursor after moving in the current mouse moving event are both located at the edge of the first side of the display screen, and the displacement information associated with the current mouse moving event indicates that the mouse moves to the first side, it can be determined that the current mouse moving event is the key-mouse crossing event. The first side can be the left side, the right side, the upper side or the lower side, which is set in advance.

[0231] Of course, in actual application, other implementation manners of determining whether it is a key-mouse crossing event can exist, and the present application does not list them one by one.

[0232] S305, in the case that the virtual input module in the tablet computer determines that the first mouse input event is a key-mouse crossing event, the virtual input module sends an interception identification switching instruction to the FWK Input module.

[0233] S306, the FWK Input module in the tablet computer receives the interception identification switching instruction, and sets the interception identification as 1.

[0234] S307, in the case that the virtual input module in the tablet computer determines that the first mouse input event is a key-mouse crossing event, the virtual input module sends a key-mouse crossing instruction (which can also be recorded as key-mouse crossing information) to the Link module.

[0235] S308, the Link module in the tablet computer sends the key-mouse crossing instruction (key-mouse crossing information) to the Link module in the computer.

[0236] S309, the Link module in the computer sends the received key-mouse crossing instruction (key-mouse crossing information) to the analysis module.

[0237] S310, the analysis module in the computer obtains the initial coordinate of the mouse of the computer from the windows system of the computer.

[0238] The initial coordinate can be the coordinate of the position where the mouse cursor of the computer is currently located, can also be the coordinate of the position which is set in advance in the center of the screen of the computer, and of course, can also be any coordinate in the screen of the computer which is set in advance.

[0239] In actual application, the analysis module can also obtain the coordinate of the position where the mouse cursor of the computer is located from other modules, for example, the coordinate of the position where the mouse cursor is located can also be obtained from the mouse driver of the computer. The present application embodiment does not limit this.

[0240] As described above, in order to obtain better user experience, the present application embodiment can take the screen of the computer as an extended screen of the tablet computer. Therefore, the determination manner of the initial coordinate in the present application embodiment also includes:

[0241] The key-mouse crossing information in steps S307 to S309 can include the vertical coordinate (in the case of moving out of the left and right sides) or the horizontal coordinate (in the case of moving out of the upper and lower sides) in the first coordinate of the first mouse input event which is located at the edge of the screen of the tablet computer.

[0242] After the resolution module receives the key-mouse traversal information in step S310, the vertical coordinate (or horizontal coordinate) in the first coordinate located at the edge of the screen of the tablet computer in the first mouse input event is converted into the vertical coordinate (or horizontal coordinate) on the display screen of the computer based on the difference between the parameters of the display screen of the tablet computer and the parameters of the display screen of the computer. The initial coordinate can be composed of the current converted vertical coordinate (or horizontal coordinate) and the horizontal coordinate (or vertical coordinate) of the edge of the display screen of the computer (the edge of the side when traversing).

[0243] After the execution of step S310, the subsequent keyboard input operation and mouse input operation received by the tablet computer will be traversed to the computer and take effect on the computer.

[0244] S311, the FWK Input module in the tablet computer detects the second mouse input event.

[0245] In the present application, when the interception identifier in the FWK Input module is 1, the monitored mouse input event and keyboard input event will not be sent to the screen of the tablet computer, and therefore, the screen of the tablet computer will not take effect on the monitored second mouse input event.

[0246] S312, the FWK Input module in the tablet computer sends the second mouse input event to the virtualinput module.

[0247] S313, the virtualinput module in the tablet computer determines that the second mouse input event is a mouse movement event.

[0248] S314, the virtualinput module in the tablet computer obtains the mouse displacement information associated with the second mouse input event from the FWK Input module.

[0249] S315, the FWK Input module sends the mouse displacement information to the link module in the tablet computer.

[0250] The mouse displacement information associated with the second mouse input event is the displacement information of the mouse (the mouse on the tablet computer side) between the start time and the end time of the second mouse input event.

[0251] It should be noted that the mouse displacement information can be obtained by the mouse hardware according to the sensor provided on the mouse hardware, and the mouse hardware sends the mouse displacement information to the mouse driver, and the mouse driver sends the mouse displacement information to the FWK Input module. Of course, in actual application, the mouse driver can send the mouse displacement information to the FWK Input module. Therefore, the virtualinput module can obtain the mouse displacement information from the FWK Input module.

[0252] Of course, in actual application, in order to make the mouse movement response of the computer side more rapid, the mouse displacement information associated with the second mouse input event can be multiple displacement information of the mouse collected at preset time intervals between the starting time and the ending time of the second mouse input event. Naturally, the FWK Input module can send the displacement information to the link module of the tablet computer after obtaining one of the multiple displacement information, so as to send the displacement information to the computer side to make the displacement information corresponding to the mouse cursor movement effective on the screen of the computer side.

[0253] S316, the link module in the tablet computer sends the mouse displacement information to the link module in the computer.

[0254] S317, the link module in the computer sends the mouse displacement information to the analysis module.

[0255] S318, the analysis module in the computer generates a virtual mouse input event on the computer side according to the initial coordinates of the mouse cursor in the computer and the mouse displacement information obtained in advance.

[0256] It should be noted that, in actual application, due to the differences in size and resolution of the display screens of the tablet computer and the computer, when the analysis module generates the mouse input operation on the computer side according to the initial coordinates and the mouse displacement information obtained in advance, the differences in size and resolution of the display screens of the tablet computer and the computer also need to be considered.

[0257] Of course, in actual application, the analysis module in the computer can also obtain the initial coordinates of the mouse cursor in the computer after step S317. That is, step S310 can be moved between steps S317 and S318.

[0258] S319, the analysis module in the computer sends the virtual mouse input event to the virtual drive.

[0259] S320, the virtual drive in the computer generates mouse cursor operation (movement) in the computer based on the virtual mouse input event.

[0260] S321, the virtual drive in the computer injects the mouse cursor operation into the windows system.

[0261] S322, the window system of the computer displays the mouse cursor movement through the screen.

[0262] It should be noted that the above embodiment takes the mouse movement event as an example, in actual application, the mouse click event and the keyboard input event can also be injected into the window of the computer in the order of the FWK Input module, the virtual input module, the link module of the tablet computer, the link module of the computer, the analysis module, and the virtual driver in the above embodiment. Only, the mouse click event and the keyboard input event do not involve the movement of the mouse cursor, so they are relatively simpler. The embodiments of the present application will not be exemplified one by one.

[0263] As described above, in actual application, after the keyboard and mouse on the tablet computer side pass through to the computer side to control the computer, the response operation of the keyboard and mouse can also pass back to the tablet computer side to control the tablet computer again.

[0264] Referring to Figure 7 The timing diagram corresponds to the flowchart shown in Figure 5 The timing diagram is based on the timing diagram shown in Figure 7 Figure 6

[0265] S401, the FWK Input module in the tablet computer monitors a third mouse input event.

[0266] In the present application, when the interception identifier in the FWK Input module is 1, the monitored mouse input event and keyboard input event will not be sent to the screen, therefore, the screen of the tablet computer will not take effect on the monitored third mouse input event.

[0267] S402, the FWK Input module in the tablet computer sends the third mouse input event to the virtual input module.

[0268] S403, the virtual input module in the tablet computer determines that the third mouse input event is a mouse movement event.

[0269] S404, the virtual input module in the tablet computer obtains mouse displacement information associated with the third mouse input event from the FWK Input module.

[0270] It should be noted that the third mouse input event and the second mouse input event as mouse input events can also be associated with displacement information, and the displacement information associated with the third mouse input event is the displacement information of the tablet computer between the start time and the end time of the third mouse input event. Exemplified one by one, can refer to the description in the embodiment in which the second mouse input event passes through to the computer side to take effect.

[0271] ​​S405, the FWK Input module in the tablet computer sends the mouse displacement information as a third mouse input event to the link module in the tablet computer.

[0272] S406, the link module in the tablet computer sends the mouse displacement information to the link module in the computer.

[0273] S407, the link module in the computer sends the mouse displacement information to the parsing module.

[0274] S408, the parsing module in the computer obtains the current coordinate of the mouse cursor on the screen of the computer from the windows.

[0275] S409, the parsing module in the computer generates a virtual mouse input operation on the computer side based on the current coordinate and the mouse displacement information.

[0276] S410, the parsing module in the computer determines that the virtual mouse input operation is a keyboard and mouse back-through event.

[0277] In the embodiments of the present application, as described above, the mouse input event on the computer side contains the starting coordinate of the mouse cursor and the displacement information of the mouse, so the computer can obtain the coordinate (denoted as the second coordinate) of the mouse cursor on the display screen of the computer before the displacement information (denoted as the third displacement information) associated with the third mouse input event is received; the computer obtains the predicted coordinate of the mouse cursor displayed on the screen of the computer based on the second coordinate and the third displacement information; and the computer determines that the predicted coordinate is located outside the edge of the second side of the display screen of the computer, which indicates that the current virtual mouse input operation is a keyboard and mouse back-through event.

[0278] S411, the parsing module in the computer sends a keyboard and mouse back-through instruction to the link module in the computer.

[0279] S412, the link module in the computer sends the keyboard and mouse back-through instruction to the link module in the tablet computer.

[0280] S413, the link module in the tablet computer sends the keyboard and mouse back-through instruction to the virtual input module.

[0281] S414, the virtual input module in the tablet computer sends an interception identification switching instruction to the FWK Input module.

[0282] S415, the FWK Input module in the tablet computer sets the interception identification to 0.

[0283] After S415, the keyboard and mouse connected to the tablet computer will control the tablet computer again, and no longer control the computer connected to the tablet computer.

[0284] S416, the FWK Input module in the tablet computer monitors a fourth mouse input event.

[0285] S417, the FWK Input module in the tablet computer sends the fourth mouse input event to the screen to generate corresponding operations on the screen when the interception identifier is set to 0.

[0286] S418, the FWK Input module in the tablet computer sends the fourth mouse input event to the virtualinput module to determine whether it is a keyboard and mouse crossing event when the interception identifier is set to 0.

[0287] S419, the virtualinput module in the tablet computer determines that the fourth mouse input event is not a keyboard and mouse crossing event.

[0288] Of course, steps S416 to S419 take the mouse input event as an example, and in actual application, after step S415, the keyboard input operation and mouse click operation received by the tablet computer are effective on the screen of the tablet computer, and not effective on the screen of the computer. The embodiments of the present application realize the flowcharts shown in Figure 6 and Figure 7 in the timing diagram. Figure 3 and Figure 5 However, in actual application, the flowcharts shown in Figure 3 and Figure 5 may also be realized by other specific implementation manners, and the embodiments of the present application do not limit the specific implementation of the flowcharts shown in Figure 3 and Figure 5 .

[0289] It should be understood that the size of the serial number of each step in the above embodiments does not mean the order of execution, and the execution order of each process should be determined according to its function and inherent logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.

[0290] The embodiments of the present application also provide a computer readable storage medium, which stores a computer program, and the computer program is executed by a processor to realize the steps in each method embodiment described above.

[0291] The embodiments of the present application also provide a computer program product, which, when running on an electronic device, enables the electronic device to realize the steps in each method embodiment described above.

[0292] The integrated unit, if implemented in the form of a software function unit and sold or used as an independent product, can be stored in a computer readable storage medium. Based on such understanding, all or part of the processes in the above-mentioned embodiment methods can be completed by a computer program instructing related hardware, and the computer program can be stored in a computer readable storage medium. The computer program can be executed by a processor to implement the steps of each method embodiment. The computer program includes computer program code, which can be in the form of source code, object code, executable files, or some intermediate forms. The computer readable medium can at least include any entity or device capable of carrying the computer program code to the first device, recording medium, computer memory, read-only memory (ROM), random access memory (RAM), electrical carrier signal, telecommunication signal, and software distribution medium. For example, U disk, mobile hard disk, magnetic disk or optical disk, etc. In some jurisdictions, according to legislation and patent practice, the computer readable medium can not be an electrical carrier signal and a telecommunication signal.

[0293] The embodiment of the present application also provides a chip system, which comprises a processor and a memory. The processor is coupled with the memory, and the processor executes a computer program stored in the memory to implement the steps of any method embodiment of the present application. The chip system can be a single chip or a chip module composed of multiple chips.

[0294] In the above embodiments, the description of each embodiment has its own focus, and the parts not described or recorded in detail in a certain embodiment can be referred to the related description of other embodiments.

[0295] Those skilled in the art can appreciate that the units and method steps of the examples described in combination with the embodiments disclosed herein can be implemented in electronic hardware or a combination of computer software and electronic hardware. Whether the functions are implemented in hardware or software depends on the specific application and design constraints of the technical solution. The skilled person can use different methods to implement the described functions for each specific application, but such implementation should not be considered beyond the scope of the present application.

[0296] The above embodiments are only used to illustrate the technical solutions of the present application, but not limit them. Although the present application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that the technical solutions recorded in the foregoing embodiments can be modified, or some technical features can be replaced by equivalents; and these modifications or replacements do not make the essence of the corresponding technical solutions deviate from the spirit and scope of the technical solutions of the embodiments of the present application, and should be included in the protection scope of the present application.

Claims

1. A switching method of an auxiliary input device, characterized by, The auxiliary input device includes a first mouse, the auxiliary input device is in communication connection with the first electronic device, the first electronic device and the second electronic device are in communication connection, the operating system of the first electronic device is an android system, and the operating system of the second electronic device is a windows system, and the method comprises: The first electronic device monitors a first input event, the first input event is an input event of the first mouse, the first input event carries first coordinates and first displacement information, the first coordinates are a plurality of coordinates of the first mouse cursor on the first display screen of the first electronic device changing with time in the first input event, and the first displacement information is a plurality of displacement information of the first mouse changing with time reported by the first mouse; The first electronic device determines that the first input event is a first key mouse crossing event, the first key mouse crossing event is an event preset for sending an input event of the auxiliary input device having communication connection with the first electronic device to a second electronic device having communication connection with the first electronic device; The first electronic device monitors a second input event, the second input event is an input event of the first mouse, the second input event is a mouse movement event, and the second input event carries displacement information of the first mouse between a start time and an end time of the second input event; The first electronic device sends the second input event to the second electronic device, wherein the second input event is used to instruct the second electronic device to perform a screen operation corresponding to the second input event based on the second input event; The first electronic device determines that the first input event is a first key mouse crossing event, comprising: The first electronic device obtains a first time when the first mouse cursor is located at an edge of a first side of the first display screen for the first time from the first coordinates; The first electronic device determines displacement information of the first mouse after the first time according to the first displacement information; The first electronic device determines that the first mouse moves to the first side after the first time according to the displacement information of the first mouse after the first time; The first electronic device determines that the first input event is the first key mouse crossing event in a case where it is determined that the first mouse moves to the first side after the first time.

2. The method of claim 1, wherein, The first key mouse crossing event is an event that a first mouse cursor displayed on a first display screen of the first electronic device moves from an edge of a first side of the first display screen to the first side out of the first display screen.

3. The method of claim 2, wherein, The first side is any one of an upper side, a lower side, a left side and a right side of the display screen.

4. The method according to any one of claims 1 to 3, characterized in that, After the first electronic device determines that the first input event is a first key mouse crossing event, the method further comprises: The first electronic device sets an interception identifier as a first character, wherein when the interception identifier is the first character, the first electronic device does not perform a screen operation corresponding to an input event of an auxiliary input device connected to the first electronic device, and the auxiliary input device further includes a first keyboard.

5. The method according to any one of claims 1 to 3, wherein After the first electronic device monitors the second input event, the method further includes: The first electronic device determines that the second input event is a mouse movement event; The first electronic device obtains second displacement information associated with the second input event; Correspondingly, the first electronic device sends the second input event to the second electronic device includes: The first electronic device sends the second displacement information associated with the second input event to the second electronic device.

6. The method of claim 5, wherein, After the first electronic device sends the second input event to the second electronic device, the method further includes: The second electronic device receives the second displacement information sent by the first electronic device; The second electronic device generates a first virtual input event according to an initial coordinate of a second mouse cursor and the second displacement information, the second mouse cursor being a mouse cursor on a second display screen of the second electronic device; The second electronic device controls the second mouse cursor on the second display screen to move based on the first virtual input event.

7. The method according to any one of claims 1 to 3, wherein After the first electronic device monitors the second input event, the method further includes: The first electronic device monitors a third input event, the third input event being an input event of the first mouse; The first electronic device sends the third input event to the second electronic device; The second electronic device determines that the third input event is a keyboard and mouse back-through event, the keyboard and mouse back-through event being a pre-set event for canceling the auxiliary input device connected to the first electronic device to take effect on the second electronic device; The second electronic device sends keyboard and mouse back-through information to the first electronic device.

8. The method of claim 7, wherein, The keyboard and mouse back-through event is an event that a second mouse cursor displayed on a second display screen of the second electronic device moves from an edge of a second side of the second display screen to the second side of the second display screen, the second side being any one of an upper side, a lower side, a left side and a right side of the second display screen.

9. The method of claim 8, wherein, The third input event is associated with third displacement information, the third displacement information being displacement information of the first mouse between a start time and an end time of the third input event; The second electronic device determines that the third input event is a keyboard and mouse back-through event includes: The second electronic device obtains a second coordinate of the second mouse cursor on the second display screen before the third displacement information associated with the third input event is received; The second electronic device obtains a predicted coordinate of the second mouse cursor based on the second coordinate and the third displacement information; The second electronic device determines that the predicted coordinate is located outside the edge of the second side of the second display screen.

10. The method of claim 1, wherein, The second keyboard and the second mouse are connected to the second electronic device; after the first electronic device determines that the first input event is the first keyboard-mouse crossing event, the method further comprises: The first electronic device sends keyboard-mouse crossing information to the second electronic device; The second electronic device receives the keyboard-mouse crossing information sent by the first electronic device; Correspondingly, after the second electronic device receives the keyboard-mouse crossing information sent by the first electronic device, the method further comprises: The second electronic device receives a fifth input event, which is an input event of the second keyboard or an input event of the second mouse; In response to the fifth input event, the second electronic device sends keyboard-mouse back crossing information to the first electronic device.

11. The method of claim 7, wherein, After the first electronic device receives the keyboard-mouse back crossing information, the method further comprises: The first electronic device sets the interception identifier as a second character, wherein when the interception identifier is the second character, the first electronic device performs a screen operation corresponding to an input event of an auxiliary input device connected to the first electronic device.

12. The method of claim 11, wherein, The auxiliary input device further comprises a first keyboard, and after the first electronic device receives the keyboard-mouse back crossing information, the method further comprises: The first electronic device monitors a fourth input event, which is an input event of the first mouse or an input event of the first keyboard; The first electronic device performs a screen operation corresponding to the fourth input event based on the fourth input event.

13. The method of any one of claims 1 to 3, wherein, The first electronic device and a third electronic device have a communication connection; the method further comprises: The first electronic device monitors a sixth input event, which is an input event of the first mouse; The first electronic device determines that the sixth input event is a second keyboard-mouse crossing event, which is an event that a first mouse cursor displayed on a first display screen of the first electronic device moves out of the first display screen from an edge of a third side of the first display screen to the third side; The first electronic device monitors a seventh input event, which is an input event of the first mouse; The first electronic device sends the seventh input event to the third electronic device, wherein the seventh input event is used to instruct the third electronic device to perform a screen operation corresponding to the seventh input event based on the seventh input event.

14. An electronic device, comprising: The electronic device comprises a processor configured to execute a computer program stored in a memory, so that the electronic device implements the method of any one of claims 1 to 13.

15. A computer-readable storage medium, characterized in that, The computer readable storage medium stores a computer program, and the computer program is executed by one or more processors to implement the method of any one of claims 1 to 13.

Citation Information

Patent Citations

  • Input device sharing method, electronic device and system

    CN114579016A

  • Method for lightening screen and electronic equipment

    CN114816153A

  • System for detection of input device

    US10739984B1

  • Pointright: a system to redirect mouse and keyboard control among multiple machines

    US20040201628A1

  • Method and device for receiving input

    US20140317530A1