CN106990708B - Alarm clock ringing method and device and electronic equipment - Google Patents

Alarm clock ringing method and device and electronic equipment Download PDF

Info

Publication number
CN106990708B
CN106990708B CN201710294908.1A CN201710294908A CN106990708B CN 106990708 B CN106990708 B CN 106990708B CN 201710294908 A CN201710294908 A CN 201710294908A CN 106990708 B CN106990708 B CN 106990708B
Authority
CN
China
Prior art keywords
time
alarm
weather condition
weather
alarm clock
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201710294908.1A
Other languages
Chinese (zh)
Other versions
CN106990708A (en
Inventor
朴俊豪
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Ruguo Technology Co ltd
Original Assignee
Shenzhen Ruguo Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Ruguo Technology Co ltd filed Critical Shenzhen Ruguo Technology Co ltd
Priority to CN201710294908.1A priority Critical patent/CN106990708B/en
Publication of CN106990708A publication Critical patent/CN106990708A/en
Application granted granted Critical
Publication of CN106990708B publication Critical patent/CN106990708B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G04HOROLOGY
    • G04GELECTRONIC TIME-PIECES
    • G04G13/00Producing acoustic time signals
    • G04G13/02Producing acoustic time signals at preselected times, e.g. alarm clocks
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04MTELEPHONIC COMMUNICATION
    • H04M1/00Substation equipment, e.g. for use by subscribers
    • H04M1/72Mobile telephones; Cordless telephones, i.e. devices for establishing wireless links to base stations without route selection
    • H04M1/724User interfaces specially adapted for cordless or mobile telephones
    • H04M1/72448User interfaces specially adapted for cordless or mobile telephones with means for adapting the functionality of the device according to specific conditions
    • H04M1/72451User interfaces specially adapted for cordless or mobile telephones with means for adapting the functionality of the device according to specific conditions according to schedules, e.g. using calendar applications

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Human Computer Interaction (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Electric Clocks (AREA)

Abstract

The invention relates to the technical field of alarm clocks, in particular to an alarm clock ringing method and device and electronic equipment. The alarm clock ringing method comprises the following steps: acquiring alarm time set in the alarm clock; when the time difference between the system time of the alarm clock and the set alarm time is detected to be a preset time length, acquiring a first day condition of the position of the alarm clock; acquiring a second weather condition of the position of the alarm clock and corresponding to the alarm time of the previous day; and adjusting the ringing time of the alarm clock according to the first weather condition and the second weather condition. The alarm clock provided by the invention can adjust the preset alarm time according to the weather condition, not only enriches the alarm clock ringing modes, but also can enable the alarm clock to ring flexibly.

Description

Alarm clock ringing method and device and electronic equipment
[ technical field ] A method for producing a semiconductor device
The invention relates to the technical field of alarm clocks, in particular to an alarm clock ringing method and device and electronic equipment.
[ background of the invention ]
In daily life, an alarm clock is very popular as a common tool for giving a time and reminding a user to get up. Usually, people set the ringing time of the alarm in advance, and when the alarm rings, people press the alarm button to start getting up and engaging in the planned affairs of the previous day.
However, when the weather condition suddenly becomes worse, if the alarm clock continuously rings normally according to the set time, after the person gets up, the preparation of the affair needing to be processed cannot be implemented, so that the sleep quality is influenced, the alarm clock cannot be used even after getting up, and the rest time is wasted.
[ summary of the invention ]
The invention aims to provide an alarm clock ringing method, an alarm clock ringing device and electronic equipment, which can enable an alarm clock to adjust ringing time in a self-adaptive manner according to weather conditions.
In one aspect of the embodiments of the present invention, an alarm clock ringing method is provided, including: acquiring alarm time set in the alarm clock; when the time difference between the system time of the alarm clock and the set alarm time is detected to be a preset time length, acquiring a first day condition of the position of the alarm clock; acquiring a second weather condition of the position of the alarm clock and corresponding to the alarm time of the previous day; and adjusting the ringing time of the alarm clock according to the first weather condition and the second weather condition.
In some embodiments, the obtaining a first day condition of a location where the alarm clock is located when it is detected that a time difference between a system time of the alarm clock and the set alarm time is a predetermined time length includes:
collecting the weather condition of the current position of the alarm clock at preset time intervals;
selecting the weather condition with the highest occurrence probability in the collected weather conditions as the first weather condition, or selecting the weather condition which is closest to the alarm time in the collected weather conditions as the first weather condition.
In some embodiments, said adjusting a ring time of said alarm clock according to said first weather condition and said second weather condition comprises:
when the first weather condition is better than the second weather condition, ringing according to a set alarm time, or delaying the set alarm time and ringing according to the delayed alarm time;
when the first weather condition is worse than the second weather condition, advancing the set alarm time and ringing according to the alarm time before and after the alarm;
and when the first weather condition is the same as the second weather condition, ringing according to the set alarm time.
In some embodiments, the ringing according to the deferred ringing time specifically includes:
and determining the time length of the set alarm time needing to be delayed according to a preset weather time relation mapping table, determining delayed alarm time according to the time length, and ringing according to the delayed alarm time.
In some embodiments, the ringing according to the ringing time before and after the mention specifically includes:
and determining the time length of the set alarm time required to be advanced according to a preset weather-time relation mapping table, determining the ring time before and after the alarm according to the time length, and ringing according to the ring time before and after the alarm.
In some embodiments, the alarm time set by the alarm clock corresponds to a predetermined event, and the predetermined event is used to remind a user of the alarm clock to go to a destination, the preset weather-to-time map table includes: origin, destination, average duration, and weather.
In another aspect of the embodiments of the present invention, an alarm clock ringing device is provided, including: the first acquisition module is used for acquiring the alarm time set in the alarm clock; the second acquisition module is used for acquiring a first day condition of the position of the alarm clock when the time difference between the system time of the alarm clock and the set alarm clock time is detected to be a preset time length; the third obtaining module is used for obtaining a second weather condition of the position of the alarm clock and corresponding to the alarm time of the previous day; and the adjusting module is used for adjusting the ringing time of the alarm clock according to the first weather condition and the second weather condition.
In some embodiments, the second obtaining module comprises:
the acquisition unit is used for acquiring the weather condition of the current position of the alarm clock at intervals of preset time;
and the selecting unit is used for selecting the weather condition with the highest occurrence probability in the collected weather conditions as the first weather condition, or selecting the weather condition which is closest to the alarm time in the collected weather conditions as the first weather condition.
In some embodiments, the adjustment module comprises:
a first adjusting unit, configured to ring according to a set alarm time when the first weather condition is better than the second weather condition, or delay the set alarm time and ring according to the delayed alarm time;
a second adjusting unit, configured to advance the set alarm time and ring according to the alarm time before and after the alarm when the first weather condition is worse than the second weather condition;
and the third adjusting unit is used for ringing according to the set alarm time when the first weather condition is the same as the second weather condition.
In another aspect of the embodiments of the present invention, an electronic device is provided, where the electronic device includes: at least one processor; and a memory communicatively coupled to the at least one processor; wherein the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the method as described above.
In the embodiment of the invention, the corresponding first weather condition is obtained according to the alarm time, the alarm time of the previous day is obtained corresponding to the second weather condition, and the ringing time of the alarm clock is adjusted by comparing the first weather condition with the second weather condition. This embodiment can adjust the alarm clock time of predetermineeing according to the weather condition, has not only richened the mode of ringing of alarm clock, can make the nimble ringing of alarm clock moreover.
[ description of the drawings ]
One or more embodiments are illustrated by way of example in the accompanying drawings, which correspond to the figures in which like reference numerals refer to similar elements and which are not to scale unless otherwise specified.
FIG. 1 is a schematic diagram of an application environment in accordance with various embodiments of the present invention;
fig. 2 is a schematic flow chart of an alarm clock ringing method according to an embodiment of the present invention;
fig. 3 is a schematic flowchart of a method for acquiring a first weather condition in an alarm clock ringing method according to an embodiment of the present invention;
fig. 4 is a schematic flowchart of a method for adjusting the alarm clock ringing time according to the first weather condition and the second weather condition in an alarm clock ringing method according to an embodiment of the present invention;
fig. 5 is a schematic structural diagram of an alarm clock ringing device according to an embodiment of the present invention;
fig. 6 is a schematic structural diagram of an alarm clock ringing device according to another embodiment of the present invention;
fig. 7 is a schematic diagram of a hardware structure of an electronic device for executing an alarm clock ringing method according to an embodiment of the present invention.
[ detailed description ] embodiments
In order to make the objects, technical solutions and advantages of the present invention more apparent, the present invention is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
It should be noted that, although a logical order is shown in the flow chart, in some cases, the steps shown or described may be performed in an order different than that shown or described herein. Further, the terms "first," "second," "third," and the like as used herein do not limit the data and the execution order, but merely distinguish the same items or similar items having substantially the same functions and actions.
Referring to fig. 1, fig. 1 is a schematic structural diagram of an application environment according to various embodiments of the present invention. As shown in fig. 1, the application environment includes an alarm clock 10, a smart terminal 20, and a cloud server 30.
In this embodiment, the alarm clock 10 has some basic alarm clock functions such as alarm setting and time counting. Further, the alarm clock 10 is provided with a GPS unit, a processor, and a wireless signal transceiving unit. The GPS unit is used for measuring the geographic coordinate of the current alarm clock, determining the current position of the alarm clock according to the measured geographic coordinate, and determining the corresponding time zone so as to determine the system time and the current time of the alarm clock. The processor coordinates the flow processes between the various units within the alarm clock by sending and receiving instructions. The wireless signal transceiving unit may establish a connection with the smart terminal 20 and the cloud server 30. After the alarm clock is connected to the intelligent terminal 20 through the wireless signal transceiving unit, the user can set basic parameters of the alarm clock at the intelligent terminal, for example, setting alarm time, timing, setting a weather expected threshold value, and the like. After the alarm clock is connected with the cloud server 30 through the wireless signal transceiving unit, the weather information sent by the cloud server 30 and the time information of the user going to a certain destination under a certain weather condition can be acquired.
The smart terminal 20 may be any type of terminal device that interacts with or provides services to a user, including a mobile phone, a tablet computer, a smart band, and the like. This intelligent terminal 20 can establish network connection with alarm clock 10 to the setting of some parameters in the direct control alarm clock 10, in addition, alarm clock 10 can time intelligent terminal 20's mobile position, for example, the alarm clock timer begins timing, and the start time is synchronous to intelligent terminal 20, and when detecting through GPS that the position change of intelligent terminal 20 that the user carried is less or when not changing, alarm clock 10 stops timing. The smart terminal 20 may also access the cloud server 30 and perform data communication with the cloud server 30.
The cloud server 30 may be one server or a server cluster. The cloud server 30 is in data communication with the alarm clock 10, and can identify the identity of the alarm clock and issue weather information according to the time zone, time, geographical coordinates, weather condition inquiry, alarm clock IP and other keyword information of the alarm clock sent by the alarm clock 10. Further, when the purpose of the alarm time set by the alarm clock 10 is to remind the user to go to a certain destination, the cloud server 30 is also used to collect information on the time spent by the user to arrive at the same destination in a large number of different weather conditions, based on the different weather conditions, and the like.
It should be noted that the relationship between the alarm clock 10 and the intelligent terminal 20 is not limited to the manner shown in fig. 1, and in some embodiments, the alarm clock 10 may also be disposed in the intelligent terminal 20 as a part of the intelligent terminal 20. In addition, only one alarm clock 10 and one intelligent terminal 20 are shown in fig. 1, and those skilled in the art will understand that any number of alarm clocks 10 and intelligent terminals 20 may be included in the application environment.
With reference to the application environment, as shown in fig. 2, an alarm clock ringing method is provided, which specifically includes:
and S11, acquiring the alarm time set in the alarm clock.
The alarm time is preset by the alarm clock user, and the alarm time can be set to remind the user to get up or to remind the user to start executing a certain event, and the like. The alarm time can be set and completed on the alarm clock directly, and the alarm clock can also be connected through the intelligent terminal and then set on the intelligent terminal. Wherein, this intelligent terminal can be through WIFI or bluetooth, and the alarm clock is established and is connected.
S12, when the time difference between the system time of the alarm clock and the set alarm time is detected to be the preset time length, acquiring the first day condition of the position of the alarm clock.
In the present embodiment, the predetermined time period may be arbitrarily set according to the habit of the user, such as 30 minutes, 10 minutes, and the like. For example, when the time length is 30 minutes, that is, when it is detected that the alarm time of the alarm clock system is 30 minutes away from the set alarm time, the weather condition corresponding to the time is obtained, that is, the first weather condition. In some embodiments, the length of time may also be set to zero, the first weather condition corresponding to the ringing time.
The first weather obtaining process comprises the step that according to the geographical position where the alarm clock is located and the expected time, the alarm clock inquires weather information corresponding to the geographical position at the expected time through accessing an external network. The first weather obtaining process further includes that the clock sends some keyword information for obtaining weather to the cloud server, and then obtains the weather information from the cloud server, wherein the keyword information includes: the alarm clock is in a time zone, a moment, a geographical coordinate, weather condition inquiry, an alarm clock IP, alarm clock identity recognition and the like. The cloud server determines whether the alarm clock identity is legal or not through alarm clock identity recognition, when the alarm clock identity is legal, the cloud server is connected to the alarm clock through a wireless network IP, inquires the current weather condition according to the current alarm clock time zone, the geographical position and other information, and sends the weather information to the alarm clock. The acquiring process of the first weather further comprises the steps that after the intelligent terminal is connected with the alarm clock through the network, weather information corresponding to the request is acquired according to the request of the alarm clock and is sent to the alarm clock.
The obtained first weather condition is weather corresponding to a certain moment, and in some embodiments, weather information in a certain time period may also be obtained, and then the first weather condition is determined according to all weather information in the time period. Specifically, as shown in fig. 3, when it is detected that the time difference between the system time of the alarm clock and the set alarm time on the same day is the preset time length, the obtaining of the first day condition of the position where the alarm clock is located includes:
s121, collecting weather conditions of the current position of the alarm clock at intervals of preset time;
s122, selecting the weather condition with the highest occurrence probability in the collected weather conditions as the first weather condition, or selecting the weather condition which is closest to the alarm time in the collected weather conditions as the first weather condition.
In this embodiment, the weather information is collected within a certain time before the alarm time is reached, until the alarm time is reached, and then the first weather condition is determined according to the collected weather information.
For example, the set alarm time is 8 am, the collection of weather information may be started half an hour in advance, and the weather condition of the current position of the alarm clock is collected every 10 minutes, that is, the corresponding weather information is collected at the time of 7:30, 7:40, and 7:50, and finally, the weather information which has the highest number of times of the same weather (i.e., the highest occurrence probability) in the time period may be selected from all the collected weather information as the first weather condition, or the weather information collected at the latest time apart from the alarm time may be used as the first weather condition. Wherein, the mode of gathering weather information at every preset moment includes: specifically, reference may be made to the description in the above embodiments.
S13, acquiring a second weather condition of the position of the alarm clock and corresponding to the alarm time of the previous day.
In this embodiment, the alarm time of the previous day refers to the alarm time set by the alarm clock of the previous day, and the alarm time is the same as the alarm time set by the current day. For example, the alarm time set for the current day is eight am, and said alarm time of the previous day refers to eight am of yesterday, where the second weather condition is the weather information of the location of the alarm clock at eight am of yesterday.
The detailed process of acquiring the second weather condition may refer to the process of acquiring the first weather condition, which is not described herein again.
And S14, adjusting the ringing time of the alarm clock according to the first weather condition and the second weather condition.
In this embodiment, after the first weather condition and the second weather condition are obtained, the ringing time of the alarm clock is determined by comparing the first weather condition and the second weather condition, where the ringing time is the formal ringing time of the alarm clock, and the ringing time is adjusted according to the set alarm time. In some cases, an alarm clock maintains a set alarm time, i.e., alarm time, when it rings. As shown in fig. 4, the adjusting the ringing time of the alarm clock according to the first weather condition and the second weather condition includes:
s141, when the first weather condition is better than the second weather condition, ringing according to the set alarm time, or delaying the set alarm time and ringing according to the delayed alarm time;
s142, when the first weather condition is worse than the second weather condition, the set alarm time is advanced, and the alarm rings according to the alarm time before and after the alarm is carried out;
s143, when the first weather condition is the same as the second weather condition, ringing according to the set alarm time.
It will be appreciated that the weather deteriorates the day relative to the previous day, and if the alarm continues to ring at the alarm time of the previous day, it may affect the scheduled transaction, e.g., cause the destination to be reached later, etc. If the weather becomes better in the day compared with the previous day and the alarm continues to ring according to the alarm time in the previous day, the time of reaching the destination may be earlier, and unnecessary time of the user is wasted. Therefore, in the embodiment of the present invention, it is necessary to determine whether to maintain the set alarm time or adjust the set alarm time according to the ring time of the previous day, and the weather condition of the previous day and the weather condition of the current day corresponding to the ring time.
In this embodiment, the comparison result of the first weather condition and the second weather condition includes: the first weather condition is better than the second weather condition, the first weather condition is worse than the second weather condition, and the first weather condition and the second weather condition are the same. That is, if the weather condition corresponding to the alarm time of the current day is better than the weather condition corresponding to the alarm time of the previous day, the set alarm time is kept ringing, or the set alarm time is delayed; if the weather condition corresponding to the alarm time of the day is worse than the weather condition corresponding to the alarm time of the previous day, the set alarm time is advanced; and if the weather condition corresponding to the alarm time of the current day is the same as the weather condition corresponding to the alarm time of the previous day, maintaining the set alarm time, namely maintaining the alarm time of the previous day unchanged.
In this embodiment, the definition of good and bad weather conditions can be preset according to general concepts understood by those skilled in the art, for example, it is defined that sunny weather is better than rainy weather, rainy weather is better than snowy weather, rainy weather is better than heavy rain weather, and the like.
It should be noted that the position of the alarm clock when the first weather condition is obtained is the same as the position of the alarm clock when the second weather condition is obtained. In addition, the alarm time set in this embodiment refers to the alarm time corresponding to one alarm of the alarm clock. In some embodiments, a plurality of alarm times may also be set simultaneously, and each alarm time may be adaptively adjusted according to the method provided by this embodiment.
The specific process of adjusting the alarm time according to the first weather condition and the second weather condition is described in detail below by way of example.
For example, if the collected weather corresponding to the alarm time of the previous day is sunny (that is, the second weather condition is sunny), and the collected first weather condition is rainy, the preset alarm time needs to be adjusted to ring the alarm clock in advance. Or, if the collected weather corresponding to the alarm time of the previous day is heavy rain (that is, the second weather condition is heavy rain), and the collected first weather condition is light rain, the preset alarm time may be maintained unchanged. Or, if the collected weather corresponding to the alarm time of the previous day is heavy rain (that is, the second weather condition is heavy rain), and the collected first weather condition is sunny, the preset alarm time may be adjusted, so that the alarm time is delayed.
Generally, when the weather conditions on the current day and the current day have large variation, the ringing time of the alarm clock needs to be adaptively adjusted. The definition of the difference can be preset in the alarm clock, and the ringing time of the alarm clock can be adjusted in a self-adaptive manner through a software or hardware method.
In some embodiments, the alarm clock is further provided with a user reminding function. For example, after the alarm clock acquires the first day condition, the alarm clock may send the acquired first day condition to the user terminal before or after the ringing time to remind the user of the attention. The alarm clock can also broadcast the first weather condition in a voice broadcast mode after the alarm clock rings, and particularly can remind a user to prepare a rainproof tool in rainy days. Further, the first weather condition further includes detailed weather information such as air temperature, and the weather information can also be reminded to the user in the above manner.
In some embodiments, the current day is a work day, and the current day is a rest day, it is understood that the number of people going out during certain time periods of the day is smaller than that of the previous day, and the traffic condition is better, for example, in general, the number of people going out eight am of the work day is significantly larger than that of people going out eight am of the rest day, that is, the traffic condition is better than that of the people going out eight am of the rest day. Thus, traffic conditions may be incorporated in addition to the weather that needs to take into account the ringing moments of the previous day. For example, the preset alarm time corresponds to a working time period, the collected first weather condition is the same as the collected second weather condition, the first weather condition corresponds to a rest day, the second weather condition corresponds to a working day, and the alarm time of the alarm clock is delayed compared with the previous day. It should be noted that, when the alarm time of the alarm clock is adjusted according to the weather condition and the traffic condition, the determination of the traffic condition may be set according to historical experience, or the traffic condition at the corresponding time may be queried through networking.
In this embodiment, when the alarm time is set for the alarm clock, a predetermined event is bound to the alarm time, and the predetermined event is used to remind the alarm clock user to go to a certain destination, at this time, in the alarm time of the delayed alarm clock or the alarm time of the advanced alarm clock, the duration of the delayed time and the duration of the advanced time may both be determined according to a preset weather-time relationship mapping table. The preset weather-time relationship mapping table comprises: origin, destination, average duration, and weather.
The process for establishing the preset weather-time relation mapping table specifically comprises the following steps: and establishing the weather-time relation mapping table according to the acquired historical weather and climate conditions and the average time spent by the user history from the same starting place to the same destination.
The process can be regarded as a learning stage of the alarm clock, in the learning stage, the alarm clock collects weather conditions of each day, records departure places and arrival destinations of each day and time spent from the departure places to the destinations, calculates average time length of users from the same departure place to the same destination under the same weather conditions after acquiring a large amount of learning data, and establishes a corresponding time relationship mapping table according to the acquired information of the departure places, the destinations, the average time length, the weather and the like. Table 1 below is an example of the time relationship mapping table.
TABLE 1
Departure place Destination Average time length Weather (weather)
Home-use Company(s) 20 minutes In sunny days
Home-use Company(s) 30 minutes Light rain
Home-use Company(s) 40 minutes Heavy rain
In table 1, the specific method for obtaining the departure point and the destination and calculating the average duration includes: when the alarm clock and the intelligent terminal carried by the user are two independent individuals, the place of departure is the position where the alarm clock is located, the position where the alarm clock is located is unchanged, and in the process, the alarm clock is connected with the intelligent terminal (such as Bluetooth or WIFI) so as to realize information sharing. Specifically, the position (namely the departure place) and the destination where the alarm clock is located can be determined through the GPS module of the intelligent terminal, the alarm clock timer starts timing, the starting time is synchronized to the intelligent terminal, the intelligent terminal and the alarm clock are synchronously timed, when the position change of the intelligent terminal is detected through the GPS within a certain time range, the intelligent terminal stops timing, correspondingly, after the alarm clock receives the timing stopping instruction of the intelligent terminal, the alarm clock also stops timing, and at the moment, the alarm clock can obtain the duration spent by the user from the departure place to the destination. According to the above process, the time length spent from the same departure place to the same destination under the same weather condition is obtained for a plurality of times, and finally, the average time length is calculated, wherein the average time length is the time spent from the departure place to the destination under the weather condition. When the alarm clock is a part of an intelligent terminal carried by a user, the position of the alarm clock is changed, so that the place of departure is the position of the alarm clock corresponding to the moment of departure, in the process, corresponding information such as the place of departure, the destination, the duration, the weather and the like can be directly obtained according to a GPS module and other related technologies built in the intelligent terminal, and the average duration is obtained based on the principle of calculating the average duration in the process.
The alarm clock can be directly stored on the alarm clock after acquiring information such as a departure place, a destination, average duration, weather and the like, and can also be uploaded to the cloud server, and when needed, the alarm clock is acquired from the cloud server.
Determining the ring time (i.e. the adjusted alarm time) of the alarm clock according to the weather time relationship mapping table includes, according to the obtained first weather condition and the second weather condition, respectively finding the time lengths corresponding to the first weather condition and the second weather condition in the weather time relationship mapping table, then calculating the time difference, according to the comparison result of the first weather condition and the second weather condition and the calculated time difference, determining the advanced time length of the advanced ring or the delayed time length of the delayed ring, where the advanced time length is the alarm time-time difference of the previous day, and the delayed time length is the alarm time + time difference of the previous day, where the alarm time of the previous day is the formal ring time of the alarm clock of the previous day.
For example, the second weather condition obtained is light rain, the time spent from home to company is 30 minutes, and the ringing time is 7 o' clock and 30 minutes; the first acquired day condition is heavy rain, the time spent from home to the company is 40 minutes, at this time, the ringing time of the alarm clock needs to be adjusted, the ringing is carried out 10 minutes ahead, and the ringing time of the alarm clock is 7 hours and 20 minutes.
In addition, it should be noted that, in the present embodiment, the time length of each late alarm or early alarm is determined according to the alarm time of the previous day, rather than according to the alarm time set for the first time. For example, the weather condition on the first day is light rain, the time spent from home to company is 30 minutes, and the ringing time is 7 o' clock and 30 minutes; the weather condition of the second day is heavy rain, the time spent from home to the company is 40 minutes, at the moment, the ringing time of the alarm clock needs to be adjusted and the ringing needs to be carried out 10 minutes ahead by taking the first day as reference, and the ringing time of the alarm clock is 7 points and 20 minutes; the weather condition on the third day is sunny, the time spent from home to company is 20 minutes, the alarm time on the second day is 7 minutes and 20 minutes, the alarm time on the second day is required to be delayed, and the alarm time on the third day is 7 minutes and 40 minutes.
The embodiment of the invention provides an alarm clock ringing method, which adaptively adjusts the ringing time of an alarm clock by comparing the weather condition of the day corresponding to the alarm clock time with the weather condition of the day before, so that the alarm clock dynamically adjusts the alarm clock time according to the weather change, thereby enriching the ringing mode of the alarm clock and improving the user experience.
In the above-described embodiment, the formal ringing time of the present day is determined according to the weather of the previous day, the weather of the present day, and the ringing time of the previous day. In some embodiments, the formal ringing time of the current day may also be determined according to the weather of the previous day, the weather of the current day, and the historical ringing time corresponding to the weather of the current day.
Specifically, when it is determined that the weather (first weather condition) of the day is greatly different from the weather (second weather condition) of the previous day, the alarm clock queries all the ringing times corresponding to the first weather condition in history according to the first weather condition, and then calculates the average value of the ringing times, and takes the average value as the formal ringing time of the alarm clock of the day. For example, the first weather condition corresponds to heavy rain, the second weather condition corresponds to clear weather, the alarm clock judges that the difference of weather changes meets a preset rule, at this time, the alarm clock inquires the ringing times corresponding to all heavy rain days in a past preset time period (for example, one or two months in the past), extracts the data of the ringing times, calculates the average value of the ringing times to obtain the formal ringing time of the alarm clock in the current day, and enables the alarm clock to ring according to the calculated ringing time.
In some embodiments, when it is determined that the weather of the current day is greatly different from the weather of the previous day and the current day is a weekend, the alarm clock queries the alarm time corresponding to the first weather condition in the history of the weekend according to the first weather condition, and then calculates an average value of the alarm times, and takes the average value as the formal alarm time of the alarm clock of the current day. For example, the first weather condition corresponds to heavy rain and the current day is saturday, the second weather condition corresponds to sunny day, the alarm clock judges that the difference of weather changes meets the preset specification, at this time, the alarm clock rings in all saturday and rainy days in the past preset time period (for example, the past month or two months) are inquired, the data of the rings are extracted, the average value of the data is calculated to obtain the ring time of the alarm clock in the current day, and the alarm clock rings according to the calculated ring time.
Referring to fig. 5, fig. 5 is a schematic structural diagram of an alarm clock ringing device according to an embodiment of the present invention. As shown in fig. 5, the apparatus 40 includes: a first obtaining module 41, a second obtaining module 42, a third obtaining module 43, and an adjusting module 44.
The first obtaining module 41 is configured to obtain alarm time set in the alarm clock; a second obtaining module 42, configured to obtain a first day situation of a location where the alarm clock is located when it is detected that a time difference between a system time of the alarm clock on the current day and the set alarm time is a predetermined time length; a third obtaining module 43, configured to obtain a second weather condition of the location of the alarm clock and corresponding to the alarm time of the previous day; and the adjusting module 44 is configured to adjust the ringing time of the alarm clock according to the first weather condition and the second weather condition.
In this embodiment, the first obtaining module 41 sends the obtained alarm time to the second obtaining module 42 and the third obtaining module 43, the second obtaining module 42 and the third obtaining module 43 respectively obtain the corresponding first weather condition and second weather condition according to the alarm time, and respectively send the obtained first weather condition and second weather condition to the adjusting module 44, and the adjusting module 44 adjusts the set alarm time according to the first weather condition and the second weather condition.
In some embodiments, referring to fig. 6, the second obtaining module 42 includes: an acquisition unit 421 and a selection unit 422. The acquisition unit 421 is configured to acquire the weather condition of the current position of the alarm clock at preset intervals; the selecting unit 422 is configured to select a weather condition with the highest occurrence probability among the collected weather conditions as the first weather condition, or select a weather condition closest to the alarm time among the collected weather conditions as the first weather condition.
In some embodiments, referring also to fig. 6, the adjustment module 44 includes: a first adjusting unit 441, a second adjusting unit 442, and a third adjusting unit 443. Wherein, the first adjusting unit 441 is configured to ring according to a set alarm time when the first weather condition is better than the second weather condition, or delay the set alarm time and ring according to the delayed alarm time; a second adjusting unit 442 for advancing the set alarm time and ringing at the alarm time before and after the alarm when the first weather condition is worse than the second weather condition; a third adjusting unit 443, configured to ring according to a set alarm time when the first weather condition is the same as the second weather condition.
Wherein, the ringing according to the delayed ringing time specifically includes: and determining the time length of the set alarm time needing to be delayed according to a preset weather time relation mapping table, determining delayed alarm time according to the time length, and ringing according to the delayed alarm time.
Wherein, the ringing according to the ringing time before and after the mention specifically includes: and determining the time length of the set alarm time required to be advanced according to a preset weather-time relation mapping table, determining the ring time before and after the alarm according to the time length, and ringing according to the ring time before and after the alarm.
Wherein the alarm time set by the alarm clock corresponds to a predetermined event, and the predetermined event is used for reminding a user of the alarm clock to go to a destination, and the preset weather-time relationship mapping table comprises: origin, destination, average duration, and weather.
It should be noted that, because the contents of information interaction, execution process, and the like between the modules and units in the alarm clock ringing device in the embodiment of the present invention are based on the same concept as the method embodiment of the present invention, the specific contents are also applicable to the alarm clock ringing device. The respective modules in the embodiments of the present invention can be implemented as separate hardware or software, and the combination of the functions of the respective units can be implemented using separate hardware or software as necessary.
The embodiment of the invention provides an alarm clock ringing device, which adaptively adjusts the ringing time of an alarm clock by comparing the weather condition of the day corresponding to the alarm clock time with the weather condition of the day before, so that the alarm clock dynamically adjusts the alarm clock time according to the weather change, thereby enriching the ringing mode of the alarm clock and improving the user experience.
Referring to fig. 7, fig. 7 is a schematic diagram of a hardware structure of an electronic device 50 for executing an alarm clock ringing method according to an embodiment of the present invention, and as shown in fig. 7, the electronic device 50 includes:
one or more processors 51 and a memory 52, with one processor 51 being an example in fig. 7.
The processor 51 and the memory 52 may be connected by a bus or other means, such as the bus connection in fig. 7.
The memory 52 is a non-volatile computer-readable storage medium, and can be used to store non-volatile software programs, non-volatile computer-executable programs, and modules, such as program instructions/modules corresponding to the alarm clock ringing method in the embodiment of the present invention (for example, the first obtaining module 41, the second obtaining module 42, the third obtaining module 43, and the adjusting module 44 shown in fig. 5). The processor 51 executes various functional applications and data processing of the server by running nonvolatile software programs, instructions and modules stored in the memory 52, that is, the alarm clock ringing method of the above-described method embodiment is implemented.
The memory 52 may include a storage program area and a storage data area, wherein the storage program area may store an operating system, an application program required for at least one function; the storage data area may store data created from use of the alarm clock ringing device, and the like. Further, the memory 52 may include high speed random access memory, and may also include non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other non-volatile solid state storage device. In some embodiments, the memory 52 optionally comprises a memory remotely located from the processor 51, and these remote memories may be connected to the alarm ringing device via a network. Examples of such networks include, but are not limited to, the internet, intranets, local area networks, mobile communication networks, and combinations thereof.
The one or more modules are stored in the memory 52, and when executed by the one or more processors 51, the alarm clock ringing method in any of the above-described method embodiments is performed, for example, the method steps S11 to S14 in fig. 2, the method steps S121 to S123 in fig. 3, and the method steps S141 to S143 in fig. 4 described above are performed, so as to implement the functions of the modules 41 to 44 in fig. 5, the modules 41 to 44 in fig. 6, the units 421 and 422, 441 and 443.
The product can execute the method provided by the embodiment of the invention, and has corresponding functional modules and beneficial effects of the execution method. For technical details that are not described in detail in this embodiment, reference may be made to the method provided by the embodiment of the present invention.
The electronic device of embodiments of the present invention exists in a variety of forms, including but not limited to: an alarm clock, a mobile communication device with an alarm clock function, a portable entertainment device with an alarm clock function, and the like.
An embodiment of the present invention provides a non-volatile computer-readable storage medium, where the non-volatile computer-readable storage medium stores computer-executable instructions, which are used by an electronic device to perform the alarm clock ringing method in any of the above-mentioned method embodiments, for example, to perform the method steps S11 to S14 in fig. 2, the method steps S121 to S123 in fig. 3, and the method steps S141 to S143 in fig. 4, which are described above, to implement the functions of the modules 41 to 44 in fig. 5, the modules 41 to 44 in fig. 6, the units 421 and 422, 441 and 443 in fig. 5.
Embodiments of the present invention provide a computer program product comprising a computer program stored on a non-volatile computer-readable storage medium, the computer program comprising program instructions that, when executed by a computer, cause the computer to perform an alarm clock alerting method in any of the above-described method embodiments, for example, perform the above-described method steps S11-S14 in fig. 2, method steps S121-S123 in fig. 3, and method steps S141-S143 in fig. 4, to implement the functions of the modules 41-44 in fig. 5, the modules 41-44 in fig. 6, the units 421-.
The above-described embodiments of the apparatus are merely illustrative, and the units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment.
Through the above description of the embodiments, those skilled in the art will clearly understand that each embodiment can be implemented by software plus a general hardware platform, and certainly can also be implemented by hardware. It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above can be implemented by hardware related to instructions of a computer program, which can be stored in a computer readable storage medium, and when executed, can include the processes of the embodiments of the methods described above. The storage medium may be a magnetic disk, an optical disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), or the like.
Finally, it should be noted that: the above examples are only intended to illustrate the technical solution of the present invention, but not to limit it; within the idea of the invention, also technical features in the above embodiments or in different embodiments may be combined, steps may be implemented in any order, and there are many other variations of the different aspects of the invention as described above, which are not provided in detail for the sake of brevity; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and the modifications or the substitutions do not make the essence of the corresponding technical solutions depart from the scope of the technical solutions of the embodiments of the present invention.

Claims (10)

1. An alarm clock ringing method, comprising:
acquiring alarm time set in the alarm clock;
when the time difference between the system time of the alarm clock and the set alarm time is detected to be a preset time length, acquiring a first day condition of the position of the alarm clock;
acquiring a second weather condition of the position of the alarm clock and corresponding to the alarm time of the previous day;
establishing a weather-time relation mapping table according to the acquired historical weather conditions and the average time spent by the user in the history of arriving at the same destination from the same place of departure;
and adjusting the ringing time of the alarm clock according to the acquired first weather condition, the acquired second weather condition and the weather-time relation mapping table.
2. The method of claim 1, wherein when it is detected that a time difference between a system time of the alarm clock and the set alarm time is a predetermined time length, the obtaining of the first weather condition of the location of the alarm clock comprises:
collecting the weather condition of the current position of the alarm clock at preset time intervals;
selecting the weather condition with the highest occurrence probability in the collected weather conditions as the first weather condition, or selecting the weather condition which is closest to the alarm time in the collected weather conditions as the first weather condition.
3. The method according to claim 1 or 2, wherein the adjusting the alarm clock ringing time according to the obtained first weather condition, the second weather condition and the weather-to-time relationship mapping table comprises:
when the first weather condition is better than the second weather condition, ringing according to a set alarm time, or delaying the set alarm time and ringing according to the delayed alarm time;
when the first weather condition is worse than the second weather condition, advancing the set alarm time and ringing according to the alarm time before and after the alarm;
and when the first weather condition is the same as the second weather condition, ringing according to the set alarm time.
4. The method according to claim 3, wherein said ringing according to the deferred ringing time specifically comprises:
and determining the time length of the set alarm time needing to be delayed according to a preset weather time relation mapping table, determining delayed alarm time according to the time length, and ringing according to the delayed alarm time.
5. The method according to claim 3, wherein said ringing according to the ring time before and after the mention specifically comprises:
and determining the time length of the set alarm time required to be advanced according to a preset weather-time relation mapping table, determining the ring time before and after the alarm according to the time length, and ringing according to the ring time before and after the alarm.
6. The method according to claim 4 or 5, wherein the alarm time set by the alarm clock corresponds to a predetermined event, and the predetermined event is used to remind the user of the alarm clock to go to a destination;
the preset weather-time relationship mapping table comprises: origin, destination, average duration, and weather.
7. An alarm clock ringing device, comprising:
the first acquisition module is used for acquiring the alarm time set in the alarm clock;
the second acquisition module is used for acquiring a first day condition of the position of the alarm clock when the time difference between the system time of the alarm clock and the set alarm clock time is detected to be a preset time length;
the third obtaining module is used for obtaining a second weather condition of the position of the alarm clock and corresponding to the alarm time of the previous day;
the adjusting module is used for establishing a weather-time relation mapping table according to the acquired historical weather conditions and the average time spent by the user in the history of arriving at the same destination from the same place of departure;
and the alarm clock is used for adjusting the ringing time of the alarm clock according to the first weather condition, the second weather condition and the weather-time relation mapping table.
8. The apparatus of claim 7, wherein the second obtaining module comprises:
the acquisition unit is used for acquiring the weather condition of the current position of the alarm clock at intervals of preset time;
and the selecting unit is used for selecting the weather condition with the highest occurrence probability in the collected weather conditions as the first weather condition, or selecting the weather condition which is closest to the alarm time in the collected weather conditions as the first weather condition.
9. The apparatus of claim 7 or 8, wherein the adjustment module comprises:
a first adjusting unit, configured to ring according to a set alarm time when the first weather condition is better than the second weather condition, or delay the set alarm time and ring according to the delayed alarm time;
a second adjusting unit, configured to advance the set alarm time and ring according to the alarm time before and after the alarm when the first weather condition is worse than the second weather condition;
and the third adjusting unit is used for ringing according to the set alarm time when the first weather condition is the same as the second weather condition.
10. An electronic device, comprising:
at least one processor; and the number of the first and second groups,
a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,
the memory stores instructions executable by the at least one processor to enable the at least one processor to perform the method of any one of claims 1 to 6.
CN201710294908.1A 2017-04-28 2017-04-28 Alarm clock ringing method and device and electronic equipment Active CN106990708B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710294908.1A CN106990708B (en) 2017-04-28 2017-04-28 Alarm clock ringing method and device and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710294908.1A CN106990708B (en) 2017-04-28 2017-04-28 Alarm clock ringing method and device and electronic equipment

Publications (2)

Publication Number Publication Date
CN106990708A CN106990708A (en) 2017-07-28
CN106990708B true CN106990708B (en) 2021-01-15

Family

ID=59417184

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710294908.1A Active CN106990708B (en) 2017-04-28 2017-04-28 Alarm clock ringing method and device and electronic equipment

Country Status (1)

Country Link
CN (1) CN106990708B (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107679823A (en) * 2017-09-06 2018-02-09 珠海市魅族科技有限公司 A kind of alarm clock prompting method, device, computer installation and computer-readable recording medium
CN108174044B (en) * 2018-03-15 2020-11-03 维沃移动通信有限公司 Alarm clock setting method and mobile terminal
CN112904704A (en) * 2021-01-29 2021-06-04 上海二三四五网络科技有限公司 Alarm clock device capable of automatically broadcasting based on weather information and control method
CN115250308A (en) * 2021-04-26 2022-10-28 华为技术有限公司 Alarm clock ringing method and equipment

Family Cites Families (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2012039228A (en) * 2010-08-04 2012-02-23 Nec Saitama Ltd Portable terminal
CN103533175B (en) * 2013-10-24 2015-07-22 上海华勤通讯技术有限公司 Automatic setting system and method of mobile phone alarm clock
CN103645629B (en) * 2013-10-28 2016-05-04 三星电子(中国)研发中心 A kind of alarm clock timing method
CN105812544A (en) * 2014-12-30 2016-07-27 Tcl集团股份有限公司 Method for controlling ringing bell of alarm clock and alarm clock
CN104580721A (en) * 2014-12-31 2015-04-29 深圳市金立通信设备有限公司 Alarm clock implementation method for terminal
CN105259744A (en) * 2015-11-12 2016-01-20 北京百纳威尔无线通信设备有限公司 Alarm clock controlling method and device, alarm clock and electronic equipment
CN106126665A (en) * 2016-06-28 2016-11-16 中科创达软件科技(深圳)有限公司 A kind of alarm clock response moment method to set up and device
CN106101459A (en) * 2016-08-26 2016-11-09 努比亚技术有限公司 Alarm clock management method, device and terminal
CN106488026A (en) * 2016-10-19 2017-03-08 珠海格力电器股份有限公司 The control method of mobile terminal, device and mobile terminal
CN106534522A (en) * 2016-10-28 2017-03-22 北京珠穆朗玛移动通信有限公司 Alarm clock prompting method and mobile terminal
CN106600241A (en) * 2017-01-17 2017-04-26 北京奇虎科技有限公司 Method and device for automatically adjusting alarm clock, and mobile terminal

Also Published As

Publication number Publication date
CN106990708A (en) 2017-07-28

Similar Documents

Publication Publication Date Title
CN106990708B (en) Alarm clock ringing method and device and electronic equipment
US9449053B2 (en) Ranking nearby destinations based on visit likelihoods and predicting future visits to places from location history
CN109376313B (en) Information recommendation method and device, terminal and storage medium
TWI679528B (en) Information collection and processing method, client and server
CN105284144B (en) Significant position is modeled
US20170085426A1 (en) System and method for preprocessing user applications
CN103597804A (en) Baseband on-board location monitoring
CN105333880A (en) Communication terminal and prompting method and device
US20150054981A1 (en) Method, electronic device, and computer program product
CN105589085B (en) Low-power-consumption Beidou positioning communication device and control method
US20180032585A1 (en) Systems and methods for context-based contact suggestion
US11032672B2 (en) Method for acquiring location information, terminal, storage medium, and electronic device
WO2020155985A1 (en) Terminal global positioning system (gps) module cold start method, device, terminal, and storage medium
CA2751729C (en) Method and apparatus for generating and using location information
EP2224771A1 (en) Access point information server
CN106878938B (en) Information pushing method, position positioning method and equipment
EP2224769A1 (en) Access point availability estimation
US20190360834A1 (en) Method and Device For Determining Geographical Location For User to Take Bus
JP5972684B2 (en) Distribution device, distribution system, and program
CN111143639B (en) User intimacy calculation method, device, equipment and medium
JP6144243B2 (en) POSITION INFORMATION MANAGEMENT DEVICE, POSITION INFORMATION MANAGEMENT METHOD, AND PROGRAM
CN108738117B (en) Method for optimizing power consumption of application program and terminal
CN111238526A (en) Meteorological information processing method based on commuting trip
CN110619748A (en) Traffic condition analysis and prediction method, device and system based on traffic big data
JP6429936B2 (en) POSITION INFORMATION MANAGEMENT DEVICE, POSITION INFORMATION MANAGEMENT METHOD, AND PROGRAM

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant