CN107278294B - Input device implementation method and implementation device thereof - Google Patents

Input device implementation method and implementation device thereof Download PDF

Info

Publication number
CN107278294B
CN107278294B CN201780000721.4A CN201780000721A CN107278294B CN 107278294 B CN107278294 B CN 107278294B CN 201780000721 A CN201780000721 A CN 201780000721A CN 107278294 B CN107278294 B CN 107278294B
Authority
CN
China
Prior art keywords
input device
input
operating system
transmission channel
unit
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201780000721.4A
Other languages
Chinese (zh)
Other versions
CN107278294A (en
Inventor
李岩刚
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Qianhaida Yunyun Intelligent Technology Co ltd
Original Assignee
Shenzhen Qianhaida Yunyun Intelligent Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Qianhaida Yunyun Intelligent Technology Co ltd filed Critical Shenzhen Qianhaida Yunyun Intelligent Technology Co ltd
Publication of CN107278294A publication Critical patent/CN107278294A/en
Application granted granted Critical
Publication of CN107278294B publication Critical patent/CN107278294B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • G06F2009/45575Starting, stopping, suspending or resuming virtual machine instances
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/455Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
    • G06F9/45533Hypervisors; Virtual machine monitors
    • G06F9/45558Hypervisor-specific management and integration aspects
    • G06F2009/45579I/O management, e.g. providing access to device drivers or storage

Landscapes

  • Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

The embodiment of the invention discloses an input device realization method and a realization device thereof, which are applied to a virtual machine system, wherein the virtual machine system comprises a main operating system and a plurality of guest operating systems, and the main operating system comprises a physical input device driving unit used for communicating with a physical input device; the guest operating system includes a guest input device driver unit for communicating with the virtual input device and an input device service unit for providing an input device application. The method comprises the following steps: acquiring device data of a physical input device through the physical input device driving unit, wherein the device data at least comprises an input event; transmitting the input event to the input device service unit through a dedicated transmission channel; the dedicated transmission channel does not pass through the client input device driving unit.

Description

Input device implementation method and implementation device thereof
Technical Field
The invention relates to the technical field of virtual machines, in particular to an input device implementation method and an input device implementation device.
Background
A virtual machine refers to a computer system that has complete hardware system functionality and is run in a completely isolated environment, which is simulated by software. In a virtual machine application environment, a plurality of different operating systems share physical hardware devices, such as a CPU, a memory, an input/output device, and the like, based on simulated hardware.
In general, a physically present computer may be referred to as a "HOST" (HOST), an operating system running on the HOST may be referred to as a HOST operating system (HOST OS), and other operating systems may be referred to as GUEST operating systems (GUEST OS).
The virtual machine may run as one of the applications within the host operating system, providing a simulated hardware device for use by the guest operating system. Such as the "goldfish" virtual hardware platform offered by Google corporation in the prior art, which may support a virtual android operating system with QEMU virtual machine support.
In order to implement an input device in a virtual machine, a backend program capable of supporting the operation of a sensor device is typically implemented in the virtual machine in the prior art. The back-end program may provide the guest operating system with input device related data that needs to be configured, such as configuration information, attributes, and input device data of the input device. The corresponding input device driver and input device service program in the client operating system realize the operation of the input device on the basis of the virtual input device provided by the back-end program.
The applicant found in the course of studying the prior art that: in the existing input device implementation process, the input device related data of the virtual input device provided by the backend program is processed through an input device driver in the kernel of the guest operating system and the input device general layer. However, because the input data is processed by the main operating system, the input device driver and the input device generic layer in the guest operating system can be directly applied to the service layer without processing some of the data therein. Therefore, the input device driver and the input device common layer in the guest operating system have repeated processing of the input device data, which reduces the efficiency of data processing.
Disclosure of Invention
The embodiment of the invention mainly solves the problem that data of the input equipment is repeatedly processed when the input equipment is realized in the related technology.
In order to solve the above technical problem, one technical solution adopted by the embodiments of the present invention is: the input device implementation method is applied to a virtual machine system, wherein the virtual machine system comprises a main operating system and a plurality of guest operating systems, and the main operating system comprises a physical input device driving unit used for communicating with a physical input device; the guest operating system includes a guest input device driver unit for communicating with the virtual input device and an input device service unit for providing an input device application. Wherein the method comprises the following steps: acquiring device data of a physical input device through the physical input device driving unit, wherein the device data at least comprises an input event; transmitting the input event to the input device service unit through a dedicated transmission channel; the dedicated transmission channel does not pass through the client input device driving unit.
In order to solve the above technical problem, another technical solution adopted in the embodiments of the present invention is: the input device implementation device is applied to a virtual machine system, wherein the virtual machine system comprises a main operating system and a plurality of guest operating systems, and the main operating system comprises a physical input device driving unit for communicating with a physical input device; the guest operating system includes a guest input device driver unit for communicating with the virtual input device and an input device service unit for providing an input device application. Wherein the device comprises: the input device back end supporting unit is used for acquiring device data of the physical input device through the physical input device driving unit, and the device data at least comprises an input event; a dedicated transmission channel for transmitting the input event to the input device service unit; the dedicated transmission channel does not pass through the client input device driving unit.
According to the input device implementation method and the implementation device thereof provided by the embodiment of the invention, the input event is directly transmitted to the input device service unit of the client operating system through the specific special transmission channel without passing through the client input device driving unit, so that the repeated processing of the input event by the client input device driving unit in the client operating system is avoided, and the data processing efficiency in the input device implementation process is effectively improved.
Drawings
One or more embodiments are illustrated by way of example in the accompanying drawings, which correspond to the figures in which like reference numerals refer to similar elements and which are not to scale unless otherwise specified.
FIG. 1 is a schematic diagram of a virtual machine system provided by an embodiment of the invention;
fig. 2 is a schematic diagram of an input device implementation apparatus implemented on a virtual machine system according to an embodiment of the present invention;
FIG. 3 is a schematic diagram of input event transmission of a dedicated transmission channel according to an embodiment of the present invention;
FIG. 4 is a schematic diagram of data interaction between a virtual machine program and a guest operating system according to an embodiment of the present invention;
FIG. 5 is a flowchart of a method for implementing a method of an input device according to an embodiment of the present invention;
fig. 6 is a flowchart of a method for starting a dedicated transmission channel according to an embodiment of the present invention;
fig. 7 is a schematic structural diagram of an electronic device according to an embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
The input-device driver refers to a driver for the input device or a corresponding functional module. The method can be used as a connecting bridge between input equipment hardware and an upper operating system, and realizes mutual translation between a high-level programming language used in the operating system and hardware equipment electronic signals used by the input equipment.
Thus, in a virtual machine system having multiple different operating systems, the host operating system has input device drivers corresponding to the physical input devices. And each guest operating system is also provided with an input device driver corresponding to the virtual input device so as to realize the communication connection between the input device and the operating system.
Fig. 1 is a virtual machine system to which an input device implementation method provided by an embodiment of the present invention is applied. As shown in fig. 1, the virtual machine system includes: a physical hardware device 100, a host operating system 200, a number of guest operating systems 300, and a virtual machine program 400.
The physical hardware device 100 is a hardware device shared by both host operating system 200 and guest operating system 300. Which may include any suitable one or more of the device components that make up the complete computer system, including the processor 101, storage medium 102, input/output devices 103, sensor devices 104, and communication module 105.
The processor 101 may be any suitable type of processor with certain logical operation capability, such as a central processing unit, a graphics processor, and the like. Processor 101 may also include multiple cores for multi-threading or parallel processing.
The storage medium 102 may include a memory module such as ROM, RAM, flash memory module, and a mass storage such as an optical disk and a hard disk. The storage medium 102 may also have stored therein computer programs that, when executed by the processor 101, may implement various method steps or procedures.
The input/output device 103 may be any suitable type of peripheral device providing one or more user interaction modes, such as a mouse, a keyboard, or a touch input screen receiving user action operation instructions, a motion sensing camera for capturing image information, a microphone for capturing sound information, or a display screen (LCD display screen, LED display screen, etc.) for presenting image information to a user, or a speaker for outputting audio.
The input/output device 103 may optionally use a wired or wireless peripheral connection, such as a USB cable or a bluetooth connection. After the connection is established, the device-related information such as the device attribute and the configuration information of the input/output device is transmitted to the operating system, so that the operating system can configure or correctly use the input/output device. The input device 103 may also receive an operation instruction of a user, and the like, and provide the operation instruction as an input event to the operating system, so as to implement interaction between the user and the operating system.
The sensor device 104 may be any suitable sensing device capable of sensing sensed information and converting the sensed information into an electrical signal or other suitable form of output information. The sensor device can be used for detecting various different types of detected information and has one or more corresponding sensing functions, such as detection of information of temperature, illumination intensity, air pressure, acceleration, rotation angle, magnetic field state, humidity, sound and the like. The sensor device 104 may include one or more discrete sensors for detecting different information to meet usage requirements.
The communication module 105 may include some network interface device that establishes a connection through a wired or wireless communication network. For example, a network cable interface, a bus interface, a USB interface, a WiFi module, or a bluetooth communication module.
In the actual application process, one or more devices can be added or omitted from the physical hardware device 100 to meet different actual application requirements, for example, a database or a server device is added, and one or more sensors are omitted.
Both the host operating system 200 and the guest operating system 300 may be any suitable type of operating system for receiving user instructions and outputting corresponding processing results for presentation to a user. The host operating system 200 uses the hardware devices of the physical hardware device 100. Guest operating system 300 uses the emulated hardware devices provided by virtual machine program 400.
When guest operating system 300 is running, virtual machine program 400 emulates a hardware device for its use by some backend program on a physical hardware device basis. The virtual machine program 400 runs as one of the application programs in the host operating system 200. That is, the virtual machine may provide simulated hardware devices for use by guest operating systems based on the basis of simulated hardware devices provided by the physical hardware devices or other virtual machines.
There is memory isolation between the different operating systems and the main operating system 200 is also unable to access the memory space of guest operating system 300. Thus, when more than 2 guest operating systems exist, when one guest operating system is restarted due to an exception, the main operating system and the other guest operating systems can also run normally and are isolated from each other. Of course, since the virtual machine program is running as an application in the host operating system. Thus, when the main operating system is restarted due to an exception, all guest operating systems need to be restarted accordingly.
As shown in fig. 1, the main operating system 200 includes a physical input device driver unit 210, which is used to establish a connection between the main operating system 200 and the physical input device 100, provide services such as an interface port, and implement control over the input device in the main operating system 200.
Correspondingly, the guest operating system 300 also includes a guest input device driver unit 310. The guest input device driver unit 310 is communicatively connected to the virtual machine program 400, so as to establish a connection between the virtual input devices emulated by the virtual machine program 400, thereby implementing the control of the input devices by the guest operating system.
The guest operating system 300 is further provided with an input device service unit 320 on an upper layer of the guest input device driver unit 310. The input device service unit 320 provides one or more input device related services to the guest operating system through the device data processed by the guest input device driver unit 310.
In the starting process of the virtual machine system, as a basis of the guest operating system, the host operating system is first started, the started host operating system occupies the input/output device 103 in the physical hardware device 100, and the device attribute, the configuration information, the input event and other related messages of the input device can be acquired through the physical input device driving unit 210.
After the main os is started, when there is no task to be executed by the main os (which may be determined according to an input event), the main os 200 may enter a sleep mode and release the occupied input device.
After the host operating system 200 enters the sleep mode, one of the guest operating systems 300 is started. In a virtual machine system, each guest operating system has its own predefined or configured input device. When the guest operating system is started, the device attribute, the configuration information, and the like of the corresponding input device are read by the guest input device driver unit 310 in the kernel of the guest operating system 300, so that the configuration of the input device of the guest operating system is completed.
The input event of the input device can be subjected to data processing by the method provided by the embodiment of the invention and is provided for a client operating system to obtain better data processing efficiency. In the case of multiple guest operating systems, the guest operating systems may also automatically enter a sleep mode and start other guest operating systems.
Correspondingly, in the running process of the virtual machine system, the operating system can be in a foreground running state or a dormant state and exists in a background. The operating system can switch between two different states of a foreground and a background according to some preset instructions, for example, when the operating system is not operated for more than preset time, the operating system is switched to enter the background, or after receiving an operating system switching instruction, the operating system is switched from the background to enter the foreground for operation.
Fig. 2 is a schematic structural diagram of an input device implementation apparatus according to an embodiment of the present invention. The input device implementation apparatus may be applied to the virtual machine system shown in fig. 1. As shown in fig. 2, the input device implementation apparatus includes: an input device back end support unit 410 and a dedicated transmission channel 500.
The input device back end support unit 410 is configured to obtain device data of a physical input device through the physical input device driving unit, where the device data at least includes an input event. The dedicated transmission channel 500 is used to transmit the input events therein to the input device service unit.
In this embodiment, as shown in fig. 2, the input device back-end support unit 410 may be one of the functional modules in the virtual machine program 400. The input device backend support unit 410 may obtain device data (e.g., device attribute information, configuration information, or input events) from the input device of the host operating system and provide a virtual input device for the guest operating system based thereon to implement input device services in the guest operating system.
The dedicated transport channel 500 is a communication channel connecting the virtual machine program 400 and the guest operating system 300, and may be any suitable form or type of program, hardware unit, or functional module having a data transfer function that runs in the virtual machine system. The dedicated transport channel 500 provides another communication channel for the guest operating system 300 to connect with the virtual machine program 400 in addition to the guest input device driver unit 310.
Through the dedicated transmission channel 500, the input event can be directly transmitted to the input device service unit 320 without passing through the client input device driving unit 310. Thus, the dedicated transmission channel 500 can avoid the client input device driving unit 310 from repeatedly processing the input event of the input device, and can effectively improve the processing efficiency of the input event.
In practical applications, the device data may generally include two types, one being input data acquired directly by the device, with a distinct temporal nature. In the present embodiment, the "input event" is used to indicate that the input device collects the acquired input data. The other is data that does not have a time-series property and is determined by the property of the input device itself, for example, device properties or configuration information of the device.
As shown in fig. 4, to implement configuration or setting of an input device, the input device back-end support unit 410 may further send information for configuring the input device, such as device attributes or configuration information of a physical input device, to the client input device driver unit 310, and then the client input device driver unit 310 implements a virtual input device preset by the client operating system 300.
The input device backend support unit 410 is a backend program in a virtual machine program, which is used to support the input device driver of the guest operating system to run. Which may provide the services of virtual registers, address space, and virtual interrupts of a virtual device based on the physical input device.
Fig. 3 is a schematic diagram of an input event transmission performed by the dedicated transmission channel 500 according to an embodiment of the present invention. As shown in fig. 3, in the present embodiment, the dedicated transport channel 500 may be composed of a transport channel backend support unit 420 belonging to the virtual machine program 400 and an input event driver unit 330 in the guest operating system.
The transmission channel back-end support unit 420 is configured to obtain an input event in the device data; and sending the input event to the guest operating system. The input event driving unit 330 is configured to receive the input event. After receiving the input events, the input device service unit 320 may read one or more input events therein to provide corresponding input services. That is, the back end support unit 420 of the transmission channel serves as a data transmitter, and the input event driver unit 330 serves as a receiver for receiving the input event transmitted by the receiver.
Specifically, as shown in fig. 3, the input event belongs to data having a temporal characteristic. Therefore, in the transmitting and receiving processes, the input event 1, the input event 2, the input event 3, and the like may be sequentially transmitted and received in time order to ensure that the input events can be accurately read.
Thus, to implement an input device in the guest operating system, the input device service unit 320 of the guest operating system may retrieve a device file node corresponding to a preset input device, read the attribute and configuration information of a required virtual input device from the guest input device driver unit 310 one by one, and read an input event of the corresponding device node received by the input event driver unit 330, or detect whether a new input event is received by the input event driver unit 330, and then perform corresponding processing on the input event of a specific virtual input device.
In this embodiment, the assumption that the direct data source of the virtual input device is the physical input device corresponding to the host operating system is based on. In other embodiments, the direct data source of the virtual input device may also be a virtual input device corresponding to another guest operating system. During the operation of the actual virtual machine, the direct data source of the virtual input device can be distinguished by setting an additional identifier or label.
Fig. 4 is a schematic diagram of a complete process of configuring a virtual input device by a guest operating system according to an embodiment of the present invention. The input device backend support unit 410 in the virtual machine program 400 obtains the attribute and configuration information of the physical input device and the input data (i.e., input event) acquired by the input device according to the corresponding input device file in the kernel of the main operating system 200.
The attribute and configuration information are transmitted to the client input device driver unit 310 of the client operating system 300, processed by the client input device driver unit 310, and received by the input device service unit 320. The input event may then be transmitted to the input device service unit 320 via the dedicated transmission channel 500.
The input device service unit 320 provides one or more services in the guest operating system to implement the virtual input device based on the received acquisition data.
Based on the input device implementation apparatus provided in the foregoing embodiment, an embodiment of the present invention further provides an input device implementation method applied to a virtual machine system. Fig. 5 is a flowchart of a method for implementing the input device according to the embodiment of the present invention.
As shown in fig. 5, the method may include the steps of:
100. acquiring device data of a physical input device through the physical input device driving unit, wherein the device data at least comprises an input event.
200. Transmitting the input event to the input device service unit through a dedicated transmission channel; the special transmission channel does not pass through the client input device driving unit and supports communication transmission between the virtual input device and the input device service unit.
The input event of the physical input device can be independently transmitted to the input device service unit of the client operating system through the special transmission channel, so that redundant processing of the input event by the client input device driving unit is avoided, and the data processing efficiency is improved.
In actual use, each guest operating system has its own predetermined input device, which may be determined by a preset configuration file. To implement these input devices in the guest operating system, the device attributes and configuration information provided by the virtual machine program are read by the guest input device driver unit (step 300), in addition to the communication of input events. After the client input device driving unit processes the data, the input device service unit reads the device attribute or configuration information corresponding to the preset virtual input device (step 400).
In some embodiments, the transmission of the input event may be performed by sending the input event by the virtual machine and receiving the input event by the guest operating system. In the transmission process, since the input events of the input device have a specific temporal characteristic, the input events may be sequentially transmitted according to a temporal order of the input events.
As disclosed in the above virtual machine system, in the virtual machine system, the operating system may run in the foreground or be dormant in the background. FIG. 6 is a method for the guest operating system to enable the dedicated transport channel. As shown in fig. 6, after receiving a system switching request (step 10), it is determined whether the guest operating system is still in foreground operation (step 20). If the guest operating system switches from foreground to background hibernation, the acquisition of input data from the input device of the host operating system from the virtual machine program may be stopped (step 30). If the guest operating system is switched from the background sleep mode to the foreground, the guest operating system starts to acquire input data from the input device of the host operating system from the virtual machine program (step 40).
It should be noted that the input device implementation method and the input device implementation apparatus provided in the above embodiments are all based on the same inventive concept. Therefore, the steps of each specific embodiment in the sensor implementation method may be executed by the corresponding functional module, and the specific function in the functional module may also have corresponding method steps in the input device implementation method, which is not described herein again.
Fig. 7 is a schematic diagram of a hardware structure of an electronic device according to an embodiment of the present invention. The hardware device can be applied to a virtual machine system and used for executing the input device implementation method. As shown in fig. 7, the apparatus 70 includes: one or more processors 710 and a memory 720, one processor 710 being illustrated in fig. 7.
The processor 710 and the memory 720 may be connected by a bus or other means, and fig. 7 illustrates an example of the connection by the bus.
The memory 720, which is a non-volatile computer-readable storage medium, can be used to store non-volatile software programs, non-volatile computer-executable programs, and modules, such as program instructions/modules corresponding to the input device implementation method in the embodiment of the present invention (for example, the input device back-end support unit 410 and the dedicated transmission channel 500 shown in fig. 2). The processor 710 executes various functional applications and data processing of the input device implementation apparatus by executing nonvolatile software programs, instructions and modules stored in the memory 720, that is, implementing the input device implementation method of the above-described method embodiments.
The memory 720 may include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required for at least one function; the storage data area may store data created according to use of the input device implementation apparatus, and the like. Further, the memory 720 may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other non-volatile solid state storage device. In some embodiments, memory 720 optionally includes memory located remotely from processor 710, which may be connected to the sensor-implemented device via a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The one or more modules are stored in the memory 720 and, when executed by the one or more processors 710, perform an input device implementation method of any of the method embodiments described above.
The product can execute the method provided by the embodiment of the invention, and has corresponding functional modules and beneficial effects of the execution method. For technical details that are not described in detail in this embodiment, reference may be made to the method provided by the embodiment of the present invention.
Embodiments of the present invention provide a computer program product comprising a computer program stored on a non-transitory computer-readable storage medium, the computer program comprising program instructions that, when executed by a computer, cause the computer to perform a method implemented by an input device in any of the above-described method embodiments, e.g., to perform method steps 100 and 200 in fig. 5 described above, to implement the functions of the corresponding functional blocks in fig. 2.
The above-described embodiments of the apparatus are merely illustrative, and the units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment.
Through the above description of the embodiments, those skilled in the art will clearly understand that each embodiment can be implemented by software plus a general hardware platform, and certainly can also be implemented by hardware. It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by hardware related to instructions of a computer program, which can be stored in a computer readable storage medium, and when executed, can include the processes of the embodiments of the methods described above. The storage medium may be a magnetic disk, an optical disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), or the like.
Finally, it should be noted that: the above examples are only intended to illustrate the technical solution of the present invention, but not to limit it; within the idea of the invention, also technical features in the above embodiments or in different embodiments may be combined, steps may be implemented in any order, and there are many other variations of the different aspects of the invention as described above, which are not provided in detail for the sake of brevity; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and the modifications or the substitutions do not make the essence of the corresponding technical solutions depart from the scope of the technical solutions of the embodiments of the present invention.

Claims (11)

1. An input device implementation method is applied to a virtual machine system, wherein the virtual machine system comprises a main operating system and a plurality of guest operating systems, and the main operating system comprises a physical input device driving unit used for communicating with a physical input device; the guest operating system including a guest input device driver unit for communicating with a virtual input device and an input device service unit for providing input device applications, the method comprising:
acquiring device data of a physical input device through the physical input device driving unit, wherein the device data at least comprises an input event;
transmitting the input event to the input device service unit through a dedicated transmission channel; the dedicated transmission channel does not pass through the client input device driving unit;
the special transmission channel comprises a transmission channel back end supporting unit and an input event driving unit in the client operating system, wherein the transmission channel back end supporting unit is used as a sending end, the input event driving unit is used as a receiving end matched with the transmission channel back end supporting unit, and the input event driving unit is used for receiving the input event sent by the transmission channel back end supporting unit;
the transmitting the input event to the input device service unit through a dedicated transmission channel specifically includes: and sequentially transmitting the input events to the input equipment service unit through a special transmission channel according to the acquisition time sequence.
2. The method of claim 1, wherein the device data comprises: device properties of the physical input device, configuration information of the physical input device, and input events.
3. The method of claim 2, wherein the guest operating system has a preset virtual input device;
the method further comprises the following steps: when the device data is the device attribute or configuration information of the physical input device, transmitting the device data to the client input device driving unit;
and reading the device attribute or configuration information corresponding to the preset virtual input device through the client input device driving unit.
4. The method according to any of claims 1-3, wherein said transmitting the input event to the input device service unit via a dedicated transmission channel specifically comprises:
acquiring an input event in the device data;
sending the input event to the guest operating system;
and receiving the input event, and reading the corresponding input event through the input equipment service unit.
5. The method of claim 4, wherein the main operating system and one of the guest operating systems are operating in foreground and the remaining operating systems are operating in a hibernate state;
and stopping reading the input event when the guest operating system is switched to a dormant state from foreground operation.
6. An input device implementation device is applied to a virtual machine system, wherein the virtual machine system comprises a main operating system and a plurality of guest operating systems, and the main operating system comprises a physical input device driving unit used for communicating with a physical input device; the guest operating system including a guest input device driver unit for communicating with a virtual input device and an input device service unit for providing input device applications, comprising:
the input device back end supporting unit is used for acquiring device data of the physical input device through the physical input device driving unit, and the device data at least comprises an input event;
a dedicated transmission channel for transmitting the input event to the input device service unit; the dedicated transmission channel does not pass through the client input device driving unit;
the special transmission channel comprises a transmission channel back end supporting unit and an input event driving unit in the client operating system, wherein the transmission channel back end supporting unit is used as a sending end, the input event driving unit is used as a receiving end matched with the transmission channel back end supporting unit, and the input event driving unit is used for receiving the input event sent by the transmission channel back end supporting unit;
the dedicated transmission channel is specifically configured to: and sequentially transmitting the input events to the input equipment service unit according to the acquisition time sequence.
7. The apparatus of claim 6, wherein the device data comprises: device properties of the physical input device, configuration information of the physical input device, and input events.
8. The apparatus of claim 7, wherein the guest operating system has a preset virtual input device;
the input device back end supporting unit is further configured to transmit the device data to the client input device driving unit when the device data is a device attribute or configuration information of a physical input device;
and the input device service unit is used for reading the device attribute or the configuration information corresponding to the preset virtual input device through the client input device driving unit.
9. The apparatus according to any of claims 6-8, wherein the dedicated transmission channel comprises in particular:
a transmission channel back end support unit, configured to obtain an input event in the device data; and sending the input event to the guest operating system;
and the input event driving unit is arranged in the client operating system and used for receiving the input event so as to enable the input equipment service unit to read the corresponding input event.
10. The apparatus of claim 9, wherein the main operating system and one of the guest operating systems are operating in foreground and the remaining operating systems are operating in a hibernate state;
when the guest operating system is switched from foreground operation to a dormant state, the input device service unit is configured to: stopping reading the input event.
11. An electronic device, comprising:
at least one processor; and the number of the first and second groups,
a memory communicatively coupled to the at least one processor; wherein,
the memory stores a program of instructions executable by the at least one processor to cause the at least one processor to perform the method of any one of claims 1-5.
CN201780000721.4A 2017-05-12 2017-05-12 Input device implementation method and implementation device thereof Active CN107278294B (en)

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2017/084182 WO2018205267A1 (en) 2017-05-12 2017-05-12 Input device implementation method and implementation apparatus thereof

