PROGRAM PLAYING METHOD AND APPARATUS

Information

  • Patent Application
  • 20230024313
  • Publication Number
    20230024313
  • Date Filed
    September 26, 2022
    a year ago
  • Date Published
    January 26, 2023
    a year ago
Abstract
In the field of communications technologies, disclosed are a program playing method and apparatus, to resolve problems of relatively high costs of an internet protocol television (IPTV) operator and relatively high costs for subscribing to and maintaining an IPTV service by a user. In the method, a communications device receives a program playing request message sent by using a first transmission protocol. The communications device determines a corresponding target program channel based on a media file identifier included in the program playing request message, and may send a data stream request message to an IPTV platform by using a second transmission protocol. The communications device may send, by using the first transmission protocol, a received data stream to a playing device for play.
Description
TECHNICAL FIELD

This application relates to the field of communications technologies, and in particular, to a program playing method and apparatus.


BACKGROUND

Currently, when an operator runs an internet protocol television (IPTV) service, a home gateway device and a set-top box (STB) terminal are required. When a user subscribes to the IPTV service for the first time, the operator provides the STB terminal free of charge. However, if the STB terminal is damaged, the user needs to purchase a new STB terminal. In addition, the operator also needs to collect a large quantity of STB terminals from STB manufacturers for IPTV service distribution and retail.


Therefore, the current IPTV service causes relatively high costs of the operator and relatively high costs for subscribing to and maintaining the IPTV service by the user.


SUMMARY

This application provides a program playing method and apparatus, to resolve problems of relatively high costs of an operator of an IPTV service and relatively high costs for subscribing to and maintaining the IPTV service by a user in the conventional technology.


According to a first aspect, an embodiment of this application provides a program playing method. The method may be performed by a communications device provided in an embodiment of this application. The communications device may be a device including an STB function module and a DMS function module. For example, the method may be applied to a gateway device with an STB function. In the method, the communications device receives a program playing request message sent by using a first transmission protocol. The program playing request message includes a media file identifier associated with a target program channel. The first transmission protocol may be a DLNA protocol. The communications device determines the corresponding target program channel based on the media file identifier, and may send a data stream request message to an IPTV platform by using a second transmission protocol. The data stream request message includes an identifier of the target program channel, and may be used to request the IPTV platform to send a data stream of the target program channel. The second transmission protocol may be an internet protocol television IPTV protocol. After receiving the data stream request message, the IPTV platform may access a server of the target program channel to obtain the data stream, and send the obtained data stream to the communications device. The communications device receives the data stream sent by the IPTV platform by using the second transmission protocol, and sends, by using the first transmission protocol, the data stream to a playing device for play.


In an example, the second transmission protocol may include a real-time transport protocol (RTP), a real-time streaming protocol (RTSP), and an internet group management protocol (IGMP).


Based on the solution, because a function of a gateway and a function of accessing the IPTV platform can be implemented by using the communications device, a user does not need to separately apply for an STB terminal, so that costs of an IPTV operator and costs for subscribing to and maintaining an IPTV service by the user can be reduced.


In a possible implementation, after being started, the communications device may receive a channel information list sent by the IPTV platform by using the second transmission protocol. The channel information list may include an identifier of a program channel provided by an IPTV service. The communications device may add a media file identifier for an identifier of each program channel in the channel information list, and store a correspondence table between an identifier and a media file identifier of a program channel. Therefore, the communications device may determine, based on the correspondence table, the target program channel corresponding to the media file identifier included in the program playing request message.


Based on the solution, the communications device may receive the channel information list by using the IPTV transmission protocol, add the media file identifier for the identifier of each program channel in the channel information list, and store the correspondence table between an identifier and a media file identifier of each program channel, to implement access to the IPTV platform.


In a possible implementation, the channel information list further includes a server address of each program channel, and the correspondence table also includes the server address of each program channel. The data stream request message sent by the communications device to the IPTV platform may also include a server address of the target program channel, so that the IPTV platform accesses the server address, and obtains the data stream of the target program channel.


Based on the solution, the communications device may determine the server address of each program channel based on the channel information list sent by using the first transmission protocol, and may add the server address of the target program channel to the data stream request message, so that the IPTV platform can obtain the data stream of the target program channel based on the server address.


In a possible implementation, after sending, by using the first transmission protocol, the data stream to the playing device for play, the communications device may further receive a program close instruction message sent by using the first transmission protocol. The program close instruction message may include the media file identifier associated with the target program channel that needs to be closed. The communications device may determine the corresponding target program channel based on the media file identifier. For example, the communications device may determine, based on the correspondence table, the target program channel corresponding to the media file identifier. The communications device may send a program close request message to the IPTV platform by using the second transmission protocol. The program close request message may include the identifier of the target program channel, and the program close request message may be used to request to leave a multicast group of the data stream of the target program channel. After receiving the program close request message, the IPTV platform may remove the communications device from the multicast group of the data stream of the target program channel, so that the communications device does not receive the data stream that is of the target program channel and that is sent by the IPTV platform.


