CN108133363B - Sleep reminding method, device, terminal and storage medium - Google Patents

Sleep reminding method, device, terminal and storage medium Download PDF

Info

Publication number
CN108133363B
CN108133363B CN201810112452.7A CN201810112452A CN108133363B CN 108133363 B CN108133363 B CN 108133363B CN 201810112452 A CN201810112452 A CN 201810112452A CN 108133363 B CN108133363 B CN 108133363B
Authority
CN
China
Prior art keywords
sleep
time point
reminding
week attribute
target user
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.)
Expired - Fee Related
Application number
CN201810112452.7A
Other languages
Chinese (zh)
Other versions
CN108133363A (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.)
Guangdong Oppo Mobile Telecommunications Corp Ltd
Original Assignee
Guangdong Oppo Mobile Telecommunications Corp 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 Guangdong Oppo Mobile Telecommunications Corp Ltd filed Critical Guangdong Oppo Mobile Telecommunications Corp Ltd
Priority to CN201810112452.7A priority Critical patent/CN108133363B/en
Publication of CN108133363A publication Critical patent/CN108133363A/en
Application granted granted Critical
Publication of CN108133363B publication Critical patent/CN108133363B/en
Expired - Fee Related legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06QINFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES; SYSTEMS OR METHODS SPECIALLY ADAPTED FOR ADMINISTRATIVE, COMMERCIAL, FINANCIAL, MANAGERIAL OR SUPERVISORY PURPOSES, NOT OTHERWISE PROVIDED FOR
    • G06Q10/00Administration; Management
    • G06Q10/10Office automation; Time management
    • G06Q10/109Time management, e.g. calendars, reminders, meetings or time accounting

