WO2017000909A1 - 可穿戴智能设备的数据统计 - Google Patents

可穿戴智能设备的数据统计 Download PDF

Info

Publication number
WO2017000909A1
WO2017000909A1 PCT/CN2016/088092 CN2016088092W WO2017000909A1 WO 2017000909 A1 WO2017000909 A1 WO 2017000909A1 CN 2016088092 W CN2016088092 W CN 2016088092W WO 2017000909 A1 WO2017000909 A1 WO 2017000909A1
Authority
WO
WIPO (PCT)
Prior art keywords
indicator data
physiological indicator
smart device
data
time
Prior art date
Application number
PCT/CN2016/088092
Other languages
English (en)
French (fr)
Inventor
伍浩铖
苏腾荣
Original Assignee
安徽华米信息科技有限公司
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 安徽华米信息科技有限公司 filed Critical 安徽华米信息科技有限公司
Publication of WO2017000909A1 publication Critical patent/WO2017000909A1/zh
Priority to US15/592,623 priority Critical patent/US10853301B2/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/38Information transfer, e.g. on bus
    • G06F13/42Bus transfer protocol, e.g. handshake; Synchronisation
    • G06F13/4282Bus transfer protocol, e.g. handshake; Synchronisation on a serial bus, e.g. I2C bus, SPI bus
    • AHUMAN NECESSITIES
    • A61MEDICAL OR VETERINARY SCIENCE; HYGIENE
    • A61BDIAGNOSIS; SURGERY; IDENTIFICATION
    • A61B5/00Measuring for diagnostic purposes; Identification of persons
    • A61B5/0002Remote monitoring of patients using telemetry, e.g. transmission of vital signals via a communication network
    • A61B5/0015Remote monitoring of patients using telemetry, e.g. transmission of vital signals via a communication network characterised by features of the telemetry system
    • A61B5/0024Remote monitoring of patients using telemetry, e.g. transmission of vital signals via a communication network characterised by features of the telemetry system for multiple sensor units attached to the patient, e.g. using a body or personal area network
    • AHUMAN NECESSITIES
    • A61MEDICAL OR VETERINARY SCIENCE; HYGIENE
    • A61BDIAGNOSIS; SURGERY; IDENTIFICATION
    • A61B5/00Measuring for diagnostic purposes; Identification of persons
    • A61B5/02Detecting, measuring or recording pulse, heart rate, blood pressure or blood flow; Combined pulse/heart-rate/blood pressure determination; Evaluating a cardiovascular condition not otherwise provided for, e.g. using combinations of techniques provided for in this group with electrocardiography or electroauscultation; Heart catheters for measuring blood pressure
    • A61B5/0205Simultaneously evaluating both cardiovascular conditions and different types of body conditions, e.g. heart and respiratory condition
    • AHUMAN NECESSITIES
    • A61MEDICAL OR VETERINARY SCIENCE; HYGIENE
    • A61BDIAGNOSIS; SURGERY; IDENTIFICATION
    • A61B5/00Measuring for diagnostic purposes; Identification of persons
    • A61B5/02Detecting, measuring or recording pulse, heart rate, blood pressure or blood flow; Combined pulse/heart-rate/blood pressure determination; Evaluating a cardiovascular condition not otherwise provided for, e.g. using combinations of techniques provided for in this group with electrocardiography or electroauscultation; Heart catheters for measuring blood pressure
    • A61B5/024Detecting, measuring or recording pulse rate or heart rate
    • AHUMAN NECESSITIES
    • A61MEDICAL OR VETERINARY SCIENCE; HYGIENE
    • A61BDIAGNOSIS; SURGERY; IDENTIFICATION
    • A61B5/00Measuring for diagnostic purposes; Identification of persons
    • A61B5/103Detecting, measuring or recording devices for testing the shape, pattern, colour, size or movement of the body or parts thereof, for diagnostic purposes
    • A61B5/11Measuring movement of the entire body or parts thereof, e.g. head or hand tremor, mobility of a limb
    • A61B5/1118Determining activity level
    • AHUMAN NECESSITIES
    • A61MEDICAL OR VETERINARY SCIENCE; HYGIENE
    • A61BDIAGNOSIS; SURGERY; IDENTIFICATION
    • A61B5/00Measuring for diagnostic purposes; Identification of persons
    • A61B5/68Arrangements of detecting, measuring or recording means, e.g. sensors, in relation to patient
    • A61B5/6801Arrangements of detecting, measuring or recording means, e.g. sensors, in relation to patient specially adapted to be attached to or worn on the body surface
    • A61B5/6802Sensor mounted on worn items
    • A61B5/6804Garments; Clothes
    • A61B5/6807Footwear
    • AHUMAN NECESSITIES
    • A61MEDICAL OR VETERINARY SCIENCE; HYGIENE
    • A61BDIAGNOSIS; SURGERY; IDENTIFICATION
    • A61B5/00Measuring for diagnostic purposes; Identification of persons
    • A61B5/68Arrangements of detecting, measuring or recording means, e.g. sensors, in relation to patient
    • A61B5/6801Arrangements of detecting, measuring or recording means, e.g. sensors, in relation to patient specially adapted to be attached to or worn on the body surface
    • A61B5/6802Sensor mounted on worn items
    • A61B5/681Wristwatch-type devices
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01CMEASURING DISTANCES, LEVELS OR BEARINGS; SURVEYING; NAVIGATION; GYROSCOPIC INSTRUMENTS; PHOTOGRAMMETRY OR VIDEOGRAMMETRY
    • G01C22/00Measuring distance traversed on the ground by vehicles, persons, animals or other moving solid bodies, e.g. using odometers, using pedometers
    • G01C22/006Pedometers
    • GPHYSICS
    • G16INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR SPECIFIC APPLICATION FIELDS
    • G16HHEALTHCARE INFORMATICS, i.e. INFORMATION AND COMMUNICATION TECHNOLOGY [ICT] SPECIALLY ADAPTED FOR THE HANDLING OR PROCESSING OF MEDICAL OR HEALTHCARE DATA
    • G16H40/00ICT specially adapted for the management or administration of healthcare resources or facilities; ICT specially adapted for the management or operation of medical equipment or devices
    • G16H40/60ICT specially adapted for the management or administration of healthcare resources or facilities; ICT specially adapted for the management or operation of medical equipment or devices for the operation of medical equipment or devices
    • G16H40/63ICT specially adapted for the management or administration of healthcare resources or facilities; ICT specially adapted for the management or operation of medical equipment or devices for the operation of medical equipment or devices for local operation
    • AHUMAN NECESSITIES
    • A61MEDICAL OR VETERINARY SCIENCE; HYGIENE
    • A61BDIAGNOSIS; SURGERY; IDENTIFICATION
    • A61B5/00Measuring for diagnostic purposes; Identification of persons
    • A61B5/68Arrangements of detecting, measuring or recording means, e.g. sensors, in relation to patient
    • A61B5/6801Arrangements of detecting, measuring or recording means, e.g. sensors, in relation to patient specially adapted to be attached to or worn on the body surface
    • A61B5/6802Sensor mounted on worn items
    • A61B5/6803Head-worn items, e.g. helmets, masks, headphones or goggles

Definitions

  • the present invention relates to data statistics for wearable smart devices.
  • Wearable smart devices are highly integrated and portable, and are favored by more and more consumers. For example, users can use them to monitor their various physiological parameters, including walking steps, heart rate, moving distance, and so on.
  • one client can usually only connect one smart device. In this case, if the user carries multiple smart devices with them, it is necessary to have multiple clients at the same time, so that data connections can be established with each smart device and data statistics can be independently performed.
  • the statistics of the clients of each smart device may be inconsistent, which may cause confusion for the user's identification.
  • one of the objects of the present invention is to provide a data statistics method for a wearable smart device to be able to fuse physiological indicator data of the same statistical item from the plurality of smart devices with respect to the same user.
  • a data statistics method for a wearable smart device includes: receiving physiological indicator data about a certain statistical item of a user collected by at least one of the plurality of smart devices, and The time information corresponding to the physiological indicator data; calculating the fusion physiological indicator data of the statistical item about the user according to the priority of each of the smart device, the physiological indicator data, and the time information corresponding to the physiological indicator data.
  • a data statistics apparatus for a wearable smart device, comprising a processor and a machine readable storage medium on which a machine corresponding to data statistical control logic is stored Executable instructions.
  • the processor By reading and executing the machine executable instructions, the processor performs the following: receiving physiological indicator data about a certain statistical item of the user collected by at least one of the plurality of smart devices and the physiological indicator data Corresponding time information; calculating fusion physiological indicator data about the statistical item of the user according to priority of each smart device, physiological indicator data, and time information corresponding to the physiological indicator data.
  • the user can view the unified physiological indicator data that combines the data of different smart devices, thereby effectively improving the user experience of using the smart device. That is, a client can connect to the smart device at the same time, and select the device with the highest priority for data synchronization, which can avoid data inconsistency caused by simultaneously synchronizing data of multiple devices. Moreover, when the data in the device being synchronized is incomplete or zero, it is also possible to switch to the device with the second highest priority for data synchronization, thereby ensuring continuity of data synchronization.
  • FIG. 1 is a flowchart of a data statistics method according to an example of the present invention.
  • FIG. 2 is a flowchart of a data statistics method according to another example of the present invention.
  • FIG. 3 is a flowchart of a data synchronization method according to an example of the present invention.
  • FIG. 4 is a schematic structural diagram of hardware of a data statistics apparatus according to an example of the present invention.
  • FIG. 5 is a functional block diagram of data statistics control logic according to an example of the present invention.
  • FIG. 6 is a functional block diagram of a computing module in data statistics control logic according to an example of the present invention.
  • a data statistics method is provided. This method can be used in programs and terminal devices for collecting or statistical data. As shown in FIG. 1, the method may include the following steps S110-S140.
  • step S110 when the physiological indicator data of a certain statistical item of a certain user is collected by the plurality of smart devices, the physiological indicator data sent by the at least one of the plurality of smart devices is received and corresponding to the physiological indicator data. Time information.
  • the physiological indicator data may include one or more of a walking step, a moving distance, a heartbeat number, and an energy consumption value.
  • step S120 the priority of each smart device is acquired.
  • the corresponding priority may be determined according to the type of each smart device.
  • step S130 the fusion physiology of the plurality of smart devices with respect to the statistical item is calculated according to the priority of each smart device, the physiological indicator data, and the time information corresponding to the physiological indicator data. Indicator data.
  • step S140 the fusion physiological index data is displayed.
  • the physiological indicator data of a certain statistical item of a certain user when the physiological indicator data of a certain statistical item of a certain user is collected by the plurality of smart devices, the physiological indicator data of the plurality of smart devices regarding the statistical item may be merged.
  • the user can view the merged physiological indicator data.
  • users can view it in a piece of software (such as a mobile app) and display a single data result to optimize the user experience.
  • the fusion physiological index data of the two smart devices can be counted.
  • the application of the terminal can be opened and the physiological indicator data collected by the two smart devices can be synchronized to the terminal, so that the terminal can receive the same at the same time.
  • the physiological index data of the two smart devices are merged into the integrated physiological index data, so that the user can view the unified physiological indicator data that is combined with different smart devices, that is, the user experience is improved.
  • the physiological indicator data may be stored in an array of preset lengths, each smart device corresponding to an array, and one element in the array corresponds to a time granularity of obtaining physiological indicator data, for example, one minute.
  • the foregoing step S130 may be specifically: obtaining a fusion array corresponding to the fused physiological indicator data according to the priority of each smart device and the corresponding array.
  • physiological index data can be recorded in minutes as a time granularity.
  • Each smart device can also be assigned a preset length number in the corresponding terminal or application. Groups, such as the 1440 uint8_t type array.
  • the elements in the smart device array can be transmitted to the corresponding location in the terminal's smart device array through the connection.
  • the terminal can assign a copy of the smart device array to each device.
  • the above step S130 may include steps S210-S220.
  • step S210 according to the priority of each smart device and the time information corresponding to the physiological indicator data, a smart device that meets the time requirement and has the highest priority is selected as the target smart device.
  • step S220 the physiological indicator data of the target smart device is counted to obtain a statistical result, and the statistical result is used as the fusion physiological indicator data.
  • the target smart device that meets the time requirement and has the highest priority is selected.
  • the smart device may be a wearable device such as a smart bracelet, a smart watch, smart glasses, or a smart running shoe.
  • these smart devices can count physiological index data such as walking steps, moving distance, heartbeat number, energy consumption value generated by the user, and the processes of the respective statistical data are independent of each other.
  • the user can manually set the priority of each smart device according to the accuracy of the statistics of each smart device.
  • the priority of each smart device can be set directly by the client directly.
  • the default smart device priority can be smart running shoes>smart watch>smart bracelet>smart glasses.
  • the corresponding client is run, it is automatically monitored whether the physiological indicator data of a certain statistical item of the user is collected through multiple smart devices.
  • the physiological indicator data of a certain statistical item of the user is collected by using multiple smart devices, the priority and time information of each smart device can be determined, and the smart device with the highest priority meeting the time requirement is determined as the target smart device. .
  • real-time synchronization which synchronizes the data counted by the smart device to the client in real time. For example, if the user opens the mobile app, the total number of steps of the mobile app is updated and displayed in real time as the user walks.
  • non-real-time synchronization which synchronizes the data counted by the smart device to the client at a predetermined time. For example, a user who has been using smart devices for a while After opening the mobile app, the mobile app will sync the historical data of the smart device and display it on the history details page.
  • users can choose the appropriate data synchronization mode according to their own situation. Thereafter, the data of the determined target smart device is synchronized according to the selected data synchronization mode, and the synchronized data is displayed in real time.
  • the time-critical and second-priority smart device may be selected as the new target smart device, and the new target smart device is counted.
  • Physiological indicator data to obtain fusion physiological indicator data.
  • step S220 may specifically include steps S310-S380.
  • step S310 it is determined whether the current data synchronization mode is real-time synchronization or non-real-time synchronization. If the current data synchronization mode is real time synchronization, the process proceeds to step S320 described below. If the current data synchronization mode is non-real time synchronization, the process proceeds to step S380 described below.
  • step S320 it is determined whether or not the target smart device has switched. If the determination is yes, the process proceeds to step S330 described below, otherwise, the process proceeds to step S370.
  • step S330 if the target smart device is switched from the first smart device to the second smart device, the historical physiological indicator data recorded by the first smart device and the current physiological indicator data of the second smart device are acquired.
  • the fusion physiological indicator data can be calculated according to the historical physiological index data recorded by the smart bracelet and the current physiological index data of the smart running shoe.
  • the historical physiological indicator data of the first smart device and the current physiological indicator data of the second smart device may be discontinuous.
  • the time interval is less than a preset threshold, for example, 5 seconds
  • the time interval is negligible, and the disconnection may be considered to have little effect on the fusion physiological indicator data.
  • the time interval is greater than or equal to a preset threshold, for example, 5 seconds
  • the impact of the break on the fusion physiological index data may be large, and may be supplemented by using preset physiological indicators.
  • the data is compensated to compensate for the break, in order to ensure the accuracy of the data of the fusion physiological indicators.
  • step S340 it is determined whether the time interval between the time corresponding to the historical physiological indicator data of the first smart device and the current time is less than a preset threshold.
  • step S350 when the time interval is greater than or equal to the preset threshold, the historical physiological indicator data recorded by the first smart device, the current physiological indicator data of the second smart device, and the preset physiological indicator compensation data are accumulated to obtain a fusion.
  • Physiological indicator data when the time interval is greater than or equal to the preset threshold, the historical physiological indicator data recorded by the first smart device, the current physiological indicator data of the second smart device, and the preset physiological indicator compensation data are accumulated to obtain a fusion.
  • step S360 when the time interval is less than the preset threshold, the historical physiological indicator data recorded by the first smart device and the current physiological indicator data of the second smart device are accumulated to obtain the combined physiological indicator data.
  • step S370 the physiological indicator data of the target smart device is counted to obtain the fusion physiological indicator data.
  • step S380 the physiological index data recorded from the first time of the unsynchronized time recorded by the target smart device to the current time is sequentially written into the fusion physiological index data.
  • data synchronization may be performed from the current time to the first minute of the unsynchronized manner from the back to the front and from the near to the far.
  • the method defines the storage format for the number of steps.
  • Each smart device can have a separate array that stores the number of steps per minute during the day.
  • the fused counts can be stored in another separate array of length 1440.
  • Each smart device has a separate total number of steps for the device.
  • the mobile app can display the total number of merged steps after the total number of steps of the smart device has been merged so far.
  • the method can pre-specify the priority of the smart device (hereinafter also referred to as "device"). For example, when physiological indicator data of a plurality of smart devices are received at the same time, which physiological device data of the smart device will be preferentially synchronized to the client and displayed.
  • the step of smart shoes The function is more accurate than the step counter function of the smart bracelet. Therefore, when the step data of the smart bracelet and the smart shoe are simultaneously transmitted to the mobile phone, the mobile phone can preferentially synchronize and display the number of steps of the smart shoe.
  • each smart device there is a total step variable.
  • the smart device can broadcast its total step variable via Bluetooth for receiving and storing by the mobile phone.
  • This variable can be called the total number of steps of the device.
  • the total number of steps in running shoes can be called the total number of steps in running shoes.
  • a fusion total step variable can also be stored in the mobile phone for displaying a unique total number of steps on the mobile phone, which can be called the total number of steps of the fusion.
  • the value of the total number of steps of the device is equal to the value of the total number of steps of the fusion.
  • the user may also wish to know the details of the steps displayed by time. Therefore, it may be necessary to store the number of steps taken during this period of time at regular intervals.
  • the device Whenever a minute passes, the device writes the number of steps walked in this minute to the corresponding element in the device array.
  • a uint8_t type array of length 1440 can also be assigned to each device in the phone.
  • the smart device is connected to the mobile phone via Bluetooth or other means and data synchronization occurs, the element values in the device array that have not been synchronized can be passed to the corresponding elements in the device array of the mobile phone.
  • the phone can assign a copy of the device array to each device.
  • the resulting accumulated number can be used as the sum of the number of steps in the device array, or simply referred to as a device Array of accumulated values.
  • the total number of steps in the device may be equal to the accumulated value of the device array.
  • the total number of steps in the device may be slightly larger than the accumulated value of the device array. This is because when the minute is not over, the number of steps in this minute will be counted in the total number of steps in the device, but may not have to count the accumulated value of the device array.
  • a uint8_t type array of length 1440 can also be stored in the mobile phone, which is used to record the number of steps per minute of the fusion of multiple devices, which can be called an array of steps per minute of fusion, or can be simply referred to as a fusion array. .
  • the number of merge steps per minute can be written to the corresponding position of the fusion array for displaying the total number of steps and/or time-sharing motion details on the mobile phone app.
  • a uint8_t type array of length 1440 can also be stored, and each element of the array can be used to record the synchronization information corresponding to the minute.
  • the synchronization information may include a synchronization type, data integrity, device identification, and the like.
  • a Flag array can be configured for the client according to the acquired identifiers of the devices, the manner in which the client synchronizes the device data (real-time synchronization or non-real-time synchronization), and the integrity of the data recorded and stored at each time granularity. .
  • the device identifier can occupy 5 bits and is used to represent each device carried by the user.
  • device identification 0 may indicate no device
  • 1 may represent a smart bracelet
  • 2 may represent a smart running shoe
  • 3 may represent a smart watch, and the like.
  • the synchronization type can occupy 2 bits and is used to indicate how the client synchronizes device data. For example, sync type 0 may indicate unsynchronization, 1 may indicate non-real time synchronization, 2 may indicate real time synchronization, and 3 may indicate compensation synchronization.
  • Data integrity can be 1 bit and is used to indicate whether the data recorded and stored is complete. For example, Synchronization Integrity 0 may indicate that the data is incomplete and 1 may indicate that the data is complete.
  • This Flag array is that when the client is converging data or uploading the number of fusions An exception occurred during the group, and it is easy to reset the fused array according to the Flag array to ensure that the data is not lost.
  • the table shows the data storage form of the mobile phone client after the user who carries the smart bracelet and the smart running shoes completes the data synchronization at 9:31:15.
  • the first line represents the synchronization information Flag array, and each Flag array includes three elements;
  • the second line indicates the specific meaning of the value of the element "synchronization type" in the Flag array, where “non” means non-real time synchronization, “no” means not synchronized;
  • Line 3 represents the specific meaning of the value of the element "data integrity" in the Flag array, where "yes” indicates the number of complete one-minute steps, and “no” indicates that the number of steps is not a complete one-minute;
  • Line 4 represents the specific meaning of the value of the element "device identification" in the Flag array, where “ring” indicates that the target smart device for generating the fusion physiological indicator data for the minute is a smart bracelet, and “shoe” indicates that the Minutes of the target smart device that incorporates physiological indicator data are smart running shoes.
  • Table 2 shows the data storage form of the mobile client after the user who has the smart bracelet and the smart running shoes completes the data synchronization at 9:31:15.
  • the first row indicates the sequence element number corresponding to the minute, from 1-1440;
  • Line 2 indicates the start time of the minute
  • Line 3 represents events such as wearing shoes, taking off shoes, synchronizing, etc. that occur within the minute;
  • Line 4 represents the numerical value of the smart bracelet array
  • Line 5 represents the cumulative value of the smart bracelet array over time
  • Line 6 indicates the total number of steps in the smart bracelet at the instant of synchronization completion
  • Line 7 represents the numerical value of the smart running shoe array
  • Line 8 represents the cumulative value of the smart running shoe array over time
  • Line 9 indicates the total number of steps in the smart running shoes at the instant of synchronization completion
  • Line 10 represents the numerical value of the fused array after the fusion of the smart bracelet array and the smart running shoe array
  • Line 11 represents the change in the accumulated value of the fused array over time
  • Line 12 indicates the cumulative total number of steps at the instant of synchronization completion. Note that the cumulative total number of steps may be slightly more than the cumulative value of the fused array, because it contains the difference between the total number of steps in the smart bracelet and the accumulated value of the smart bracelet array.
  • the fusion array will select the step counter data of the synchronous smart running shoes within half an hour from 9:00-9:30, and select the step counting data of the synchronous smart bracelet at other times.
  • the total number of steps displayed is the total number of steps accumulated.
  • the device synchronizes data with the phone and maintains the connection.
  • Data synchronization can be divided into two ways, one is non-real-time synchronization, and the other is real-time synchronization.
  • Non-real-time synchronization is mainly used for users to view their own day's sports details after using the smart device for a period of time. As long as he opens the mobile app, the phone will automatically try to connect to the smart device, and the process can also be manually pulled down and refreshed. At this time, the device will transfer all the stored historical data (per minute data) to the mobile phone. The mobile phone needs to run for a long time to capture all the historical data in the device, and then process the motion details of the mobile phone. Go to the page.
  • Non-real-time synchronization transfers two types of data: one is an array of devices, and the other is the total number of steps in the device. After receiving multiple device arrays and total device steps, the phone will set the merged array according to the non-real-time synchronization policy to display the total number of steps. Table 3 shows the case where the mobile phone copies the data on the bracelet when non-real-time synchronization occurs at 9:31:15.
  • Real-time synchronization is mainly used after the user opens the app to connect the device and completes the non-real-time synchronization. If the user does not close the app and the total number of steps of the device continues to change, the device will broadcast the total number of steps of the device, after being received by the mobile phone. , can be displayed on the phone in real time. Real-time synchronization allows users to see in real-time how their total number of steps displayed on the phone changes as they walk, and can also be used to see if the pedometer function of the device is accurate.
  • Real-time synchronization transfers the total number of steps in the device. After receiving the total number of steps of the device for multiple devices, the phone sets the merged array according to the real-time synchronization policy to be able to display the total number of steps of the fusion.
  • the device can broadcast a connection packet every short period of time, for example, 2s, and the connection package only contains the MAC address of the device itself, and may not contain information such as the number of steps.
  • the device When the connection package is not received for a long time, the device can be considered to be disconnected from the mobile phone, and it may be necessary to decide whether to reconnect according to the situation.
  • these devices can copy a step counter array in the phone while syncing.
  • writing to a fused array it is possible to determine which device's data needs to be written first in the minute based on a pre-specified priority.
  • the smart bracelet and the smart watch are mainly used to calculate the number of steps by the shaking of the arm during the step counting, and there may be a phenomenon of miscalculation. Therefore, the highest priority when integrating step data is smart running shoes. Secondly, because smart watches can introduce more complex models in the counting algorithm, the counting steps are relatively more Accurate, the second highest priority in the integration of step data is the smart watch. In summary, the priority of the step counter device for data synchronization is as follows, smart bracelet ⁇ smart watch ⁇ smart running shoes.
  • Synchronization strategies can be divided into real-time synchronization and non-real-time synchronization. The two synchronization strategies are described separately below.
  • Non-real-time synchronization is a relatively simple synchronization strategy. Its purpose is to fuse the historical data in the device array into a fused array to show the motion details.
  • the basic strategy of synchronizing a single device with a mobile phone is described.
  • the flexible method when multiple devices are synchronized with the mobile phone is described. Two special cases are discussed.
  • the single device mentioned here does not mean that the user can only have one device, but that only one device has a non-real-time synchronization with the mobile phone within a certain period of time.
  • the following data can be used to synchronize the historical data in the device array of a single device into the fused array, assuming that the sequence number of the device is N.
  • the operation of modifying the variable during synchronization may include the following: for the fused array, directly copy the number of steps in the device array to the corresponding position of the fused array for the minute; for the Flag array, write "1-1-N", that is, Indicates that the minute is "non-real-time synchronization", "data is complete", and the synchronized device serial number is N; for the fused array accumulated value, the number of steps for the minute is accumulated.
  • Flag array element of the minute has already been written with a value, and the number of steps in the minute is not 0, and The "integrity" in the Flag is displayed as 1, indicating that the minute has full data, then skip the minute.
  • the replacement operation is directly performed, which may include: for the fused array, directly copy the number of steps in the device array to the fused array.
  • the corresponding position of the minute; for the Flag array, writing "1-1-N" means that the minute is "non-real-time synchronization", "data is complete", and the synchronized device serial number is N; for the fusion array Accumulate value, accumulate the number of steps in the minute.
  • the value of the Flag array element of the minute has been written and the value is equal to "2-0-M"
  • the device number of the last real-time synchronization is M. The reasons for such a Flag can be found in Section 5.2.
  • the operation of modifying the variable during synchronization may specifically include the following: for the fused array, the fused array element is replaced by the device array element; for the Flag array, the write is performed. Enter “3-1-N", which means that the minute is "non-real-time synchronization compensation real-time synchronization", "data is complete”, and the synchronized device serial number is N; for the fused array accumulated value, the device array element is accumulated Blends the difference between array elements. Other than this, no modifications can be made.
  • Non-real-time synchronization is usually done at some point in the middle of a minute. For example, synchronize data before 9:30:00 at 9:30:30. Thus, a portion of the steps may have been generated within 30 seconds of 9:30:00-9:30:30, but not written to the device array because the device array will only be written to the minute at the end of one minute. The number of steps. However, the number of steps generated in these 30 seconds must be reflected in the total number of steps of the fusion. Therefore, after all the data per minute has been synchronized, the total number of steps of the device needs to be received, and the total number of steps of the fusion is reset. E.g,
  • Total merging steps fused array accumulated value + total device steps - synchronized device array accumulated value.
  • this operation also has priority. If the high priority device fills in the total number of merged steps, the low priority device does not do this.
  • a common situation is: after the user uses the smart running shoes and the smart bracelet for a period of time, the mobile phone app is opened, and the motion data of the two devices is synchronized to the mobile terminal, so that the mobile terminal can Both device arrays are received at the same time.
  • the following principle can be used to convert the problem of simultaneous synchronization of multiple devices into a synchronous problem, and then synchronize using the synchronization principle of a single device.
  • the time in the phone may be inconsistent with the time in the device. For example, since the mobile phone and the device use different chips, their clock cycles may be different. After a long time, the time in the mobile phone and the time in the device may be in error, such as a few seconds or a few minutes. Therefore, the device array in the device and the device array in the mobile phone may be misaligned.
  • the smart running shoe For example, if the user takes off the smart running shoes at 9:31:05 seconds. In the first 5 seconds of 9:31 minutes, the running shoe produced 16 steps, and then in the remaining 55 seconds, the smart bracelet counted 100 steps.
  • the 16 steps of the running shoes will occupy the fusion array of the minute. Also, due to the first-come-first-served principle, the number of steps in the minute of the bracelet will not be replaced into the fused array, resulting in fewer steps in this minute.
  • the data of the client when performing non-real-time data synchronization may be as follows:
  • the operation content of the data synchronization can be specifically as follows:
  • the user walked for a while after putting on the running shoes.
  • the running shoes produced a small number of steps (30 steps), so when the mobile client was opened in the 542th minute, the running shoes were written in the fusion array. 30 steps, but can not be replaced by the 100-step data of the bracelet statistics at 541 minutes.
  • the mobile phone client After the synchronization is completed in the 542th minute, since the mobile phone client is still in the open state, the data of the running shoes and the number of steps of the bracelet are acquired by the mobile client, and the real-time synchronization mode is entered. Thereafter, the mobile phone writes the data of the running shoe in the fused array, and records the above Flag array as "real-time synchronization mode".
  • the mobile client was turned off at 9:12:30. In the 30 seconds before turning off, the running shoes count 50 steps, and within 30 seconds after turning off, the running shoes count 50 steps. At 9:12:30, when the mobile client is turned off, the real-time synchronization mode stops, and only 50 steps are synchronized in real time.
  • the value of the Flag array element is 2-0-2, indicating "real-time synchronization mode", "incomplete” "Data, synchronization equipment is "running shoes.”
  • the synchronization is 552-571 minutes, using the non-real time synchronization mode.
  • the value of the Flag array element is "2-0-2", and this incomplete minute data is compensated by accumulating the difference between the device array elements and the fused array elements.
  • the 20 steps will occupy the merged array first because of the higher priority, and will not be modified.
  • the synchronization time is 9:31:25
  • the first 25 seconds of the bracelet produces 50 steps, which are not written into the bracelet array, only reflected in the total number of bracelets. Therefore, it is also necessary to compensate the total number of steps of the fusion by using the method of integrating the accumulated value of the array + the total number of steps of the device - the accumulated value of the synchronized device array. At this time, the total number of steps of the fusion is modified to 5100 steps.
  • the above data synchronization method does not need to maintain the signal connection between the client and each device in real time, which can save power consumption, and can also effectively integrate the historical data in the device array into the fusion array.
  • the main purpose of the real-time synchronization strategy design is to enable the user to wear the smart device and display the merged data more accurately while walking in real time to view the changes in the number of steps on the mobile phone.
  • the main purpose of real-time synchronization strategy design is to be able to quickly respond to changes in the number of steps of a device and to be reflected in historical data by minute.
  • a user of a smart bracelet connects to the wristband, he looks at the number of steps brought by the smart bracelet while holding the mobile phone, and meditation on the actual walking steps to experience whether the smart stepping function of the smart bracelet is accurate. He walked 500 steps and took 3 minutes. After 3 minutes, he clicked into the sports details page and wanted to see the details of the steps in his three minutes per minute.
  • the number of steps per minute for the user in real-time synchronization needs to be recorded in a timely manner. That is to say, the fusion array needs to be able to perform data statistics in real time to display the motion details in real time.
  • a user of a smart bracelet bought a pair of new smart running shoes. When he connected the smart running shoes, he put down the bracelet and began to wear smart running shoes. He looked at the changes in the number of steps brought by the smart running shoes with his mobile phone to experience whether the new shoes were connected properly. After running the shoes for a while, he took off his running shoes, put on his bracelet and walked, and looked at the changes in the number of steps brought by the smart bracelet to see if the bracelet was still connected.
  • the switching of the device is involved twice: the first time is to display the number of steps of the wristband originally displayed on the mobile phone.
  • the display of the number of steps needs to be changed immediately with the number of steps of the running shoe. Accumulate.
  • the second time when he took off his running shoes, the display of the number of steps was immediately accumulated as the number of steps in the bracelet changed.
  • these two processes must be automatic and do not require the user to manually switch.
  • real-time synchronization may require the ability to directly manipulate the fused array elements and enable instant switching between multiple devices.
  • the single device mentioned here does not mean that the user only has one device, but that only one device synchronizes with the mobile phone in real time within a certain period of time.
  • Conditions for real-time synchronization between the device and the mobile phone after non-real-time synchronization, such as If the user does not close the app and the total number of steps of the device continues to change, the device will broadcast the total number of steps of the device, which can be displayed in real time after being received by the mobile phone.
  • the following data can be used to synchronize the historical data in the device array of a single device into the fused array, assuming that the sequence number of the device is N.
  • Principle B Perform non-real-time synchronization first.
  • the starting point the total number of steps of fusion - the cumulative value of the fusion array
  • the corresponding element will be modified as follows: For the fused array, the value of the fused array element value is added to the difference between the number of steps of the new broadcast packet and the previous broadcast packet step after writing the starting step number; Array, if the Flag array element is not equal to "2-0-N", then write "2-0-N", which means that the minute is "real-time synchronization", "non-complete", and the device serial number is N; For melting The total number of steps is equal to the sum of the fused array accumulated value and the value of the minute fused array element.
  • the device When the device is connected to the phone, the device continuously broadcasts the connection package to maintain a normal connection to the phone.
  • the connection package When the connection package is not received for a long time, it can be considered that the device has lost connection with the mobile phone, needs to be reconnected, and calls non-real time synchronization. Otherwise, the device and the phone are considered to be connected properly.
  • Principle B Use the adjacent connection package to confirm the end of one minute across the minute.
  • a very common situation is: after the user uses a smart running shoe and a smart bracelet for a period of time, open the mobile app, synchronize the motion data of the two devices to the mobile phone, and then start one side. Walk and observe the jump in the total number of steps on the mobile phone.
  • a basic principle is to select a device that wants to be displayed in real time according to the priority order and the first-come-first-served principle, and continuously update the total number of steps after the device is merged, while ignoring other devices. . When the device no longer updates the number of steps, another device is selected and its total number of steps is updated in real time.
  • a table can be saved that stores the most recent broadcast packet P(N, T, S) of each device received by the phone since the last non-real-time synchronization.
  • Each broadcast packet can contain three pieces of information: device number, timestamp, and total number of steps in the device. It also saves the last broadcast packet for the last selected device.
  • the priority of the device may specifically be: smart bracelet 1 ⁇ smart watch 3 ⁇ smart running shoes 2.
  • the table 7 is initialized after the non-real-time synchronization, the timestamp is the timestamp at the end of the non-real-time synchronization, and the total number of steps is the total number of steps of each device, and the currently selected broadcast packet is empty.
  • the difference of the total number of steps of the broadcast packet device is accumulated by using principle B2, and the time stamp and the total number of devices in the currently selected broadcast packet are updated.
  • the currently selected device is immediately switched to the newly received broadcast packet. And if the difference between the new broadcast packet timestamp and the current selected timestamp is greater than or equal to a certain threshold, the difference of the total number of steps of the broadcast packet device is accumulated, otherwise it is not accumulated, and only the switching is performed. Of course, while the device is switched, the currently selected broadcast packet can be replaced.
  • the inter-threshold is set to 4 seconds (s).
  • the currently selected broadcast packet can be replaced with Ps2, and the selected device can be switched, and the corresponding element can be modified as follows: Because 17:50:34-17:50:33 ⁇ 4, no modification is made; for Flag array, modify Flag to "2-0-2", which means that the minute is "real-time synchronization" and the data is "non- Complete", and the device serial number is 2; for the total number of steps of fusion, since 17:50:34-17:50:33 ⁇ 4, no modification is made.
  • the currently selected device is switched to be newly received.
  • the device in the broadcast packet and accumulates the difference in the total number of steps of the device, and replaces the currently selected broadcast packet. Otherwise no changes will be made.
  • the time threshold is set to 4s.
  • the device when a broadcast packet of a higher priority device is received, the device can be immediately switched to the device. However, the total number of steps of the fusion needs to see whether the broadcast packet time exceeds the threshold. If it exceeds, the difference is accumulated. Otherwise, the difference is not Accumulate. The purpose of this is to prevent two devices from generating data at the same time. In fact, they represent the walking state of the same time period. If they are directly accumulated, the number of steps will be too large. Only when the threshold is exceeded, it means that only one device is in the step and another device is in the rest. In this case, it is safe to perform the accumulation, and it will not cause a large number of steps, although there may still be a problem that the number of steps is small.
  • Table 8 shows that within one minute, after the user performs the non-real-time synchronization of the smart bracelet and the smart shoes, the user walks a long way with his hand, and then puts on the shoes to start walking, then takes off the bracelet and walks with the running shoes. road. If the time interval between the first broadcast packet after the running shoe generates the number of steps and the last broadcast packet of the wristband is too short, the number of steps may be too small.
  • Line 1 represents time in seconds.
  • Line 2 indicates the event: the user performed a non-real-time synchronization in the 5th second; the 7th second began to walk with the bracelet; the 12th, 14th, 16th, and 17th seconds received the 4 broadcast packets of the bracelet; the 18th second took off the hand Ring; walked in shoes in the 14th second; received 4 broadcast packages of running shoes in the 20th, 21st, 24th and 26th seconds.
  • Lines 3 and 4 represent the number of steps and time of the bracelet broadcast.
  • Lines 5 and 6 indicate the number of steps and time for running shoes.
  • Line 7 indicates the selected broadcast device after the mobile phone receives the broadcast of the two devices.
  • Line 8 represents the total number of steps that the mobile phone calculates based on the selected broadcast device after real-time synchronization.
  • the two devices will not send the first broadcast packet after 10 steps, which may be due to the internal logic of the pedometer.
  • the pedometer may require that only the number of steps accumulate to a certain extent to be considered a valid number of steps, otherwise the number of steps that are considered invalid will be restarted. In this example, it takes 10 steps to start broadcasting the broadcast packet. After that, as long as the number of steps changes, the broadcast packet is sent.
  • Table 9 shows a situation similar to that of Table 8, with a slight difference in that the time to broadcast the first broadcast packet after running the shoe is 22 seconds.
  • the data statistics may be specifically as follows:
  • the user has been wearing the smart bracelet, wearing smart running shoes during the period, and taking off the running shoes for a while.
  • the device selected in real time is a wristband, which is switched to running shoes after putting on running shoes, and then switched to the bracelet after the running shoes are taken off.
  • the non-real-time synchronization was performed in the 50th second; after that, the number of steps of the wristband was synchronized 9 times, respectively (54 seconds, 110 steps), (56 seconds, 115 steps), (58 Seconds, 120 steps), (0 seconds, 125 steps), (2 seconds, 130 steps), (5 seconds, 135 steps), (7 seconds, 140 steps), (8 seconds, 145 steps), (11 seconds, 150 steps); the number of steps for running shoes has been synchronized 4 times, respectively (57 seconds, 10 steps), (59 seconds, 16 steps), (1 second, 22 steps), (3 seconds, 28 steps) .
  • the specific data synchronization operation may include the following:
  • Non-real-time synchronization is performed in the 50th second, but it is not known at this time whether the user will walk, so the fusion array element and the Flag array element may not be modified.
  • the number of steps of the bracelet changes, and it is considered that the real-time synchronization mode is entered.
  • the difference between the number of steps in the first synchronization of the new minute and the number of steps in the previous synchronization can be added to the cumulative total step.
  • the number, and the difference between the accumulated total steps and the fused array accumulated value is recorded in the fused array element corresponding to the minute.
  • the Flag array element can be modified to be "2-0-1" to indicate that the minute enters "real-time synchronization mode", the data is "incomplete", and the device that was last selected is "Bracelet".
  • the number of steps in the running shoes changes. Since the priority of the running shoes is higher than the bracelet, the synchronized equipment can be switched to the running shoes immediately. Since the interval duration (3s) of this data synchronization and the last data synchronization is less than the preset threshold (4s), it is not necessary to write the compensation data. However, the Flag array element needs to be modified to be "2-0-2" to indicate that the minute enters "real-time synchronization mode", the data is "incomplete", and the device that was last selected is "running shoes".
  • the Flag array element can be changed to "2-1-2" to indicate that the minute enters "real-time synchronization mode", the data is "complete”, and the most recently selected device is "running shoes” .
  • the number of steps in the running shoe statistics is synchronized, and the Flag array element is modified to be "2-0-2" to indicate that the minute enters "real-time synchronization mode", the data is "incomplete”, and the device selected last time is " running shoes”.
  • the signal connection is established with the wristband, and the number of steps of the synchronization of the wristband is started. Since the duration of the disconnection of the signal connection with the running shoe reaches the preset threshold of 4 seconds, the wristband statistics are required. The difference between the number of steps (140 steps) and the number of steps (135 steps) of the previous bracelet statistics (5 steps) is added to the fused array, and the Flag array element is modified to be "2-0-1" to indicate the Minutes enter "real-time sync mode", data is "incomplete", and the most recently selected device is "bangle".
  • the client provides real-time data synchronization and non-real-time data synchronization two data synchronization methods for users to select according to their own needs, thereby improving the use effect.
  • the present disclosure simultaneously provides a data statistics device for a wearable smart device.
  • the apparatus 400 can include a processor 410 and a machine readable storage medium 420, wherein the processor 410 and the machine readable storage medium 420 are typically interconnected by an internal bus 430.
  • the apparatus 400 may also include an outer
  • the network interface 440 is capable of communicating with other devices or components.
  • the machine readable storage medium 420 can be: ROM (Read-Only Memory), volatile memory, non-volatile memory, flash memory, storage drive (eg, hard drive), solid state Hard disk, any type of storage disk (such as a compact disc, DVD, etc.), or similar storage medium, or a combination thereof.
  • ROM Read-Only Memory
  • volatile memory non-volatile memory
  • flash memory storage drive (eg, hard drive), solid state Hard disk, any type of storage disk (such as a compact disc, DVD, etc.), or similar storage medium, or a combination thereof.
  • storage drive eg, hard drive
  • solid state Hard disk any type of storage disk (such as a compact disc, DVD, etc.), or similar storage medium, or a combination thereof.
  • machine-readable storage medium 420 stores machine-executable instructions corresponding to control logic 500 for controlling statistics of the wearable smart device.
  • the control logic 500 can include:
  • the receiving module 510 is configured to receive physiological indicator data and physiological indicator data sent by at least one of the plurality of smart devices when collecting physiological indicator data of a certain statistical item of a certain user by using multiple smart devices Corresponding time information;
  • An obtaining module 520 configured to acquire a priority of each smart device
  • the calculating module 530 is configured to calculate, according to the priority of each smart device, the physiological indicator data, and the time information corresponding to the physiological indicator data, the fusion physiological indicator data of the plurality of smart devices about the statistical item;
  • the display module 540 is configured to display the fusion physiological indicator data.
  • the physiological indicator data may include one or more of a walking step number, a moving distance, a heartbeat number, and an energy consumption value.
  • the physiological indicator data can be stored in an array of preset lengths.
  • Each smart device corresponds to an array, and the physiological indicator data collected by each device in a time granularity is an element in the array.
  • the calculation module 530 is configured to: obtain corresponding fusion physiological indicator data in the fusion array according to a priority of each of the smart devices and a corresponding device array.
  • the calculating module 530 may specifically include:
  • the selecting sub-module 531 is configured to select, according to the priority of each smart device and the time information corresponding to the physiological indicator data, the smart device that meets the time requirement and has the highest priority as the target smart device;
  • the statistic sub-module 532 is configured to collect physiological indicator data of the target smart device to obtain a statistical result, and use the statistical result as the fusion physiological indicator data.
  • the statistic sub-module 532 is further configured to: when the physiological indicator data of the target smart device is incomplete or zero, select a smart device that meets the time requirement and has the second highest priority as the new device.
  • the target smart device replaces the physiological indicator data of the last target smart device with the physiological indicator data of the new target smart device.
  • the statistic sub-module 532 is further configured to: determine whether the data synchronization mode in which the plurality of smart devices are currently located is real-time synchronization or non-real-time synchronization; in a case where the data synchronization mode is non-real-time synchronization And performing statistics on the physiological indicator data of the target smart device from the first time of the unsynchronized to the current time to obtain corresponding fusion physiological indicator data; in the case that the data synchronization mode is real-time synchronization, The current physiological indicator data of the target smart device is statistically obtained to obtain corresponding fusion physiological indicator data.
  • the statistic sub-module 532 is further configured to: if detecting that the target smart device is switched from the first smart device to the second smart device, acquiring historical physiological indicator data and a location of the first smart device The current physiological indicator data of the second smart device; the fusion physiological indicator data is calculated according to the historical physiological indicator data of the first smart device and the current physiological indicator data of the second smart device.
  • the statistic sub-module 532 is further configured to: calculate a time interval between a historical time corresponding to the historical physiological indicator data of the first smart device and a current time; and the time interval is greater than or equal to the pre-
  • the fusion physiological indicator data is obtained by accumulating historical physiological indicator data of the first smart device, current physiological indicator data of the second smart device, and preset physiological indicator compensation data.
  • the fusion physiological indicator data is obtained by accumulating the historical physiological indicator data of the first target smart device and the current physiological indicator data of the second target smart device.
  • embodiments of the present invention can be provided as a method, system, or computer program product. Accordingly, the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment, or a combination of software and hardware. Moreover, the invention can take the form of a computer program product embodied on a computer usable storage medium (including but not limited to disk storage and optical storage, etc.) in which computer usable program code is embodied.
  • a computer usable storage medium including but not limited to disk storage and optical storage, etc.
  • the computer program instructions can also be stored in a computer readable memory that can direct a computer or other programmable data processing device to operate in a particular manner, such that the instructions stored in the computer readable memory produce an article of manufacture comprising the instruction device.
  • the apparatus implements the functions specified in one or more blocks of a flow or a flow and/or block diagram of the flowchart.
  • These computer program instructions can also be loaded onto a computer or other programmable data processing device such that a series of operational steps are performed on a computer or other programmable device to produce computer-implemented processing for execution on a computer or other programmable device.
  • the instructions provide steps for implementing the functions specified in one or more of the flow or in a block or blocks of a flow diagram.
  • the device embodiment since it basically corresponds to the method embodiment, reference may be made to the partial description of the method embodiment.
  • the device embodiments described above are merely illustrative, wherein the units described as separate components may or may not be physically separate, and the components displayed as units may or may not be physical units, ie may be located A place, or it can be distributed to multiple network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the embodiment. Those of ordinary skill in the art can understand and implement without any creative effort.

Abstract

一种可穿戴智能设备的数据统计方法及装置。当可通过多个智能设备采集用户的某一统计项目的生理指标数据时,接收多个智能设备中的部分或全部发送的生理指标数据和与其对应的时间信息(S110);根据每个智能设备的优先级、生理指标数据和与生理指标数据对应的时间信息,计算关于所述用户的所述统计项目的融合生理指标数据(S130)。

Description

可穿戴智能设备的数据统计 技术领域
本发明涉及可穿戴智能设备的数据统计。
背景技术
可穿戴智能设备的信息集成化程度高且方便携带,被越来越多的消费者所青睐。例如,用户可以利用它们监测自身的各项生理参数,包括步行步数、心跳次数、移动距离等。目前,利用可穿戴智能设备监测人体生理参数的过程中,一个客户端通常只能连接一部智能设备。在这种情况下,若用户随身携带多部智能设备,则需要同时拥有多个客户端,以能够分别与各智能设备建立数据连接并独立进行数据统计。然而,各智能设备的客户端统计的数据可能不一致,这样就可能给用户的辨别造成了困扰。
发明内容
有鉴于此,本发明的目的之一是提供一种可穿戴智能设备的数据统计方法,以能够将来自多个智能设备的关于同一用户的同一统计项目的生理指标数据进行融合。
根据本申请的一个方面,提供了一种可穿戴智能设备的数据统计方法,包括:接收多个智能设备中的至少一个智能设备采集的关于用户的某一统计项目的生理指标数据和与所述生理指标数据对应的时间信息;根据每个所述智能设备的优先级、生理指标数据和与生理指标数据对应的时间信息,计算关于所述用户的所述统计项目的融合生理指标数据。
根据本申请的另一个方面,提供了一种可穿戴智能设备的数据统计装置,其包括处理器和机器可读存储介质,所述机器可读存储介质上存储有与数据统计控制逻辑对应的机器可执行指令。通过读取和执行所述机器可执行指令,所述处理器执行以下:接收多个智能设备中的至少一个智能设备采集的关于用户的某一统计项目的生理指标数据和与所述生理指标数据对应的时间信息;根据每个所述智能设备的优先级、生理指标数据和与生理指标数据对应的时间信息,计算关于所述用户的所述统计项目的融合生理指标数据。
通过本发明的技术方案,使得用户可以查看到融合了不同智能设备数据的统一的生理指标数据,从而可有效提升用户对智能设备的使用体验。即实现了一个客户端可以同时连接智能设备,并选择其中优先级最高的设备进行数据同步,可避免同时同步多个设备的数据导致的数据不统一。并且,当正在进行同步的设备中的数据不完整或为零时,还可以切换到优先级次高的设备进行数据同步,从而可确保数据同步的连续性。
本发明的其它特征和优点将在随后的说明书中阐述,并且,部分地从说明书中变得显而易见,或者通过实施本发明而了解。本发明的目的和其他优点可通过在所写的说明书、权利要求书、以及附图中所特别指出的结构来实现和获得。
下面通过附图和实施例,对本发明的技术方案做进一步的详细描述。
附图说明
为了更清楚地说明本申请实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动性的前提下,还可以根据这些附图获得其他的附图。
图1为本发明根据一示例的数据统计方法的流程图;
图2为本发明根据另一示例的数据统计方法的流程图;
图3为本发明根据一示例的数据同步方法的流程图;
图4为本发明根据一示例的数据统计装置的硬件结构示意图;
图5为本发明根据一示例的数据统计控制逻辑的功能模块框图;
图6为本发明根据一示例的数据统计控制逻辑中的计算模块的功能模块框图。
具体实施方式
下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述。显然,所描述的实施例仅仅是本申请一部分实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本申请保护的范围。
根据本发明实施例的第一方面,提供一种数据统计方法。该方法可用于采集或统计数据的程序及终端设备中。如图1所示,该方法可包括如下步骤S110-S140。
在步骤S110中,当通过多个智能设备采集某一用户的某一统计项目的生理指标数据时,接收所述多个智能设备中的至少一个智能设备发送的生理指标数据和与生理指标数据对应的时间信息。
在一个实施例中,生理指标数据可包括步行步数、移动距离、心跳次数和能量消耗值中的一项或多项。
在步骤S120中,获取每个智能设备的优先级。
在一个示例中,可根据每个智能设备的类型确定对应的优先级。
在步骤S130中,根据每个智能设备的优先级、生理指标数据和与生理指标数据对应的时间信息,计算多个智能设备的关于该统计项目的融合生理 指标数据。
在步骤S140中,显示融合生理指标数据。
在该实施例中,当通过多个智能设备采集某一用户的某一统计项目的生理指标数据时,可将多个智能设备的关于该统计项目的生理指标数据进行融合。这样,用户可以查看到融合后的生理指标数据。例如,用户可以在一个软件(如手机app)里面进行查看,并显示一个单一的数据结果,从而可以优化用户体验。
当用户拥有多个可穿戴式智能设备时,例如用户使用了一段时间的智能跑鞋,又使用了一段时间的智能手环。通常,用户只能分别查看两个智能设备对应的生理指标数据。而通过本发明的技术方案,可以统计两个智能设备的融合生理指标数据。这样,如果用户想在例如智能手机等的终端上查看融合生理指标数据,则可打开终端的应用并同时同步这两个智能设备采集的生理指标数据至该终端,以使得该终端可以同时收到两个智能设备的生理指标数据并融合成融合生理指标数据,从而使得用户可以查看到融合了不同智能设备的统一的生理指标数据,也即提升了用户的使用体验。
在一个实施例中,生理指标数据可储存于预设长度的数组中,每个智能设备对应一个数组,数组中的一个元素对应获取生理指标数据的一个时间粒度、例如一分钟。在这种情况下,上述步骤S130可具体为:根据每个智能设备的优先级和对应的数组,得到融合生理指标数据对应的融合数组。
在该实施例中,可以以分钟为时间粒度记录生理指标数据。每一个智能设备可以为自身分配一个预设长度的数组,如长度为1440的uint8_t类型的数组(1440=24*60),可记录当天每分钟内该智能设备所记录的生理指标数据。这个数组可被称为智能设备数组。每过一分钟,智能设备就会将这一分钟内所采集的生理指标数据写入智能设备数组对应的元素中。
在对应的终端或应用程序里也可为每一个智能设备分配预设长度的数 组,例如1440的uint8_t类型数组。当智能设备与终端通过有线或无线连接时,智能设备数组中的元素可通过该连接传递至终端的智能设备数组中对应的位置。简而言之,终端可为每一个设备分配一个智能设备数组的拷贝。
如图2所示,在一个实施例中,上述步骤S130可包括步骤S210-S220。
在步骤S210中,根据每个智能设备的优先级和与生理指标数据对应的时间信息,选取出符合时间要求的且优先级最高的智能设备作为目标智能设备。
在步骤S220中,统计目标智能设备的生理指标数据以得到统计结果,将统计结果作为融合生理指标数据。
在该实施例中,根据智能设备的优先级和生理指标数据的时间信息,选取出符合时间要求的且优先级最高的目标智能设备。其中,智能设备可以是智能手环、智能手表、智能眼镜、智能跑鞋等可穿戴式设备。一般来说,这些智能设备可以统计用户产生的步行步数、移动距离、心跳次数、能量消耗值等生理指标数据,并且各自统计数据的过程是相互独立的。这样,用户可以根据各智能设备所统计数据的准确性,手动对各智能设备进行优先级设置。当然,也可直接由客户端对各智能设备的优先级进行默认设置,例如默认设置的智能设备优先级可为智能跑鞋>智能手表>智能手环>智能眼镜。此后,当运行相应的客户端时,可自动监测是否通过多个智能设备采集用户的某一统计项目的生理指标数据。当监测到通过多个智能设备采集用户的某一统计项目的生理指标数据时,可判断各个智能设备的优先级和时间信息,并确定出符合时间要求的优先级最高的智能设备作为目标智能设备。
此处,有两种数据同步模式可供选择。一种是实时同步,即将智能设备统计的数据实时同步到客户端。例如,用户打开手机app,手机app的总步数随着用户的走路实时更新并显示。另一种是非实时同步,即按预定时间将智能设备统计的数据同步到客户端。例如,用户在使用了一段时间的智能设 备之后打开手机app,手机app将同步智能设备的历史数据并展示在历史详情页面里。一般来说,用户可以根据自身的情况选择适宜的数据同步模式。之后,可根据所选择的数据同步模式对上述确定出的目标智能设备所统计的数据进行同步,并实时显示已同步的数据。
在一个实施例中,在目标智能设备的生理指标数据不完整或为零时,可选取出符合时间要求的且优先级次高的智能设备作为新的目标智能设备,并统计新的目标智能设备的生理指标数据以得到融合生理指标数据。
如图3所示,上述步骤S220可具体包括步骤S310-S380。
在步骤S310中,判断当前的数据同步模式是实时同步还是非实时同步。如果当前的数据同步模式是实时同步,则进入下述步骤S320。如果当前的数据同步模式是非实时同步,则进入下述步骤S380。
在步骤S320中,判断目标智能设备是否发生了切换,并在判断为是的情况下进入下述步骤S330,否则进入步骤S370。
在步骤S330,若目标智能设备由第一智能设备切换至第二智能设备,获取第一智能设备记录的历史生理指标数据和第二智能设备的当前生理指标数据。
例如,在实时同步模式下,若检测到目标智能设备由智能手环切换成智能跑鞋,则可根据智能手环记录的历史生理指标数据和智能跑鞋的当前生理指标数据计算融合生理指标数据。
然而,在第一智能设备的历史生理指标数据对应的历史时刻与当前时刻之间存在时间间隔的情况下,第一智能设备的历史生理指标数据和第二智能设备的当前生理指标数据可能不连续。若该时间间隔小于预设阈值、例如5秒时,该时间间隔可忽略不计,则可认为该断档(disconnect)对融合生理指标数据的影响不大。然而,若该时间间隔大于或等于预设阈值、例如5秒,则该断档对融合生理指标数据的影响可能较大,并可使用预设的生理指标补 偿数据来补偿该断档,以尽量确保融合生理指标数据的准确性。
在步骤S340中,判断第一智能设备的历史生理指标数据对应的时刻与当前时刻之间的时间间隔是否小于预设阈值。
在步骤S350中,在该时间间隔大于或等于预设阈值时,将第一智能设备记录的历史生理指标数据、第二智能设备的当前生理指标数据和预设生理指标补偿数据进行累加,得到融合生理指标数据。
在步骤S360中,在该时间间隔小于预设阈值时,将第一智能设备记录的历史生理指标数据和第二智能设备的当前生理指标数据进行累加,得到融合生理指标数据。
在步骤S370中,对目标智能设备的生理指标数据进行统计以得到融合生理指标数据。
在步骤S380中,将目标智能设备记录的从未同步的第一时刻起至当前时刻的生理指标数据依次写入融合生理指标数据。
例如,可以按照从后至前、由近至远的方式,从当前时刻开始往前进行数据同步,直至未同步的第一分钟。
下文以计步数为例,阐述数据融合的具体定义与策略。这些定义与策略也同样适用于其他类型的生理指标数据的融合。
首先,该方法定义了计步数的存储格式。每种智能设备可拥有一个独立的数组,用以存储一天里每分钟的计步数。这个数组的长度可为1440(1440=24*60)。融合后的计步数可被存储在另外一个独立的长度为1440的数组里。每个智能设备拥有单独的设备总步数。手机app上可显示到目前为止融合了多个智能设备的总步数之后的融合总步数。
其次,该方法可预先指定智能设备(以下还可简称为“设备”)的优先级。例如,当同时收到多个智能设备的生理指标数据时,哪个智能设备的生理指标数据将优先被同步到客户端并进行显示。一般来说,智能鞋的计步 功能比智能手环的计步功能要准确。因此,当智能手环和智能鞋的计步数据同时传输给手机时,手机可优先同步和显示智能鞋的计步数。
1、多设备的数据存储格式
1)总步数变量的定义
在每个智能设备中,有一个总步数变量,当总步数发生变化时,智能设备可通过蓝牙广播它的总步数变量供手机接收和存储。可称该变量为设备总步数,如跑鞋的总步数可被称之为跑鞋总步数等。
在手机中还可存储一个融合总步数变量,用于在手机上显示唯一的总步数,可称该变量为融合总步数。当用户只携带有一个智能设备的时候,设备总步数的值就等于融合总步数的值。
2)设备每分钟步数数组的定义
在通常的情况下,用户可能还希望知道按照时间显示的步数详情。所以,可能还需要每隔一段时间存储这段时间之内步行的计步数。
例如,可以分钟为粒度记录历史数据。在智能设备里为自身分配了一个长度为1440的uint8_t类型的数组(1440=24*60),以能够记录当天每分钟内该智能设备所记录的计步数。这个数组可被称为设备每分钟步数数组,或者可简称为设备数组。
每当过一分钟,设备就会将这一分钟内所步行的步数写入设备数组对应的元素中。在手机里也可为每一个设备分配长度为1440的uint8_t类型数组。当智能设备与手机通过蓝牙或其他方式连接并发生数据同步时,设备数组中还未同步的元素值可传递至手机的设备数组中对应的元素。简而言之,手机可为每一个设备分配一个设备数组的拷贝。
从设备数组的对应第一分钟的元素的值开始累加,直到对应最接近当前时刻的一分钟的元素的值,所得到的累加数可作为设备数组中的步数的总和,还可简称为设备数组累加值。
在每分钟的步数写入设备数组中对应元素后的一瞬间,设备总步数才可能等于设备数组累加值。而在其它时间,设备总步数有可能略大于设备数组累加值。这是因为在一分钟还没有结束的时候,这一分钟之内的步数会被计入设备总步数,但可能还没有来得及计入设备数组累加值。
3)融合每分钟步数数组的定义
与此同时,在手机中也可存储一个长度为1440的uint8_t类型数组,用于记录多个设备的融合后每分钟步数,可被称为融合每分钟步数数组,或可简称为融合数组。在手机获取了多个设备数组之后,可将每分钟的融合步数写入融合数组对应的位置,用于在手机app上展示总步数和/或分时间显示运动详情。
4)同步信息Flag数组的定义
在手机端还可存储一个长度也是1440的uint8_t类型数组,该数组的每个元素可用于记录该分钟对应的同步信息。所述同步信息可包括同步类型、数据完整性、设备标识等。此处,可以根据获取的各设备的标识、客户端同步各设备数据的方式(实时同步或非实时同步)以及每个时间粒度所记录并储存的数据的完整性,为客户端配置一个Flag数组。
其中,设备标识可占5bit,用于表示用户所携带的各设备。例如,设备标识0可表示无设备,1可表示智能手环,2可表示智能跑鞋,3可表示智能手表,等等。
同步类型可占2bit,用于表示客户端同步设备数据的方式。例如,同步类型0可表示未同步,1可表示非实时同步,2可表示实时同步,3可表示补偿同步。
数据完整性可占1bit,用于表示所记录并存储的数据是否完整。例如,同步完整性0可表示数据不完整,1可表示数据完整。
配置这个Flag数组的好处在于,当客户端在融合数据或者上传融合数 组时发生了异常,可以很容易地根据Flag数组重新设置融合数组,以保证数据不丢失。
例如,如下方表1所示,该表显示了携带有智能手环和智能跑鞋的用户在9:31:15完成数据同步之后,手机客户端的数据存储形式。
表1
Flag数组 1-1-1 1-1-1 …… 1-1-1 1-1-2 1-1-2 …… 1-1-2 1-0-1 …… 0-0-0
同步类型 …… …… ……
数据完整性 …… ……  
设备标识 …… …… ……
第1行表示同步信息Flag数组,每个Flag数组包括三个元素;
第2行表示Flag数组中元素“同步类型”的值的具体含义,其中“非”表示非实时同步,“未”表示未同步;
第3行表示Flag数组中元素“数据完整性”的数值的具体含义,其中“是”表示是完整的一分钟的步数,“否”表示不是完整的一分钟的步数;
第4行表示Flag数组中元素“设备标识”的数值的具体含义,其中“环”表示用于生成该分钟的融合生理指标数据的目标智能设备是智能手环,“鞋”表示用于生成该分钟的融合生理指标数据的目标智能设备是智能跑鞋。
在一个实施例中,如下方表2所示,预设客户端和各设备的数据粒度可均为1分钟(min),且可为客户端和各设备均配置一个长度为1440(24h*60min=1440)的uint8_t类型数组,以能够记录用户当天每分钟内各设备记录的步行步数。
表2显示了一个携带有智能手环和智能跑鞋的用户在9:31:15完成数据同步之后,手机客户端的数据存储形式。
表2
Figure PCTCN2016088092-appb-000001
参照表2,第1行表示该分钟对应的数组元素序号,从1-1440;
第2行表示该分钟的起始时间;
第3行表示在该分钟之内发生的例如穿鞋、脱鞋、同步等的事件;
第4行表示智能手环数组的数值情况;
第5行表示智能手环数组累加值随时间的变化;
第6行表示在同步完成一瞬间的智能手环总步数;
第7行表示智能跑鞋数组的数值情况;
第8行表示智能跑鞋数组累加值随时间的变化;
第9行表示在同步完成一瞬间的智能跑鞋总步数;
第10行表示智能手环数组和智能跑鞋数组融合之后的融合数组的数值情况;
第11行表示融合数组累加值随时间的变化;
第12行表示在同步完成一瞬间的累计总步数,注意累计总步数有可能稍多于融合数组累加值,因为包含了智能手环总步数与智能手环数组累加值的差值。
即在9:00-9:30这半小时内,用户穿上了智能跑鞋跑步(即手机客户端与智能跑鞋建立信号连接),其他时间用户均没有穿着跑鞋(即手机客户端与 智能跑鞋建立的信号连接断开),所以只有在这半个小时之内智能跑鞋数组的计步数据不为0,其他时间的计步数据均为0。根据预设的各设备同步的优先级,融合数组会在9:00-9:30这半小时内选择同步智能跑鞋的计步数据,其他时间选择同步智能手环的计步数据。显示的总步数为累计总步数。
2、设备与手机同步数据和保持连接的方式
目前智能设备大都通过蓝牙与手机通信,进行数据同步的操作。数据同步可分为两种方式,一种是非实时性的同步,另外一种是实时性的同步。
2.1 非实时性同步
非实时性同步主要用于用户在使用了一段时间的智能设备之后,希望查看自己一天的运动详情。他只要打开手机app,手机会自动地尝试与智能设备相连,这个过程也可以手动下拉刷新。在这个时候,设备会传输存储的所有历史数据(每分钟数据)到手机端,手机端需要运行一段较长的时间才能抓取到设备中所有的历史数据,再经过处理展示到手机的运动详情页面中去。
非实时性同步会传输两种数据:一种是设备数组,另外一种是设备总步数。在收到多个设备数组和设备总步数之后,手机会按照非实时性同步策略设置融合数组,显示融合总步数。如表3示出了在9:31:15发生非实时性同步时,手机拷贝手环上的数据的情况。
表3
序号 1 2 …… …… 571 572 573 …… 1440
时间     …… …… 9:30 9:31 9:32 …… 23:59
事件           同步      
手环上的手环数组 20 30 …… …… 98 0 0 …… 0
手环上的手环数组累加值 20 50 …… …… 5098        
手环上的手环总步数           6000      
复制和计算          
手机上的手环数组 20 30 …… …… 98 0 0 …… 0
手机上的手环数组累加值 20 50 …… …… 5098     ……  
手机上的手环总步数           6000      
2.2 实时性同步
实时性同步主要用于在用户打开app连接设备并完成非实时性的同步之后,如果用户没有关闭app,且设备总步数继续发生变化,设备会广播自己的设备总步数,被手机接收之后,可实时地展示在手机上。实时同步使得用户可以随着自己的走路实时地看到手机上显示的总步数在变化,还可以用于查看设备的计步器功能是否准确。
实时性同步会传输设备总步数。在收到多个设备的设备总步数之后,手机会按照实时性同步策略设置融合数组以能够显示融合总步数。
值得注意的是,实时性同步必须在进行了一次非实时性同步之后才能进行。
2.3 保持连接的方式
设备为了保持与手机的实时连接,可每隔一段很短的时间、例如2s广播一个连接包,该连接包中仅仅包含设备自身的MAC地址,而可以不含有步数等信息。
当长时间没有收到连接包时,可以认为设备与手机断开了连接,并可能需要视情况决定是否重连。
3、多设备同步的优先级
当用户拥有多个设备时,这些设备在同步的时候均能在手机中复制一个计步数组。当写入融合数组的时候,可根据预先指定的优先级来确定在该分钟哪个设备的数据需优先写入。
智能跑鞋只有触地的时候才会对跑步数进行累加,计步准确性有保障。而智能手环和智能手表在计步时主要是通过手臂的晃动来计算步数,可能会有误计步的现象发生。所以,融合计步数据时优先级最高的是智能跑鞋。其次,由于智能手表在计步算法中可以引入较为复杂的模型来使得计步相对较 准确,融合计步数据时优先级次高的是智能手表。综上所述,计步设备进行数据同步时的优先级如下,智能手环<智能手表<智能跑鞋。
4、多设备的同步策略
同步策略可以分为实时同步和非实时同步,下面对这两种同步策略分别阐述。
4.1 非实时同步
非实时同步是一种较为简单的同步策略。它的目的是将设备数组中的历史数据融合到融合数组中,来展示运动详情。首先阐述单设备与手机同步时的基本策略,然后阐述多设备与手机同时同步时的变通方法,再讨论两种特殊的情况举例说明。
4.1.1 单设备非实时同步
这里所说的单设备并非指用户只能拥有一个设备,而是指一定时间内只有一个设备与手机发生非实时同步。
可利用如下原则将单设备的设备数组中的历史数据同步到融合数组中,假设该设备的序号为N。
原则A1. 从后至前,由近至远
从最后一分钟开始往前同步,直至未同步的第一分钟,详细讨论可见第5.1.3节。
同步时修改变量的操作可包括如下:对于融合数组,直接将设备数组中该分钟的计步数拷贝至融合数组该分钟的对应位置;对于Flag数组,写入“1-1-N”,即表示该分钟是“非实时性同步”,“数据是完整的”,且同步的设备序号为N;对于融合数组累加值,累加该分钟的计步数。
原则A2. 先到先得
若该分钟的Flag数组元素已经写入了数值,且该分钟步数不为0,且 Flag中“完整性”显示为1,则说明该分钟已经有完整数据,则跳过该分钟。
原则A3. 替换0步数数组元素
若该分钟的Flag数组元素已写入了数值,但该分钟步数为0,则直接做替换操作,具体可包括:对于融合数组,直接将设备数组中该分钟的计步数拷贝至融合数组该分钟的对应位置;对于Flag数组,写入“1-1-N”,即表示该分钟是“非实时性同步”,“数据是完整的”,且同步的设备序号为N;对于融合数组累加值,累加该分钟的计步数。
原则A4. 补写未完成的实时数据
若该分钟的Flag数组元素已经写入了数值,且数值等于“2-0-M”,即则说明该分钟曾执行了实时同步,但是数据不完整。有可能在该分钟内正在进行实时同步时,同步还没有结束设备就断开连接了(比如关闭app)。另外,上次实时同步的设备序号为M。产生这样的Flag的原因可详见第5.2节。
若设备序号M=N,且设备数组元素步数大于融合数组元素步数,同步时修改变量的操作可具体包括如下:对于融合数组,把融合数组元素替换为设备数组元素;对于Flag数组,写入“3-1-N”,即表示该分钟是“非实时同步补偿实时同步”,“数据是完整的”,且同步的设备序列号为N;对于融合数组累加值,累加设备数组元素与融合数组元素之间的差值。除此之外的情况,可不作任何修改。
原则A5. 补写融合总步数
通常会在一分钟的中间某个时间点进行非实时性同步。比如,在9:30:30同步9:30:00之前的数据。这样,在9:30:00-9:30:30这30秒内可能已经产生了一部分步数,但是没有写入到设备数组中,因为设备数组只有在一分钟结束时才会写入该分钟的计步数。但是这30秒产生的步数必须在融合总步数上体现出来,所以在同步完所有的每分钟的数据之后,还需要接收设备总步数,重新设置融合总步数。例如,
融合总步数=融合数组累加值+设备总步数-已同步的设备数组累加值。
值得注意的是,这个操作也有优先级,若高优先级的设备补写了融合总步数之后,低优先级的设备则不做此操作。
4.1.2 多设备同时非实时同步
当用户拥有多个设备时,一种常见的情况是:用户使用了一段时间的智能跑鞋和智能手环之后,打开手机app,同时同步这两个设备的运动数据至手机端,这样手机端可以同时收到两个设备数组。
可利用如下的一个原则,把多设备同时同步的问题转化成先后同步的问题去解决,再利用单设备的同步原则进行同步。
原则A6. 高级优先
具言之,可先同步高优先级的设备,再同步低优先级的设备。
在上述单设备非实时性同步中,所有需要同步的分钟都是从最后一分钟开始往前同步。这样设计的出发点是因为手机中的时间可能会出现与设备中的时间不一致的情况。例如,由于手机和设备使用的芯片不一样,他们的时钟周期有可能不一样,在经过较长时间之后,手机中的时间和设备中的时间可能会出现误差,例如几秒或者几分钟。所以,设备中的设备数组和手机中的设备数组有可能会发生不对齐的现象。
为了解决这个问题,可以从最后一分钟开始同步。这样做的一个基本假设是:设备的最近一分钟和手机的最近一分钟是对应的。从物理时间来说这个假设是成立的。
若手机中的时间领先设备中的时间1分钟,即若手机中当前时间是9:31:15,设备中的时间是9:30:35,则可使用如下表4所示的同步策略:
表4
Figure PCTCN2016088092-appb-000002
若手机中的时间落后设备中的时间1分钟,即若手机中当前时间是9:31:35,设备中的时间是9:32:15,则可使用如下表5所示的同步策略:
表5
Figure PCTCN2016088092-appb-000003
在这种同步方式中,可能会碰到如下的一个问题:当设备到达新的一 分钟时,设备会写入上一分钟的步数。当手机到达新的一分钟时,手机会空出一分钟供设备的步数写入。由于手机端和设备端的时间不一致,所以它们到达新的一分钟的时间也不一致。在这种情况下,可以设定:只有当手机有新的待写入的每分钟的融合数组元素时,且设备端有新写入未同步的设备数组元素时,才进行A1-A5原则的非实时性同步;否则,仅采用A5原则,即仅仅修改融合总步数为等于融合数组累加值+设备总步数-已同步的设备数组累加值。
在非实时性数据同步的策略设计中,基于高级优先原则,优先级高的设备总是优先占有融合数组。但若一分钟里,优先级高的设备仅仅使用了很短的时间,产生了很少的步数,而优先级低的设备在这一分钟内产生较多步数,则根据先到先得原则,优先级低的设备产生的步数将无法计入融合数组,从而可能会导致步数偏少。
举例来说,若用户在9:31:05秒脱下智能跑鞋。在9:31分钟的前5秒钟内,跑鞋产生了16步,然后在剩下的55秒内,智能手环计数了100步。在非实时性同步时,若先同步跑鞋,或者跑鞋和手环同时同步,基于高级优先原则,跑鞋的16步会占据该分钟的融合数组。并且,由于先到先得原则,手环在这一分钟的步数将无法替换进入融合数组,从而使得这一分钟里的计步数偏少。
但是这种情况一般只在设备切换的那一分钟会产生,并且用户很难察觉这一分钟的数据是否符合真实情况,所以基本可以不用考虑这个问题。
下面用一个完整的例子来说明非实时性同步。
在一个实施例中,如下方表6所示,当用户同时拥有智能手环和智能跑鞋,客户端进行非实时性数据同步时的各项数据可具体如下:
表6
Figure PCTCN2016088092-appb-000004
参照表6可知,用户:
24小时佩戴着智能手环;
在9:00:15穿上智能跑鞋;
在9:01:05打开手机客户端,之后开始走路;
在9:12:30关闭手机客户端;
在9:11:20脱鞋,然后仅仅与手环建立信号连接并走路;
在9:31:25打开手机客户端。
相应地,数据同步的操作内容可具体如下:
在第542分钟发生非实时同步,跑鞋先同步,手环后同步。
在第1-540分钟内,由于跑鞋没有产生任何步数,所以即使跑鞋先同步,这段时间的融合数组仍然会被手环的数据替换。
在第541分钟,用户穿上跑鞋之后走了一段时间,这段时间跑鞋产生了少量的步数(30步),所以在第542分钟打开手机客户端时,在融合数组里写入了跑鞋的30步,而在541分钟时无法被手环统计的100步数据所替换。
在第542分钟同步完成之后,由于手机客户端仍然处于打开的状态,跑鞋和手环步数变化的数据均被手机客户端获取,进入实时同步模式。此后,手机在融合数组中写入跑鞋的数据,并且把上述Flag数组记为“实时同步模式”。
在第552分钟内,手机客户端在9:12:30被关掉。在关掉之前的30秒内,跑鞋计数50步,在关掉之后的30秒内,跑鞋又计数50步。在9:12:30手机客户端被关掉的瞬间,实时同步模式停止,只实时同步了50步,Flag数组元素对应的值是2-0-2,表示“实时同步模式”,“不完整”数据,同步设备是“跑鞋”。
在第572分钟,同步第552-571分钟,采用非实时同步模式。
对于552分钟,Flag数组元素对应的值是“2-0-2”,则采用累加设备数组元素-融合数组元素之间的差值的方式对这个不完整的分钟数据进行补偿。
对于第553分钟,由于脱鞋时是9:11:20,前20秒钟产生了一个很小的20步。所以在同步时该20步会因为优先级较高率先占据融合数组,并不再修改。
由于同步的时间是9:31:25,前25秒手环产生了50步,并没有写入到手环数组中,仅仅在手环总步数上体现出来。所以还需要采用融合数组累加值+设备总步数-已同步的设备数组累加值的计算方式对融合总步数进行补偿,此时融合总步数修改为5100步。
采用上述数据同步方式不需要实时保持客户端与各设备之间的信号连接,可节省耗电量,还可以有效将设备数组中的历史数据融合到融合数组中。
4.2 实时同步策略
实时同步策略设计的主要目的是使得当用户戴着智能设备,一边走路一边实时查看手机端步数变化情况时,能够较为准确地显示融合后的数据。 换言之,实时同步策略设计的主要目的在于,能够快速地对一种设备的步数变化做出反应,并体现在按分钟统计的历史数据中。
例如,一个智能手环的用户连上手环之后,一边端着手机查看智能手环带来的步数变化,并且心中默念真正的走路步数,以体验智能手环的计步功能是否准确。他走了500步,耗时3分钟。3分钟后,他点击进入运动详情页面,想看看自己这三分钟每分钟的步数详情。
在这种情景中,用户在实时同步状况下的每分钟步数需要及时记录。也就是说,融合数组需要在实时状态下也能进行数据统计,以实时展示运动详情。
又例如,一个智能手环的用户买来一双新的智能跑鞋,当他连上智能跑鞋之后,他放下了手环,开始穿上智能跑鞋。他端着手机查看智能跑鞋带来的步数变化,以体验新鞋是否连接正常。他用了一会儿跑鞋之后,他脱下跑鞋,戴上手环开始走路,端着手机查看智能手环带来的步数的变化,以体验手环是否仍然处在连接状态。
在上述场景中涉及到两次设备的切换:第一次是显示手机上本来显示的是手环的步数,当他穿着跑鞋时,步数的显示要即时地随着跑鞋的步数变化进行累加。第二次是当他脱掉跑鞋之后,步数的显示要即时地随着手环的步数变化进行累加。当然,这两个过程必须是自动的,不能要求用户手动地进行切换。
基于以上,实时同步时可能需要能够直接操作融合数组元素,并能够实现多设备之间的即时切换。
4.2.2 单设备实时同步
这里所说的单设备并非指用户只拥有一个设备,而是指一定时间内只有一个设备与手机发生实时同步。
设备与手机发生实时性同步的条件:在进行非实时性的同步之后,如 果用户没有关闭app,且设备总步数继续发生了变化,设备会广播自己的设备总步数,被手机接收之后可实时地展示出来。
可利用如下原则将单设备的设备数组中的历史数据同步到融合数组中,假设该设备的序号为N。
原则B1. 先进行非实时性同步
该原则指的是,在进行实时性同步进行之前,必须要进行一次非实时性同步,以能够:
(1)同步之前所有未同步的数据,从而获取设备总步数和设备数组累计值;
(2)获取当前的融合总步数,作为实时性同步的计数起点;
(3)找到实时性同步时需要写入的融合数组位置;以及
(4)根据各个设备广播的设备总步数广播包,初始化广播包表,详细说明可见第5.2.3节。
此外,如果手机与设备失去连接长达一定时间,即使仍然在实时显示的页面下,也要先进行一次非实时性同步才能开始实时性同步。
原则B2. 直接累加融合数组元素
在实时性同步中,会在该分钟内随着步数的变化反复地累加同一个融合数组元素,每分钟累加的起点分两种情况:
(1)非实时性同步之后所在的分钟:起点=融合总步数-融合数组累加值;
(2)下一个实时同步的新一分钟:起点=新分钟第一个广播包的步数-上一个广播包的步数,其中,新的一分钟开始的判断可详见原则B3。
每收到一个广播包,相应元素都会做如下修改:对于融合数组,在写入起点步数之后,融合数组元素值累加新广播包的步数与上一个广播包步数的差值;对于Flag数组,若Flag数组元素不等于“2-0-N”,则写入“2-0-N”,即表示该分钟是“实时性同步”,“非完整的”,且设备序号为N;对于融 合总步数,等于融合数组累加值与该分钟融合数组元素值的和。
原则B3. 连接包间隔时间过长则重连
当设备与手机相连时,设备会不断地广播连接包,以保持与手机的正常连接。当长时间没有收到连接包时,可以认为设备与手机失去了连接,需要重连,并调用非实时同步。否则,认为设备与手机连接正常。
原则B4. 用相邻连接包跨分钟来确认认为一分钟结束
在设备与手机连接正常的条件下,若收到的两个相邻的连接包正好包含了一个新分钟的开始,即跨分钟,则认为前一分钟已经结束,相应的变量可能需要作出如下修改:对于Flag数组,写入“2-1-N”,即表示该分钟是“实时性同步”,数据是“完整的”,且设备序号为N;对于融合数组累加值,累加该分钟融合数组元素值。
4.2.3 多设备实时同步
当用户拥有多个设备时,一种非常常见的情况是:用户使用了一段时间的智能跑鞋和智能手环之后,打开手机app,同时同步这两个设备的运动数据至手机端,然后开始一边走路一边观察手机端总步数的跳变。
在多设备实时同步时,一个基本的原则是:根据优先级顺序和先到先得原则选定一个想要实时展示的设备,不断更新融合这个设备之后的融合总步数,而忽略其它的设备。当该设备不再更新步数时,选定另外一个设备,并实时更新它的总步数。
可以保存一张表,这张表存储了从上一次非实时性同步之后手机收到的每个设备最近一次的广播包P(N,T,S)。每个广播包可包含三个信息:设备号,时间戳和设备总步数。还可保存上次选择的设备对应的最近一次广播包。如表7中,设备的优先级可具体是:智能手环1<智能手表3<智能跑鞋2。
表7
上一次广播包 智能手环Pb1 智能跑鞋Ps1 智能手表Pw1 当前选择Pw1
设备号 1 2 3 3
时间戳 17:50:31 17:50:20 17:50:33 17:50:33
设备总步数 2500 1000 2600 2600
该表7在进行非实时性同步之后就被初始化好了,时间戳为非实时同步结束时的时间戳,总步数为各设备总步数,当前选择的广播包为空。
当收到新的广播包时,与当前选择的广播包相比较,分三种情况选择是否切换数据来源。
原则B5. 若选择设备为空或者设备不变,则立即累加
若上一次选择设备为空或者设备号不变,则利用原则B2,累加广播包设备总步数的差值,并且更新当前选择的广播包中的时间戳和设备总步数。
比如,当前选择是智能手环的广播包Pw1=(3,17:50:33,2600),新收到的广播包Pw2=(3,17:50:34,2602),则替换当前选择的广播包为Pw2,且相应元素可作如下修改:对于融合数组,该分钟融合数组元素值累加2(=2602-2600);对于Flag数组,若Flag数组元素不等于“2-0-3”,则写入“2-0-3”,即表示该分钟是“实时性同步”,数据是“非完整的”,且设备序号为3;对于融合总步数,累加2(=2602-2600)。
原则B6. 若设备优先级更高,则立即切换,条件累加
若新收到的广播包中设备优先级高于当前选择的设备优先级,则立即切换当前选择的设备为新收到的广播包中的设备。且若新广播包时间戳与当前选择时间戳差值大于或等于一定阈值,则累加广播包设备总步数的差值,否则不累加,仅仅做切换而已。当然,切换设备的同时,可替换当前选择广播包。
比如,假设当前选择是智能手环的广播包Pw1=(3,17:50:33,2600),时 间阈值设定的是4秒(s)。
(1)若新收到的广播包Ps2=(2,17:50:34,1010),则可替换当前选择的广播包为Ps2,切换选择设备,且相应元素可作如下修改:对于融合数组,因为17:50:34-17:50:33<4,则不作修改;对于Flag数组,修改Flag为“2-0-2”,即表示该分钟是“实时性同步”,数据是“非完整的”,且设备序号为2;对于融合总步数,因为17:50:34-17:50:33<4,则不作修改。
(2)若新收到的广播包Ps2=(2,17:50:38,1010),则可替换当前选择的广播包为Ps2,切换选择设备,且把Ps2广播包中步数的变化值写入相应元素,具体为:对于融合数组,因为17:50:38-17:50:33>4,则该分钟的融合数组元素值累加10(=1010-1000);对于Flag数组,修改Flag为“2-0-2”,即表示该分钟是“实时性同步”,数据是“非完整的”,且设备序号为2;对于融合总步数,因为17:50:38-17:50:33>4,则该分钟融合总步数累加10(=1010-1000)。
原则B7. 若设备优先级更低,则条件切换,条件累加
若新收到的广播包中设备优先级低于当前选择的设备优先级,且若新广播包时间戳与当前选择时间戳差值大于或等于一定阈值,则切换当前选择的设备为新收到的广播包中的设备,且累加设备总步数的差值,并替换当前选择广播包。否则不作任何修改。
比如,假设当前选择是智能手环的广播包Pw1=(3,17:50:33,2500),时间阈值设定的是4s。
(1)若新收到的广播包Pb2=(1,17:50:34,2505),由于17:50:34-17:50:33<4,则不作任何修改。
(2)若新收到的广播包Pb2=(1,17:50:38,2505),由于17:50:38-17:50:33>4,则替换当前选择的广播包为Pb2,切换选择设备,且把Pb2广播包中步数的变化值写入相应元素,可具体为:对于融合数组,该分钟融合数组元素值 累加5(=2505-2500);对于Flag数组,修改Flag为“2-0-1”,即表示该分钟是“实时性同步”,数据是“非完整的”,且设备序号为1;对于融合总步数,该分钟融合总步数累加5(=2505-2500)。
在B6规则中,当收到更高优先级的设备的广播包时,可立即切换到该设备,但是融合总步数还需要看广播包时间是否超过阈值,若超过则累加差值,否则不累加。如此做的目的在于防止两个设备同时产生数据时,实际上它们代表的是同一个时段的走路状态,若直接累加会造成步数的偏大。只有当超过一定时间阈值,则说明这段时间可能只有一个设备在计步、另外一个设备在休息。这样的情况下进行累加才是安全的,不会造成偏大的计步数,虽然仍有可能计步数偏小的问题。
表8展示了一分钟之内,用户在进行非实时性同步智能手环和智能鞋之后,先用手环走了一段路,期间穿上鞋开始走,然后摘下手环,用跑鞋走了一段路。若跑鞋产生步数之后的第一个广播包与手环的最后一个广播包之间的时间间隔太短,就可能造成步数偏小。
表8
Figure PCTCN2016088092-appb-000005
从表8可以看出,在该例子中:
第1行表示时间,以秒为单位。
第2行表示事件:用户在第5秒进行了非实时性同步;第7秒开始戴着手环走路;第12、14、16、17秒收到手环的4个广播包;第18秒摘下手环;第14秒开始穿着鞋走路;第20、21、24、26秒收到跑鞋的4个广播包。
第3、4行表示手环广播的步数和时间。
第5、6行表示跑鞋广播的步数和时间。
第7行表示手机收到两个设备的广播之后,选择的广播设备。
第8行表示手机在实时同步之后,根据选择的广播设备计算出的融合总步数。
值得注意的是,两个设备在累计10步之后才会发出第一个广播包,这可能是由于计步器的内部逻辑设定的。例如,为了过滤掉不精准的计步,计步器可要求只有步数累积到一定程度才会认为是有效的步数,否则会认为是无效的步数重新开始计数。在本例中,需要累计10步才开始发送广播包,在此之后,只要步数发生变化,就会发送广播包。
从表8中可以看出,手环和跑鞋在累计步数的过程中存在一段时间的重叠,即14-17秒。由于跑鞋在累计10步后发出第一个广播包的时间是第20秒,距离上次选择的手环的广播包第17秒仅相差3秒时间,少于阈值设定的4秒。所以,可基于原则B6执行立即切换但是不累加数值的数据同步操作。
可以看到,在第17-20秒之间,跑鞋的计步数被抹掉了,没有累加在融合步数中,这可能会导致步数偏少。
类似的,基于原则B6和B7的同步操作有可能会造成步数的偏多。
表9展示了与表8类似的情况,稍有不同的是,跑鞋产生步数了之后广播第一个广播包的时间是22秒。
表9
Figure PCTCN2016088092-appb-000006
从表9中可以看出,手环和跑鞋在累计步数的过程中存在一段时间的重叠,即14-17秒。由于跑鞋在累计10步后发出的第一个广播包的时间是第22秒,距离上次选择的手环的广播包的时间第17秒的时间差为5秒时间,大于阈值设定的4秒。所以,将基于原则B6执行立即切换且累加数值的数据同步操作。
可以看到,在第14-27秒之间,跑鞋的计步数被重复累积到融合总步数中,从而可导致总步数偏多。
以上总结了两种可能会导致计步数偏少或者偏多的情况。但是这两种情况通常只有在设备切换时才会发生,并且影响的步数只在几秒钟范围内,对总步数影响不大。
在一个实施例中,如下方表10所示,当用户客户端根据实时性同步方式进行数据同步时,各项数据统计可具体如下:
表10
Figure PCTCN2016088092-appb-000007
参照表10,在本实施例中,用户一直佩戴着智能手环,期间穿上了智能跑鞋,走一段时间又脱下跑鞋。在整个过程中,实时同步选择的设备一开始是手环,在穿上跑鞋之后切换成跑鞋,在跑鞋脱下后再切换到手环。可以看出,在第50秒进行了非实时性同步;此后手环的计步数一共被同步了9次,分别是(54秒,110步)、(56秒,115步)、(58秒,120步)、(0秒,125步)、(2秒,130步)、(5秒,135步)、(7秒,140步)、(8秒,145步)、(11秒,150步);跑鞋的计步数一共被同步了4次,分别是(57秒,10步)、(59秒,16步)、(1秒,22步)、(3秒,28步)。
其中,具体的数据同步操作可包括如下:
在第50秒进行非实时性同步,但是此时还不知道用户是否会走路,因此可不修改融合数组元素和Flag数组元素。
在第54秒,手环的计步数发生变化,此时可认为进入了实时同步模式。首先,可将新分钟第一次同步的步数与上一次同步的步数的差值累加到累计总步 数,并把累计总步数与融合数组累加值的差值记录于该分钟对应的融合数组元素中。接着,可修改Flag数组元素为“2-0-1”,以表示该分钟进入“实时同步模式”,数据“不完整”,最近一次选择的设备是“手环”。
在第57秒,跑鞋的计步数发生变化,由于跑鞋优先级高于手环,则所同步的设备可立即切换到跑鞋。由于本次数据同步与上次数据同步的间隔时长(3s)小于预设阈值(4s),无需写入补偿数据。但是,需修改Flag数组元素为“2-0-2”,以表示该分钟进入“实时同步模式”,数据“不完整”,最近一次选择的设备是“跑鞋”。
在第0秒,由于跨分钟,Flag数组元素可改成“2-1-2”,以表示该分钟进入“实时同步模式”,数据是“完整的”,最近一次选择的设备是“跑鞋”。
在第1秒,同步跑鞋统计的步数,同时修改Flag数组元素为“2-0-2”,以表示该分钟进入“实时同步模式”,数据“不完整”,最近一次选择的设备是“跑鞋”。
在第3秒,继续同步跑鞋统计的步数,此后与跑鞋建立的信号连接断开。
在第7秒,与手环建立信号连接,开始同步手环统计的步数,由于此次与跑鞋建立的信号连接断开的持续时长达到预设阈值4秒,则需将此次手环统计的步数(140步)与上一次手环统计的步数(135步)的差值(5步)累加到融合数组中,并修改Flag数组元素为“2-0-1”,以表示该分钟进入“实时同步模式”,数据“不完整”,最近一次选择的设备是“手环”。
在第8秒,继续同步手环统计的步数,并及时累加到融合数组中。
上述实施例实现了用户可实时查看客户端步数的变化情况。综上,客户端提供了实时性数据同步和非实时性数据同步两种数据同步方式供用户根据自身需求进行选择,从而可提高使用效果。
参见图4所示,对应于上述方法,本公开同时提供一种可穿戴智能设备的数据统计装置。如图4所示,所述装置400可包括处理器410以及机器可读存储介质420,其中,处理器410和机器可读存储介质420通常借由内部总线430相互连接。在其他可能的实现方式中,所述装置400还可能包括外 部网络接口440,以能够与其他设备或者部件进行通信。
在不同的例子中,所述机器可读存储介质420可以是:ROM(Read-Only Memory,只读存储器)、易失存储器、非易失性存储器、闪存、存储驱动器(如硬盘驱动器)、固态硬盘、任何类型的存储盘(如光盘、DVD等),或者类似的存储介质,或者它们的组合。
进一步地,机器可读存储介质420上存储有与用于对可穿戴智能设备的数据统计进行控制的控制逻辑500对应的机器可执行指令。从功能上划分,如图5所示,所述控制逻辑500可包括:
接收模块510,用于当通过多个智能设备采集某一用户的某一统计项目的生理指标数据时,接收所述多个智能设备中的至少一个智能设备发送的生理指标数据和与生理指标数据对应的时间信息;
获取模块520,用于获取每个智能设备的优先级;
计算模块530,用于根据每个智能设备的优先级、生理指标数据和与生理指标数据对应的时间信息,计算多个智能设备的关于该统计项目的融合生理指标数据;
显示模块540,用于显示所述融合生理指标数据。
在一个实施例中,所述生理指标数据可包括步行步数、移动距离、心跳次数以及能量消耗值等中的一项或多项。
在一个实施例中,所述生理指标数据可储存于预设长度的数组中。每个智能设备对应一个数组,每个设备在一个时间粒度内采集的生理指标数据为该数组中的一个元素。换言之,按照获取生理指标数据的时间粒度,一个元素可对应一个时间点。在这种情况下,所述计算模块530可用于:根据每个所述智能设备的优先级和对应的设备数组,得到所述融合数组中对应的融合生理指标数据。
如图6所示,在一个实施例中,所述计算模块530可具体包括:
选取子模块531,用于根据每个智能设备的优先级和与生理指标数据对应的时间信息,选取出符合时间要求的且优先级最高的智能设备作为目标智能设备;
统计子模块532,用于统计所述目标智能设备的生理指标数据以得到统计结果,并将所述统计结果作为所述融合生理指标数据。
在一个实施例中,所述统计子模块532还可用于:在所述目标智能设备的生理指标数据不完整或为零时,选取符合时间要求的且设备优先级次高的智能设备作为新的目标智能设备,并以所述新的目标智能设备的生理指标数据替换上次的目标智能设备的生理指标数据。
在一个实施例中,所述统计子模块532还可用于:判断所述多个智能设备当前所处的数据同步模式是实时同步还是非实时同步;在所述数据同步模式为非实时同步的情况下,对所述目标智能设备的从未同步的第一时刻起至当前时刻的生理指标数据进行统计以得到对应的融合生理指标数据;在所述数据同步模式为实时同步的情况下,对所述目标智能设备的当前生理指标数据进行统计以得到对应的融合生理指标数据。
在一个实施例中,所述统计子模块532还可用于:若检测到所述目标智能设备由第一智能设备切换至第二智能设备,获取所述第一智能设备的历史生理指标数据和所述第二智能设备的当前生理指标数据;根据所述第一智能设备的历史生理指标数据和所述第二智能设备的当前生理指标数据计算得到所述融合生理指标数据。
在一个实施例中,所述统计子模块532还可用于:计算所述第一智能设备的历史生理指标数据对应的历史时刻与当前时刻之间的时间间隔;在所述时间间隔大于或等于预设阈值的情况下,通过将所述第一智能设备的历史生理指标数据、所述第二智能设备的当前生理指标数据和预设的生理指标补偿数据进行累加,来得到所述融合生理指标数据;在所述时间间隔小于所述 预设阈值的情况下,通过将所述第一目标智能设备的历史生理指标数据和所述第二目标智能设备的当前生理指标数据进行累加,来得到所述融合生理指标数据。
本领域内的技术人员应明白,本发明的实施例可提供为方法、系统、或计算机程序产品。因此,本发明可采用完全硬件实施例、完全软件实施例、或结合软件和硬件方面的实施例的形式。而且,本发明可采用在其中包含有计算机可用程序代码的计算机可用存储介质(包括但不限于磁盘存储器和光学存储器等)上实施的计算机程序产品的形式。
本发明是参照根据本发明实施例的方法、设备(系统)、和计算机程序产品的流程图和/或方框图来描述的。应理解可由计算机程序指令实现流程图和/或方框图中的每一流程和/或方框、以及流程图和/或方框图中的流程和/或方框的结合。可提供这些计算机程序指令到通用计算机、专用计算机、嵌入式处理机或其他可编程数据处理设备的处理器以产生一个机器,使得通过计算机或其他可编程数据处理设备的处理器执行的指令产生用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的装置。
这些计算机程序指令也可存储在能引导计算机或其他可编程数据处理设备以特定方式工作的计算机可读存储器中,使得存储在该计算机可读存储器中的指令产生包括指令装置的制造品,该指令装置实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能。
这些计算机程序指令也可装载到计算机或其他可编程数据处理设备上,使得在计算机或其他可编程设备上执行一系列操作步骤以产生计算机实现的处理,从而在计算机或其他可编程设备上执行的指令提供用于实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能的步骤。
对于装置实施例而言,由于其基本对应于方法实施例,所以相关之处参见方法实施例的部分说明即可。以上所描述的装置实施例仅仅是示意性的,其中所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部模块来实现本实施例方案的目的。本领域普通技术人员在不付出创造性劳动的情况下,即可以理解并实施。
需要说明的是,在本文中,诸如第一和第二等之类的关系术语仅仅用来将一个实体或者操作与另一个实体或操作区分开来,而不一定要求或者暗示这些实体或操作之间存在任何这种实际的关系或者顺序。术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者设备不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者设备所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括所述要素的过程、方法、物品或者设备中还存在另外的相同要素。
以上对本发明实施例所提供的方法和装置进行了详细介绍,本文中应用了具体个例对本发明的原理及实施方式进行了阐述,以上实施例的说明只是用于帮助理解本发明的方法及其核心思想;同时,对于本领域的一般技术人员,依据本发明的思想,在具体实施方式及应用范围上均会有改变之处,综上所述,本说明书内容不应理解为对本发明的限制。

