The application is that on 2 28th, 2013 the entitled of proposition " realize alarm clock under a kind of intelligent terminal off-mode
Method and intelligent terminal " Chinese invention patent application 201310064129.4 divisional application.
The content of the invention
It is an object of the invention to provide the method and device that alarm clock is realized under a kind of intelligent terminal off-mode, to solve to be
Startup alarm clock needs to increase hardware cost, the problem in plate level space under realizing off-mode.
The purpose of the present invention is achieved through the following technical solutions:
A kind of method that alarm clock is realized under intelligent terminal off-mode, including:
During shutdown, whether there is the corresponding alarm time value of the first alarm clock type identification in detection real-time clock alarm clock list, it is described
First alarm clock type identification is used to indicate to start alarm clock in the power-offstate according to corresponding alarm time value;
If it has, writing power management list using the corresponding alarm time value of the first alarm clock type identification as real time clock value
The real-time clock register of unit;
Under off-mode, alarm clock is started according to the corresponding alarm time value of the first alarm clock type identification.
A kind of intelligent terminal, including:
Whether alarm clock type detection module, during for shutting down, have the first alarm clock type identification in detection real-time clock alarm clock list
Corresponding alarm time value, the first alarm clock type identification is used to indicate according to corresponding alarm time value in the power-offstate
Start alarm clock;
Time value processing module, if for implementing to have the corresponding alarm time of the first alarm clock type identification in clock alarm list
Value, using the corresponding alarm time value of the first alarm clock type identification as the real-time of real time clock value write-in PMU
Clock register;
Alarm clock management module, for off-mode under, started according to the corresponding alarm time value of the first alarm clock type identification
Alarm clock.
The embodiment of the present invention, during shutdown, by by the corresponding alarm clock of the first alarm clock type identification in RTC alarm lists
Time value writes the RTC registers of PMU as RTC values.So as to be realized on the basis of hardware cost, plate grade space is not increased
Alarm clock function under off-mode.
Specific embodiment
The embodiment of the present invention, during shutdown, by by the corresponding alarm clock of the first alarm clock type identification in RTC alarm lists
Time value writes the RTC registers of PMU as RTC values.So as to be realized on the basis of hardware cost, plate grade space is not increased
Alarm clock function under off-mode.
The intelligent terminal of embodiment of the present invention only one of which RTC registers suitable for PMU.
Below in conjunction with accompanying drawing, technical scheme provided in an embodiment of the present invention is described in detail.
The method of alarm clock is realized under a kind of intelligent terminal off-mode provided in an embodiment of the present invention as shown in figure 1, specific
Including following operation:
When step 100, shutdown, whether there are the first alarm clock type identification corresponding alarm times in detection RTC alarm lists
Value, if it has, performing step 110.
Wherein, the first alarm clock type identification starts noisy in the power-offstate for instruction according to corresponding alarm time values
Clock.
Step 110, the RTC that the corresponding alarm time values of the first alarm clock type identification are write PMU as RTC values
Register.
Under step 120, off-mode, alarm clock is started according to the corresponding alarm time values of the first alarm clock type identification.
Above-mentioned processing procedure can with but be not limited only to by intelligent terminal Alarm drive layer realize.
If there is no the corresponding alarm time values of the first alarm clock type identification in RTC alarm lists, power management is emptied
RTC values in the RTC registers of unit.
By above-mentioned processing procedure, after shutdown, intelligent terminal PMU is only responded and is provided with the first alarm clock type identification
Alarm time values, the common alarm clock set by other application fails after shut down.
If receiving alarm clock request before being powered off, it is preferred that after receiving alarm clock request, being carried during the alarm clock is asked
Time value preserved as alarm time values and the first alarm clock type identification are corresponding in RTC alarm lists, and by the alarm clock
The time value carried in request is preserved as alarm time values and the second alarm clock type identification are corresponding in RTC alarm lists.
That is, for an alarm clock request, two alarm time values, a type for alarm time values are set in RTC alarm lists
It is the first alarm clock type, the type of another alarm time value is the second alarm clock type, and the two alarm time values are noisy
The time value of clock request.After alarm clock request can also be received, the time value carried during alarm clock is asked is used as alarm time values
It is corresponding in RTC alarm lists with the first alarm clock type identification and the second alarm clock type identification to preserve.That is, for an alarm clock
Request, sets an alarm time value, and correspondence preserves a first alarm clock type identification and a second alarm clock type mark
Know.Can specifically be realized setting alarm time values in RTC alarm lists by alarm clock application layer.In the embodiment of the present invention, institute
State the second alarm clock type identification for indicate alarm clock is not started according to corresponding alarm time value in the power-offstate.That is, second
The corresponding alarm time value of alarm clock type identification, fails after shutdown.
In order to the time value that an alarm clock request is carried is associated with two alarm clock type identifications, it is preferred that please by alarm clock
It is alarm clock request the first alarm clock type identification of distribution and the before asking the time value of carrying to write RTC alarm lists
Two alarm clock type identifications.Specifically can be by framework(framework)Layer alarm clock management service(Alarm Manager Service)
Realize.
By taking the intelligent terminal of Android platform as an example, alarm clock provided in an embodiment of the present invention setting, startup method are carried out in detail
Describe in detail bright.In the intelligent terminal, two kinds of alarm clock types, respectively the first alarm clock type and the second alarm clock class are provided with advance
Type.Its specific implementation as shown in Fig. 2 including:
Step 200, after alarm clock request is received, the alarm clock management service of framework layer is alarm clock request one the first alarm clock of distribution
Type identification and a second alarm clock type identification.
The time value that step 210, alarm clock application layer are asked according to the alarm clock, and the mark distributed in step 200, in RTC
The corresponding alarm time values of one the first alarm clock type identification of setting in alarm lists, and a second alarm clock type identification pair
The alarm time values answered.
The two alarm time values are the time value of alarm clock request.Specifically, can correspond to that alarm time values are preserved
With the first alarm clock type identification, and correspondence preservation alarm time values and the second alarm clock type identification.
If the time value of alarm clock request is reached under open state, implementation phase is processed with existing alarm clock
Together, the present invention is repeated no more.
If during shutdown, the time value of alarm clock request is not reached also, then perform step 220, alarm clock and drive layer to detect
There are the corresponding alarm time values of the first alarm clock type identification in RTC alarm lists, the alarm time values are write as RTC values
In entering the RTC registers of PMU.
Under off-mode, when the corresponding alarm time values of the first alarm clock type identification are reached, in the RTC registers of PMU
Corresponding RTC is interrupted and arrived, and performs the RTC registers of step 230, PMU for system is powered up, and starts alarm clock.
Based on the inventive concept same with method, the embodiment of the present invention also provides a kind of intelligent terminal, its structure such as Fig. 3 institutes
Show, specifically include:
Whether alarm clock type detection module 301, during for for shutting down, have the first alarm clock class in detection real-time clock alarm clock list
Type identifies corresponding alarm time value, and the first alarm clock type identification is used to indicate according to corresponding alarm time value in shutdown
Start alarm clock under state;
Time value processing module 302, if for for implementing to have the first alarm clock type identification corresponding in clock alarm list
Alarm time value, power management list is write using the corresponding alarm time value of the first alarm clock type identification as real time clock value
The real-time clock register of unit;
Alarm clock management module 303, for off-mode under, opened according to the corresponding alarm time value of the first alarm clock type identification
Dynamic alarm clock.
It is preferred that as shown in figure 4, intelligent terminal provided in an embodiment of the present invention can also also include:
First alarm clock setting module 304, after before being powered off, receiving alarm clock request, carries during the alarm clock is asked
Time value is preserved as alarm time value and the first alarm clock type identification are corresponding in the real-time clock alarm clock list, and by institute
The time value carried in alarm clock request is stated to be arranged in the real-time clock alarm clock as alarm time value and the second alarm clock type identification
Correspondence is preserved in table, and the second alarm clock type identification is used to indicate not opened in the power-offstate according to corresponding alarm time value
Dynamic alarm clock.
It is preferred that as shown in figure 5, intelligent terminal provided in an embodiment of the present invention can also also include:
Second alarm clock setting module 305, for before being powered off, after receiving alarm clock request, carried during the alarm clock is asked when
Between be worth as alarm time value and the first alarm clock type identification and the second alarm clock type identification in the real-time clock alarm clock list
Middle correspondence is preserved, and the second alarm clock type identification is used to indicate not started in the power-offstate according to corresponding alarm time value
Alarm clock.
It is preferred that it is preferred that as shown in figs. 6 or 7, intelligent terminal provided in an embodiment of the present invention can also also include:
Alarm clock type distribute module 306, the time value carried during the alarm clock is asked for the alarm clock setting module is in institute
State before preserving in real-time clock alarm clock list, be alarm clock request distribution the first alarm clock type identification and the second alarm clock type
Mark.
If it is preferred that there is no the corresponding time value of the first alarm clock type identification in real-time clock alarm clock list, when described
Between value processing module 302 be additionally operable to:
Empty the real time clock value in the real-time clock register of PMU.
Intelligent terminal described in the embodiment of the present invention can with but be not limited only to be mobile phone, tablet device, hand-held device etc..
It can be the intelligent terminal of intelligent terminal, or other operating systems for being based on Android platform.
It should be understood by those skilled in the art that, embodiments of the invention can be provided as method, system or computer program
Product.Therefore, the present invention can be using the reality in terms of complete hardware embodiment, complete software embodiment or combination software and hardware
Apply the form of example.And, the present invention can be used and wherein include the computer of computer usable program code at one or more
Usable storage medium(Including but not limited to magnetic disk storage, CD-ROM, optical memory etc.)The computer program of upper implementation is produced
The form of product.
The present invention is with reference to method according to embodiments of the present invention, equipment(System)And the flow of computer program product
Figure and/or block diagram are described.It should be understood that every first-class during flow chart and/or block diagram can be realized by computer program instructions
The combination of flow and/or square frame in journey and/or square frame and flow chart and/or block diagram.These computer programs can be provided
The processor of all-purpose computer, special-purpose computer, Embedded Processor or other programmable data processing devices is instructed to produce
A raw machine so that produced for reality by the instruction of computer or the computing device of other programmable data processing devices
The device of the function of being specified in present one flow of flow chart or multiple one square frame of flow and/or block diagram or multiple square frames.
These computer program instructions may be alternatively stored in can guide computer or other programmable data processing devices with spy
In determining the computer-readable memory that mode works so that instruction of the storage in the computer-readable memory is produced and include finger
Make the manufacture of device, the command device realize in one flow of flow chart or multiple one square frame of flow and/or block diagram or
The function of being specified in multiple square frames.
These computer program instructions can be also loaded into computer or other programmable data processing devices so that in meter
Series of operation steps is performed on calculation machine or other programmable devices to produce computer implemented treatment, so as in computer or
The instruction performed on other programmable devices is provided for realizing in one flow of flow chart or multiple flows and/or block diagram one
The step of function of being specified in individual square frame or multiple square frames.
, but those skilled in the art once know basic creation although preferred embodiments of the present invention have been described
Property concept, then can make other change and modification to these embodiments.So, appended claims are intended to be construed to include excellent
Select embodiment and fall into having altered and changing for the scope of the invention.
Obviously, those skilled in the art can carry out various changes and modification without deviating from essence of the invention to the present invention
God and scope.So, if these modifications of the invention and modification belong to the scope of the claims in the present invention and its equivalent technologies
Within, then the present invention is also intended to comprising these changes and modification.