Based on the solution, the communications device may determine, based on the media file identifier in the program close instruction message received by using the DLNA transmission protocol, the target program channel that needs to be closed, and send the program close request message to the IPTV platform by using the IPTV transmission protocol, to close the target program channel.


According to a second aspect, an embodiment of this application further provides a program playing apparatus, which may be configured to perform the operations in any one of the first aspect and the possible implementations of the first aspect. For example, the apparatus may include a module or a unit configured to perform the operations in any one of the first aspect and the possible implementations of the first aspect. For example, the apparatus includes a communications unit and a processing unit.


According to a third aspect, an embodiment of this application further provides another program playing apparatus. The apparatus may include a transceiver and a processor coupled to the transceiver, and may be configured to perform the operations in any one of the first aspect and the possible implementations of the first aspect.


According to a fourth aspect, an embodiment of this application provides a computer program product. The computer program product includes computer program code, and when the computer program code is run by a communications unit and a processing unit or a transceiver and a processor of a program playing apparatus, the program playing apparatus performs the method in any one of the first aspect and the possible implementations of the first aspect.


According to a fifth aspect, an embodiment of this application provides a computer readable storage medium. The computer readable storage medium stores a program, and the program enables a program playing apparatus to perform the method in any one of the first aspect and the possible implementations of the first aspect.


For technical effects that can be achieved in any one of the second aspect to the fifth aspect or any design of any one of the aspects, refer to the technical effects that can be achieved in any one of the first aspect and the designs of the first aspect. Details are not described herein again.





BRIEF DESCRIPTION OF DRAWINGS


FIG. 1 is a schematic diagram of a television program playing system according to this application;



FIG. 2 is an example flowchart of a program playing method according to this application;



FIG. 3 is a schematic diagram of an interface of user equipment according to this application;



FIG. 4 is an example flowchart of a program playing method according to this application;



FIG. 5 is a schematic diagram of an interface of user equipment according to this application;



FIG. 6 is a block diagram of a program playing apparatus according to this application; and



FIG. 7 is a block diagram of a program playing apparatus according to this application.





DESCRIPTION OF EMBODIMENTS

The following describes technical solutions of this application with reference to the accompanying drawings.


Currently, when an operator runs an internet protocol television (IPTV) service, a home gateway device and a set-top box (STB) terminal are required. When a user subscribes to the IPTV service for the first time, the operator provides the STB terminal free of charge. However, if the STB terminal is damaged, the user needs to purchase a new STB terminal. In addition, the operator also needs to collect a large quantity of STB terminals from STB manufacturers for IPTV service distribution and retail. Therefore, the current IPTV service causes relatively high costs of the operator and relatively high costs for subscribing to and maintaining the IPTV service by the user.


If a user does not subscribe to the IPTV service at home, the user may watch a corresponding over the top (OTT) platform television program by using a smart television, or watch a network video by using a mobile terminal or a PC via an OTT client. In the foregoing two methods, videos are transmitted through a network, and obvious freezing often occurs. In addition, both the smart television and the OTT client are bound to an OTT platform, and due to a copyright limitation, program content that can be provided by the smart television and the OTT client may be greatly different from program content provided by an IPTV platform. Main differences are as follows: The OTT platform provides fewer videos on demand and live videos, and has a larger delay when a video goes live on the OTT platform for the first time. In addition, because the mobile terminal is limited by a screen size, the user may be unable to enjoy visual enjoyment brought by large-screen playing.


To resolve the foregoing problems, this application provides a program playing method, to reduce costs of an operator and costs for subscribing to and maintaining an IPTV service by a user. All aspects, embodiments, or features are presented in this application by describing a system that may include a plurality of devices, components, modules, and the like. It should be appreciated and understood that, each system may include another device, component, module, and the like, and/or may not include all devices, components, modules, and the like discussed with reference to the accompanying drawings. In addition, a combination of these solutions may be used.


For ease of understanding embodiments of this application, a television program playing system shown in FIG. 1 is first used as an example to describe in detail a network system applicable to embodiments of this application. FIG. 1 is a diagram of a framework of a network system applicable to the program playing method provided in embodiments of this application. The network system 100 includes an IPTV platform 101, a playing device 102, and a communications device 103. It should be understood that the communications device 103 may further include a plurality of components (for example, a processor, a modulator, a multiplexer, a demodulator, or a demultiplexer) related to signal sending and receiving.


The playing device 102 is a device with a function of playing a video file or an audio file or a chip that may be disposed in the device, and the device includes but is not limited to a television (TV), a mobile phone, a tablet computer (Pad), a computer with a wireless transceiver function, a virtual reality (VR) device, an augmented reality (AR) device, and the like. It should be noted that the playing device 102 in this application can support a digital living network alliance (DLNA) technology and protocol.


In the network system 100, the IPTV platform 101 may communicate with a plurality of communications devices (for example, the communications device 103 shown in the figure). The communications device 103 may communicate with a plurality of playing devices (for example, the playing device 102 shown in the figure). The communications device 103 may be a gateway device, an STB, or the like.