Landscapes

  • Business, Economics & Management (AREA)
  • Human Resources & Organizations (AREA)
  • Engineering & Computer Science (AREA)
  • Strategic Management (AREA)
  • Entrepreneurship & Innovation (AREA)
  • Operations Research (AREA)
  • Economics (AREA)
  • Marketing (AREA)
  • Data Mining & Analysis (AREA)
  • Quality & Reliability (AREA)
  • Tourism & Hospitality (AREA)
  • Physics & Mathematics (AREA)
  • General Business, Economics & Management (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Measurement Of The Respiration, Hearing Ability, Form, And Blood Characteristics Of Living Organisms (AREA)

Abstract

The embodiment of the application discloses a sleep reminding method, a sleep reminding device, a sleep reminding terminal and a storage medium, and is used for the field of smart home. The method comprises the following steps: the method comprises the steps of obtaining a historical sleep record of a target user in a date corresponding to a week attribute, obtaining a sleep reminding time point corresponding to the week attribute according to the historical sleep record of the target user in the date corresponding to the week attribute, and sending a sleep reminding for reminding the user to fall asleep when the sleep reminding time point arrives in the next date corresponding to the week attribute. The week attribute comprises a date position of a corresponding date in one week, and the historical sleep record comprises a time point of falling asleep. According to the embodiment, the corresponding historical sleep record can be acquired according to the day and the week attribute, so that the time point for reminding the user to fall asleep can be acquired according to the week attribute of the day and the date in a targeted manner, and the effect that the user falls asleep within the date of the specified week attribute is improved.

Description

Sleep reminding method, device, terminal and storage medium
Technical Field
The embodiment of the application relates to the field of smart home, in particular to a sleep reminding method, a sleep reminding device, a terminal and a storage medium.
Background
With the widespread use of electronic products and the proliferation of entertainment products, there is an increasing number of entertainment activities that a user can perform before going to sleep, making it often difficult for the user to fall asleep at a desired time.
In the related art, in order to ensure the sleep duration at night, a user usually sets an alarm clock at a time desired to fall asleep, and when the system time reaches the fall asleep time, the alarm clock rings, and the user hears the alarm clock and then prepares to fall asleep. However, if the user falls asleep before the alarm clock, the alarm clock will wake up the user, and the reminding effect is poor.
Disclosure of Invention
The embodiment of the application provides a sleep reminding method, a sleep reminding device, a sleep reminding terminal and a sleep reminding storage medium, which can be used for solving the problem that if a user falls asleep before an alarm clock, the alarm clock can wake up the user and the reminding effect is poor. The technical scheme is as follows:
in a first aspect, a sleep reminding method is provided, and the method includes:
acquiring historical sleep records of a target user in a date corresponding to a week attribute, wherein the week attribute comprises a date position of the corresponding date in a week, and the historical sleep records comprise time points of falling asleep;
acquiring a sleep reminding time point corresponding to the week attribute according to the historical sleep record of the target user in the date corresponding to the week attribute;
and sending a sleep reminding for reminding the user to fall asleep when the sleep reminding time point arrives in the next date corresponding to the week attribute.
In a second aspect, there is provided a sleep reminder device, the device comprising:
the record acquisition module is configured to acquire a historical sleep record of a target user in a date corresponding to a week attribute, wherein the week attribute comprises a date position of the corresponding date in a week, and the historical sleep record comprises a sleep-falling time point;
the time point acquisition module is configured to acquire a sleep reminding time point corresponding to the week attribute according to the historical sleep record of the target user in the date corresponding to the week attribute;
and the sleep reminding module is configured to send a sleep reminding for reminding the user to fall asleep when the sleep reminding time point arrives in the next date corresponding to the week attribute.
In a third aspect, a terminal is provided, where the terminal includes a processor and a memory, where the memory stores at least one instruction, and the instruction is loaded and executed by the processor to implement the sleep reminding method according to the first aspect.
In a fourth aspect, a computer-readable storage medium is provided, in which at least one instruction is stored, and the instruction is loaded and executed by a processor to implement the sleep reminder method according to the first aspect.
The technical scheme provided by the embodiment of the application has the following beneficial effects:
in the embodiment of the application, the sleep reminding time point corresponding to the week attribute is obtained by obtaining the historical sleep record of the target user in the date corresponding to the week attribute and according to the historical sleep record of the target user in the date corresponding to the week attribute, and the sleep reminding for reminding the user to fall asleep is sent out when the sleep reminding time point arrives in the next date corresponding to the week attribute. The week attribute comprises a date position of a corresponding date in one week, and the historical sleep record comprises a time point of falling asleep. According to the embodiment, the corresponding historical sleep record can be acquired according to the day and the week attribute, so that the time point for reminding the user to fall asleep can be acquired according to the week attribute of the day and the date in a targeted manner, and the effect that the user falls asleep within the date of the specified week attribute is improved.
Drawings
In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed to be used in the description of the embodiments are briefly introduced below, and it is obvious that the drawings in the following description are only some embodiments of the present application, and it is obvious for those skilled in the art to obtain other drawings based on these drawings without creative efforts.
Fig. 1 is a flowchart of a method for sleep reminding according to an embodiment of the present application;
fig. 2 is a flowchart of another sleep reminding method provided in an embodiment of the present application;
FIG. 3 is a schematic diagram of a target user falling asleep according to the embodiment shown in FIG. 2;
FIG. 4 is a block diagram illustrating a sleep alert device according to an exemplary embodiment of the present application;
fig. 5 shows a block diagram of a terminal according to an exemplary embodiment of the present application.
Detailed Description
To make the objects, technical solutions and advantages of the present application more clear, embodiments of the present application will be described in further detail below with reference to the accompanying drawings.
In order to facilitate the description and understanding of the embodiments of the present application, terms appearing in the embodiments of the present invention are explained below.
Week attribute: the date position of the corresponding date in one week is included, specifically, a specified date, specifically, a day of week is included, seven different attribute values of monday, tuesday, wednesday, thursday, friday, saturday and sunday are included, that is, when the week attribute is 1, the date position is used for indicating that the specified date is the first day (date position) in one week. Alternatively, the week attribute may be obtained from a time service center provided by each country, region, or organization. For the terminal, the week attribute may be pre-stored in the terminal or may be acquired from the server. Each assigned date has a unique week attribute.
And (3) recording the historical sleep: including a point in time to fall asleep, which can be acquired by a wearable device worn by the user. The wearable device determines a time point of falling asleep for the target user by acquiring at least one physiological index of the heart rate or blood pressure of the user. Optionally, the historical sleep record is a data record in which at least one time point of falling asleep for the target user is recorded.
Sleep reminding time points: for indicating the point in time when the target user is reminded of sleeping. And when the system time of the terminal reaches the sleep reminding time point, the terminal sends out a sleep reminding for reminding the target user to fall asleep.
In the embodiment of the application, the sleep reminding method is applied to the terminal. In order to carry out sleep reminding on the user, the user can obviously perceive the reminding information. The terminal can remind the user through at least one mode of ringing, vibrations or the warning light is luminous, and correspondingly, the terminal can possess subassemblies such as speaker, vibrations subassembly or warning light.
As a possible implementation manner, the terminal may include a mobile phone, a smart watch, a smart bracelet, a smart ring, smart glasses, a smart speaker, a tablet computer, a laptop computer, a desktop computer, a computer all-in-one machine, a television, an MP4 player terminal, an MP5 player terminal, a learning machine, a point-and-read machine, an electronic book, an electronic dictionary, a Virtual Reality (VR) player terminal, or an Augmented Reality (AR) player terminal. The terminal can remind the user of sleeping through at least one of ringing, vibration, voice or light emitting of the prompting lamp.
Referring to fig. 1, a flowchart of a method for sleep reminding according to an embodiment of the present application is shown. The method can be applied to the terminal and comprises the following steps:
and step 110, acquiring historical sleep records of the target user in a date corresponding to a week attribute, wherein the week attribute comprises a date position of the corresponding date in a week, and the historical sleep records comprise time points of falling asleep.
In the embodiment of the application, the terminal may first acquire the historical sleep record of the target user in the date corresponding to the one-week attribute. Alternatively, since the total number of the week attributes is seven, seven different data tables may be preset to have the historical sleep records corresponding to the week attributes. For example, monday sleep records, tuesday sleep records, …, saturday sleep records, and sunday sleep records.
Alternatively, each table specifying the week attribute may hold the most recently specified number of records. For example, specifying a tuesday sleep record, the last 30 tuesday sleep records may be saved. When a new sleep record is stored, the record with the earliest time can be deleted, namely the record with the earliest time is replaced by the newly stored sleep record. It should be noted that the specified number of records that can be stored in each table of the specified week attribute can be adjusted according to actual requirements, such as 4, 8, 12, 16, or 24 sleep records.
For example, please refer to table one, which shows the sleep record corresponding to the target user on the specified day of the week attribute (tuesday). In table one, 16 sleep records of target user a are recorded. Wherein "D" represents a Date (Date) and "R" represents a history (Record). Alternatively, the history may be accurate to minutes.
Watch 1
D 17.11.7 17.11.14 17.11.21 17.11.28 17.12.5 17.12.12 17.12.19 17.12.28
R 21:48 21:52 21:59 21:30 20:25 22:07 22:13 21:40
D 18.1.2 18.1.9 18.1.16 18.1.23 18.1.30 18.2.6 18.2.13 18.2.20
R 22:25 23:40 21:46 21:55 22:03 22:15 22:01 22:07
Alternatively, in this step, if this step is performed by the terminal, the terminal may first determine which historical sleep record of the specified day attribute is to be acquired, for example, the terminal acquires the historical sleep record of tuesday if the day is tuesday. If the step is executed by the server, the server can acquire a historical record acquisition request of the terminal, the request can carry the identification of the target user, the server determines the historical sleep record which the terminal wants to acquire according to the identification of the target user, and feeds the historical sleep record back to the terminal.
And step 120, acquiring a sleep reminding time point corresponding to the week attribute according to the historical sleep record of the target user in the date corresponding to the week attribute.
In this embodiment, the terminal may obtain the sleep reminding time point corresponding to the week attribute according to the historical sleep record. For example, taking the historical sleep records shown in table one as an example, the terminal may average all 16 records at the time of falling asleep to an average of about 21:59 (to the nearest minute). Alternatively, the recorded averages of the last 4 time points to sleep were found to be about 22:07 (to the nearest minute). It should be noted that, here, obtaining the sleep reminding time point corresponding to the week attribute is only two methods that can be implemented, and no limitation is made to other implementable manners of this step.
And step 130, sending a sleep reminder for reminding the user to fall asleep when the sleep reminder time point arrives in the next date corresponding to the week attribute.
In the application, the terminal sends the sleep reminding for reminding the user to fall asleep when the sleep reminding time point arrives within the next date corresponding to the week attribute. For convenience of illustration, the historical sleep record shown in table one is still taken as an example. After the terminal acquires the historical sleep record shown in the table I, the terminal determines the date of which the week attribute is Tuesday corresponding to the historical sleep record shown in the table I. The terminal determines that the date of the next Tuesday is '18.2.27' according to the latest historical record date '18.2.20' in the table, and if the sleep reminding time point is 21:59, the terminal reminds the target user at 21 points 59 of 2, 27 and 2018. The specific reminding mode can be different according to the actual form of the terminal.
Optionally, when the actual form of the terminal is the smart band worn by the target user, the smart band may remind the target user in a vibration manner. When the actual form of the terminal is the mobile phone, the terminal can remind the target user in a ringing mode. Or, when the actual form of the terminal is a mobile phone, the terminal can also display the sleep reminding message of the user on the screen through the pop-up window.
In summary, in the embodiment of the present application, the historical sleep record of the target user in the date corresponding to the week attribute is obtained, the sleep reminding time point corresponding to the week attribute is obtained according to the historical sleep record of the target user in the date corresponding to the week attribute, and in the next date corresponding to the week attribute, the sleep reminding for reminding the user to fall asleep is sent when the sleep reminding time point arrives. The week attribute comprises a date position of a corresponding date in one week, and the historical sleep record comprises a time point of falling asleep. According to the embodiment, the corresponding historical sleep record can be acquired according to the day and the week attribute, so that the time point for reminding the user to fall asleep can be acquired according to the week attribute of the day and the date in a targeted manner, and the effect that the user falls asleep within the date of the specified week attribute is improved.
According to the embodiment of the application, the historical sleep records with large interference can be removed when the sleep reminding time point is obtained. For details, refer to fig. 2, which is a flowchart of another sleep reminding method provided in the embodiment of the present application, and the method can be applied to the above terminal, and the method can include the following steps:
step 201, obtaining the historical sleep record of the target user in the date corresponding to the week attribute, wherein the week attribute comprises the date position of the corresponding date in the week, and the historical sleep record comprises the time point of falling asleep.
In the embodiment of the present application, the execution process of step 201 is the same as the execution process of step 110, and is not described herein again.
Step 202, according to the historical sleep records of the target user in the date corresponding to the week attribute, at least two sleep time points which meet the error condition in the sleep time points of the target user in the date corresponding to the week attribute are obtained.
In the embodiment of the application, the terminal can obtain at least two sleep-falling time points of the target user in the date corresponding to the week attribute according to the historical sleep records of the target user in the date corresponding to the week attribute. It should be noted that the method provided by the present embodiment requires acquiring at least two time points of falling asleep under the specified error condition.
In a possible implementation, step 202 may be alternatively implemented by step 2021, step 2022 and step 2023.
Step 2021, performing average calculation on the time point of falling asleep within the date corresponding to the week attribute of the target user to obtain a second average time point.
In the embodiment of the application, the terminal calculates the average value of the time points of falling asleep within the date corresponding to the week attribute of the target user to obtain the second average time point. For example, the user may calculate the second average time point by the following equation (1-1).
Figure BDA0001569650790000061
Wherein M is1Representing a second average time point, k representing the kth historical sleep record in the historical sleep records of the target user in the date corresponding to the week attribute, N representing the total number of the historical sleep records of the target user in the date corresponding to the week attribute, TkIndicating an objective in the kth historical sleep recordThe time point of falling asleep of the user is marked.
Alternatively, taking the data in Table I as an example, the value of N is 16, and M can be calculated according to equation (1-1)1Approximately equal to 21:59 (to the nearest minute).
Step 2022, calculate the difference between the time-to-sleep point and the second average point in time for the target user within the date corresponding to the week attribute.
In the embodiment of the application, the terminal respectively calculates the difference between the time point of falling asleep and the second average time point of the user in each historical sleep record. Still taking the data shown in table one as an example, since there are 16 historical sleep records in table one, the terminal obtains 16 difference values. For example, if the historical sleep record "17.12.12" corresponds to a time point of falling asleep of 22:07 and the second average time point is 21:59, the difference value for the historical sleep record "17.12.12" is 8 minutes.
Step 2023, obtaining at least two falling-asleep time points of which the difference value with the second average time point is within the preset difference value range, wherein the at least two falling-asleep time points meet the error condition in the falling-asleep time points of the target user within the date corresponding to the week attribute.
In the embodiment of the present application, the preset difference range may be a value preset by a user or a terminal designer, for example, a time length of 2 hours, 1 hour, or 0.5 hour. Still taking the data shown in table one as an example, if the preset difference range is 1 hour, the differences between the rest 14 records and the second average time point are within the preset difference range, except for the two records of "20: 25" corresponding to "17.12.5" and "23: 40" corresponding to "18.1.9" in the 16 records recorded in table one. The terminal will obtain the time point of falling asleep corresponding to each of the 14 records.
Alternatively, the terminal may calculate the difference between each record and the second average time point by equation (1-2).
dk=|Tk-M1| (1-2)
Wherein d iskTime point T of falling asleep representing the kth historical sleep recordkAnd a second average time point M1Absolute difference betweenAnd (6) comparing the values.
And step 203, calculating the average value of at least two time points falling asleep to obtain a first average time point.
In the embodiment of the application, the terminal performs average calculation on at least two time points falling asleep to obtain a first average time point. Alternatively, the terminal may calculate the first average time point by equation (1-3).
Figure BDA0001569650790000071
Wherein M is2Indicating a first average time point, K indicating the kth historical sleep record meeting the error condition in the historical sleep records of the target user in the date corresponding to the week attribute, K indicating the total number of the historical sleep records of the target user in the date corresponding to the week attribute, TkIndicating the time point of falling asleep for the target user in the kth historical sleep record.
Alternatively, taking the data provided in Table one as an example, the value of K is 14, and M is obtained by calculation using the formula (1-3)2The value of (1) is 21: 58.
And step 204, acquiring the first average time point as a sleep reminding time point.
In the embodiment of the present application, the terminal averages the first average time point M2The acquisition is a sleep reminding time point. For example, 21:58 obtained by the calculation of equation (1-3) is acquired as the sleep reminder time point.
It should be noted that, after the step 204 is completed, the embodiment of the present application may perform the step 205 and the step 206, may perform the step 205 and the step 207, or perform the step 208, the step 209, and the step 210, or perform the step 208, the step 209, and the step 211.
Step 205, in the next date corresponding to the week attribute, when the sleep reminding time point arrives, it is detected whether the target user has entered the sleep state.
In the embodiment of the application, the terminal determines the next date corresponding to the week attribute. That is, the terminal acquires the Tuesday sleep record as in Table one and simultaneously acquires the current date of the terminal, for example, the current date acquired by the terminal is 2018, 2 and 23 days, the terminal will detect whether the target user has entered the sleep state in the next Tuesday (2018, 2 and 27 days), when the system clock reaches 21: 58.
In step 206, if the target user has entered the sleep state, the sleep reminder is cancelled.
In the embodiment of the application, if the target user enters the sleep state, the terminal cancels the sleep reminding. In an actual implementation process, the terminal may determine whether the user has entered the sleep state through at least one of the blood pressure and the heart rate of the target user. If the terminal determines that the user enters the sleep state, the terminal cancels the sleep reminding aiming at the target user, and the user who enters the sleep state is enabled to be awakened.
And step 207, if the target user does not enter the sleep state, performing sleep reminding.
And step 208, acquiring environmental parameters when the sleep reminding time point arrives in the next date corresponding to the week attribute, wherein the environmental parameters comprise at least one of light parameters and sound parameters.
It should be noted that the reminder cancellation condition includes at least one of the sound parameter being lower than the third threshold value, or the light parameter being lower than the fourth threshold value.
In the first case, the reminder cancellation condition is that the sound parameter is below a third threshold, in which case the third threshold may be in decibels (db). If the third threshold is 30 db, the terminal may determine that the reminder cancellation condition is satisfied when the sound parameter is continuously less than 30 db for more than 2 minutes.
In the second case, the reminder cancellation condition is that the light parameter is lower than the fourth threshold, in which case the fourth threshold may be expressed by using the illumination intensity and may be in lux (Lx), and if the fourth threshold is 50 lux, the terminal may determine that the reminder cancellation condition is satisfied if the light parameter lasts less than 50 lux for more than 2 minutes.
In a third case, the reminder cancellation condition is that the sound parameter is lower than the third threshold and the light parameter is lower than the fourth threshold, in which case the terminal may determine that the reminder cancellation condition is satisfied in a case where the sound parameter is lower than the third threshold and the light parameter is lower than the fourth threshold.
Step 209, detecting whether the environmental parameter meets the cancel reminding condition.
In the embodiment of the application, the terminal can detect whether the environmental parameter meets the reminding cancellation condition through a sensor configured on the terminal. For example, the terminal may detect whether the sound parameter is lower than a third threshold value by the microphone and whether the light parameter is lower than a fourth threshold value by the light sensor. And whether the environmental parameters meet the reminding cancellation condition or not is determined according to the actual detection result.
And step 210, if the environmental parameters meet the reminding cancellation conditions, canceling the sleep reminding.
In the embodiment of the application, the terminal can cancel the sleep reminder when the environmental parameter meets the reminder cancellation condition. It should be noted that, when the environment parameter satisfies the reminder cancellation condition, the following scenario may be used.
In one possible scenario, the target user is lying in bed to fall asleep, and the terminal detects that the user is awake by heart rate or blood pressure because the user is actually awake, but the user has turned off the illumination lamp to go to sleep. At this time, the light sensor of the terminal detects that the ambient light is lower than the third threshold, so that the sleep reminder is cancelled, and the sleep reminder is prevented from mistakenly disturbing the user who is ready to fall asleep.
In another possible scenario, the target user lies in bed to fall asleep, and since the user is actually awake, the terminal detects that the user is awake through the heart rate or the blood pressure, but the user turns on a small night light but the environment is quite, and at this time, the microphone of the terminal acquires the sound parameter which is continuously lower than the fourth threshold, so that the sleep reminder is cancelled, and the sleep reminder is prevented from mistakenly disturbing the user who is ready to fall asleep.
And step 211, if the environmental parameter does not meet the reminding cancellation condition, performing sleep reminding.
For example, in a possible implementation manner of the embodiment of the present application, taking the terminal as an intelligent bracelet as an example, a possible application scenario of the embodiment is described. If the day is 2018, 2, month and 27, the smart bracelet determines that the day is Tuesday, and data recorded by Tuesday sleep is obtained as shown in the table I. After excluding the two records of "20: 25" corresponding to "17.12.5" and "23: 40" corresponding to "18.1.9" in table one, which have larger data deviation, the average time point of falling asleep of the remaining 14 records is calculated to obtain the sleep reminding time point 21: 58. When the system time of the smart band reaches 21:58, the smart band firstly judges whether the user falls asleep or not according to the heart rate and the blood pressure of the user.
In one case, the smart band will cancel the sleep alert after the smart band determines that the user has fallen asleep. And the time point of falling asleep at this time, for example, 21:40, the smart bracelet stores the record "21: 40" corresponding to "18.2.27" into table one, and deletes the record "21: 48" corresponding to the record "17.11.7" with the earliest date. At this time, the terminal adds the time of falling asleep of the target user in the next date corresponding to the week attribute to the historical sleep record of the target user in the date corresponding to the week attribute.
In another case, after the smart band determines that the user is not asleep, the smart band may remind the user to fall asleep by vibrating after 21: 58. Or the smart band can continue to collect the ambient light brightness through the optical sensor and collect the ambient sound through the microphone, and when the ambient light brightness is smaller than the fourth threshold or the ambient sound is smaller than the third threshold, the sleep reminding is cancelled. Referring to fig. 3, fig. 3 is a schematic diagram illustrating that a target user falls asleep based on the embodiment shown in fig. 2. In fig. 3, the smart band 31 determines that the sleep reminding time point is 21:58, and determines that the target user 30 has entered the sleep state through the blood pressure and the heart rate at 21:58, and cancels the sleep reminding.
In summary, in the embodiments of the present application, by obtaining the historical sleep records of the target user within the date corresponding to the week attribute, the week attribute includes the date position of the corresponding date within one week, the historical sleep records include the time point of falling asleep, obtaining at least two sleep-falling time points which meet error conditions in the sleep-falling time points of the target user in the date corresponding to the week attribute according to the historical sleep records of the target user in the date corresponding to the week attribute, calculating the average value of at least two time points falling asleep to obtain a first average time point, acquiring the first average time point as a sleep reminding time point, and detecting whether the target user enters a sleep state or not when the sleep reminding time point arrives in the next date corresponding to the week attribute, and if so, cancelling the sleep reminding. The terminal can automatically determine the historical sleep record of the same week attribute in history according to the week attribute of the current date, so that the sleep reminding time point for reminding the user to fall asleep by the terminal is determined to be more in line with the historical habits of the user, the rest of the target user who falls asleep can be avoided, and the effect of reminding the target user to fall asleep is improved.
The following are embodiments of the apparatus of the present application that may be used to perform embodiments of the method of the present application. For details which are not disclosed in the embodiments of the apparatus of the present application, reference is made to the embodiments of the method of the present application.
Referring to fig. 4, a block diagram of a sleep reminding apparatus according to an exemplary embodiment of the present application is shown. The sleep reminding device can be realized by software, hardware or a combination of the software and the hardware to be all or part of the terminal. The device includes:
a record obtaining module 410 configured to obtain a historical sleep record of the target user within a date corresponding to a week attribute, wherein the week attribute includes a date position of the corresponding date within a week, and the historical sleep record includes a time point of falling asleep;
a time point obtaining module 420, configured to obtain a sleep reminding time point corresponding to the week attribute according to a historical sleep record of the target user in a date corresponding to the week attribute;
a sleep reminding module 430 configured to send a sleep reminder for reminding the target user to fall asleep when the sleep reminding time point arrives within a next date corresponding to the week attribute.
In an optional embodiment, the time point obtaining module 420 is configured to obtain, according to the historical sleep records of the target user in the date corresponding to the week attribute, at least two sleep-falling time points that meet an error condition among the sleep-falling time points of the target user in the date corresponding to the week attribute; calculating the average value of the at least two time points of falling asleep to obtain a first average time point; and acquiring the first average time point as the sleep reminding time point.
In an optional embodiment, the time point obtaining module 420 is configured to perform an average calculation on the time point of falling asleep for the target user within the date corresponding to the week attribute, so as to obtain a second average time point; calculating a difference value between the time point of falling asleep of the target user in the date corresponding to the week attribute and the second average time point; and acquiring at least two falling-asleep time points of which the difference value with the second average time point is within a preset difference value range, wherein the at least two falling-asleep time points meet error conditions in the falling-asleep time points of the target user in the date corresponding to the week attribute.
In an optional embodiment, the sleep reminding apparatus further includes a record adding module configured to add the sleep time of the target user in the next date corresponding to the week attribute to the historical sleep record of the target user in the date corresponding to the week attribute.
In an optional embodiment, the sleep reminding apparatus further includes a sleep detection module configured to detect whether the target user has entered a sleep state when the sleep reminding time point arrives within a next date corresponding to the week attribute; a cancel reminder module configured to cancel the sleep reminder if the target user has entered a sleep state.
In an optional embodiment, the sleep detection module is configured to acquire an environmental parameter when the sleep reminding time point arrives within a next date corresponding to the week attribute, wherein the environmental parameter includes at least one of a light parameter and a sound parameter; detecting whether the environmental parameters meet reminding cancellation conditions or not; a cancel reminder module configured to cancel the sleep reminder if the environmental parameter satisfies the reminder cancel condition.
In an optional embodiment, the reminder cancellation condition includes: the sound parameter is lower than a third threshold value, or the light parameter is lower than at least one of a fourth threshold value.
Referring to fig. 5, a block diagram of a terminal according to an exemplary embodiment of the present application is shown. As shown in fig. 5, the terminal includes a processor 510 and a memory 520, where the memory 520 stores at least one instruction, and the instruction is loaded and executed by the processor 510 to implement the sleep reminding method according to the above embodiments.
The embodiment of the present application further provides a computer-readable medium, where at least one instruction is stored, and the at least one instruction is loaded and executed by the processor to implement the sleep reminding method according to the above embodiments.
The embodiment of the present application further provides a computer program product, where at least one instruction is stored, and the at least one instruction is loaded and executed by the processor to implement the sleep reminding method according to the above embodiments.
The above-mentioned serial numbers of the embodiments of the present application are merely for description and do not represent the merits of the embodiments.
It will be understood by those skilled in the art that all or part of the steps for implementing the above embodiments may be implemented by hardware, or may be implemented by a program instructing relevant hardware, where the program may be stored in a computer-readable storage medium, and the above-mentioned storage medium may be a read-only memory, a magnetic disk or an optical disk, etc.
The above description is only exemplary of the present application and should not be taken as limiting the present application, as any modification, equivalent replacement, or improvement made within the spirit and principle of the present application should be included in the protection scope of the present application.

Claims (7)

1. A sleep reminding method, the method comprising:
acquiring historical sleep records of a target user in a date corresponding to a week attribute, wherein the week attribute comprises a date position of the corresponding date in a week, the historical sleep records comprise sleep-falling time points, and a table of each week attribute stores the historical sleep records corresponding to each week attribute;
calculating the average value of the time points of falling asleep of the target user in the table corresponding to the week attribute to obtain a second average time point;
calculating the difference value between the time point of falling asleep and the second average time point of the target user in the table corresponding to the week attribute;
acquiring at least two time points falling asleep, the difference value of which is within a preset difference value range, from the time points falling asleep within the date corresponding to the week attribute of the target user, wherein the time points falling asleep satisfies an error condition;
calculating the average value of the at least two time points of falling asleep to obtain a first average time point;
acquiring the first average time point as the sleep reminding time point;
sending a sleep reminder for reminding the target user to fall asleep when the sleep reminder time point arrives within the next date corresponding to the week attribute;
the method further comprises the following steps:
within the next date corresponding to the week attribute, when the sleep reminding time point arrives, acquiring an environmental parameter, wherein the environmental parameter comprises at least one of a light parameter and a sound parameter;
detecting whether the environmental parameters meet reminding cancellation conditions or not;
and if the environmental parameters meet the reminding cancellation conditions, cancelling the sleep reminding.
2. The method of claim 1, further comprising:
and adding the sleeping time of the target user in the next date corresponding to the week attribute into the historical sleeping record of the target user in the date corresponding to the week attribute.
3. The method of claim 1, further comprising:
detecting whether the target user enters a sleep state or not when the sleep reminding time point arrives in the next date corresponding to the week attribute;
and if the target user enters a sleep state, cancelling the sleep reminding.
4. The method of claim 1, wherein the reminder cancellation condition comprises:
the sound parameter is lower than a third threshold value, or the light parameter is lower than at least one of a fourth threshold value.
5. A sleep alert device, the device comprising:
the record acquisition module is configured to acquire a historical sleep record of a target user in a date corresponding to a week attribute, wherein the week attribute comprises a date position of the corresponding date in a week, the historical sleep record comprises a sleep-falling time point, and a table of each week attribute stores the historical sleep record corresponding to each week attribute;
the time point acquisition module is configured to acquire a sleep reminding time point corresponding to the week attribute according to the historical sleep record of the target user in the date corresponding to the week attribute;
the sleep reminding module is configured to send a sleep reminding for reminding the target user to fall asleep when the sleep reminding time point arrives in the next date corresponding to the week attribute;
the time point acquisition module is configured to perform average calculation on the time points of falling asleep in the table corresponding to the week attribute of the target user to obtain a second average time point; calculating a difference value between the time point of falling asleep of the target user in the date corresponding to the week attribute and the second average time point; acquiring at least two time points falling asleep, the difference value of which is within a preset difference value range, from the time points falling asleep within the date corresponding to the week attribute of the target user, wherein the time points falling asleep satisfies an error condition;
the time point acquisition module is configured to perform average calculation on the at least two time points of falling asleep to obtain a first average time point; acquiring the first average time point as the sleep reminding time point;
the device further comprises:
the sleep detection module is configured to acquire an environmental parameter when the sleep reminding time point arrives within the next date corresponding to the week attribute, wherein the environmental parameter comprises at least one of a light parameter and a sound parameter; detecting whether the environmental parameters meet reminding cancellation conditions or not;
a cancel reminder module configured to cancel the sleep reminder if the environmental parameter satisfies the reminder cancel condition.
6. A terminal, characterized in that the terminal comprises a processor and a memory, wherein the memory stores at least one instruction, and the instruction is loaded and executed by the processor to realize the sleep reminding method according to any one of claims 1 to 4.
7. A computer-readable storage medium having stored therein at least one instruction which is loaded and executed by a processor to implement the sleep alert method as claimed in any one of claims 1 to 4.
CN201810112452.7A 2018-02-05 2018-02-05 Sleep reminding method, device, terminal and storage medium Expired - Fee Related CN108133363B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810112452.7A CN108133363B (en) 2018-02-05 2018-02-05 Sleep reminding method, device, terminal and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810112452.7A CN108133363B (en) 2018-02-05 2018-02-05 Sleep reminding method, device, terminal and storage medium

Publications (2)

Publication Number Publication Date
CN108133363A CN108133363A (en) 2018-06-08
CN108133363B true CN108133363B (en) 2021-02-09

Family

ID=62430479

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810112452.7A Expired - Fee Related CN108133363B (en) 2018-02-05 2018-02-05 Sleep reminding method, device, terminal and storage medium

Country Status (1)

Country Link
CN (1) CN108133363B (en)

Families Citing this family (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109326309B (en) * 2018-09-28 2020-11-03 苏州狗尾草智能科技有限公司 User sleep management system
CN109803054A (en) * 2019-01-30 2019-05-24 上海与德通讯技术有限公司 A kind of control method of alarm clock, device, storage medium and electronic equipment
CN109788351A (en) * 2019-01-30 2019-05-21 上海与德通讯技术有限公司 A kind of control method of alarm clock, device, storage medium and electronic equipment
CN110286951A (en) 2019-06-28 2019-09-27 百度在线网络技术(北京)有限公司 A kind of processing method of interruption-free, device and storage medium
CN110351431B (en) * 2019-07-18 2024-02-27 深圳传音控股股份有限公司 Sleep mode setting method, user terminal and computer readable storage medium
CN111529886A (en) * 2020-05-12 2020-08-14 深圳市腾瑞丰物联网科技有限公司 Method for intelligently waking up user and intelligent alarm clock wake-up system
CN112254309A (en) * 2020-09-29 2021-01-22 杭州微碳信息科技有限公司 Hotel sleep mode switching method of intelligent air purifier
CN112819084A (en) * 2021-02-09 2021-05-18 珠海格力电器股份有限公司 Method and device for determining target sleep information

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103338312A (en) * 2013-07-18 2013-10-02 沈阳华立德电子科技有限公司 Intelligent handset sleeping energy-saving system and method
CN104750483A (en) * 2015-03-13 2015-07-01 广东欧珀移动通信有限公司 Method and device of controlling terminal alarm clock
CN104881121A (en) * 2015-05-28 2015-09-02 小米科技有限责任公司 Prompting method and device
CN106540367A (en) * 2016-11-01 2017-03-29 北京小米移动软件有限公司 Dormancy management method and Intelligent bracelet
WO2017058359A1 (en) * 2015-09-30 2017-04-06 Apple Inc. Facilitating restful sleep using reminders
CN106686250A (en) * 2017-02-10 2017-05-17 广东小天才科技有限公司 Reminding mode setting method and device of intelligent terminal and intelligent watch
CN106913313A (en) * 2015-12-28 2017-07-04 ***通信集团公司 A kind of sleep monitor method and system

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103338312A (en) * 2013-07-18 2013-10-02 沈阳华立德电子科技有限公司 Intelligent handset sleeping energy-saving system and method
CN104750483A (en) * 2015-03-13 2015-07-01 广东欧珀移动通信有限公司 Method and device of controlling terminal alarm clock
CN104881121A (en) * 2015-05-28 2015-09-02 小米科技有限责任公司 Prompting method and device
WO2017058359A1 (en) * 2015-09-30 2017-04-06 Apple Inc. Facilitating restful sleep using reminders
CN106913313A (en) * 2015-12-28 2017-07-04 ***通信集团公司 A kind of sleep monitor method and system
CN106540367A (en) * 2016-11-01 2017-03-29 北京小米移动软件有限公司 Dormancy management method and Intelligent bracelet
CN106686250A (en) * 2017-02-10 2017-05-17 广东小天才科技有限公司 Reminding mode setting method and device of intelligent terminal and intelligent watch

Also Published As

Publication number Publication date
CN108133363A (en) 2018-06-08

Similar Documents

Publication Publication Date Title
CN108133363B (en) Sleep reminding method, device, terminal and storage medium
CN103518204B (en) Messaging device, information processing method and program
CN104427075B (en) Sound volume regulating system and method
CN110533894B (en) Visual fatigue reminding method, device, equipment and readable storage medium
US20180107793A1 (en) Health activity monitoring and work scheduling
KR20160099423A (en) Electronic device for inputting sleeping information and method for controlling thereof
US10721363B2 (en) System and method for controlling notifications in an electronic device according to user status
KR20170024913A (en) Noise Cancelling Electronic Device and Noise Cancelling Method Using Plurality of Microphones
JP6692239B2 (en) Information processing device, information processing system, terminal device, information processing method, and information processing program
US20210205701A1 (en) Gamification of health awareness based on sleep patterns
CN108229920B (en) Affair reminding method and mobile terminal
CN113038337B (en) Audio playing method, wireless earphone and computer readable storage medium
CN105094800B (en) Alarming method, device and terminal
CN104883411A (en) Intelligent device and method for data information sharing and remote health care
US20170285582A1 (en) Information processing apparatus, method for controlling information processing apparatus, and recording medium
KR20200061020A (en) Electronic device for providing meditation contents and operating method thereof
US10754611B2 (en) Filtering sound based on desirability
US20170109706A1 (en) Method and Apparatus For Changing Electronic Device Status
CN111314561B (en) Intelligent reminding method, terminal and storage medium
CN111163219A (en) Alarm clock processing method and device, storage medium and terminal
WO2018172410A1 (en) Method and apparatus for sending a message to a subject
WO2023012777A1 (en) System and method for personalized hearing aid adjustment
CN114305376A (en) Coma state determination method and device and health monitoring equipment
KR102213797B1 (en) The Clever smoking-quitting system
EP1540956A1 (en) Device and method for finding media data pertaining to suggestions

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
CB02 Change of applicant information
CB02 Change of applicant information

Address after: Changan town in Guangdong province Dongguan 523860 usha Beach Road No. 18

Applicant after: GUANGDONG OPPO MOBILE TELECOMMUNICATIONS Corp.,Ltd.

Address before: Changan town in Guangdong province Dongguan 523860 usha Beach Road No. 18

Applicant before: GUANGDONG OPPO MOBILE TELECOMMUNICATIONS Corp.,Ltd.

GR01 Patent grant
GR01 Patent grant
CF01 Termination of patent right due to non-payment of annual fee
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20210209