A kind of method of rapidly deleting EPG data of set-top boxTechnical field
The present invention relates to technical field of digital television set-top, relate in particular to a kind of method of rapidly deleting EPG data of set-top box.
Background technology
Electronic program guides (EPG:Electronic Program Guide) is a kind of data message that is stored on the set-top box, it provides the human-computer interaction interface that is made of literal, figure and image etc. by video screen to the user, is responsible for the navigation of TV programme and various value-added services.Electronic program guides is a critical function of digital TV set-top box, the electronic program guides of existing set-top box generally can provide some days interior detailed programme informations to the user, comprise program broadcasting time, program detailed content etc., make the user can understand the content of TV program and the broadcast time of advance notice fast, so that can in time watch and be user-friendly to favorite program.Because the memory capacity of memory is limited in the set-top box, when the electronic program guide information of needs storage surpasses the memory capacity of set-top box memory, the data that need to store before the deletion could be stored new electronic program guide information, and the data of storage just can not receive the new electronic program guide information of storage before not deleting.
Existing set-top box adopts waits for that the user deletes expired EPG data, does not then store new electronic program guide information as not deleting expired EPG data, and this way can not in time be stored new electronic program guide information, and inconvenient user uses.The set-top box that perhaps has is a foundation with the electronic program guide information Data Receiving time, take to delete the way of the EPG data of receiving at first and delete the EPG data of storage in the past so that store new EPG data, adopt this method, user in the set-top box can be thought the data deletion of the portions of electronics performance guide information that keeps, when the user need use these data once more, must obtain data again, the user can't in time see in a period of time and wants the portions of electronics performance guide information that keeps.
Summary of the invention
The object of the invention provides and a kind ofly can preferentially keep electronic program guide information that the user watched, can upgrade in time the method for rapidly deleting EPG data of set-top box of effective electron performance guide information again automatically.
The present invention is by the following technical solutions: the method for rapidly deleting EPG data of set-top box comprises the steps:
Step 01: the set-top box program receives new EPG data, detect and judge whether the memory space of set-top box memory enough stores new EPG data, when insufficient memory is deposited new EPG data, whether expired EPG data early than current system time are arranged in the detection of stored space, if have then delete this expired EPG data, detect to judge whether memory space enough stores new EPG data again, if memory space is enough stored new EPG data, then directly storage;
Step 02: if memory space was still stored new EPG data inadequately after step 01 was finished, which TV programme what detect then that the user watches at present is, determines the frequency at the TV programme place that this is being watched;
Step 03: read current all the rendition lists, all frequencies of analyzing in the rendition list put in order, and are the division center with joining end to end of putting in order, with the described frequency of step 02, divide equally two frequency tables creating this frequency upside and downside;
Step 04: according to two frequency tables in the step 03, calculate two described frequencies of frequency table middle distance step 02 frequency farthest respectively, delete all EPG data except that this day in this frequency TV program list;
Step 05: detect and judge whether the memory space of set-top box memory enough stores new EPG data, if memory space is enough stored new EPG data, then directly storage, if memory space is still stored new EPG data inadequately, then repeated execution of steps 03 is to step 05, delete all EPG data except that this day in the TV program list of each frequency one by one, enough store new EPG data until the memory space of set-top box memory.
If the memory space through above-mentioned steps operation back set-top box memory is still stored new EPG data inadequately, then carry out following steps again:
Step 06: analyze new EPG data, delete all EPG data except that this day in the new EPG data;
Step 07: detection judges whether the memory space of set-top box memory enough stores the new EPG data after deleting, the new EPG data after if memory space is enough stored and deleted, then directly storage, if memory space is still stored the new EPG data after deleting inadequately, the new EPG data that then detect current reception belong to the frequency at which TV programme and this program place, deletion is apart from this day EPG data in this frequency frequency TV program list farthest, repeat this step, delete this day EPG data in each frequency TV program list one by one, enough store new EPG data after deleting until the memory space of set-top box memory.
The invention has the beneficial effects as follows: the present invention adopts the method for progressively deleting the electronic program guide information (EPG data) of the program of watching away from the user automatically, guarantee that set-top box memory has enough memory spaces, this delet method is through the practical proof statistics, basic symbols is share the use habit at family, make set-top box can either preserve original portions of electronics performance guide information useful to the user, can receive the new portions of electronics performance guide information useful again to the user, guarantee that the user can in time obtain required electronic program guide information, be user-friendly to.
Embodiment
The present invention includes following steps:
Step 01: the set-top box program receives new EPG data, detect and judge whether the memory space of set-top box memory enough stores new EPG data, when insufficient memory is deposited new EPG data, whether expired EPG data early than current system time are arranged in the detection of stored space, if have then delete this expired EPG data, detect to judge whether memory space enough stores new EPG data again, if memory space is enough stored new EPG data, then directly storage;
Step 02: if memory space was still stored new EPG data inadequately after step 01 was finished, which TV programme what detect then that the user watches at present is, determines the frequency at the TV programme place that this is being watched;
Step 03: read current all the rendition lists, all frequencies of analyzing in the rendition list put in order, and are the division center with joining end to end of putting in order, with the described frequency of step 02, divide equally two frequency tables creating this frequency upside and downside;
Step 04: according to two frequency tables in the step 03, calculate two described frequencies of frequency table middle distance step 02 frequency farthest respectively, delete all EPG data except that this day in this frequency TV program list;
Step 05: detect and judge whether the memory space of set-top box memory enough stores new EPG data, if memory space is enough stored new EPG data, then directly storage, if memory space is still stored new EPG data inadequately, then repeated execution of steps 03 is to step 05, delete all EPG data except that this day in the TV program list of each frequency one by one, enough store new EPG data until the memory space of set-top box memory.
If the memory space through above-mentioned steps operation back set-top box memory is still stored new EPG data inadequately, then carry out following steps again:
Step 06: analyze new EPG data, delete all EPG data except that this day in the new EPG data;
Step 07: detection judges whether the memory space of set-top box memory enough stores the new EPG data after deleting, the new EPG data after if memory space is enough stored and deleted, then directly storage, if memory space is still stored the new EPG data after deleting inadequately, the new EPG data that then detect current reception belong to the frequency at which TV programme and this program place, deletion is apart from this day EPG data in this frequency frequency TV program list farthest, repeat this step, delete this day EPG data in each frequency TV program list one by one, enough store new EPG data after deleting until the memory space of set-top box memory.