Disclosure of Invention
In view of the above, a screen projection method, a server, a screen projection system, and a storage medium are provided to solve the problem that dedicated screen projection hardware is required in the existing screen projection technology, to eliminate the limitation that a television terminal needs to support a screen projection function in screen projection, and to solve the problem that the dedicated screen projection hardware or the television terminal is found one-to-one when the number of the dedicated screen projection hardware or the television terminal is too large.
The invention adopts the following technical scheme:
in a first aspect, an embodiment of the present application provides a screen projection method, where the method includes:
the mobile terminal scans equipment identification to realize the binding of the mobile terminal and the screen projection equipment;
the mobile terminal sends a screen projection control request to a server;
the server applies a virtual screen projection service to convert the screen projection control request into a control command of the screen projection equipment;
and the screen projection equipment acquires and responds to the control command so as to project the application content of the mobile terminal.
Further, the screen projection device acquiring the control command includes:
the screen projection equipment acquires the control command from the server through a hypertext transfer protocol; or, the screen projection equipment receives the control command sent by the server through a user datagram protocol.
Further, the screen projection equipment comprises a television or a set top box.
Further, the virtual screen projection service includes a device virtual screen projection service supporting a DLNA screen projection protocol.
Further, the virtualized screen projection service includes virtualization of a plurality of hardware terminals that support screen projection functionality.
Further, the device identifier includes a two-dimensional code or a bar code currently displayed by the device.
In a second aspect, an embodiment of the present application provides a server, where the server includes at least two network connection ports, where:
the first network connection port is used for connecting a guest network where the mobile terminal is located;
the second network connection port is used for connecting screen projection equipment, and the server receives a screen projection control request from the mobile terminal;
the server applies a virtual screen projection service to convert the screen projection control request into a control command of the screen projection equipment;
and the server sends the control command to the screen projection equipment so as to instruct the screen projection equipment to project the screen.
Further, the third network connection port is connected to the internet and is used for maintaining the server through the internet.
In a third aspect, an embodiment of the present application provides a screen projection system, where the screen projection system includes the mobile terminal and the screen projection device described in the first aspect of the embodiment of the present application, and the server described in the second aspect.
In a fourth aspect, an embodiment of the present application provides a storage medium, where the storage medium stores a computer program, and when the computer program is executed by a processor, the computer program implements the steps in the screen projection method according to the first aspect.
According to the technical scheme, the mobile terminal and the screen projection equipment are bound through the mobile terminal scanning equipment identification, so that the mobile terminal and the screen projection equipment are bound one to one, and one mobile terminal is ensured to find only one screen projection equipment; the mobile terminal sends a screen projection control request to the server; the server applies a virtual screen projection service to convert a screen projection control request into a control command of screen projection equipment; and the screen projection equipment acquires and responds to the control command so as to project the application content of the mobile terminal. By applying the virtual screen projection server, the screen projection has common adaptation, and screen projection can be realized without screen projection equipment with a screen projection function or special screen projection hardware. The problem that special screen projection hardware is needed in the existing screen projection technology is solved, the limitation that the television terminal needs to support the screen projection function in the screen projection is eliminated, and in addition, the problem that the special screen projection hardware or the television terminal is discovered one to one when the number of the television terminals is too large is also solved.
Examples
Fig. 1 is a flowchart of a screen projection method according to an embodiment of the present invention. Referring to fig. 1, the method may specifically include the following steps:
s101, the mobile terminal scans the device identification to achieve binding of the mobile terminal and the screen projection device.
Specifically, the applicable scene of the embodiment of the application is a commercial scene, for example, places such as hotels and nursing homes, and is different from a household scene, the number of screen projection devices in the scene is usually many, for example, each hotel room has one screen projection device, and 300 hotel rooms are taken as examples, so that the number of screen projection devices in one hotel is as many as 300, and the number of screen projection devices in the household scene is usually only 2-3, and a user can automatically judge which screen projection device to project a screen, so that the problem caused by excessive screen projection devices in the commercial scene does not exist. Taking a hotel scene as an example, the mobile terminal can be a mobile phone of a hotel guest, and the screen projection equipment can be a television terminal of a hotel room.
Firstly, a one-to-one connection between the mobile terminal and the screen projection device needs to be established, and optionally, the device identifier includes a two-dimensional code or a bar code displayed by the current device. In a specific application scenario, a display interface for scanning a code and projecting a screen is usually arranged on a television terminal, and a user can scan a two-dimensional code or a bar code on the display interface by using a mobile phone of the user so as to realize the binding of the mobile terminal and screen projecting equipment, so that one mobile terminal can only find one television or set top box.
S102, the mobile terminal sends a screen projection control request to the server.
Specifically, when the mobile terminal has a screen projection requirement, a screen projection control request may be sent to the server, and for example, the screen projection control request may be implemented by a user by starting a screen projection function of a corresponding application of the mobile phone. In a specific example, the screen-casting control request sent by the mobile terminal may be a DLNA screen-casting control request.
S103, the server applies the virtual screen projection service to convert the screen projection control request into a control command of the screen projection equipment.
Optionally, the virtualized screen-casting service includes a device virtualized screen-casting service supporting a DLNA screen-casting protocol. In the embodiment of the application, the virtual screen projection service can convert the screen projection control request of the mobile phone of the user into the control command of the screen projection equipment, so that the screen projection equipment can recognize and receive the control command. For example, taking a video as an example, the control command may be to play a certain video, or may be to pause or fast forward. In addition, the virtualized screen projection service in the embodiment of the application supports virtualization of a plurality of hardware terminals with screen projection functions.
And S104, the screen projection equipment acquires and responds to the control command so as to project the application content of the mobile terminal.
Specifically, after the screen projection device obtains the control command, information included in the control command, for example, screen projection content and a device identifier of the mobile terminal bound to the screen projection device, may be analyzed. Therefore, the application content of the mobile terminal bound one to one can be accurately projected on the screen projection device. In a specific example, the application may be a video application, an audio application, or other applications. And projecting the application content of the mobile terminal. In addition, the video application content of the mobile terminal is projected in a Streaming mode.
Optionally, the acquiring the control command by the screen projection device includes: the screen projection equipment acquires a control command from the server through a hypertext transfer protocol; or, the screen projection equipment receives a control command sent by the server through a user datagram protocol. The screen projection equipment acquires the control command in two modes, one mode is an active acquisition mode, and the other mode is a passive receiving mode. Specifically, the two modes have different transmission protocols, and in the first mode, a control command is actively acquired from a server through a hypertext transmission protocol; in the second mode, the server sends the control command to the screen projection device through a user datagram protocol.
According to the technical scheme, the mobile terminal and the screen projection equipment are bound through the mobile terminal scanning equipment identification, so that the mobile terminal and the screen projection equipment are bound one to one, and one mobile terminal is ensured to find only one screen projection equipment; the mobile terminal sends a screen projection control request to the server; the server applies a virtual screen projection service to convert a screen projection control request into a control command of screen projection equipment; and the screen projection equipment acquires and responds to the control command so as to project the application content of the mobile terminal. By applying the virtual screen projection server, the screen projection has common adaptation, and screen projection can be realized without screen projection equipment with a screen projection function or special screen projection hardware. The problem that special screen projection hardware is needed in the existing screen projection technology is solved, the limitation that the television terminal needs to support the screen projection function in the screen projection is eliminated, and in addition, the problem that the special screen projection hardware or the television terminal is discovered one to one when the number of the television terminals is too large is also solved.
In summary, the technical scheme of the embodiment of the application has the following beneficial effects that screen projection hardware is not needed, the DLNA protocol is realized through software, DLNA screen projection equipment is virtualized, that is, the television terminal does not need to support the DLNA protocol, and the requirement on the television terminal is reduced; the simple screen-projecting action control instruction protocol aiming at the television terminal is realized; in addition, screen projection can be realized in a uniform mode aiming at television terminals of various brands, and the method is particularly suitable for commercial scenes.
Fig. 2 is a schematic structural diagram of a server according to an embodiment of the present invention. Referring to fig. 2, the server may specifically include at least two network connection ports.
Wherein: the first network connection port 21 is used for connecting a guest network where the mobile terminal is located; the second network connection port 22 is used for connecting a screen projection device; the method comprises the steps that a server receives a screen projection control request from a mobile terminal; the server applies a virtual screen projection service to convert a screen projection control request into a control command of screen projection equipment; and the server sends the control command to the screen projection equipment so as to instruct the screen projection equipment to project the screen.
Specifically, since the application scenario of the embodiment of the application is generally a commercial scenario, taking a hotel as an example, the mobile terminal, for example, a mobile phone of a guest is generally in a guest network, and the screen projection device, for example, a television terminal of a hotel room is in a MYCOOL local area network. Therefore, the server comprises at least two network connection ports, and the first network connection port 21 is connected to a guest network where the mobile terminal is located; the second network connection port 22 is connected to a screen projection device.
In the actual application process, the server receives a screen projection control request from the mobile terminal; then, converting a screen projection control request into a control command of screen projection equipment by applying a virtual screen projection service; and sending the control command to the screen projection equipment to indicate the screen projection equipment to project the screen.
Optionally, the third network connection port 23 is connected to the internet, and is used for maintaining the server through the internet. In addition, in order to make the functions of the server more complete, the third network connection port 23 of the server is connected to the internet, so that the server can be periodically or periodically maintained.
The embodiment of the present application further provides a screen projection system, and referring to fig. 3, the screen projection system includes the mobile terminal 31, the screen projection device 32, and the server 20 in the embodiment of the present application. In the embodiment of the present application, the number of the network connection ports is at least two, and in fig. 3, three network connection ports are used as an example, which include a first network connection port 21, a second network connection port 22, and a third network connection port 23. Further, 33 and 34 denote switches for providing a guest network and a MYCOOL local area network, respectively. It should be noted that fig. 3 illustrates only three mobile terminals and three screen projection devices, and is not limited in particular.
The embodiment of the invention also provides a storage medium, wherein the storage medium stores a computer program, and when the computer program is executed by a processor, the steps in the screen projection method in the embodiment of the invention are realized; the mobile terminal scans the equipment identifier to realize the binding of the mobile terminal and the screen projection equipment; the mobile terminal sends a screen projection control request to the server; the server applies a virtual screen projection service to convert a screen projection control request into a control command of screen projection equipment; and the screen projection equipment acquires and responds to the control command so as to project the application content of the mobile terminal.
It is understood that the same or similar parts in the above embodiments may be mutually referred to, and the same or similar parts in other embodiments may be referred to for the content which is not described in detail in some embodiments.
It should be noted that the terms "first," "second," and the like in the description of the present invention are used for descriptive purposes only and are not to be construed as indicating or implying relative importance. Further, in the description of the present invention, the meaning of "a plurality" means at least two unless otherwise specified.
Any process or method descriptions in flow charts or otherwise described herein may be understood as representing modules, segments, or portions of code which include one or more executable instructions for implementing specific logical functions or steps of the process, and alternate implementations are included within the scope of the preferred embodiment of the present invention in which functions may be executed out of order from that shown or discussed, including substantially concurrently or in reverse order, depending on the functionality involved, as would be understood by those reasonably skilled in the art of the present invention.
It should be understood that portions of the present invention may be implemented in hardware, software, firmware, or a combination thereof. In the above embodiments, the various steps or methods may be implemented in software or firmware stored in memory and executed by a suitable instruction execution system. For example, if implemented in hardware, as in another embodiment, any one or combination of the following techniques, which are known in the art, may be used: a discrete logic circuit having a logic gate circuit for implementing a logic function on a data signal, an application specific integrated circuit having an appropriate combinational logic gate circuit, a Programmable Gate Array (PGA), a Field Programmable Gate Array (FPGA), or the like.
It will be understood by those skilled in the art that all or part of the steps carried by the method for implementing the above embodiments may be implemented by hardware related to instructions of a program, which may be stored in a computer readable storage medium, and when the program is executed, the program includes one or a combination of the steps of the method embodiments.
In addition, functional units in the embodiments of the present invention may be integrated into one processing module, or each unit may exist alone physically, or two or more units are integrated into one module. The integrated module can be realized in a hardware mode, and can also be realized in a software functional module mode. The integrated module, if implemented in the form of a software functional module and sold or used as a stand-alone product, may also be stored in a computer readable storage medium.
The storage medium mentioned above may be a read-only memory, a magnetic or optical disk, etc.
In the description herein, references to the description of the term "one embodiment," "some embodiments," "an example," "a specific example," or "some examples," etc., mean that a particular feature, structure, material, or characteristic described in connection with the embodiment or example is included in at least one embodiment or example of the invention. In this specification, the schematic representations of the terms used above do not necessarily refer to the same embodiment or example. Furthermore, the particular features, structures, materials, or characteristics described may be combined in any suitable manner in any one or more embodiments or examples.
Although embodiments of the present invention have been shown and described above, it is understood that the above embodiments are exemplary and should not be construed as limiting the present invention, and that variations, modifications, substitutions and alterations can be made to the above embodiments by those of ordinary skill in the art within the scope of the present invention.