The network architecture and the service scenario that are described in FIG. 1 of embodiments of this application are intended to more clearly describe the technical solutions in embodiments of this application, but are not intended to limit the technical solutions provided in embodiments of this application. A person of ordinary skill in the art may know that as the network architecture evolves and a new service scenario emerges, the technical solutions provided in embodiments of this application may be further applied to another similar network system framework.


The word “example” in the following descriptions is used to indicate an example, an illustration, or a description. Any embodiment or design scheme described as an “example” in this application should not be explained as being more preferred or having more advantages than another embodiment or design scheme. Exactly, the word “example” is used to present a concept in a specific manner.


In embodiments of this application, “information”, “signal”, “message”, and “channel” may be interchangeably used sometimes. It should be noted that expressed meanings are consistent when differences are not emphasized. “Of”, “relevant”, and “corresponding” may be interchangeably used sometimes. It should be noted that expressed meanings are consistent when differences are not emphasized.


It should be understood that FIG. 1 is only an example simplified schematic diagram for ease of understanding. The network system may further include another communications device or another playing device, which is not drawn in FIG. 1.


The communications device in embodiments of this application is a device that may include a set-top box (STB) function module and a digital media server (DMS) function module. The STB function module is configured to provide a video stream or a signal source for the playing device. The DMS function module provides a media sharing capability. Specifically, the DMS function module searches, by using a specific mechanism, for a DMS apparatus or interface module that is on a network and that can match the DMS function module. After a connection succeeds, a subsequent media data transmission action may be performed. A gateway device usually includes the DMS function module. Therefore, the communications device in this application may be a gateway device with an STB function. For example, the STB function may be integrated into a gateway or a gateway-like device. For example, a plug-in integrated with the STB function is loaded into the gateway device, or the STB function may be loaded into the gateway device in a form of a computer program.


To clearly understand the technical solutions provided in embodiments of this application, the following first describes a method for generating a correspondence table between an identifier and a media file identifier of each program channel.


In an example, when a user subscribes to an IPTV service, the communications device initiates an authentication procedure to the IPTV platform after being started. Specifically, the authentication procedure may include the following steps:


(1) The communications device requests a version update from a set-top box version server.


(2) The set-top box version server checks whether a current version of the communications device needs to be updated; and if the version needs to be updated, returns the latest version, so that the version of the communications device is updated; otherwise, notifies the communications device that the version does not need to be updated.


(3) The communications device initiates a login request to an P-CSCF, enters an account and a password, and submits a service authentication request to the proxy-call session control function (P-CSCF) to request the P-CSCF to send the account and the password to an internet protocol multimedia subsystem (IMS) core network.


(4) The IMS core network interacts with a related functional entity, generates a temporary identity certificate and authorization information after authentication on the account and the password succeeds, and notifies an IPTV AS user that the authentication succeeds.


(5) The IMS core network returns an authentication result, the temporary identity certificate, and the authorization information to the P-CSCF, and the P-CSCF generates a new page based on the authentication result, the temporary identity certificate, and the authorization information, and returns the authentication result, the temporary identity certificate, and the authorization information to the communications device.


(6) The communications device updates an electrical program guide (EPG) based on the new page, and records the authorization information and the temporary identity certificate.


It should be understood that the authentication procedure in embodiments of this application may be performed by the STB function module in the communications device.


After the authentication procedure is performed, the STB function module in the communications device may extract a channel information list from the updated EPG. The channel information list may include identifiers of at least two program channels and corresponding server addresses. For example, the channel information list may include channels (for example, CCTV-1) provided by the IPTV platform and server addresses of the channels, as shown in Table 1.









TABLE 1







Channel information










Identifier of a program channel
Server address






Channel 1
Server address 1



Channel 2
Server address 2



Channel 3
Server address 3









It should be understood that the channel information list may be received by using a second transmission protocol. The STB function module may send the channel information list to the DMS function module in the communications device. The DMS function module may add a media file identifier for an identifier of each program channel.


In an embodiment, the media file identifier may be a name of a media file of each program channel. For example, the DMS function module may create and store the media file of the identifier of each program channel. It should be noted that no data is stored in the media file herein. The DMS function module may generate, based on an address for storing the media file, a uniform resource locator (URL) address for accessing the media file. The DMS function module may store a correspondence table between an identifier and a media file identifier of each program channel. The correspondence table may include the media file identifier of each program channel, the identifier of the program channel, a server address, and a URL address, as shown in Table 2.









TABLE 2







Correspondence table










Media file
Identifier of a




identifier
program channel
Server address
URL address





001
Channel 1
Server address 1
URL address 1


002
Channel 2
Server address 2
URL address 2


003
Channel 3
Server address 3
URL address 3









After generating the correspondence table, the DMS function module may send the correspondence table to the playing device and/or user equipment (UE).