Publications (2)

Publication Number Publication Date
CN107278294A CN107278294A (en) 2017-10-20
CN107278294B true CN107278294B (en) 2020-11-06

Family

ID=60076622

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201780000721.4A Active CN107278294B (en) 2017-05-12 2017-05-12 Input device implementation method and implementation device thereof

Country Status (2)

Country Link
CN (1) CN107278294B (en)
WO (1) WO2018205267A1 (en)

Families Citing this family (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108235759B (en) * 2017-12-20 2022-09-16 深圳前海达闼云端智能科技有限公司 Input processing method and device based on multiple operating systems and electronic equipment
WO2019127476A1 (en) * 2017-12-29 2019-07-04 深圳前海达闼云端智能科技有限公司 Virtual system bluetooth communication method and device, virtual system, storage medium, and electronic apparatus
CN109189523B (en) * 2018-08-08 2022-03-15 广东微云科技股份有限公司 Method and system for judging idle virtual machine and method for closing virtual machine
CN110642028B (en) * 2019-09-25 2021-06-15 张占军 Multi-link automatic bunker allocation system and method based on bunker coal position
CN112905275B (en) * 2019-12-03 2024-08-27 斑马智行网络(香港)有限公司 Display method and display device for multiple operating systems
CN113741718B (en) * 2020-05-29 2024-06-04 杭州海康威视数字技术股份有限公司 Control data conversion method and device and main control equipment

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101136045A (en) * 2006-08-29 2008-03-05 联想(北京)有限公司 Virtual machine system and safety input method thereof

Family Cites Families (9)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN100464295C (en) * 2006-05-17 2009-02-25 联想(北京)有限公司 Safety inputting method based on virtual machine
US9176765B2 (en) * 2006-09-25 2015-11-03 Lenovo (Beijing) Limited Virtual machine system and a method for sharing a graphics card amongst virtual machines
CN101493781B (en) * 2008-01-24 2012-02-15 中国长城计算机深圳股份有限公司 Virtual machine system and start-up method thereof
CN102385525B (en) * 2010-08-30 2015-03-04 联想(北京)有限公司 Virtual machine system and method for uninstalling docking station equipment in virtual machine system
US9317444B2 (en) * 2013-03-15 2016-04-19 Vmware, Inc. Latency reduction for direct memory access operations involving address translation
CN103246544B (en) * 2013-04-09 2016-02-24 何钦淋 virtual hardware driving method
CN104253842B (en) * 2013-06-28 2018-03-06 华为技术有限公司 Method, apparatus, terminal and the server of synchronous terminal mirror image
CN104391672A (en) * 2014-10-27 2015-03-04 深圳市京华科讯科技有限公司 Earphone mic virtualization implementation system based on virtual desktop and audio frequency transmission method of earphone mic virtualization implementation system
CN105573816B (en) * 2015-12-11 2018-12-21 北京奇虎科技有限公司 The method, apparatus and system virtually inputted

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101136045A (en) * 2006-08-29 2008-03-05 联想(北京)有限公司 Virtual machine system and safety input method thereof

Also Published As

Publication number Publication date
CN107278294A (en) 2017-10-20
WO2018205267A1 (en) 2018-11-15

Similar Documents

Publication Publication Date Title
CN107278294B (en) Input device implementation method and implementation device thereof
CN109766302B (en) Method and device for managing equipment
CN108235759B (en) Input processing method and device based on multiple operating systems and electronic equipment
US9223596B1 (en) Virtual machine fast provisioning based on dynamic criterion
US10922251B2 (en) Electronic device and method for controlling same
US10088515B2 (en) Electronic device and method for determining defect in an electronic device
US20170031694A1 (en) System and method for remote system configuration managment
EP3208722B1 (en) Data transceiving method and device
US10846124B2 (en) Communication method, apparatus and system for virtual machine and host machine
US10852719B2 (en) Server, electronic device, and electronic device information providing method
CN107278293B (en) Sensor implementation device and method for virtual machine
JP6415581B2 (en) Dynamic reassignment for multi-operating system devices
WO2017032112A1 (en) Method for communicating with board having no central processing unit and communication device
CN107360633B (en) Pairing connection method and device of virtual reality system and virtual reality system
KR102631745B1 (en) Method for controlling the execution of different operating systems, electronic device and storage medium therefor
WO2015062217A1 (en) Connection processing method and device for peripheral in virtual desktop system
CN113867993A (en) Virtualized RDMA method, system, storage medium and electronic device
KR20200058157A (en) Electronic device and method for providing in-vehicle infortainment service
KR20150128256A (en) Server system having virtual android apparatus for interworking between application and real smart device
CN112789597A (en) Electronic device for executing a plurality of operating systems and control method thereof
CN113703914A (en) Test method and test system
US20140351833A1 (en) Multi-computing environment operating on a single native operating system
CN114499945A (en) Intrusion detection method and device for virtual machine
CN107506323B (en) Hot plug processing method and device
CN111726848B (en) Equipment binding method, target starting device, fixed terminal and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant