Disclosure of Invention
In view of this, the application provides a drive control method and device, a storage medium, and a computer device based on a cloud mobile phone, which enable a user to realize a drive function through a cloud mobile phone client without sensing in a process of using the cloud mobile phone, so that the experience of the user is greatly improved while the functions of the cloud mobile phone are enriched.
According to an aspect of the present application, there is provided a drive control method based on a cloud mobile phone, applied to the cloud mobile phone, including:
monitoring a drive starting request from a preset application program through a HAL layer, sending the drive starting request to an intermediate layer when the drive starting request is monitored, sending the drive starting request to a preset transmission interface of a cloud mobile phone client based on the intermediate layer so as to enable the cloud mobile phone client to start a target drive, acquiring target data corresponding to the drive starting request based on the target drive, and feeding back the target data through the preset transmission interface, wherein the preset application program is an application program installed in a cloud mobile phone;
receiving the target data fed back by the preset transmission interface through the intermediate layer, forwarding the target data to the HAL layer, and storing the target data through the HAL layer.
Optionally, before monitoring, by the HAL layer, a driver activation request from a preset application program, the method further includes:
responding to a cloud mobile phone starting request, loading the HAL layer and the middle layer, and starting a remote connection interface of the middle layer;
and receiving a communication connection request sent by the preset transmission interface through the remote connection interface of the middle layer, and establishing communication connection with the preset transmission interface.
Optionally, the storing the target data by the HAL layer specifically includes:
storing the target data by a circular queue in the HAL layer;
after storing the target data through a circular queue in the HAL layer, the method further comprises:
monitoring a data reading request from the preset application program through the HAL layer, and sending the target data corresponding to the data reading request in the circular queue to the preset application program when the data reading request is monitored.
Optionally, the method further comprises:
monitoring a drive closing request from the preset application program through the HAL layer, and sending the drive closing request to the preset transmission interface of the cloud mobile phone client based on the intermediate layer when the drive closing request is monitored, so that the cloud mobile phone client closes the target drive.
According to another aspect of the present application, there is provided a cloud-based mobile phone drive control method, applied to a cloud mobile phone client, including:
receiving a drive starting request sent by a cloud mobile phone intermediate layer through a preset transmission interface, starting a target drive based on the drive starting request, and acquiring target data corresponding to the drive starting request based on the target drive;
and calling the preset transmission interface, feeding the target data back to the intermediate layer through the preset transmission interface so that the intermediate layer forwards the target data to a HAL layer, and storing the target data through the HAL layer.
Optionally, before receiving, through a preset transmission interface, a drive starting request sent by a cloud mobile phone intermediate layer, the method further includes:
responding to a cloud mobile phone login instruction, acquiring a login personnel identifier, and generating a cloud mobile phone opening request based on the login personnel identifier;
calling an interface layer initialization function, establishing the preset transmission interface in the interface layer after the interface layer is initialized, generating a communication connection request through the preset transmission interface, sending the communication connection request to a remote connection interface of the middle layer, and establishing communication connection with the middle layer.
Optionally, after the interface layer establishes the preset transmission interface after the interface layer is initialized, the method further includes:
sending a preset callback pointer to the preset transmission interface;
the method includes the steps of receiving a drive starting request sent by a cloud mobile phone intermediate layer through a preset transmission interface, and starting a target drive based on the drive starting request, and specifically includes:
receiving a drive starting request sent by the cloud mobile phone intermediate layer through the preset transmission interface, identifying the callback pointer through the preset transmission interface, determining a target address corresponding to the callback pointer, forwarding the drive starting request to the target address, and calling a target drive function to start the target drive.
According to another aspect of the present application, there is provided a drive control apparatus based on a cloud mobile phone, applied to the cloud mobile phone, including:
the device comprises a request sending module, a data processing module and a data processing module, wherein the request sending module is used for monitoring a drive starting request from a preset application program through an HAL layer, sending the drive starting request to an intermediate layer when the drive starting request is monitored, sending the drive starting request to a preset transmission interface of a cloud mobile phone client based on the intermediate layer so as to enable the cloud mobile phone client to start a target drive, acquiring target data corresponding to the drive starting request based on the target drive, and feeding back the target data through the preset transmission interface, wherein the preset application program is an application program installed in a cloud mobile phone;
and the data receiving module is used for receiving the target data fed back by the preset transmission interface through the middle layer, forwarding the target data to the HAL layer and storing the target data through the HAL layer.
Optionally, the apparatus further comprises:
the loading module is used for responding to a cloud mobile phone starting request before monitoring a driving starting request from a preset application program through the HAL layer, loading the HAL layer and the middle layer and starting a remote connection interface of the middle layer;
and the connection establishing module is used for receiving the communication connection request sent by the preset transmission interface through the remote connection interface of the middle layer and establishing the communication connection with the preset transmission interface.
Optionally, the data receiving module is specifically configured to:
storing the target data by a circular queue in the HAL layer;
the device further comprises:
and the data reading module is used for monitoring a data reading request from the preset application program through the HAL layer after the target data is stored through the circular queue in the HAL layer, and sending the target data corresponding to the data reading request in the circular queue to the preset application program when the data reading request is monitored.
Optionally, the request sending module is further configured to:
monitoring a drive closing request from the preset application program through the HAL layer, and sending the drive closing request to the preset transmission interface of the cloud mobile phone client based on the intermediate layer when the drive closing request is monitored, so that the cloud mobile phone client closes the target drive.
According to another aspect of the present application, there is provided a drive control apparatus based on a cloud mobile phone, applied to a cloud mobile phone client, including:
the driving starting module is used for receiving a driving starting request sent by a cloud mobile phone intermediate layer through a preset transmission interface, starting a target drive based on the driving starting request, and acquiring target data corresponding to the driving starting request based on the target drive;
and the interface calling module is used for calling the preset transmission interface, feeding the target data back to the intermediate layer through the preset transmission interface so as to enable the intermediate layer to forward the target data to the HAL layer, and storing the target data through the HAL layer.
Optionally, the apparatus further comprises:
the request generation module is used for responding to a cloud mobile phone login instruction before receiving a driving starting request sent by a cloud mobile phone intermediate layer through a preset transmission interface, acquiring a login personnel identifier and generating a cloud mobile phone starting request based on the login personnel identifier;
the function calling module is used for calling an interface layer initialization function, establishing the preset transmission interface in the interface layer after the interface layer is initialized, generating a communication connection request through the preset transmission interface, sending the communication connection request to the remote connection interface of the middle layer, and establishing communication connection with the middle layer.
Optionally, the apparatus further comprises:
the pointer sending module is used for sending a preset callback pointer to the preset transmission interface after the interface layer establishes the preset transmission interface after the interface layer is initialized;
the drive starting module is specifically used for:
receiving a drive starting request sent by the cloud mobile phone intermediate layer through the preset transmission interface, identifying the callback pointer through the preset transmission interface, determining a target address corresponding to the callback pointer, forwarding the drive starting request to the target address, and calling a target drive function to start the target drive.
According to still another aspect of the present application, there is provided a storage medium having stored thereon a computer program which, when executed by a processor, implements the cloud-based drive control method described above.
According to still another aspect of the present application, there is provided a computer device, including a storage medium, a processor, and a computer program stored on the storage medium and executable on the processor, where the processor implements the cloud mobile phone-based drive control method when executing the program.
By means of the technical scheme, according to the drive control method and device based on the cloud mobile phone, the storage medium and the computer equipment, firstly, the HAL layer can monitor a drive starting request of a preset application program running in the cloud mobile phone, when the HAL layer monitors the drive starting request of the preset application program, the HAL layer can forward the drive starting request through the middle layer, the drive starting request is sent to the preset transmission interface which is in communication connection with the middle layer, after the preset transmission interface of the cloud mobile phone client receives the drive starting request, the cloud mobile phone client can start a corresponding target drive, and target data corresponding to the drive starting request can be obtained through the target drive. Then, after the cloud mobile phone client acquires target data corresponding to the drive starting request, a preset transmission interface can be called to feed the target data back to the intermediate layer. After receiving the target data, the intermediate layer may forward the target data to the HAL layer, so that the target data may be stored in the HAL layer. According to the cloud mobile phone driving method and device, the target data obtained by the cloud mobile phone client are returned to the HAL layer for storage, the driving function of the cloud mobile phone is achieved, the user can use the cloud mobile phone in the process of being unaware of the driving function achieved through the cloud mobile phone client, the cloud mobile phone function is enriched, and meanwhile the experience feeling of the user is greatly improved.
The foregoing description is only an overview of the technical solutions of the present application, and the present application can be implemented according to the content of the description in order to make the technical means of the present application more clearly understood, and the following detailed description of the present application is given in order to make the above and other objects, features, and advantages of the present application more clearly understandable.
Detailed Description
The present application will be described in detail below with reference to the accompanying drawings in conjunction with embodiments. It should be noted that the embodiments and features of the embodiments in the present application may be combined with each other without conflict.
In this embodiment, a drive control method based on a cloud mobile phone is provided, and is applied to the cloud mobile phone, as shown in fig. 1, the method includes:
step 101, monitoring a drive starting request from a preset application program through an HAL layer, sending the drive starting request to an intermediate layer when the drive starting request is monitored, sending the drive starting request to a preset transmission interface of a cloud mobile phone client based on the intermediate layer so as to enable the cloud mobile phone client to start a target drive, acquiring target data corresponding to the drive starting request based on the target drive, and feeding back the target data through the preset transmission interface, wherein the preset application program is an application program installed in a cloud mobile phone;
the cloud mobile phone-based drive control method provided by the embodiment of the application can control the real phone drive where the cloud mobile phone client is located, so that the simulation of the cloud mobile phone drive is realized, and the functions of recording, recording video, photographing and the like of the cloud mobile phone are enriched. The cloud mobile phone-based drive control method provided by the embodiment of the application can be applied to a cloud mobile phone, and particularly can be used on a cloud server where the cloud mobile phone is located. The cloud mobile phone-based drive control method provided by the embodiment of the application is mainly realized by three parts, namely a Hardware Abstraction Layer (HAL) Layer of a cloud mobile phone end, an intermediate Layer and an interface Layer of a cloud mobile phone client, wherein the intermediate Layer is used for receiving communication between the HAL Layer and the interface Layer, and the interface Layer is used for receiving communication between the intermediate Layer and the cloud mobile phone client. Firstly, the HAL layer may monitor, in real time, a driver start request of a preset application running in the cloud mobile phone, where the driver start request may include a request for starting a recording, a request for starting a camera, and the like. After monitoring a drive starting request of a preset application program, the HAL layer can send the drive starting request to the intermediate layer, and can forward the drive starting request through the intermediate layer, and send the drive starting request to a preset transmission interface which is in communication connection with the intermediate layer, after receiving the drive starting request, the preset transmission interface of the cloud mobile phone client can further send the drive starting request to a target address, a target drive function can be stored in the target address, and after calling the target drive function, a corresponding target drive can be started, and then, corresponding physical hardware can be called through the target drive, and target data corresponding to the drive starting request is obtained. For example, when the drive starting request is a recording starting request, the cloud mobile phone client starts to start the recording device and record, and the target data may be recording data; when the drive starting request is a request for starting the camera, the cloud mobile phone client starts to start the camera and starts to record video, and the target data can be video data. Here, the preset application may be an application installed in the cloud phone, that is, a program running on the cloud phone.
And 102, receiving the target data fed back by the preset transmission interface through the intermediate layer, forwarding the target data to the HAL layer, and storing the target data through the HAL layer.
In this embodiment, after the cloud mobile phone client acquires the target data corresponding to the drive starting request, the preset transmission interface may be called to feed the target data back to the intermediate layer. After receiving the target data, the intermediate layer may forward the target data to the HAL layer, so that the target data may be stored in the HAL layer.
By applying the technical scheme of the embodiment, firstly, the HAL layer can monitor a drive starting request of a preset application program running in the cloud mobile phone, after the HAL layer monitors the drive starting request of the preset application program, the drive starting request can be forwarded through the intermediate layer, the drive starting request is sent to a preset transmission interface which is in communication connection with the intermediate layer, after the preset transmission interface of the cloud mobile phone client receives the drive starting request, the cloud mobile phone client can start a corresponding target drive, and target data corresponding to the drive starting request can be acquired through the target drive. Then, after the cloud mobile phone client acquires target data corresponding to the drive starting request, a preset transmission interface can be called to feed the target data back to the intermediate layer. After receiving the target data, the intermediate layer may forward the target data to the HAL layer, so that the target data may be stored in the HAL layer. According to the cloud mobile phone driving method and device, the target data obtained by the cloud mobile phone client are returned to the HAL layer for storage, the driving function of the cloud mobile phone is achieved, the user can use the cloud mobile phone in the process of being unaware of the driving function achieved through the cloud mobile phone client, the cloud mobile phone function is enriched, and meanwhile the experience feeling of the user is greatly improved.
Further, as a refinement and an extension of the specific implementation of the above embodiment, in order to fully describe the specific implementation process of the embodiment, another drive control method based on a cloud mobile phone is provided, and is applied to the cloud mobile phone, as shown in fig. 2, the method includes:
step 201, responding to a cloud mobile phone starting request, loading the HAL layer and the middle layer, and starting a remote connection interface of the middle layer; receiving a communication connection request sent by the preset transmission interface through a remote connection interface of the middle layer, and establishing communication connection with the preset transmission interface;
in this embodiment, after receiving a cloud mobile phone opening request sent by a cloud mobile phone client, the HAL layer and the intermediate layer may be automatically loaded, and after the intermediate layer is loaded, the remote connection interface corresponding to the intermediate layer is opened to wait for connection of the cloud mobile phone client. Here, the remote connection interface corresponding to the middle layer may be a socket server interface. After the preset transmission interface of the cloud mobile phone client sends the communication connection request, the remote connection interface of the middle layer can receive the communication connection request and establish communication connection with the preset transmission interface.
Step 202, monitoring a drive starting request from a preset application program through an HAL layer, sending the drive starting request to an intermediate layer when the drive starting request is monitored, sending the drive starting request to a preset transmission interface of a cloud mobile phone client based on the intermediate layer so as to enable the cloud mobile phone client to start a target drive, acquiring target data corresponding to the drive starting request based on the target drive, and feeding back the target data through the preset transmission interface, wherein the preset application program is an application program installed in a cloud mobile phone;
in this embodiment, the HAL layer may monitor, in real time, a driver start request of a preset application running in the cloud mobile phone, after the HAL layer monitors the driver start request of the preset application, the driver start request may be forwarded through the intermediate layer, the driver start request is sent to a preset transmission interface that establishes communication connection with the intermediate layer, after the driver start request is received by the preset transmission interface of the cloud mobile phone client, the driver start request may be further sent to a target address, a target drive function may be stored in the target address, and after the target drive function is called, a corresponding target driver may be started, and then, a corresponding physical hardware may be called by the target driver, so as to obtain target data corresponding to the driver start request.
Step 203, receiving the target data fed back by the preset transmission interface through the middle layer, and forwarding the target data to the HAL layer;
in this embodiment, after the cloud mobile phone client acquires the target data corresponding to the drive starting request, the preset transmission interface may be called to feed the target data back to the intermediate layer. After receiving the target data, the intermediate layer may forward the target data to the HAL layer.
Step 204, storing the target data through a circular queue in the HAL layer; monitoring a data reading request from the preset application program through the HAL layer, and sending the target data corresponding to the data reading request in the circular queue to the preset application program when the data reading request is monitored;
in this embodiment, when the HAL layer stores the target data, the HAL layer may store the target data in the form of a circular queue, which may greatly reduce the space occupied by the target data storage. The HAL layer may also monitor a data reading request of a preset application program in real time, and after target data is stored in a circular queue of the HAL layer, if the HAL layer monitors the data reading request from the preset application program, the HAL layer may further find target data corresponding to the data reading request from the circular queue and send the target data to the preset application program. After the target data are stored in the circular queue of the HAL layer, the preset application program reads the target data immediately, so that the storage requirement of the target data can be met by the circular queue storage.
Step 205, monitoring a drive closing request from the preset application program through the HAL layer, and when the drive closing request is monitored, sending the drive closing request to the preset transmission interface of the cloud mobile phone client based on the intermediate layer, so that the cloud mobile phone client closes the target drive.
In this embodiment, the HAL layer may also monitor a drive closing request from a preset application in real time, and when the HAL layer monitors the drive closing request, the drive closing request may be sent to a preset transmission interface in the cloud mobile phone client through the intermediate layer, and after the preset transmission interface of the cloud mobile phone client receives the drive closing request, the drive closing request may be further sent to a target address, where a target drive function may be stored in the target address, and after the target drive function is called, the corresponding target drive may be closed.
In this embodiment, another cloud-based mobile phone drive control method is provided, and is applied to a cloud mobile phone client, as shown in fig. 3, the method includes:
step 301, receiving a drive starting request sent by a cloud mobile phone intermediate layer through a preset transmission interface, starting a target drive based on the drive starting request, and acquiring target data corresponding to the drive starting request based on the target drive;
the cloud mobile phone-based drive control method provided by the embodiment of the application can control the real phone drive where the cloud mobile phone client is located, so that the simulation of the cloud mobile phone drive is realized, and the functions of recording, recording video, photographing and the like of the cloud mobile phone are enriched. The cloud mobile phone-based drive control method provided by the embodiment of the application is mainly realized by three parts, namely an HAL layer and an intermediate layer of a cloud mobile phone end and a preset transmission interface of a cloud mobile phone client, wherein the intermediate layer is used for receiving communication between the HAL layer and the preset transmission interface, and the preset transmission interface is used for receiving communication between the intermediate layer and the cloud mobile phone client. The HAL layer may monitor, in real time, a driver start request of a preset application program running in the cloud mobile phone, where the driver start request may include a request for starting a recording, a request for starting a camera, and the like. When the HAL layer monitors a drive starting request of a preset application program, the HAL layer can forward the drive starting request through the middle layer and send the drive starting request to a preset transmission interface which is in communication connection with the middle layer. Firstly, a preset transmission interface of a cloud mobile phone client can receive a drive starting request sent by a cloud mobile phone intermediate layer, then the drive starting request can be further sent to a target address, a target drive function can be stored in the target address, after the target drive function is called, a corresponding target drive can be started, and then, corresponding physical hardware can be called through the target drive to obtain target data corresponding to the drive starting request. For example, when the drive starting request is a recording starting request, the cloud mobile phone client starts to start the recording device and record, and the target data may be recording data; when the drive starting request is a request for starting the camera, the cloud mobile phone client starts to start the camera and starts to record video, and the target data can be video data.
Step 302, calling the preset transmission interface, feeding the target data back to the intermediate layer through the preset transmission interface, so that the intermediate layer forwards the target data to a HAL layer, and storing the target data through the HAL layer.
In this embodiment, after the cloud mobile phone client acquires the target data corresponding to the drive starting request, the preset transmission interface may be called to feed the target data back to the intermediate layer. After receiving the target data, the intermediate layer may forward the target data to the HAL layer, so that the target data may be stored in the HAL layer.
According to the cloud mobile phone driving method and device, the target data obtained by the cloud mobile phone client are returned to the HAL layer for storage, the driving function of the cloud mobile phone is achieved, the user can use the cloud mobile phone in the process of being unaware of the driving function achieved through the cloud mobile phone client, the cloud mobile phone function is enriched, and meanwhile the experience feeling of the user is greatly improved.
Further, as a refinement and an extension of the specific implementation of the above embodiment, in order to fully describe the specific implementation process of the embodiment, another cloud-based drive control method is provided, which is applied to a cloud mobile phone client, as shown in fig. 4, the method includes:
step 401, responding to a cloud mobile phone login instruction, acquiring a login personnel identifier, and generating a cloud mobile phone opening request based on the login personnel identifier; calling an interface layer initialization function, establishing a preset transmission interface in the interface layer after the interface layer is initialized, generating a communication connection request through the preset transmission interface, sending the communication connection request to a remote connection interface of the intermediate layer, and establishing communication connection with the intermediate layer;
in this embodiment, before logging in the cloud mobile phone, a user may generate a cloud mobile phone login instruction by triggering a cloud mobile phone icon on a cloud mobile phone client, and in response to the cloud mobile phone login instruction, may obtain a login person identifier, where the login person identifier may be an identifier corresponding to the cloud mobile phone client. Then, a cloud mobile phone opening request can be generated on the basis of the identification of the login personnel. And then, an interface layer initialization function can be called, the initialization of the interface layer of the cloud mobile phone client is realized through the interface layer initialization function, a preset transmission interface can be established in the interface layer after the initialization is finished, and a communication connection request is generated through the preset transmission interface. After the communication connection request is generated, the preset transmission interface can further send the communication connection request to a remote connection interface of the cloud mobile phone intermediate layer, so that communication connection is successfully established with the intermediate layer, and data transmission is achieved. Here, when the remote connection interface of the middle layer is a Socket server, the preset transmission interface of the cloud mobile phone client may be a Socket client, that is, the Socket client establishes communication connection with the Socket server, and the use of the Unix Socket enables communication to be simpler and more efficient.
Step 402, receiving a drive starting request sent by a cloud mobile phone intermediate layer through a preset transmission interface, starting a target drive based on the drive starting request, and acquiring target data corresponding to the drive starting request based on the target drive;
in this embodiment, first, a preset transmission interface of the cloud mobile phone client may receive a drive start request sent by the cloud mobile phone intermediate layer, then, the drive start request may be further sent to a target address, a target drive function may be stored in the target address, and after the target drive function is called, a corresponding target drive may be further started, and then, a corresponding physical hardware may be called by the target drive, so as to obtain target data corresponding to the drive start request.
Step 403, invoking the preset transmission interface, feeding the target data back to the intermediate layer through the preset transmission interface, so that the intermediate layer forwards the target data to the HAL layer, and storing the target data through the HAL layer.
In this embodiment, after the cloud mobile phone client acquires the target data corresponding to the drive starting request, the preset transmission interface may be called to feed the target data back to the intermediate layer. After receiving the target data, the intermediate layer may forward the target data to the HAL layer, so that the target data may be stored in the HAL layer.
In this embodiment of the present application, optionally, after "after the interface layer is initialized and the preset transmission interface is established in the interface layer" instep 401, the method further includes: sending a preset callback pointer to the preset transmission interface; instep 402, "receiving a drive start request sent by a cloud mobile phone intermediate layer through a preset transmission interface, and starting a target drive based on the drive start request" specifically includes: receiving a drive starting request sent by the cloud mobile phone intermediate layer through the preset transmission interface, identifying the callback pointer through the preset transmission interface, determining a target address corresponding to the callback pointer, forwarding the drive starting request to the target address, and calling a target drive function to start the target drive.
In this embodiment, after the interface layer establishes the preset transmission interface, the preset callback pointer may also be sent to the preset transmission interface, so that the preset transmission interface may send, when receiving the drive-related control requests sent by the remote connection interface from the intermediate layer, the requests to the corresponding target addresses through the callback pointer. Specifically, after the preset transmission interface receives a drive starting request sent by the intermediate layer through the remote transmission interface, the preset transmission interface can identify a corresponding target address in the callback pointer, so that the drive starting request can be sent to the target address, and a target drive function in the target address can be called to start the target drive.
Further, as a specific implementation of the method in fig. 1, an embodiment of the present application provides a drive control apparatus based on a cloud mobile phone, which is applied to the cloud mobile phone, and as shown in fig. 5, the apparatus includes:
the device comprises a request sending module, a data processing module and a data processing module, wherein the request sending module is used for monitoring a drive starting request from a preset application program through an HAL layer, sending the drive starting request to an intermediate layer when the drive starting request is monitored, sending the drive starting request to a preset transmission interface of a cloud mobile phone client based on the intermediate layer so as to enable the cloud mobile phone client to start a target drive, acquiring target data corresponding to the drive starting request based on the target drive, and feeding back the target data through the preset transmission interface, wherein the preset application program is an application program installed in a cloud mobile phone;
and the data receiving module is used for receiving the target data fed back by the preset transmission interface through the middle layer, forwarding the target data to the HAL layer and storing the target data through the HAL layer.
Optionally, the apparatus further comprises:
the loading module is used for responding to a cloud mobile phone starting request before monitoring a driving starting request from a preset application program through the HAL layer, loading the HAL layer and the middle layer and starting a remote connection interface of the middle layer;
and the connection establishing module is used for receiving the communication connection request sent by the preset transmission interface through the remote connection interface of the middle layer and establishing the communication connection with the preset transmission interface.
Optionally, the data receiving module is specifically configured to:
storing the target data by a circular queue in the HAL layer;
the device further comprises:
and the data reading module is used for monitoring a data reading request from the preset application program through the HAL layer after the target data is stored through the circular queue in the HAL layer, and sending the target data corresponding to the data reading request in the circular queue to the preset application program when the data reading request is monitored.
Optionally, the request sending module is further configured to:
monitoring a drive closing request from the preset application program through the HAL layer, and sending the drive closing request to the preset transmission interface of the cloud mobile phone client based on the intermediate layer when the drive closing request is monitored, so that the cloud mobile phone client closes the target drive.
Further, as a specific implementation of the method in fig. 3, an embodiment of the present application provides a drive control apparatus based on a cloud mobile phone, which is applied to a cloud mobile phone client, and as shown in fig. 6, the apparatus includes:
the driving starting module is used for receiving a driving starting request sent by a cloud mobile phone intermediate layer through a preset transmission interface, starting a target drive based on the driving starting request, and acquiring target data corresponding to the driving starting request based on the target drive;
and the interface calling module is used for calling the preset transmission interface, feeding the target data back to the intermediate layer through the preset transmission interface so as to enable the intermediate layer to forward the target data to the HAL layer, and storing the target data through the HAL layer.
Optionally, the apparatus further comprises:
the request generation module is used for responding to a cloud mobile phone login instruction before receiving a driving starting request sent by a cloud mobile phone intermediate layer through a preset transmission interface, acquiring a login personnel identifier and generating a cloud mobile phone starting request based on the login personnel identifier;
the function calling module is used for calling an interface layer initialization function, establishing the preset transmission interface in the interface layer after the interface layer is initialized, generating a communication connection request through the preset transmission interface, sending the communication connection request to the remote connection interface of the middle layer, and establishing communication connection with the middle layer.
Optionally, the apparatus further comprises:
the pointer sending module is used for sending a preset callback pointer to the preset transmission interface after the interface layer establishes the preset transmission interface after the interface layer is initialized;
the drive starting module is specifically used for:
receiving a drive starting request sent by the cloud mobile phone intermediate layer through the preset transmission interface, identifying the callback pointer through the preset transmission interface, determining a target address corresponding to the callback pointer, forwarding the drive starting request to the target address, and calling a target drive function to start the target drive.
It should be noted that other corresponding descriptions of the functional units related to the driving control device based on the cloud mobile phone provided in the embodiment of the present application may refer to corresponding descriptions in the methods in fig. 1 to fig. 4, and are not described herein again.
Based on the above methods shown in fig. 1 to 4, correspondingly, an embodiment of the present application further provides a storage medium, on which a computer program is stored, and the computer program, when executed by a processor, implements the cloud mobile phone-based drive control method shown in fig. 1 to 4.
Based on such understanding, the technical solution of the present application may be embodied in the form of a software product, which may be stored in a non-volatile storage medium (which may be a CD-ROM, a usb disk, a removable hard disk, etc.), and includes several instructions for enabling a computer device (which may be a personal computer, a server, or a network device, etc.) to execute the method according to the implementation scenarios of the present application.
Based on the method shown in fig. 1 to 4 and the virtual device embodiment shown in fig. 5 to 6, in order to achieve the above object, the present application further provides a computer device, which may specifically be a personal computer, a server, a network device, and the like, where the computer device includes a storage medium and a processor; a storage medium for storing a computer program; a processor for executing a computer program to implement the cloud handset based drive control method as shown in fig. 1 to 4.
Optionally, the computer device may also include a user interface, a network interface, a camera, Radio Frequency (RF) circuitry, sensors, audio circuitry, a WI-FI module, and so forth. The user interface may include a Display screen (Display), an input unit such as a keypad (Keyboard), etc., and the optional user interface may also include a USB interface, a card reader interface, etc. The network interface may optionally include a standard wired interface, a wireless interface (e.g., a bluetooth interface, WI-FI interface), etc.
It will be appreciated by those skilled in the art that the present embodiment provides a computer device architecture that is not limiting of the computer device, and that may include more or fewer components, or some components in combination, or a different arrangement of components.
The storage medium may further include an operating system and a network communication module. An operating system is a program that manages and maintains the hardware and software resources of a computer device, supporting the operation of information handling programs, as well as other software and/or programs. The network communication module is used for realizing communication among components in the storage medium and other hardware and software in the entity device.
Through the above description of the embodiments, those skilled in the art will clearly understand that the present application can be implemented by software plus a necessary general hardware platform, and can also be implemented by hardware. The method comprises the steps that firstly, a HAL layer can monitor a drive starting request of a preset application program running in the cloud mobile phone, when the HAL layer monitors the drive starting request of the preset application program, the drive starting request can be forwarded through an intermediate layer, the drive starting request is sent to a preset transmission interface which is in communication connection with the intermediate layer, after the preset transmission interface of a cloud mobile phone client receives the drive starting request, the cloud mobile phone client can start a corresponding target drive, and target data corresponding to the drive starting request can be acquired through the target drive. Then, after the cloud mobile phone client acquires target data corresponding to the drive starting request, a preset transmission interface can be called to feed the target data back to the intermediate layer. After receiving the target data, the intermediate layer may forward the target data to the HAL layer, so that the target data may be stored in the HAL layer. According to the cloud mobile phone driving method and device, the target data obtained by the cloud mobile phone client are returned to the HAL layer for storage, the driving function of the cloud mobile phone is achieved, the user can use the cloud mobile phone in the process of being unaware of the driving function achieved through the cloud mobile phone client, the cloud mobile phone function is enriched, and meanwhile the experience feeling of the user is greatly improved.
Those skilled in the art will appreciate that the figures are merely schematic representations of one preferred implementation scenario and that the blocks or flow diagrams in the figures are not necessarily required to practice the present application. Those skilled in the art will appreciate that the modules in the devices in the implementation scenario may be distributed in the devices in the implementation scenario according to the description of the implementation scenario, or may be located in one or more devices different from the present implementation scenario with corresponding changes. The modules of the implementation scenario may be combined into one module, or may be further split into a plurality of sub-modules.
The above application serial numbers are for description purposes only and do not represent the superiority or inferiority of the implementation scenarios. The above disclosure is only a few specific implementation scenarios of the present application, but the present application is not limited thereto, and any variations that can be made by those skilled in the art are intended to fall within the scope of the present application.