The technical solutions provided in embodiments of this application are described below with reference to the accompanying drawings. FIG. 2 is an example flowchart of a program playing method that is provided in an embodiment of this application and that is shown from a perspective of device interaction. As shown in FIG. 2, the method may include the following steps.


Step 201: A communications device receives a program playing request message sent by using a first transmission protocol.


The first transmission protocol herein may be a DLNA protocol. When receiving the program playing request message, the communications device may parse the program playing request message to obtain information in the program playing request message. The program playing request message may include a media file identifier associated with a target program channel. The target program channel in the program playing request message is a program channel that a user requests to play.


In this embodiment of this application, the program playing request message is sent in the following two methods.


Method 1: The user sends the program playing request message by using a playing device.


The playing device herein may be integrated with a related function of a digital media controller (DMC).


In an example, the user may control, by using a remote control, the playing device to send the program playing request message. For example, the user may select, by using a key on the remote control, a channel that the user wants to watch, and the remote control may detect the pressed key, and then may encode key information in a form similar to a Morse code and then send a radio frequency signal to the playing device. The playing device may determine, based on a correspondence between a radio frequency signal and a program channel, a program channel corresponding to the radio frequency signal, or may determine a media file identifier of the program channel based on a correspondence table between an identifier and a media file identifier of a program channel. Therefore, the playing device may send the determined media file identifier to a DMS function module.


In an embodiment, the program playing request message may be carried in a hypertext transfer protocol (HTTP) request. For example, the playing device may obtain a URL address of the program channel based on the correspondence table between an identifier and a media file identifier of a program channel, and send an HTTP request carrying the URL address to the DMS module in the communications device, to request to access a corresponding media file.


In another example, the user may control, by using a key of the playing device, the playing device to send the program playing request message. For example, the user selects, by using a key, a channel that the user wants to watch. The playing device may identify an identifier of the selected program channel, and determine a media file identifier of the program channel based on a correspondence table between an identifier and a media file identifier of a program channel. Therefore, the playing device may send the identified media file identifier to a DMS function module in the communications device.


In an embodiment, the program playing request message may be carried in an HTTP request. For example, after determining the media file identifier of the program channel, the playing device may determine a URL address of the program channel based on the correspondence table, and send an HTTP request carrying the URL address to the DMS function module in the communications device, to request to access a corresponding media file.


Method 2: The user sends the program playing request message by using an application of UE.


The application of the UE may implement a function of a DMC. In an example, the UE may search for a communications device and a playing device in a same network environment by using a universal plug and play (UPNP) protocol, so that the communications device, the playing device, and the UE can communicate with each other.


After receiving a correspondence table sent by a DMS function module, the application of the UE may display a program list shown in FIG. 3, and in this case, the user may select, by using the program list, a program that the user wants to watch. The application of the UE may identify a selected program channel, and obtain a media file identifier from the correspondence table based on an identifier of the selected program channel. The UE may send a program playing request message carrying the media file identifier to the playing device by using a UPNP message, and the playing device may send the program playing request message to the communications device.


In an embodiment, the program playing request message may be carried in an HTTP request. For example, after receiving the program playing request message, the playing device may obtain a URL address from the correspondence table. Alternatively, the UE may obtain a URL address from the correspondence table based on the identifier of the selected program channel. The UE may send the URL address to the playing device by using a UPNP message. The playing device may send an HTTP request carrying the URL address to the DMS function module in the communications device, to request to access a corresponding media file.


It should be understood that, generally, because storage of the communications device is limited, the communications device does not locally store complete media data corresponding to a program. Therefore, the media file provided in Method 1 and Method 2 may be an empty file, in other words, includes no specific media data; or the media file may be a virtual file, and there is only a media file name and an actual file does not exist locally. Media files may be in a one-to-one correspondence with media file identifiers.


Step 202: The communications device determines the corresponding target program channel based on the received media file identifier.


The communications device may determine, based on the correspondence table (Table 2), the target program channel corresponding to the media file identifier. The DMS function module may send an identifier of the target program channel to an STB function module.


Step 203: The communications device sends a data stream request message to an IPTV platform by using a second transmission protocol.


The data stream request message herein includes the identifier of the target channel, and the data stream request message is used to request the IPTV platform to send a data stream of the target program channel. The second transmission protocol may be an IPTV protocol, and the IPTV protocol may include an RTP protocol, an RTSP protocol, an IGMP protocol, or the like.


In an example, the communications device may further add a server address of the target program channel to the data stream request message, and send the data stream request message to the IPTV platform. After receiving the data stream request message, the IPTV platform may access a server of the target program channel based on the server address, obtain the data stream of the target program channel, and send the data stream to the communications device. Because a plurality of communications devices may request the data stream of the target program channel, the IPTV platform may store a list of communications devices requesting the data stream of the target program channel. For example, after receiving the data stream request message carrying the identifier of the target program channel, the IPTV platform may store, in the list of communications devices, identity information of the communications device sending the data stream request message, and send the data stream to each communications device in the list of communications devices.


In another example, the data stream request message may be an IGMP report packet. The STB function module may send the IGMP report packet to the IPTV platform. In the IGMP protocol, a server address can identify a multicast group. Members in the multicast group can receive a multicast data stream, and a device other than the members in the multicast group cannot receive the multicast data stream. Therefore, the communications device may determine a server address of the target program channel based on the correspondence table, and add the identifier and the server address of the target program channel to the report packet. After receiving the report packet, the IPTV platform may add identity information of the communications device to the members in the multicast group, and push the data stream of the target program channel to the communications device.


Step 204: The communications device receives the data stream sent by the IPTV platform by using the second transmission protocol.


Step 205: The communications device sends, by using the first transmission protocol, the data stream to the playing device for play.


In an embodiment, after receiving the data stream sent by the IPTV platform, the STB function module may establish a pipe between the STB function module and a media file of the target program channel, and transmit the data stream to the pipe. A write end of the pipe is a side on which the STB function module is connected to the pipe, and a read end of the pipe is a side on which the pipe is connected to the media file.


After receiving the data stream sent by the IPTV platform, the communications device writes the data stream to the write end of the pipe. The DMS function module may read the data stream from the read end of the pipe, and send, by using the first transmission protocol, the data stream to the playing device for play.


In an example, the playing device may decode and play the data stream. It should be understood that the playing device supporting the DLNA protocol has a decoding function.


In another example, the communications device may decode the data stream, and send data obtained after the decoding to the playing device by using the first transmission protocol. The playing device herein may not have a decoding function.


Based on the solution, because a function of a gateway and a function of accessing the IPTV platform can be implemented by using the communications device, the user does not need to separately apply for an STB terminal, so that costs of an IPTV operator and costs for subscribing to and maintaining an IPTV service by the user can be reduced.


In embodiments of this application, a program being played on a playing device may be further closed. FIG. 4 is an example flowchart of a method, shown from a perspective of device interaction, for closing a program being played in an embodiment of this application. The method may include the following steps.


Step 401: A communications device receives a program close instruction message sent by using a first transmission protocol.


The program close instruction message herein may include a media file identifier associated with a target program channel that needs to be closed. For the media file identifier and the first transmission protocol, refer to related descriptions in the foregoing method embodiment. Details are not described herein again.


In this embodiment of this application, the program close instruction message may be sent in the following two manners.


Manner 1: A user sends the program close instruction message by using a playing device.


The playing device herein may be integrated with a related function of a DMC.


In an example, the user may close, by using a close key on a remote control, the target program channel being played. In this case, the remote control may send a corresponding radio frequency signal to the playing device. The playing device may identify the media file identifier of the target program channel and/or an identifier of the target program channel, add the media file identifier and/or the identifier of the target program channel to the program close instruction message, and send the program close instruction message to the communications device by using the first transmission protocol. The playing device may be further powered off based on the radio frequency signal.


Manner 2: A user sends the program close instruction message by using an application of UE.


The application of the UE may implement a function of a DMC. After the user plays a selected program through step 201 to step 205, a program being played may be displayed on the UE, as shown in FIG. 5. The user closes, in the interface, the program being played. For example, the user may close, by using a close key, the program being played, or the user may double-tap or perform a slide operation on the program being played, to close the program. This is not specifically limited in this application. The UE may identify a media file identifier of the program, and therefore the UE may send the program close instruction message carrying the media file identifier to a DMS function module in the communications device by using a UPNP message.


Step 402: Determine the corresponding target program channel based on the media file identifier.


The communications device herein may determine, based on a correspondence table between an identifier and a media file identifier of a program channel, the target program channel corresponding to the media file identifier. The communications device may further determine a server address of the target program channel based on the correspondence table.


Step 403: The communications device sends a program close request message to an IPTV platform by using a second transmission protocol.


The communications device may add the identifier of the target program channel to the program close request message, and send the program close request message to the IPTV platform. After receiving the program close request message, the IPTV platform may delete identity information of the communications device from a list of communications devices of the target program channel. In this case, the IPTV platform no longer sends a data stream of the target program channel to the communications device.


In an example, the program close request message may be an IGMP leave packet. An STB function module may add the identifier of the target program channel and the server address of the target program channel to the leave packet. After receiving the IGMP leave packet sent by the STB function module, the IPTV platform may delete the identity information of the communications device from a multicast group identified by the server address, so that the IPTV platform no longer sends the data stream of the target program channel to the communications device.


The STB function module in the communications device may also stop transmitting the data stream to a write end of a pipe between the STB function module and a media file of the target program channel, and the DMS function module may stop reading the data stream from a read end of the pipe.


The foregoing describes in detail the program playing method in embodiment of this application with reference to FIG. 1 to FIG. 5. The following describes in detail a program playing apparatus in embodiment of this application with reference to FIG. 6 and FIG. 7.


A program playing apparatus 600 includes one or more processors 601, and the one or more processors 601 may implement the method in the embodiment shown in FIG. 2 or FIG. 4.