Claims (20)

  1. 一种可穿戴智能设备的数据统计方法,包括:
    接收多个智能设备中的至少一个智能设备采集的关于用户的某一统计项目的生理指标数据和与所述生理指标数据对应的时间信息;
    根据每个所述智能设备的优先级、生理指标数据和与生理指标数据对应的时间信息,计算关于所述用户的所述统计项目的融合生理指标数据。
  2. 如权利要求1所述的方法,其特征在于,
    每个智能设备对应一个预设长度的设备数组,每个智能设备在一个时间粒度获取的生理指标数据为该设备数组中与该获取时间点对应的元素,
    一个时间粒度的所述融合生理指标数据存储于融合数组的对应元素中,所述融合数组也具有所述预设长度。
  3. 如权利要求2所述的方法,其特征在于,根据每个所述智能设备的优先级、生理指标数据和与生理指标数据对应的时间信息,计算关于所述用户的所述统计项目的融合生理指标数据,包括:
    根据每个所述智能设备的优先级和对应的设备数组,得到所述融合数组中对应的融合生理指标数据。
  4. 如权利要求3所述的方法,其特征在于,根据每个所述智能设备的优先级和对应的设备数组,得到所述融合数组中对应的融合生理指标数据,包括:
    在非实时同步模式下,从当前时刻开始向前依次填写融合生理指标数据至所述融合数组中对应的位置;
    当实时同步模式下,从当前时刻开始向后依次填写融合生理指标数据至所述融合数组中对应的位置。
  5. 如权利要求1所述的方法,其特征在于,根据每个所述智能设备的优先级、生理指标数据和与生理指标数据对应的时间信息,计算关于所述用户的所述统计项目的融合生理指标数据,包括:
    根据每个智能设备的优先级和与生理指标数据对应的时间信息,选取出符合时间要求的且优先级最高的智能设备作为目标智能设备;
    统计所述目标智能设备的生理指标数据以得到统计结果,并将所述统计结果作为所述融合生理指标数据。
  6. 如权利要求5所述的方法,其特征在于,统计所述目标智能设备的生理指标数据,包括:
    在所述目标智能设备的生理指标数据不完整或为零时,选取符合时间要求的且设备优先级次高的智能设备作为新的目标智能设备,并以所述新的目标智能设备的生理指标数据替换上次的目标智能设备的生理指标数据。
  7. 如权利要求5所述的方法,其特征在于,统计所述目标智能设备的生理指标数据,包括:
    判断所述多个智能设备当前所处的数据同步模式是实时同步还是非实时同步;
    在所述数据同步模式为非实时同步的情况下,对所述目标智能设备的从未同步的第一时刻起至当前时刻的生理指标数据进行统计以得到对应的融合生理指标数据;
    在所述数据同步模式为实时同步的情况下,对所述目标智能设备的当前生理指标数据进行统计以得到对应的融合生理指标数据。
  8. 如权利要求7所述的方法,其特征在于,对所述目标智能设备的当前生理指标数据进行统计以得到对应的融合生理指标数据,包括:
    若检测到所述目标智能设备由第一智能设备切换至第二智能设备,获取所述第一智能设备的历史生理指标数据和所述第二智能设备的当前生理指标数据;
    根据所述第一智能设备的历史生理指标数据和所述第二智能设备的当前生理指标数据计算得到所述融合生理指标数据。
  9. 如权利要求8所述的方法,其特征在于,根据所述第一智能设备的历史生理指标数据和所述第二智能设备的当前生理指标数据计算得到所述融合 生理指标数据,包括:
    计算所述第一智能设备的历史生理指标数据对应的历史时刻与当前时刻之间的时间间隔;
    在所述时间间隔大于或等于预设阈值的情况下,通过将所述第一智能设备的历史生理指标数据、所述第二智能设备的当前生理指标数据和预设的生理指标补偿数据进行累加,来得到所述融合生理指标数据;
    在所述时间间隔小于所述预设阈值的情况下,通过将所述第一目标智能设备的历史生理指标数据和所述第二目标智能设备的当前生理指标数据进行累加,来得到所述融合生理指标数据。
  10. 如权利要求1所述的方法,其特征在于,所述生理指标数据包括步行步数、移动距离、心跳次数和能量消耗值中的一项或多项。
  11. 一种可穿戴智能设备的数据统计装置,包括处理器和机器可读存储介质,所述机器可读存储介质上存储有与数据统计控制逻辑对应的机器可执行指令,通过读取和执行所述机器可执行指令,所述处理器执行以下:
    接收多个智能设备中的至少一个智能设备采集的关于用户的某一统计项目的生理指标数据和与所述生理指标数据对应的时间信息;
    根据每个所述智能设备的优先级、生理指标数据和与生理指标数据对应的时间信息,计算关于所述用户的所述统计项目的融合生理指标数据。
  12. 如权利要求11所述的装置,其特征在于,
    每个智能设备对应一个预设长度的设备数组,每个智能设备在一个时间粒度获取的生理指标数据为该设备数组中与该获取时间点对应的元素,
    一个时间粒度的所述融合生理指标数据存储于融合数组的对应元素中,所述融合数组也具有所述预设长度。
  13. 如权利要求12所述的装置,其特征在于,在根据每个所述智能设备的优先级、生理指标数据和与生理指标数据对应的时间信息,计算关于所述用户的所述统计项目的融合生理指标数据时,所述机器可执行指令促使所述处理器:
    根据每个所述智能设备的优先级和对应的设备数组,得到所述融合数组中对应的融合生理指标数据。
  14. 如权利要求13所述的装置,其特征在于,在根据每个所述智能设备的优先级和对应的设备数组,得到所述融合数组中对应的融合生理指标数据时,所述机器可执行指令促使所述处理器:
    在非实时同步模式下,从当前时刻开始向前依次填写融合生理指标数据至所述融合数组中对应的位置;
    当实时同步模式下,从当前时刻开始向后依次填写融合生理指标数据至所述融合数组中对应的位置。
  15. 如权利要求11所述的装置,其特征在于,在根据每个所述智能设备的优先级、生理指标数据和与生理指标数据对应的时间信息,计算关于所述用户的所述统计项目的融合生理指标数据时,所述机器可执行指令促使所述处理器:
    根据每个智能设备的优先级和与生理指标数据对应的时间信息,选取出符合时间要求的且优先级最高的智能设备作为目标智能设备;
    统计所述目标智能设备的生理指标数据以得到统计结果,并将所述统计结果作为所述融合生理指标数据。
  16. 如权利要求15所述的装置,其特征在于,在统计所述目标智能设备的生理指标数据时,所述机器可执行指令促使所述处理器:
    在所述目标智能设备的生理指标数据不完整或为零时,选取符合时间要求的且设备优先级次高的智能设备作为新的目标智能设备,并以所述新的目标智能设备的生理指标数据替换上次的目标智能设备的生理指标数据。
  17. 如权利要求15所述的装置,其特征在于,在统计所述目标智能设备的生理指标数据时,所述机器可执行指令促使所述处理器:
    判断所述多个智能设备当前所处的数据同步模式是实时同步还是非实时同步;
    在所述数据同步模式为非实时同步的情况下,对所述目标智能设备的从 未同步的第一时刻起至当前时刻的生理指标数据进行统计以得到对应的融合生理指标数据;
    在所述数据同步模式为实时同步的情况下,对所述目标智能设备的当前生理指标数据进行统计以得到对应的融合生理指标数据。
  18. 如权利要求17所述的装置,其特征在于,在对所述目标智能设备的当前生理指标数据进行统计以得到对应的融合生理指标数据时,所述机器可执行指令促使所述处理器:
    若检测到所述目标智能设备由第一智能设备切换至第二智能设备,获取所述第一智能设备的历史生理指标数据和所述第二智能设备的当前生理指标数据;
    根据所述第一智能设备的历史生理指标数据和所述第二智能设备的当前生理指标数据计算得到所述融合生理指标数据。
  19. 如权利要求18所述的装置,其特征在于,在根据所述第一智能设备的历史生理指标数据和所述第二智能设备的当前生理指标数据计算得到所述融合生理指标数据时,所述机器可执行指令促使所述处理器:
    计算所述第一智能设备的历史生理指标数据对应的历史时刻与当前时刻之间的时间间隔;
    在所述时间间隔大于或等于预设阈值的情况下,通过将所述第一智能设备的历史生理指标数据、所述第二智能设备的当前生理指标数据和预设的生理指标补偿数据进行累加,来得到所述融合生理指标数据;
    在所述时间间隔小于所述预设阈值的情况下,通过将所述第一目标智能设备的历史生理指标数据和所述第二目标智能设备的当前生理指标数据进行累加,来得到所述融合生理指标数据。
  20. 如权利要求11所述的装置,其特征在于,所述生理指标数据包括步行步数、移动距离、心跳次数和能量消耗值中的一项或多项。
PCT/CN2016/088092 2015-07-01 2016-07-01 可穿戴智能设备的数据统计 WO2017000909A1 (zh)

Priority Applications (1)

Application Number Priority Date Filing Date Title
US15/592,623 US10853301B2 (en) 2015-07-01 2017-05-11 Data statistics for wearable device

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201510391594.8 2015-07-01
CN201510391594.8A CN106156480A (zh) 2015-07-01 2015-07-01 一种数据统计方法及装置

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US15/592,623 Continuation-In-Part US10853301B2 (en) 2015-07-01 2017-05-11 Data statistics for wearable device

Publications (1)

Publication Number Publication Date
WO2017000909A1 true WO2017000909A1 (zh) 2017-01-05

Family

ID=57348210

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2016/088092 WO2017000909A1 (zh) 2015-07-01 2016-07-01 可穿戴智能设备的数据统计

Country Status (3)

Country Link
US (1) US10853301B2 (zh)
CN (1) CN106156480A (zh)
WO (1) WO2017000909A1 (zh)

Families Citing this family (17)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107847194B (zh) * 2014-06-30 2020-11-24 塞罗拉公司 使有操作延迟的pc与有实时时钟的微控制器同步的系统
CN106535101B (zh) * 2016-12-05 2020-04-28 爱国者电子科技有限公司 蓝牙通信方法、系统和无线路由器
CN108345598B (zh) * 2017-01-22 2023-07-18 杭州爱钥医疗健康科技有限公司 测量记录迁移方法、装置及电子设备
US10716493B2 (en) * 2017-02-27 2020-07-21 New Lifeware Inc. Systems, methods, and apparatuses for peripheral arterial disease detection and mitigation thereof
CN107590220A (zh) * 2017-08-31 2018-01-16 江西博瑞彤芸科技有限公司 存储文件生成方法
CN110209884B (zh) * 2018-01-10 2022-08-05 杭州海康威视数字技术股份有限公司 一种索引校对方法和装置
CN108347480B (zh) * 2018-01-30 2020-05-01 深圳阿凡达智控有限公司 数据同步方法、装置、计算机可读存储介质及电子烟
CN108595670B (zh) * 2018-04-28 2021-05-14 金蝶蝶金云计算有限公司 一种数据存储方法、装置、计算机装置及存储介质
CN109361727B (zh) * 2018-08-30 2021-12-07 Oppo广东移动通信有限公司 信息共享方法、装置、存储介质及穿戴式设备
CN116016566A (zh) * 2018-10-19 2023-04-25 中兴通讯股份有限公司 数据同步方法、装置及计算机可读存储介质
CN110686699A (zh) * 2019-08-19 2020-01-14 苏宁智能终端有限公司 计步方法及装置
CN111125127B (zh) * 2019-12-06 2023-01-31 腾讯科技(深圳)有限公司 数据同步方法和装置、存储介质及电子装置
CN111291061B (zh) * 2020-01-16 2023-06-13 北京旷视科技有限公司 数据统计方法、装置和电子系统
CN113555132A (zh) * 2020-04-24 2021-10-26 华为技术有限公司 多源数据处理方法、电子设备和计算机可读存储介质
CN113729622A (zh) * 2020-05-29 2021-12-03 芯海科技(深圳)股份有限公司 生物指标测量方法、装置、测量设备和存储介质
CN113341959B (zh) * 2021-05-25 2022-02-11 吉利汽车集团有限公司 一种机器人数据统计方法及其系统
CN117643461B (zh) * 2024-01-30 2024-04-02 吉林大学 基于人工智能的心率智能监测系统及方法

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20120246261A1 (en) * 2011-03-22 2012-09-27 Roh Yohan J Method and apparatus for managing sensor data and method and apparatus for analyzing sensor data
CN104169926A (zh) * 2012-01-19 2014-11-26 耐克创新有限合伙公司 能量消耗
CN104169923A (zh) * 2012-01-18 2014-11-26 耐克创新有限合伙公司 活动点数
CN104605939A (zh) * 2015-02-05 2015-05-13 腾讯科技(深圳)有限公司 生理信息处理方法及信息处理装置
CN105593862A (zh) * 2013-08-07 2016-05-18 耐克创新有限合伙公司 具有活动提醒的活动识别

Family Cites Families (10)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9646209B2 (en) * 2010-08-26 2017-05-09 Blast Motion Inc. Sensor and media event detection and tagging system
US8849610B2 (en) * 2010-09-30 2014-09-30 Fitbit, Inc. Tracking user physical activity with multiple devices
US20150170531A1 (en) * 2012-10-08 2015-06-18 Lark Technologies, Inc. Method for communicating wellness-related communications to a user
RU2015129763A (ru) * 2012-12-21 2017-01-26 Дека Продактс Лимитед Партнершип Система, способ и аппарат для электронного ухода за пациентом
CN104219038A (zh) * 2014-08-27 2014-12-17 小米科技有限责任公司 一种同步数据的方法及装置
CN104301528B (zh) * 2014-09-28 2017-12-12 小米科技有限责任公司 显示信息的方法及装置
WO2016070128A1 (en) * 2014-10-31 2016-05-06 Irhythm Technologies, Inc. Wireless physiological monitoring device and systems
WO2016105166A1 (en) * 2014-12-26 2016-06-30 Samsung Electronics Co., Ltd. Device and method of controlling wearable device
CN104537132A (zh) * 2015-01-30 2015-04-22 小米科技有限责任公司 运动数据记录方法及装置
US20160302671A1 (en) * 2015-04-16 2016-10-20 Microsoft Technology Licensing, Llc Prediction of Health Status from Physiological Data

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20120246261A1 (en) * 2011-03-22 2012-09-27 Roh Yohan J Method and apparatus for managing sensor data and method and apparatus for analyzing sensor data
CN104169923A (zh) * 2012-01-18 2014-11-26 耐克创新有限合伙公司 活动点数
CN104169926A (zh) * 2012-01-19 2014-11-26 耐克创新有限合伙公司 能量消耗
CN105593862A (zh) * 2013-08-07 2016-05-18 耐克创新有限合伙公司 具有活动提醒的活动识别
CN104605939A (zh) * 2015-02-05 2015-05-13 腾讯科技(深圳)有限公司 生理信息处理方法及信息处理装置

Also Published As

Publication number Publication date
US20170249280A1 (en) 2017-08-31
CN106156480A (zh) 2016-11-23
US10853301B2 (en) 2020-12-01

Similar Documents

Publication Publication Date Title
WO2017000909A1 (zh) 可穿戴智能设备的数据统计
US10469647B2 (en) Tracking activity data between wearable devices paired with a companion
US10484943B2 (en) Power management of a personal area fabric
CN103095389B (zh) 分布式稳健时钟同步
CN105590007B (zh) 刷牙姿态的分析方法及分析系统
CN104580748B (zh) 调整闹钟的方法、系统及移动终端
CN103519821B (zh) 一种基于人体生理信息采集的运动提醒方法
WO2018228353A1 (zh) 一种多相机系统同步曝光的控制方法、装置及终端设备
RU2014118970A (ru) Отложенная публикация данных в системах управления процессами
JP2008306472A (ja) センサネットシステム、及びセンサノード
WO2018228488A1 (zh) 一种数据同步方法、装置及移动设备
US10341204B2 (en) Methods and apparatus for device management
CN105528366B (zh) 一种数据同步控制方法和装置
CN104932855A (zh) 一种亮度控制的方法和终端
EP3167415A1 (en) Apparatus, method, and computer program product for determining calendar entries to advance user goals
JP7000340B2 (ja) 複数のスマートデバイスのための協調的な送信管理
CA3117931C (en) Medical device usage monitoring system and method
CN105630605A (zh) 基于数据服务访问情况动态调整数据服务集群的方法
US20170213367A1 (en) User data processing method, and device for displaying data acquired from a wearable device
CN115240850A (zh) 信息处理方法、装置、可穿戴设备和电子设备
EP4130958A1 (en) Data transmission method and apparatus, and wearable device and storage medium
CN105022497A (zh) 将光学导航传感器伪装成具有高画面刷新率的方法与装置
WO2020200083A1 (zh) 一种选取信号通道的方法以及可穿戴智能设备
CN111128250A (zh) 信息的处理方法和装置
WO2023109550A1 (zh) 体温测量方法及电子设备

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 16817273

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 16817273

Country of ref document: EP

Kind code of ref document: A1