In a possible design, the program playing apparatus 600 includes a means configured to determine a corresponding target program channel based on a media file identifier. For the media file identifier and the target program channel, refer to related descriptions in the foregoing method embodiments. For example, the target program channel may be determined by using one or more processors. Optionally, the processor 601 may implement another function in addition to implementing the method in the embodiment shown in FIG. 2 or FIG. 4.


Optionally, in a design, the processor 601 may execute instructions 603, so that the program playing apparatus 600 performs the method described in the foregoing method embodiment. All or some of the instructions may be stored in the processor, or may be stored in a memory 602 coupled to the processor.


In another possible design, the program playing apparatus 600 may further include a circuit, and the circuit may implement the functions in the foregoing method embodiment.


In still another possible design, the program playing apparatus 600 may include one or more memories 602. The one or more memories 602 store instructions 604, and the instructions may run on the processor, so that the program playing apparatus 600 performs the method described in the foregoing method embodiment. Optionally, the memory may further store data. Optionally, the processor may also store instructions and/or data. For example, the one or more memories 602 may store the channel information list described in the foregoing embodiment. The processor and the memory may be separately disposed, or may be integrated together.


In yet another possible design, the program playing apparatus 600 may further include a transceiver unit 605 and an antenna 606. The processor 601 may be referred to as a processing unit, and controls the program playing apparatus. The transceiver unit 605 may be referred to as a transceiver, a transceiver circuit, or the like, and is configured to implement a transceiver function of the program playing apparatus by using the antenna 606.


In a possible implementation, a program playing apparatus 700 shown in FIG. 7 may be used as the communications device in the foregoing method embodiment, and perform the steps performed by the communications device in the foregoing method embodiment. As shown in FIG. 7, the program playing apparatus 700 may include a processing unit 701 and a communications unit 702, and the processing unit 701 and the communications unit 702 are mutually coupled. The processing unit 701 may be configured to support the program playing apparatus 700 in performing a processing action in the foregoing method embodiment.


When actions performed by the program playing apparatus in the foregoing method embodiments are performed, the communications unit 702 may be configured to receive a program playing request message sent by using a first transmission protocol; or may be configured to send a data stream request message to an IPTV platform by using a second transmission protocol; or may be configured to: receive a data stream sent by an IPTV platform by using a second transmission protocol, and send, by using a first transmission protocol, the data stream to a playing device for play. For the first transmission protocol and the second transmission protocol, refer to related descriptions in the foregoing method embodiments.


The processing unit 701 may be configured to determine a corresponding target program channel based on a media file identifier.


In a design, the communications unit 702 may be further configured to receive a channel information list sent by the IPTV platform by using the second transmission protocol. For the channel information list, refer to related descriptions in the foregoing method embodiments.


The processing unit 701 may be further configured to: add a media file identifier for an identifier of each program channel in the channel information list, and store a correspondence table between an identifier and a media file identifier of each program channel. For the channel information list, refer to related descriptions in the foregoing method embodiments.


In a design, the communications unit 702 may be further configured to receive a program close instruction message sent by using the first transmission protocol; or may be configured to send a program close request message to the IPTV platform by using the second transmission protocol. For the program close instruction message and the program close request message, refer to related descriptions in the foregoing method embodiments.


The processing unit 701 may be further configured to determine the corresponding target program channel based on the media file identifier.


One or more of the units in FIG. 7 may be implemented by software, hardware, firmware, or a combination thereof. The software or the firmware includes but is not limited to a computer program instruction or code, and may be executed by a hardware processor. The hardware includes but is not limited to a variety of integrated circuits such as a central processing unit (CPU), a digital signal processor (DSP), a field programmable gate array (FPGA), or an application-specific integrated circuit (ASIC).


It should be noted that the processor in embodiments of this application may be an integrated circuit chip, and has a signal processing capability. In an implementation process, the steps in the foregoing method embodiments may be completed by using a hardware integrated logic circuit in the processor or instructions in a form of software. The foregoing processor may be a general-purpose processor, a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field programmable gate array (FPGA) or another programmable logic device, a discrete gate or transistor logic device, or a discrete hardware component. The methods, steps, and logical block diagrams that are disclosed in embodiments of this application may be implemented or performed. The general-purpose processor may be a microprocessor, or the processor may be any conventional processor or the like. The steps of the methods disclosed with reference to embodiments of this application may be directly performed and completed by a hardware decoding processor, or may be performed and completed by using a combination of hardware in the decoding processor and a software module. The software module may be located in a mature storage medium in the art, such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory, an electrically erasable programmable memory, or a register. The storage medium is located in the memory, and the processor reads information in the memory and completes the steps in the foregoing methods in combination with hardware of the processor.


It may be understood that, in embodiments of this application, the memory may be a volatile memory or a non-volatile memory, or may include both a volatile memory and a non-volatile memory. The non-volatile memory may be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory may be a random access memory (RAM), used as an external cache. Through example but not limitative description, many forms of RAMs may be used, for example, a static random access memory (SRAM), a dynamic random access memory (DRAM), a synchronous dynamic random access memory (SDRAM), a double data rate synchronous dynamic random access memory (DDR SDRAM), an enhanced synchronous dynamic random access memory (ESDRAM), a synchlink dynamic random access memory (SLDRAM), and a direct rambus random access memory (DR RAM). It should be noted that the memory in the system and the methods described in this specification aims to include but is not limited to these memories and any memory of another proper type.


An embodiment of this application further provides a computer readable medium. The computer readable medium stores a computer program, and when the computer program is executed by a computer, the program playing method in any one of the foregoing method embodiments is implemented.


An embodiment of this application further provides a computer program product. When the computer program product is executed by a computer, the program playing method in any one of the foregoing method embodiments is implemented.


All or some of the foregoing embodiments may be implemented by using software, hardware, firmware, or any combination thereof. When software is used to implement the embodiments, all or some of the embodiments may be implemented in a form of a computer program product. The computer program product includes one or more computer instructions. When the computer instructions are loaded and executed on a computer, the procedures or functions according to embodiments of this application are completely or partially generated. The computer may be a general-purpose computer, a dedicated computer, a computer network, or another programmable apparatus. The computer instructions may be stored in a computer-readable storage medium or may be transmitted from a computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions may be transmitted from a website, computer, server, or data center to another website, computer, server, or data center in a wired (for example, a coaxial cable, an optical fiber, or a digital subscriber line (DSL)) or wireless (for example, infrared, radio, or microwave) manner. The computer-readable storage medium may be any usable medium accessible by a computer, or a data storage device, such as a server or a data center, integrating one or more usable media. The usable medium may be a magnetic medium (for example, a floppy disk, a hard disk, or a magnetic tape), an optical medium (for example, a high-density digital video disc (DVD)), a semiconductor medium (for example, a solid state disk (SSD)), or the like.


An embodiment of this application further provides a program playing apparatus, including a processor and an interface. The processor is configured to perform the program playing method in any one of the foregoing method embodiments.


It should be understood that the program playing apparatus may be a chip. The processor may be implemented by hardware, or may be implemented by software. When the processor is implemented by the hardware, the processor may be a logic circuit, an integrated circuit, or the like. When the processor is implemented by the software, the processor may be a general-purpose processor. The general-purpose processor is implemented by reading software code stored in a memory. The memory may be integrated into the processor, or may be located outside the processor and exist independently.


In addition, functional units in embodiments of this application may be integrated into one processing unit, each of the units may exist alone physically, or two or more units may be integrated into one unit. The integrated unit may be implemented in a form of hardware, or may be implemented in a form of a software functional unit.


The foregoing descriptions are merely specific implementations of this application, but are not intended to limit the protection scope of this application. Any variation or replacement readily figured out by a person skilled in the art within the technical scope disclosed in this application shall fall within the protection scope of this application.

Claims
  • 1. A program playing method, comprising: receiving a program playing request message using a first transmission protocol, wherein the program playing request message comprises a media file identifier corresponding to a target program channel, and the first transmission protocol is a digital living network alliance (DLNA) protocol;determining the target program channel based on the media file identifier in the program playing request message;sending a data stream request message to an internet protocol television (IPTV) platform using a second transmission protocol, wherein the data stream request message comprises an identifier of the target program channel, and is used to request the IPTV platform to send a data stream of the target program channel, and the second transmission protocol is an IPTV protocol;receiving the data stream from the IPTV platform using the second transmission protocol; andsending, using the first transmission protocol, the data stream to a playing device for play.
  • 2. The method according to claim 1, wherein before receiving the program playing request comprising the media file identifier, the method further comprises: receiving a channel information list from the IPTV platform using the second transmission protocol, wherein the channel information list comprises identifiers of at least two program channels;for each program channel in the channel information list, identifying a media file identifier for the program channel; andstoring a correspondence table between the identifiers for the program channels in the channel information list and media file identifiers corresponding to the program channels.
  • 3. The method according to claim 2, wherein the channel information list further comprises a server address of each program channel in the channel information list, and the correspondence table also comprises the server address of each program channel in the channel information list; andwherein the data stream request message comprises a server address of the target program channel, to allow the IPTV platform to access the server address and obtain the data stream.
  • 4. The method according to claim 1, wherein after the sending, using the first transmission protocol, the data stream to the playing device for play, the method further comprises: receiving a program close instruction message using the first transmission protocol, wherein the program close instruction message comprises the media file identifier corresponding to the target program channel that needs to be closed;determining the target program channel based on the media file identifier in the program close instruction message; andsending a program close request message to the IPTV platform using the second transmission protocol, wherein the program close request message comprises the identifier of the target program channel, and is used to request to leave a multicast group of the data stream of the target program channel.
  • 5. The method according to claim 1, wherein the second transmission protocol comprises an internet group management protocol (IGMP) protocol.
  • 6. An apparatus, comprising: a memory, configured to store a computer program; anda processor, configured to execute the computer program stored in the memory, to enable the apparatus to perform a program playing method, wherein the method comprises: receiving a program playing request message using a first transmission protocol, wherein the program playing request message comprises a media file identifier corresponding to a target program channel, and the first transmission protocol is a digital living network alliance (DLNA) protocol;determining the target program channel based on the media file identifier in the program playing request message;sending a data stream request message to an internet protocol television (IPTV) platform using a second transmission protocol, wherein the data stream request message comprises an identifier of the target program channel, and is used to request the IPTV platform to send a data stream of the target program channel, and the second transmission protocol is an IPTV protocol;receiving the data stream from the IPTV platform using the second transmission protocol; andsending, using the first transmission protocol, the data stream to a playing device for play.
  • 7. The apparatus according to claim 6, wherein before receiving the program playing request comprising the media file identifier, the method further comprises: receiving a channel information list from the IPTV platform using the second transmission protocol, wherein the channel information list comprises identifiers of at least two program channels;for each program channel in the channel information list, identifying a media file identifier for the program channel; andstoring a correspondence table between the identifiers for the program channels in the channel information list and media file identifiers corresponding to the program channels.
  • 8. The apparatus according to claim 7, wherein the channel information list further comprises a server address of each program channel in the channel information list, and the correspondence table also comprises the server address of each program channel in the channel information list; andwherein the data stream request message comprises a server address of the target program channel, to allow the IPTV platform to access the server address and obtain the data stream.
  • 9. The apparatus according to claim 6, wherein after the sending, using the first transmission protocol, the data stream to the playing device for play, the method further comprises: receiving a program close instruction message using the first transmission protocol, wherein the program close instruction message comprises the media file identifier corresponding to the target program channel that needs to be closed;determining the target program channel based on the media file identifier in the program close instruction message; andsending a program close request message to the IPTV platform using the second transmission protocol, wherein the program close request message comprises the identifier of the target program channel, and is used to request to leave a multicast group of the data stream of the target program channel.
  • 10. The apparatus according to claim 6, wherein the second transmission protocol comprises an internet group management protocol (IGMP) protocol.
  • 11. A non-transitory computer-readable medium, wherein the non-transitory computer-readable medium stores computer-executable instructions, and the computer-executable instructions, when executed, are used to enable a computer to perform a program playing method, wherein the method comprises: receiving a program playing request message using a first transmission protocol, wherein the program playing request message comprises a media file identifier corresponding to a target program channel, and the first transmission protocol is a digital living network alliance (DLNA) protocol;determining the target program channel based on the media file identifier in the program playing request message;sending a data stream request message to an internet protocol television (IPTV) platform using a second transmission protocol, wherein the data stream request message comprises an identifier of the target program channel, and is used to request the IPTV platform to send a data stream of the target program channel, and the second transmission protocol is an IPTV protocol;receiving the data stream from the IPTV platform using the second transmission protocol; andsending, using the first transmission protocol, the data stream to a playing device for play.
  • 12. The non-transitory computer-readable medium according to claim 11, wherein before receiving the program playing request comprising the media file identifier, the method further comprises: receiving a channel information list from the IPTV platform using the second transmission protocol, wherein the channel information list comprises identifiers of at least two program channels;for each program channel in the channel information list, identifying a media file identifier for the program channel; andstoring a correspondence table between the identifiers for the program channels in the channel information list and media file identifiers corresponding to the program channels.
  • 13. The non-transitory computer-readable medium according to claim 12, wherein the channel information list further comprises a server address of each program channel in the channel information list, and the correspondence table also comprises the server address of each program channel in the channel information list; andwherein the data stream request message comprises a server address of the target program channel, to allow the IPTV platform to access the server address and obtain the data stream.
  • 14. The non-transitory computer-readable medium according to claim 11, wherein after the sending, using the first transmission protocol, the data stream to the playing device for play, the method further comprises: receiving a program close instruction message using the first transmission protocol, wherein the program close instruction message comprises the media file identifier corresponding to the target program channel that needs to be closed;determining the target program channel based on the media file identifier in the program close instruction message; andsending a program close request message to the IPTV platform using the second transmission protocol, wherein the program close request message comprises the identifier of the target program channel, and is used to request to leave a multicast group of the data stream of the target program channel.
  • 15. The non-transitory computer-readable medium according to claim 11, wherein the second transmission protocol comprises an internet group management protocol (IGMP) protocol.
Priority Claims (1)
Number Date Country Kind
202010231153.2 Mar 2020 CN national
CROSS-REFERENCE TO RELATED APPLICATIONS

This application is a continuation of International Application No. PCT/CN2021/081664, filed on Mar. 19, 2021, which claims priority to Chinese Patent Application No. 202010231153.2, filed on Mar. 27, 2020. The disclosures of the aforementioned applications are hereby incorporated by reference in their entireties.

Continuations (1)
Number Date Country
Parent PCT/CN2021/081664 Mar 2021 US
Child 17953053 US