CN112714401B - Data processing method and device, equipment and storage medium - Google Patents

Data processing method and device, equipment and storage medium Download PDF

Info

Publication number
CN112714401B
CN112714401B CN202011567952.3A CN202011567952A CN112714401B CN 112714401 B CN112714401 B CN 112714401B CN 202011567952 A CN202011567952 A CN 202011567952A CN 112714401 B CN112714401 B CN 112714401B
Authority
CN
China
Prior art keywords
measurement data
broadcast signal
historical measurement
target
client
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202011567952.3A
Other languages
Chinese (zh)
Other versions
CN112714401A (en
Inventor
陈廷峰
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Chenbei Technology Co Ltd
Original Assignee
Shenzhen Chenbei Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Chenbei Technology Co Ltd filed Critical Shenzhen Chenbei Technology Co Ltd
Priority to CN202011567952.3A priority Critical patent/CN112714401B/en
Publication of CN112714401A publication Critical patent/CN112714401A/en
Application granted granted Critical
Publication of CN112714401B publication Critical patent/CN112714401B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/06Selective distribution of broadcast services, e.g. multimedia broadcast multicast service [MBMS]; Services to user groups; One-way selective calling services
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/30Services specially adapted for particular environments, situations or purposes
    • H04W4/38Services specially adapted for particular environments, situations or purposes for collecting sensor information
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/80Services using short range communication, e.g. near-field communication [NFC], radio-frequency identification [RFID] or low energy communication

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Multimedia (AREA)
  • Testing, Inspecting, Measuring Of Stereoscopic Televisions And Televisions (AREA)
  • Two-Way Televisions, Distribution Of Moving Picture Or The Like (AREA)

Abstract

The embodiment of the application discloses a data processing method, a device, equipment and a storage medium, wherein the method comprises the following steps: the client sends a first broadcast signal, the first broadcast signal comprises measurement data of a target user, after the intelligent scale receives the first broadcast signal, if the intelligent scale determines that the historical measurement data stored by the intelligent scale contains the target historical measurement data belonging to the target user according to the measurement data of the target user, the target historical measurement data and a corresponding first storage serial number are carried in a second broadcast signal and fed back to the client, after the intelligent scale receives a third broadcast signal, the target historical measurement data corresponding to the second storage serial number are deleted, accurate transmission of the target historical measurement data between the intelligent scale and the client can be effectively realized, the transmission process is simple, the probability of errors in the transmission process of the target historical measurement data can be effectively reduced, and the target historical measurement data can be deleted after the target historical measurement data are determined to be stored, avoiding the false deletion.

Description

Data processing method and device, equipment and storage medium
Technical Field
The present application relates to the field of intelligent device technologies, and in particular, to a data processing method and apparatus, a device, and a storage medium.
Background
At present, there are various interaction modes between smart devices, for example: the wireless communication modes can include a bluetooth communication mode, a zigbee communication mode, a wifi communication mode, a 4G wireless mode, and the like, and the wireless communication modes are commonly used at present, and particularly in an intelligent home scene, the general flow of the existing bluetooth communication is as follows: sending out a broadcast signal from a slave device (intelligent household electrical appliance terminal) → searching for a slave device broadcast signal from a master device (control device) → establishing a pairing connection → sending out an instruction from the master device → receiving an instruction from the slave device. The intelligent device and the intelligent device can realize data interaction through connection establishment.
However, in a scenario of implementing data transmission by transmitting a broadcast signal, how to transmit history data between the smart device and the smart device still remains to be solved.
Disclosure of Invention
The present application mainly aims to provide a data processing method, device, apparatus, and storage medium, which can solve the problem in the prior art that historical data cannot be transmitted in a broadcast manner.
To achieve the above object, a first aspect of the present application provides a data processing method, including:
the method comprises the steps that an intelligent scale receives a first broadcast signal sent by a client, wherein the first broadcast signal at least comprises measurement data of a target user corresponding to the client;
If the target historical measurement data belonging to the target user exists in the historical measurement data stored by the intelligent scale according to the measurement data of the target user, carrying a first storage serial number corresponding to the target historical measurement data and the target historical measurement data in a second broadcast signal and feeding back the second storage serial number to the client;
and if a third broadcast signal fed back by the client is received, the third broadcast signal at least comprises a second storage serial number, and the intelligent scale deletes target historical measurement data corresponding to the second storage serial number in the historical measurement data.
Optionally, the feeding back the target historical measurement data and the first storage sequence number corresponding to the target historical measurement data to the client in a second broadcast signal, if a third broadcast signal fed back by the client is received, where the third broadcast signal at least includes the second storage sequence number, and the smart scale deletes the target historical measurement data corresponding to the second storage sequence number in the historical measurement data, includes:
sending the second broadcast signal, wherein the second broadcast signal comprises ith item label historical measurement data and a first storage serial number of the ith item label historical measurement data, the initial value of i is 1, the first storage serial number is i, the ith item label historical measurement data is the data with the earliest storage time point in the target historical measurement data to be sent, i is not more than N, and N is the total number of the target historical measurement data belonging to the target user;
And if a third broadcast signal fed back by the client is received, wherein the third broadcast signal at least comprises a second storage sequence number of the historical measurement data stored by the client, deleting the target historical measurement data corresponding to the second storage sequence number, making i equal to i +1, and returning to the step of sending the second broadcast signal.
Optionally, the first broadcast signal and the third broadcast signal are similar signals carrying the same data type; if the client is initially started, or the second broadcast signal is not received, or the target historical measurement data carried in the second broadcast signal is not stored, the second storage sequence number carried in the first broadcast signal is a preset storage sequence number, and the preset storage sequence number is different from the first storage sequence number corresponding to the target historical measurement data.
Optionally, before deleting the target historical measurement data corresponding to the second storage sequence number, the method further includes:
comparing the second storage sequence number in the third broadcast signal with the first storage sequence number carried by the sent second broadcast signal;
and when the second storage sequence number in the third broadcast signal is the same as the first storage sequence number carried by the sent second broadcast signal, continuing to execute the step of deleting the target historical measurement data corresponding to the second storage sequence number.
Optionally, the method further comprises:
performing unit conversion on the historical measurement data according to a preset weight unit to obtain converted historical measurement data;
grouping the converted historical measurement data according to a preset user measurement data change rule to obtain at least one group of measurement data, wherein one group of measurement data corresponds to one user; the user measurement data change rule comprises: the corresponding relation between the storage time difference of two adjacent historical measurement data and the weight change range;
and respectively matching the measurement data with each group of measurement data, and taking historical measurement data contained in target group measurement data matched with the measurement data as the target historical measurement data.
To achieve the above object, a second aspect of the present application provides a data processing method, including:
a client sends a first broadcast signal, wherein the first broadcast signal at least comprises measurement data of a target user corresponding to the client, and a weight unit corresponding to the measurement data;
if a second broadcast signal fed back by the intelligent scale is received, target historical measurement data carried in the second broadcast signal is stored, the target historical measurement data is historical measurement data which is matched by the intelligent scale based on the measurement data and belongs to the target user, and the second broadcast signal also carries a storage serial number corresponding to the target historical measurement data;
And the client sends a third broadcast signal, wherein the third broadcast signal at least comprises the storage serial number, and the storage serial number is used for indicating the intelligent scale to delete the target historical measurement data corresponding to the storage serial number.
To achieve the above object, a third aspect of the present application provides a data processing apparatus comprising:
a receiving module, configured to receive a first broadcast signal sent by a client, where the first broadcast signal at least includes measurement data of a target user corresponding to the client;
the data sending module is used for carrying a first storage serial number corresponding to the target historical measurement data and the target historical measurement data in a second broadcast signal and feeding back the first storage serial number to the client if the target historical measurement data belonging to the target user exists in the historical measurement data stored by the intelligent scale according to the measurement data of the target user;
and the data deleting module is used for deleting the target historical measurement data corresponding to the second storage sequence number in the historical measurement data by the intelligent scale if a third broadcast signal fed back by the client is received, wherein the third broadcast signal at least comprises the second storage sequence number.
Optionally, the data sending module is specifically configured to: sending the second broadcast signal, wherein the second broadcast signal comprises ith item label historical measurement data and a first storage serial number of the ith item label historical measurement data, the initial value of i is 1, the first storage serial number is i, the ith item label historical measurement data is the data with the earliest storage time point in the target historical measurement data to be sent, i is not more than N, and N is the total number of the target historical measurement data belonging to the target user;
optionally, the data deleting module is specifically configured to, if a third broadcast signal fed back by the client is received, where the third broadcast signal at least includes a second storage sequence number of the historical measurement data stored by the client, delete the target historical measurement data corresponding to the second storage sequence number, set i to i +1, and return to the data sending module.
Optionally, the first broadcast signal and the third broadcast signal are similar signals carrying the same data type; if the client is initially started, or the second broadcast signal is not received, or the target historical measurement data carried in the second broadcast signal is not stored, the second storage sequence number carried in the first broadcast signal is a preset storage sequence number, and the preset storage sequence number is different from the first storage sequence number corresponding to the target historical measurement data.
Optionally, the apparatus further comprises:
the comparison module is used for comparing the second storage sequence number in the third broadcast signal with the first storage sequence number carried by the sent second broadcast signal;
and the triggering module is used for continuously executing the data deleting module when the second storage sequence number in the third broadcast signal is the same as the first storage sequence number carried by the sent second broadcast signal.
Optionally, the method further comprises:
the conversion module is used for performing unit conversion on the historical measurement data according to a preset weight unit to obtain converted historical measurement data;
the grouping module is used for grouping the converted historical measurement data according to a preset user measurement data change rule to obtain at least one group of measurement data, wherein one group of measurement data corresponds to one user; the user measurement data change rule comprises: the corresponding relation between the storage time difference of two adjacent historical measurement data and the weight change range;
and the matching module is used for matching the measurement data with each group of measurement data respectively and taking historical measurement data contained in target group measurement data matched with the measurement data as the target historical measurement data.
To achieve the above object, a fourth aspect of the present application provides a data processing apparatus comprising:
a first sending module, configured to send a first broadcast signal, where the first broadcast signal at least includes measurement data of a target user corresponding to the client;
the storage module is used for storing target historical measurement data carried in a second broadcast signal if the second broadcast signal fed back by the intelligent scale is received, wherein the target historical measurement data is the historical measurement data of the intelligent scale, which belongs to the target user and is determined based on the measurement data, and the second broadcast signal also carries a first storage serial number corresponding to the target historical measurement data;
and the second sending module is used for sending a third broadcast signal, the third broadcast signal at least comprises the first storage serial number, and the first storage serial number is used for indicating the intelligent scale to delete the target historical measurement data corresponding to the first storage serial number.
To achieve the above object, a fifth aspect of the present application provides a computer-readable storage medium storing a computer program, which, when executed by a processor, causes the processor to execute the data processing method of the first aspect or the second aspect.
To achieve the above object, a sixth aspect of the present application provides a computer device, including a memory and a processor, where the memory stores a computer program, and the computer program, when executed by the processor, causes the processor to execute the data processing method of the first aspect or the second aspect.
By adopting the embodiment of the application, the following beneficial effects are achieved:
the application provides a data processing method, a client sends a first broadcast signal, the first broadcast signal at least comprises measurement data of a target user corresponding to the client, after the intelligent scale receives the first broadcast signal, if the target historical measurement data belonging to the target user exists in the historical measurement data stored by the intelligent scale according to the measurement data of the target user in the first broadcast signal, a first storage serial number corresponding to the target historical measurement data and the target historical measurement data is carried in a second broadcast signal and fed back to the client, and after a third broadcast signal fed back by the client is received, the target historical measurement data corresponding to a second storage serial number carried in the third broadcast signal is deleted, so that accurate transmission of the target historical measurement data between the intelligent scale and the client can be effectively realized, and the transmission process is simple, the probability of errors in the transmission process of the target historical measurement data can be effectively reduced, and the target historical measurement data corresponding to the second storage sequence number carried by the third broadcast signal can be deleted after the third broadcast signal is received, so that the target historical measurement data can be deleted after being stored, and mistaken deletion can be effectively avoided.
Drawings
In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, it is obvious that the drawings in the following description are only some embodiments of the present application, and for those skilled in the art, other drawings can be obtained according to the drawings without creative efforts.
Wherein:
FIG. 1 is a schematic flow chart of a data processing method according to an embodiment of the present application;
FIG. 2a is a schematic diagram illustrating a state change relationship of a smart scale according to an embodiment of the present application;
FIG. 2b is another schematic diagram of a state change relationship of a smart scale in an embodiment of the present application;
FIG. 3 is a schematic diagram illustrating an interaction flow of a data processing method according to an embodiment of the present application;
FIG. 4 is a schematic flow chart illustrating a data processing method according to an embodiment of the present application;
FIG. 5 is a schematic structural diagram of a data processing apparatus according to an embodiment of the present application;
FIG. 6 is a schematic diagram of another embodiment of a data processing apparatus;
fig. 7 is a block diagram of a computer device according to an embodiment of the present application.
Detailed Description
The technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it is obvious that the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present application.
The data processing method is applied to a scene that data transmission is carried out between the client and the intelligent scale, the client can be an intelligent terminal such as a smart phone, a tablet personal computer and the like provided with an application program, the broadcasting function of the client can be started when the application program is started, and the intelligent scale also has the broadcasting function. The broadcast function described herein may include, but is not limited to, broadcast using wireless technologies such as bluetooth broadcast, wireless fidelity (WIFI) broadcast, and the like. In general, the smart scale may include, but is not limited to, a smart weight scale, a smart body fat scale, a smart child scale, or a smart heart rate scale, so as to respectively and correspondingly detect corresponding human body physical parameters, such as weight, body fat, heart rate, child health growth indicators, or health diet indicators. This intelligent scale can realize the data broadcast transmission mode with this customer end looks adaptation through wireless transmission technology, will detect the measured data broadcast that acquires to this customer to carry out prompt information such as voice broadcast, light or screen display and give the user.
Please refer to fig. 1, which is a schematic flow chart of a data processing method according to an embodiment of the present application, the method including:
step 101, receiving a first broadcast signal sent by a client, wherein the first broadcast signal at least comprises measurement data of a target user corresponding to the client;
In the embodiment of the application, after the intelligent scale is started, a broadcast signal may be sent, and after the intelligent scale is started, a client may also send the broadcast signal, if the intelligent scale and the client can receive broadcast signals of each other, it indicates that the intelligent scale and the client can detect each other, and data interaction may be performed based on the broadcast signal without establishing a connection. Wherein the broadcast signal may be a bluetooth broadcast signal, wifi broadcast, or the like.
Wherein, if under the unable circumstances that detects each other at intelligent scale and customer end, the user uses intelligent scale to measure, then this measured data will not be sent to the customer end, and this measured data will be preserved to intelligent scale to as the historical measured data of intelligent scale, this historical measured data include but not limited to: the point in time at which this historical measurement data was generated, the measured weight data, the weight units used in the measurement, the measured fat rate, muscle proportion and moisture, etc.
In the embodiment of the application, the client and the user have a corresponding relationship, and the user can log in the client by using the registered account and the password, so that the measurement data of the user can be recorded by the client.
After the client is started, a first broadcast signal is sent at preset time intervals, and the first broadcast signal at least comprises measurement data of a target user corresponding to the client.
When the intelligent scale and the client can detect each other, the intelligent scale can receive a first broadcast signal sent by the client and acquire the measurement data of the target user from the first broadcast signal, so that whether historical measurement data belonging to the target user exists can be further determined on the intelligent scale side.
And 102, if the target historical measurement data belonging to the target user exist in the historical measurement data stored by the intelligent scale according to the measurement data of the target user, carrying a first storage sequence number corresponding to the target historical measurement data and the target historical measurement data in a second broadcast signal, and feeding back the second storage sequence number to the client.
Step 103, if a third broadcast signal fed back by the client is received, where the third broadcast signal at least includes a second storage serial number, and the smart scale deletes, in the historical measurement data, the target historical measurement data corresponding to the second storage serial number.
In the embodiment of the application, the smart scale may determine whether target historical measurement data belonging to a target user exists in historical measurement data stored by the smart scale according to measurement data of the target user, and if so, determine that transmission of the target historical measurement data is required, and may carry a first storage sequence number corresponding to the target historical measurement data and the target historical measurement data in a second broadcast signal to feed back to the client. The first storage sequence number is used to identify the target historical measurement data, and it can be understood that the first storage sequence numbers of different target historical measurement data are different.
After receiving the second broadcast signal of the intelligent scale, the client stores the target historical measurement data carried in the second broadcast signal, and further, the target historical measurement data can be used for updating the measurement data of the target user, and the updated result is displayed, so that the target user can know the measurement data of the target user more clearly.
And furthermore, after the client stores the target historical measurement data, the client will continue to send a third broadcast signal, the third broadcast signal at least comprises a second storage serial number, the second storage serial number is a first storage serial number corresponding to the historical target measurement data stored by the client, and after the intelligent scale receives the third broadcast signal, the target historical measurement data corresponding to the second storage serial number is deleted from the historical measurement data, so that the client can delete the target historical measurement data after storing one piece of target historical measurement data by the intelligent scale in a mode of transmitting the storage serial numbers between the intelligent scale and the client, and the like can be effectively avoided. It can be understood that the first storage sequence number is a storage sequence number described from the smart scale side, the second storage sequence number is a storage sequence number described from the client side, the first storage sequence number is an identifier of target historical measurement data in the second broadcast signal, and the second storage sequence number is an identifier of target historical measurement data in the second broadcast signal.
In the embodiment of the application, a client sends a first broadcast signal, the first broadcast signal at least includes measurement data of a target user corresponding to the client, after the smart scale receives the first broadcast signal, if it is determined that target historical measurement data belonging to the target user exists in the historical measurement data stored by the smart scale according to the measurement data of the target user in the first broadcast signal, a first storage serial number corresponding to the target historical measurement data and the target historical measurement data is carried in a second broadcast signal and fed back to the client, and after a third broadcast signal fed back by the client is received, the target historical measurement data corresponding to a second storage serial number carried in the third broadcast signal is deleted, so that accurate transmission of the target historical measurement data between the smart scale and the client can be effectively realized, and the transmission process is simple, the probability of errors in the transmission process of the target historical measurement data can be effectively reduced, and the target historical measurement data corresponding to the second storage sequence number carried by the third broadcast signal can be deleted after the third broadcast signal is received, so that the target historical measurement data can be deleted after being stored, and mistaken deletion can be effectively avoided.
For better understanding of the technical solution in the embodiment of the present application, please refer to fig. 3, which is a schematic diagram of an interaction flow of a data processing method in the embodiment of the present application, including:
step 301, a client sends a first broadcast signal, where the first broadcast signal at least includes measurement data of a target user corresponding to the client;
step 302, if a first broadcast signal sent by a client is received, acquiring measurement data of a target user;
it can be understood that the content in step 301 and step 302 is similar to the content related to step 101 in the embodiment shown in fig. 1, and specifically, the content in the embodiment shown in fig. 1 may be referred to, and is not described herein again.
Step 303, the intelligent scale matches the measurement data with historical measurement data stored by the intelligent scale to determine whether the historical measurement data contains target historical measurement data belonging to a target user;
in one possible implementation, the smart scale may select from the measurement data type with the smallest amount of change in the same time period under normal conditions to perform matching. Taking the weight data in the measurement data as an example, first body weight data in the measurement data of the target user can be acquired, the weight data is matched with second body weight data in historical measurement data stored by the intelligent scale, if the difference value between the first body weight data and the second body weight data is within a preset weight range, the historical measurement data is determined to be the target historical measurement data of the target user, and through the matching mode, which historical measurement data stored by the intelligent scale belong to the target historical measurement data of the target user can be effectively determined. The preset weight range can be set according to needs, and can be [ -3kg, 3kg ], for example.
In another possible implementation manner, the similarity between the overall measurement data and the target measurement data may be calculated according to a plurality of data types included in the historical measurement data to determine whether the target historical measurement data belonging to the target user exists (for example, if the measurement data includes weight and fat rate, whether the deviation of the weight falls within a preset weight range and the deviation of the fat rate falls within a preset fat rate range are calculated respectively); if the similarity is greater than the similarity threshold, the target historical measurement data belongs to the target user (for example, the deviation of the weight and the deviation of the fat rate both belong to a preset range), otherwise, the target historical measurement data does not belong to the target user. The scheme for calculating the similarity between data is not limited in the present application.
In another possible implementation, considering that a smart scale may be used by multiple persons, the smart scale may select the measurement data type with the smallest variation in the same period of time to perform matching. Taking the weight data in the measurement data as an example, in order to realize more accurate matching, the matching process can be realized according to the following steps:
A. Performing unit conversion on the historical measurement data according to a preset weight unit to obtain converted historical measurement data; optionally, the preset weight unit is carried in the first broadcast signal.
B. Grouping the converted historical measurement data according to a preset user measurement data change rule to obtain at least one group of measurement data, wherein one group of measurement data corresponds to one user; the user measurement data change rule comprises the following steps: the corresponding relation between the storage time difference of two adjacent historical measurement data and the weight change range;
C. and respectively matching the measurement data with each group of measurement data, and taking historical measurement data contained in target group measurement data matched with the measurement data as target historical measurement data.
In this embodiment, the matching process may be implemented by using weight data in the measurement data, where the weight data includes weight units, and the weight units include multiple types, such as kilograms, catties, etc., in order to improve the matching accuracy, it is necessary to convert the historical measurement data into converted historical measurement data according to a preset weight unit, and specifically, it may be determined whether the weight unit in the historical measurement data is the same as the weight unit in the measurement data of the target user in the first broadcast signal, if so, conversion is not needed, and if not, conversion is performed based on the weight unit in the measurement data of the target user, for example, if the weight unit of the target user included in the first broadcast signal is kilograms and the weight unit used in the weight data in the historical measurement data is catties, the weight data in the historical measurement data is converted into data in kilograms of body weight.
Presetting a user measurement data change rule, wherein the user measurement data change rule comprises the following steps: the corresponding relationship between the preservation time difference of two adjacent historical measurement data and the weight change range can be set based on the weight change that the user may generate in the healthy weight reduction/fat increase situation, for example, if the normal person decreases or increases the weight by 1 jin at most in one day, the weight change range corresponding to the preservation time difference of 1 day can be set as [ -1, 1] in the user measurement data change rule, and if the normal person decreases or increases the weight by 5 jin at most in one week, the weight change range corresponding to the preservation time difference of 7 days can be set as [ -5, 5] in the user measurement data change rule. Furthermore, the storage time difference is also a range, so the correspondence relationship between the storage time difference and the weight change range may be a correspondence relationship between a time range and a weight change range, for example, the time difference range is [0, 1], and the corresponding weight change range is [ -1, 1], that is, when the storage time difference of two pieces of temporally adjacent historical measurement data is within one day, the weight change of the user is [ -1, 1 ]. Wherein the time difference range may be continuous.
In this embodiment of the present application, the converted historical measurement data are grouped according to the above-mentioned user measurement data change rule to obtain at least one group of data, where a group of measurement data corresponds to a user, specifically, the historical measurement data in the intelligent scale are sorted sequentially according to their storage time, traversal may be performed from the historical measurement data whose storage time is the second earliest, a time difference and a weight difference between the historical measurement data and the previous historical measurement data are determined, then the user measurement data change rule is searched based on the time difference, a weight change range corresponding to the time difference is determined, whether the weight difference is within the weight change range is determined, if the weight difference is within the weight change range, it is determined that the historical measurement data and the previous historical measurement data belong to the same user, and then the historical measurement data and the previous historical measurement data may be marked as belonging to the same group, and the group number is set, if the group number is not in the range, the historical measurement data and the previous historical measurement data are respectively grouped, and different group numbers are respectively set.
Furthermore, the measurement data of the target user may be respectively matched with each set of measurement data, and the historical measurement data included in the target set of measurement data matched with the measurement data may be used as the target historical measurement data, that is, the historical measurement data belonging to the target user. Specifically, the weight data in each group of measurement data may be averaged, and if the average value is compared with the weight data in the measurement data of the target user, if the difference value is within a preset threshold range, matching is determined, and if the difference value exceeds the preset threshold range, mismatching is determined.
Further, if the smart scale generates new historical measurement data, the historical measurement data can be used for matching with the last historical measurement data in the historical measurement data of each group, and if the weight data in the new historical measurement data is matched with the weight data in the last historical measurement data of a certain group, the group can be determined to belong to the group.
Step 304, the intelligent scale sends a second broadcast signal, wherein the second broadcast signal comprises ith item label historical measurement data and a first storage serial number of the ith item label historical measurement data;
step 305, the client saves the target historical measurement data in the second broadcast signal;
Step 306, the client sends a third broadcast signal, wherein the third broadcast signal at least comprises a first storage serial number;
and 307, after the intelligent scale receives the third broadcast signal, deleting the target historical measurement data corresponding to the first storage serial number.
In the embodiment of the application, when the smart scale transmits the target historical measurement data to the client, in order to make sure which item is marked with the historical measurement data, the smart scale may use the first storage serial number to identify, so as to achieve accurate transmission of the target historical measurement data without sending the target historical measurement data mistakenly or without sending the target historical measurement data. And the storage sequence numbers corresponding to the historical measurement data of each target are different.
Optionally, the smart scale may send one piece of target historical measurement data, that is, send the next piece of target historical measurement data after the sending of one piece of target historical measurement data is completed, so that the transmission of 36 bytes of data is supported at most mainly in consideration of the data limitation of the second broadcast signal, and generally, the size of one piece of target historical measurement data may be controlled within 36 bytes, and one piece of target historical measurement data sending mode may also avoid the occurrence of confusion and incompleteness of data sending. In a possible implementation manner, the condition that the smart scale can send the next second bluetooth broadcast is that the third bluetooth broadcast corresponding to the storage sequence number in the previous second bluetooth broadcast is received, and the target historical measurement data corresponding to the storage sequence number is deleted. In another possible implementation manner, the condition that the smart scale may send the next second bluetooth broadcast is that the previous second bluetooth broadcast is continuously sent for a preset duration or continuously sent for a preset number of times. Correspondingly, the condition that the client sends the next third bluetooth broadcast is as follows: a second bluetooth broadcast of a new stored sequence number is received. In another possible implementation manner, the condition for the client to send the next third bluetooth broadcast is: and receiving the second Bluetooth broadcast of the new storage sequence number and continuously transmitting the third Bluetooth broadcast for a preset time or continuously transmitting for a preset number of times. The above mode can further ensure the accuracy of data transmission.
In the embodiment of the application, for a set of measurement data, the intelligent scale determines that data with the earliest storage time point in the set of measurement data is used as ith item marked historical measurement data, and sets a first storage serial number of the item marked historical measurement data as i, wherein the initial value of i is 1, the maximum value of i is the total number N of target historical measurement data contained in the matched set of measurement data, and i is not more than N.
The intelligent scale sends a second broadcast signal, and the second broadcast signal comprises the ith item label historical measurement data and a first storage serial number thereof.
After receiving the second broadcast signal, the client saves the ith historical measurement data in the second broadcast signal, acquires the first storage sequence number in the second broadcast signal as a second storage sequence number, and when a third broadcast signal is sent next time, the third broadcast signal at least comprises the second storage sequence number of the ith historical measurement data which is stored recently so as to inform the intelligent scale which receives the third broadcast signal, and the historical measurement data with the second storage sequence number i is transmitted last time.
After receiving the third broadcast signal, the intelligent scale compares a second storage serial number in the third broadcast signal with the first storage serial number carried by the sent second broadcast signal, and if the second storage serial number in the third broadcast signal is the same as the first storage serial number carried by the sent second broadcast signal, the target historical measurement data corresponding to the second storage serial number is deleted. Considering that the smart scale is a piece of transmission target historical measurement data, the first storage serial number may be a first storage serial number in the second broadcast signal transmitted last time.
Through the method, the intelligent scale completes transmission of the target historical measurement data, and the transmission mode is that after the intelligent scale sends the target historical measurement data and the first storage serial number, the intelligent scale receives the storage serial number sent by the client again, so that the fact that the transmission of the target historical measurement data is completed is indicated, the target historical measurement data can be deleted, accurate sending of the target historical measurement data of the intelligent scale is achieved, data is not mistakenly sent, the intelligent scale determines that the target historical measurement data is deleted after being stored by the client, and the fact that the historical measurement data is not mistakenly deleted is achieved.
It should be understood that, in the above description, when N is equal to 1, that is, when there is only one piece of target historical measurement data, the smart scale transmits the target historical measurement data, and if N is greater than 1, for the other pieces of target historical measurement data that are not transmitted, i is equal to i +1, and the process returns to step 304 until all the N pieces of target historical measurement data are transmitted.
It should be noted that the data packet formats of the first broadcast signal and the third broadcast signal sent by the client may be the same, so that the first broadcast signal and the third broadcast signal are the same type of signal carrying the same data type, for example, both include measurement data of a target user corresponding to the client and a second storage sequence number corresponding to the measurement data, where the second storage sequence number is 0, the second storage sequence number may be the first broadcast signal, and if the second storage sequence number is not 0, the second storage sequence number may be the third broadcast signal. Specifically, for the client, if the client is initially started, or does not receive the second broadcast signal, or does not store the target historical measurement data carried in the second broadcast signal, the second storage sequence number carried in the first broadcast signal is a preset storage sequence number, for example, may be 0, where the preset storage sequence number is different from the first storage sequence number corresponding to the target historical measurement data. That is, for the smart scale, if the storage serial number included in the received broadcast signal is 0, the above step 302 may be executed, and a process of determining whether there is target historical measurement data belonging to a target user is entered, if the storage serial number included in the received broadcast signal is not 0, it indicates that the target historical measurement data may be continuously transmitted based on the storage serial number until it is determined that there is no target historical measurement data to be transmitted, and for the client, the data packet formats of the first broadcast signal and the third broadcast signal are the same, so that the client may not need to determine what type of broadcast signal is transmitted under what condition, but may transmit broadcast signals of a uniform data format to implement different interaction flows, may simplify the execution logic of the client, and is easy to implement, and may not generate an error transmission.
In addition, the first broadcast signal and the third broadcast signal may further include a current timestamp, so that each time the smart scale receives the first broadcast signal and the third broadcast signal, the time may be updated with the current timestamp. Further, the smart scale may also set a local weight unit based on the weight units in the first broadcast signal and the third broadcast signal.
It should be noted that, the format of the broadcast signal sent by the smart scale is set to be a uniform format, and the format of the broadcast signal sent by the client is also set to be a uniform format, in the embodiment of the present application, a function of performing data interaction is added on the basis of the detection device, and in order to enable data interaction, the format of the broadcast signal is set to be a format containing data that may need to be used in a data interaction process, and further, by setting a status code in the broadcast signal data of the smart scale, the client can determine the current state of the smart scale and actions that the client needs to execute through the status code, and by setting a storage serial number in the broadcast signal data of the client, the smart scale can determine actions that the client needs to execute based on the storage serial number, so that in the case that no response mechanism exists, the method and the system have the advantages that the accurate data interaction process between the client and the intelligent scale is realized, especially the transmission of target historical measurement data can be realized, and the wrong transmission and the missing transmission can be avoided on the basis of simple interaction.
In the embodiment of the present application, the smart scale and the client may transmit the target historical measurement data under a preset condition, and for better understanding, please refer to the following description.
After the intelligent scale is started, the intelligent scale comprises three states, namely an idle state, a real-time data transmission state and a historical data transmission state.
In a feasible implementation manner, the idle state refers to a state in which the smart scale is in a working state, but a user does not use the smart scale to perform measurement and measurement data is not generated, wherein the working state refers to a state in which the smart scale is powered on; the real-time data transmission state refers to a state that the intelligent scale is in a working state, and when the intelligent scale can be mutually detected with the client, if a user uses the intelligent scale to measure and generate measurement data, the intelligent scale can transmit the measurement data with the client in real time; the transmission state of the historical data needs to be judged whether the transmission requirement of the historical measurement data exists or not by the intelligent scale in an idle state, if the historical measurement data needs to be transmitted, the intelligent scale enters a historical data transmission state from the idle state, and if the historical measurement data does not need to be transmitted, the intelligent scale is in the idle state. For better understanding of the three states of the smart scale in this implementation, please refer to fig. 2a, which is a schematic diagram illustrating the switching relationship between the three states of the smart scale. The idle state and the real-time data transmission state can be switched with each other, the idle state and the historical data transmission state can be switched with each other, and the historical data transmission state can be switched to the real-time data transmission state.
Taking the state of fig. 2a as an example, under the condition that the application program of the client is already started, the client may send the first broadcast signal at preset intervals, at this time, if the user steps on the smart scale, the smart scale is powered on to enter a working state, and the smart scale may perform a corresponding operation according to the current state.
Specifically, after the intelligent scale enters the working state, the intelligent scale collects measurement data to determine whether a user uses the intelligent scale to measure, and if the measurement data collected by the intelligent scale is smaller than a preset data threshold, it is determined that the user does not use the intelligent scale, and the intelligent scale is in an idle state.
When the smart scale is in the idle state, the smart scale sends a broadcast signal, where the broadcast signal includes a state code used to identify the state where the smart scale is located, for example, the state code in the idle state may be 0, so that after receiving the broadcast signal, the client may determine that the state where the smart scale is located is the idle state based on the state code included in the broadcast signal, and the broadcast signal does not have measurement data that needs to be stored.
The intelligent scale is in an idle state, the acquired measurement data are continuously acquired, if the acquired measurement data are larger than or equal to a preset data threshold value, it is indicated that a user uses the intelligent scale, at the moment, the intelligent scale is switched to a real-time data transmission state, the acquired real-time measurement data and a state code of the real-time data transmission state are carried in a broadcast signal by the intelligent scale and sent, after the client receives the broadcast signal, the client can determine that the intelligent scale is currently in the real-time data transmission state according to the state code, the real-time measurement data need to be stored, and the client stores the real-time measurement data carried in the broadcast signal, so that the intelligent scale can transmit the real-time measurement data of the user in the real-time data transmission state. Wherein, the status code of the real-time data transmission status may be 1.
And the intelligent scale also continuously compares the acquired measurement data with a preset data threshold value in the real-time data transmission state, if the acquired measurement data is greater than or equal to the preset data threshold value, the real-time data transmission state is maintained, the real-time measurement data is transmitted, if the acquired measurement data is less than the preset data threshold value, the user is indicated to leave the intelligent scale, and at the moment, the intelligent scale is switched to the idle state.
Further, when the smart scale is in an idle state and receives the first broadcast signal, it is determined whether target historical measurement data belonging to a target user in the first broadcast signal exists in the stored historical measurement data, and if the target historical measurement data exists, the smart scale switches from the idle state to a historical data transmission state so as to transmit the target historical measurement data, where a process of transmitting the target historical measurement data of the target user between the smart scale and the client may refer to the contents in the foregoing method embodiment, which is not described herein again.
When the intelligent scale is in a historical data transmission state, the acquired measurement data is monitored in real time, if the acquired measurement data is smaller than a preset data threshold value, the intelligent scale is kept in the historical data transmission state, and a second broadcast signal carrying target historical measurement data of a target user and a state code of the historical data transmission state is sent, wherein the state code of the historical data transmission state can be 2, for example. After receiving the second broadcast signal, the client determines that the intelligent scale is in a historical data transmission state based on the state code, determines that target historical measurement data needs to be stored, and stores the target historical measurement data in the second broadcast signal.
When the intelligent scale is in a historical data transmission state, if the acquired measurement data are greater than or equal to a preset data threshold value, it is indicated that the user is using the intelligent scale at the moment, the transmission of the target historical measurement data is stopped, and the intelligent scale is switched to a real-time data transmission state.
In another feasible implementation manner, the idle state refers to a state in which the smart scale is in a working state, but a user does not use the smart scale to perform measurement and measurement data is not generated, and no historical measurement data needs to be transmitted; the real-time data transmission state refers to a state that the intelligent scale is in a working state, and when the intelligent scale and the client can mutually detect, if a user uses the intelligent scale to measure and generate measurement data, the intelligent scale can transmit the measurement data to the client in real time; the historical data transmission state refers to a state when the intelligent scale is in a working state, but a user does not use the intelligent scale to measure and does not generate measurement data, and the historical measurement data needing to be transmitted exist. For better understanding of the three states of the smart scale in this implementation, please refer to fig. 2b, which is a schematic diagram illustrating the switching relationship between the three states of the smart scale. The idle state and the real-time data transmission state can be switched with each other, the real-time data transmission state and the historical data transmission state can be switched with each other, and the historical data transmission state can be switched to the idle state.
Taking the state of fig. 2b as an example, under the condition that the application program of the client is already started, the client may send the first broadcast signal at preset intervals, at this time, if the user steps on the smart scale, the smart scale is powered on to enter a working state, and the smart scale may perform a corresponding operation according to the current state.
Specifically, after the intelligent scale enters the working state, whether a user uses the intelligent scale for measurement is determined, if the measurement data collected by the intelligent scale is smaller than a preset data threshold value, it is determined that no user uses the intelligent scale, the intelligent scale receives the first broadcast signal, and it is determined that no historical measurement data of the target user exists, and the intelligent scale enters the idle state. If the measured data collected by the intelligent scale is larger than or equal to the preset data threshold value, the situation that a user uses the intelligent scale at the moment is indicated, and the intelligent scale enters a real-time data transmission state.
When the smart scale is in the idle state, a broadcast signal is sent, where the broadcast signal includes a status code for identifying the state where the smart scale is located, for example, the status code of the idle state may be 0, so that after receiving the broadcast signal, the client may determine that the smart scale is in the idle state based on the status code in the broadcast signal. And when the client determines that the intelligent scale is in an idle state, the client can determine that the intelligent scale does not have target historical measurement data required to be transmitted.
The intelligent scale is in an idle state, acquired measurement data are monitored, if the acquired measurement data are larger than or equal to a preset data threshold value, it is indicated that a user uses the intelligent scale, the intelligent scale is switched to a real-time data transmission state at the moment, the acquired real-time measurement data and a state code of the real-time data transmission state are carried in a broadcast signal by the intelligent scale and sent, and after a client receives the broadcast signal, the client can determine that the intelligent scale is in the real-time data transmission state at present according to the state code and store the real-time measurement data carried in the broadcast signal, so that the intelligent scale can transmit the real-time measurement data of the user in the real-time data transmission state, wherein the state code of the real-time data transmission state can be 1.
The intelligent scale further monitors the acquired measurement data in the real-time data transmission state, if the acquired measurement data is greater than or equal to a preset data threshold, the real-time data transmission state is maintained, and the real-time measurement data is transmitted, and if the acquired measurement data is less than the preset data threshold, the user is indicated to leave the intelligent scale, at this time, the intelligent scale further determines whether the target historical measurement data of the target user exists, and if the target historical measurement data of the target user exists, the intelligent scale is switched to the historical data transmission state so as to transmit the target historical measurement data.
When the intelligent scale is in the historical data transmission state, the intelligent scale also continues to monitor the acquired measurement data, and if the acquired measurement data is smaller than a preset data threshold, the intelligent scale is kept in the historical data transmission state and sends a broadcast signal carrying the target historical measurement data of the target user and a status code of the historical data transmission state, for example, the status code of the historical data transmission state may be 2. After receiving the broadcast signal, the client determines that the intelligent scale is in a historical data transmission state based on the state code, and saves the target historical measurement data in the broadcast signal. It should be noted that, the process of transmitting the target historical measurement data between the client and the smart scale may refer to the contents in the foregoing embodiment, which is not described herein again.
When the intelligent scale is in a historical data transmission state, if the acquired measurement data are greater than or equal to a preset data threshold value, it is indicated that the user is using the intelligent scale at the moment, the intelligent scale stops the transmission of the target historical measurement data, and the intelligent scale is switched to a real-time data transmission state.
In addition, when the intelligent scale is in a historical data transmission state, if the transmission of the historical target data of the target user is completed, and the acquired measurement data is smaller than a preset data threshold value, namely, no user uses the intelligent scale, the intelligent scale is switched to an idle state.
It should be noted that, when the intelligent scale is in an idle state or a real-time data transmission state, the transmitted broadcast signal includes a preset storage serial number, and the preset storage serial number may be 0.
It should be noted that the measurement data may specifically use a weight value included in the measurement data, and the preset data threshold may be 5kg, that is, if the weight value included in the measurement data is less than 5kg, it indicates that no user uses the smart scale, and if the weight value included in the measurement data is greater than or equal to 5kg, it indicates that a user uses the smart scale.
It should be noted that, under the condition that the intelligent scale is in the historical data transmission state, if the historical transmission data transmission is completed and no user uses the intelligent scale, the intelligent scale is adjusted to be in the idle state; if the intelligent scale is used by a user in the process of transmitting the historical data, the intelligent scale is adjusted to be in a real-time data transmission state. It should be noted that, when the smart scale is in the real-time data transmission state, if the determination condition that the user uses the smart scale is not satisfied, the smart scale is adjusted to the historical data transmission state or the idle state according to whether the current smart scale has historical transmission data. In addition, when the smart scale is in the idle state, the smart scale is adjusted to the real-time data transmission state once a user uses the smart scale.
Further, with reference to the different states of fig. 2a and fig. 2b, when the smart scale is in different states, the format of the broadcast signal sent by the smart scale is also the same, and the broadcast signal includes the status code, the measurement data and the first storage serial number, for example, if the smart scale is in an idle state, the smart scale sends a broadcast signal with the status code of 0, the measurement data of 0 and the first storage serial number of 0, and after receiving the broadcast signal, when the client reads the status code and determines that the status code is 0, the client indicates that the broadcast signal does not perform data transmission. If the intelligent scale is in a real-time data transmission state, the state code sent by the intelligent scale is 1, the measured data is a broadcast signal with a real-time generated value and a first storage serial number of 0, and after the client receives the broadcast signal and reads the state code to determine that the state code is 1, the client indicates that the measured data currently transmitted by the intelligent scale is real-time data. If the intelligent scale is in a historical data transmission state, the state code sent by the intelligent scale is 2, and the target historical measurement data and the first storage serial number of the target historical measurement data are determined, after the client receives the broadcast signal and reads the state code to determine that the state code is 2, the client indicates that the intelligent scale currently transmits the target historical measurement data of the target user, the target historical measurement data are stored, the first storage serial number is used for updating the second storage serial number, and a third broadcast signal is continuously sent.
Please refer to fig. 4, which is another schematic flow chart of a data processing method according to an embodiment of the present application, the method includes:
step 401, a client sends a first broadcast signal, where the first broadcast signal at least includes measurement data of a target user corresponding to the client;
step 402, if a second broadcast signal fed back by the intelligent scale is received, storing target historical measurement data carried in the second broadcast signal, wherein the target historical measurement data is historical measurement data which is matched by the intelligent scale based on the measurement data and belongs to a target user;
and step 403, the client sends a third broadcast signal, where the third broadcast signal at least includes the storage serial number, and the storage serial number is used to instruct the smart scale to delete the target historical measurement data corresponding to the storage serial number.
It should be noted that, the content in the embodiment shown in fig. 4 has been described in detail in the foregoing embodiment, and may specifically refer to the content described in the foregoing embodiment, which is not described herein again.
In the embodiment of the application, a client sends a first broadcast signal, the first broadcast signal at least includes measurement data of a target user corresponding to the client, after the smart scale receives the first broadcast signal, if it is determined that target historical measurement data belonging to the target user exists in historical measurement data stored by the smart scale according to the measurement data of the target user in the first broadcast signal, a first storage serial number corresponding to the target historical measurement data and the target historical measurement data is carried in a second broadcast signal and fed back to the client, and after a third broadcast signal fed back by the client is received, the target historical measurement data corresponding to a second storage serial number carried in the third broadcast signal is deleted, so that accurate transmission of the target historical measurement data between the smart scale and the client can be effectively realized, and the transmission process is simple, the probability of errors in the transmission process of the target historical measurement data can be effectively reduced, and the target historical measurement data corresponding to the second storage sequence number carried by the third broadcast signal can be deleted after the target historical measurement data is stored, so that the mistaken deletion is effectively avoided.
Please refer to fig. 5, which is a schematic structural diagram of a data processing apparatus in an embodiment of the present application, the apparatus including:
a receiving module 501, configured to receive a first broadcast signal sent by a client, where the first broadcast signal at least includes measurement data of a target user corresponding to the client;
a data sending module 502, configured to, if it is determined that there is target historical measurement data belonging to the target user in the historical measurement data stored in the smart scale according to the measurement data of the target user, carry a first storage sequence number corresponding to the target historical measurement data and the target historical measurement data in a second broadcast signal, and feed back the second storage sequence number to the client;
the data deleting module 503 is configured to delete the target historical measurement data corresponding to the second storage sequence number from the historical measurement data if a third broadcast signal fed back by the client is received, where the third broadcast signal at least includes the second storage sequence number.
It should be noted that, the contents of the relevant modules of the data processing apparatus have been described in the foregoing embodiments, and specific reference may be made to the contents in the foregoing embodiments, which are not described herein again.
The data processing device may be a program module in the smart scale, and the processor in the smart scale may call the data processing device stored in the storage medium to implement the data processing method on the smart scale side.
Please refer to fig. 6, which is a schematic structural diagram of a data processing apparatus according to an embodiment of the present application, the apparatus including:
a first sending module 601, configured to send a first broadcast signal, where the first broadcast signal at least includes measurement data of a target user corresponding to the client;
a saving module 602, configured to, if a second broadcast signal fed back by an intelligent scale is received, save target historical measurement data carried in the second broadcast signal, where the target historical measurement data is historical measurement data of the intelligent scale that belongs to the target user and is determined based on the measurement data, and the second broadcast signal also carries a first storage serial number corresponding to the target historical measurement data;
a second sending module 603, configured to send a third broadcast signal, where the third broadcast signal at least includes the first storage sequence number, and the first storage sequence number is used to instruct the smart scale to delete the target historical measurement data corresponding to the first storage sequence number.
It should be noted that, the contents of the relevant modules of the data processing apparatus have been described in the foregoing embodiments, and specific reference may be made to the contents in the foregoing embodiments, which are not described herein again.
The data processing device may be a program module in a client, and a processor in the client may call the data processing device stored in a storage medium to implement the data processing method on the client side.
In the embodiment of the application, the client sends a first broadcast signal, the first broadcast signal at least comprises measurement data of a target user corresponding to the client, the smart scale can determine whether target historical measurement data belonging to the target user exists based on the measurement data of the target user sent by the client and stored historical measurement data, and sends the target historical measurement data and a first storage serial number thereof only when the target historical measurement data of the target user exists, so that accurate transmission of the target historical measurement data between the smart scale and the client can be effectively realized, the transmission process is simple, the probability of error in the transmission process of the target historical measurement data can be effectively reduced, and after the target historical measurement data is stored by the client, the client sends a third broadcast signal comprising a second storage serial number, so that the smart scale can delete the target historical measurement data corresponding to the second storage serial number, the data can be deleted after the data transmission is determined to be completed, and the mistaken deletion is avoided.
FIG. 7 is a diagram that illustrates an internal structure of the computer device in one embodiment. The computer device may particularly be a smart device, such as a smart scale, or a client. As shown in fig. 7, the computer device includes a processor, a memory, and a network interface connected by a system bus. Wherein the memory includes a non-volatile storage medium and an internal memory. The non-volatile storage medium of the computer device stores an operating system and may also store a computer program, which, when executed by the processor, causes the processor to carry out the steps of the above-described method embodiments. The internal memory may also store a computer program, which, when executed by the processor, causes the processor to perform the steps of the above-described method embodiments. Those skilled in the art will appreciate that the architecture shown in fig. 7 is merely a block diagram of some of the structures associated with the disclosed aspects and is not intended to limit the computing devices to which the disclosed aspects apply, as particular computing devices may include more or less components than those shown, or may combine certain components, or have a different arrangement of components.
In an embodiment, a computer device is proposed, comprising a memory and a processor, the memory storing a computer program, which, when executed by the processor, causes the processor to perform the steps in the embodiments of fig. 1 to 3 or in the embodiment of fig. 4 described above.
In an embodiment, a computer-readable storage medium is proposed, in which a computer program is stored, which, when executed by a processor, causes the processor to perform the steps in the embodiments of fig. 1 to 3 described above, or in the embodiment of fig. 4.
It will be understood by those skilled in the art that all or part of the processes of the methods of the embodiments described above may be implemented by a computer program, which may be stored in a non-volatile computer readable storage medium, and when executed, may include the processes of the embodiments of the methods described above. Any reference to memory, storage, database or other medium used in the embodiments provided herein can include non-volatile and/or volatile memory. Non-volatile memory can include read-only memory (ROM), Programmable ROM (PROM), Electrically Programmable ROM (EPROM), Electrically Erasable Programmable ROM (EEPROM), or flash memory. Volatile memory can include Random Access Memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms such as Static RAM (SRAM), Dynamic RAM (DRAM), Synchronous DRAM (SDRAM), Double Data Rate SDRAM (DDRSDRAM), Enhanced SDRAM (ESDRAM), Synchronous Link DRAM (SLDRAM), Rambus Direct RAM (RDRAM), direct bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
All possible combinations of the technical features in the above embodiments may not be described for the sake of brevity, but should be considered as being within the scope of the present disclosure as long as there is no contradiction between the combinations of the technical features.
The above-mentioned embodiments only express several embodiments of the present application, and the description thereof is specific and detailed, but not construed as limiting the scope of the present application. It should be noted that, for a person skilled in the art, several variations and modifications can be made without departing from the concept of the present application, and these are all within the scope of protection of the present application. Therefore, the protection scope of the present patent application shall be subject to the appended claims.

Claims (10)

1. A method of data processing, the method comprising:
the method comprises the steps that an intelligent scale receives a first broadcast signal sent by a client, wherein the first broadcast signal at least comprises measurement data of a target user corresponding to the client;
if the target historical measurement data belonging to the target user exists in the historical measurement data stored by the intelligent scale according to the measurement data of the target user, carrying a first storage serial number corresponding to the target historical measurement data and the target historical measurement data in a second broadcast signal and feeding back the second storage serial number to the client;
And if a third broadcast signal fed back by the client is received, wherein the third broadcast signal at least comprises a second storage serial number, and the intelligent scale deletes the target historical measurement data corresponding to the second storage serial number in the historical measurement data, wherein the second storage serial number is the storage serial number of the historical measurement data stored by the client.
2. The method according to claim 1, wherein the feeding back the target historical measurement data and the first stored sequence number corresponding to the target historical measurement data to the client in a second broadcast signal, and if a third broadcast signal fed back by the client is received, where the third broadcast signal at least includes the second stored sequence number, the smart scale deleting the target historical measurement data corresponding to the second stored sequence number from the historical measurement data includes:
sending the second broadcast signal, wherein the second broadcast signal comprises ith item label historical measurement data and a first storage serial number of the ith item label historical measurement data, the initial value of i is 1, the first storage serial number is i, the ith item label historical measurement data is the data with the earliest storage time point in the target historical measurement data to be sent, i is not more than N, and N is the total number of the target historical measurement data belonging to the target user;
And if a third broadcast signal fed back by the client is received, wherein the third broadcast signal at least comprises a second storage sequence number of the historical measurement data stored by the client, deleting the target historical measurement data corresponding to the second storage sequence number, making i equal to i +1, and returning to the step of sending the second broadcast signal.
3. The method of claim 1, wherein the first broadcast signal and the third broadcast signal are homogeneous signals carrying the same data type; if the client is initially started, or the second broadcast signal is not received, or the target historical measurement data carried in the second broadcast signal is not stored, the second storage sequence number carried in the first broadcast signal is a preset storage sequence number, and the preset storage sequence number is different from the first storage sequence number corresponding to the target historical measurement data.
4. The method according to claim 1, wherein before deleting the target historical measurement data corresponding to the second stored sequence number, the method further comprises:
comparing the second storage sequence number in the third broadcast signal with the first storage sequence number carried by the sent second broadcast signal;
And when the second storage sequence number in the third broadcast signal is the same as the first storage sequence number carried by the sent second broadcast signal, continuing to execute the step of deleting the target historical measurement data corresponding to the second storage sequence number.
5. The method of claim 1, further comprising:
performing unit conversion on the historical measurement data according to a preset weight unit to obtain converted historical measurement data;
grouping the converted historical measurement data according to a preset user measurement data change rule to obtain at least one group of measurement data, wherein one group of measurement data corresponds to one user; the user measurement data change rule comprises: the corresponding relation between the storage time difference of two adjacent historical measurement data and the weight change range;
and respectively matching the measurement data with each group of measurement data, and taking historical measurement data contained in target group measurement data matched with the measurement data as the target historical measurement data.
6. A method of data processing, the method comprising:
a client sends a first broadcast signal, wherein the first broadcast signal at least comprises measurement data of a target user corresponding to the client;
If a second broadcast signal fed back by the intelligent scale is received, target historical measurement data carried in the second broadcast signal is stored, the target historical measurement data is historical measurement data which is matched by the intelligent scale based on the measurement data and belongs to the target user, and the second broadcast signal also carries a first storage serial number corresponding to the target historical measurement data;
and the client sends a third broadcast signal, wherein the third broadcast signal at least comprises the first storage serial number, and the first storage serial number is used for indicating the intelligent scale to delete the target historical measurement data corresponding to the first storage serial number.
7. A data processing apparatus, characterized in that the apparatus comprises:
a receiving module, configured to receive a first broadcast signal sent by a client, where the first broadcast signal at least includes measurement data of a target user corresponding to the client;
the data sending module is used for carrying a first storage serial number corresponding to the target historical measurement data and the target historical measurement data in a second broadcast signal and feeding back the first storage serial number to the client if the target historical measurement data belonging to the target user exists in the historical measurement data stored by the intelligent scale according to the measurement data of the target user;
And the data deleting module is used for deleting the target historical measurement data corresponding to the second storage sequence number in the historical measurement data by the intelligent scale if a third broadcast signal fed back by the client is received, wherein the third broadcast signal at least comprises the second storage sequence number.
8. A data processing apparatus, characterized in that the apparatus comprises:
a first sending module, configured to send a first broadcast signal, where the first broadcast signal at least includes measurement data of a target user corresponding to a client;
the storage module is used for storing target historical measurement data carried in a second broadcast signal if the second broadcast signal fed back by the intelligent scale is received, wherein the target historical measurement data is the historical measurement data of the intelligent scale, which belongs to the target user and is determined based on the measurement data, and the second broadcast signal also carries a first storage serial number corresponding to the target historical measurement data;
and the second sending module is used for sending a third broadcast signal, the third broadcast signal at least comprises the first storage serial number, and the first storage serial number is used for indicating the intelligent scale to delete the target historical measurement data corresponding to the first storage serial number.
9. A computer-readable storage medium, in which a computer program is stored which, when being executed by a processor, causes the processor to carry out the steps of the method according to one of claims 1 to 5 or causes the processor to carry out the steps of the method according to claim 6.
10. A computer device comprising a memory and a processor, characterized in that the memory stores computer programs causing the processor to perform the steps of the method according to any of claims 1 to 5 or causing the processor to perform the steps of the method according to claim 6.
CN202011567952.3A 2020-12-25 2020-12-25 Data processing method and device, equipment and storage medium Active CN112714401B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202011567952.3A CN112714401B (en) 2020-12-25 2020-12-25 Data processing method and device, equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202011567952.3A CN112714401B (en) 2020-12-25 2020-12-25 Data processing method and device, equipment and storage medium

Publications (2)

Publication Number Publication Date
CN112714401A CN112714401A (en) 2021-04-27
CN112714401B true CN112714401B (en) 2022-05-24

Family

ID=75545409

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202011567952.3A Active CN112714401B (en) 2020-12-25 2020-12-25 Data processing method and device, equipment and storage medium

Country Status (1)

Country Link
CN (1) CN112714401B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113349756A (en) * 2021-07-20 2021-09-07 深圳市晨北科技有限公司 User identity identification method and device, electronic equipment and storage medium
CN113925485B (en) * 2021-09-30 2024-02-06 深圳市晨北科技有限公司 Body fat rate measuring method, body fat rate measuring device, electronic scale and storage medium

Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110851394A (en) * 2019-11-15 2020-02-28 中山乐心电子有限公司 Measurement data obtaining method, terminal equipment and storage medium

Family Cites Families (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US8738925B1 (en) * 2013-01-07 2014-05-27 Fitbit, Inc. Wireless portable biometric device syncing
US20160258806A1 (en) * 2015-03-03 2016-09-08 Camry Industries Company Limited Device and Method of Communicating with a Bathroom Scale
CN108521453A (en) * 2018-03-26 2018-09-11 上海康斐信息技术有限公司 A kind of the weighing information method for pushing and system of body weigher
CN110763317A (en) * 2018-07-25 2020-02-07 视联动力信息技术股份有限公司 Body weight measuring method and body weight scale
CN109405949A (en) * 2018-09-28 2019-03-01 芯海科技(深圳)股份有限公司 A kind of communication means based on 2.4G two-way communication intelligent broadcast scale
CN109871389A (en) * 2019-02-18 2019-06-11 珠海格力电器股份有限公司 Data synchronization method, device, storage medium and communication equipment
CN110680327A (en) * 2019-09-27 2020-01-14 陈旭 Body fat scale-based plantar pressure detection method and device
WO2021114264A1 (en) * 2019-12-13 2021-06-17 深圳市伊欧乐科技有限公司 Data transmission method and device, and computer-readable storage medium

Patent Citations (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110851394A (en) * 2019-11-15 2020-02-28 中山乐心电子有限公司 Measurement data obtaining method, terminal equipment and storage medium

Also Published As

Publication number Publication date
CN112714401A (en) 2021-04-27

Similar Documents

Publication Publication Date Title
CN112714401B (en) Data processing method and device, equipment and storage medium
CN109474494A (en) Equipment detection method, device, server and storage medium
CN111143163A (en) Data monitoring method and device, computer equipment and storage medium
CN111768608B (en) Data transmission method and device based on double-core intelligent electric meter and computer equipment
CN103444134B (en) Supervision system, monitoring arrangement and the method performed by monitoring arrangement, termination and the method performed by termination
CN112165413B (en) Equipment state reporting method and device and electronic device
CN110601945A (en) Dual-redundancy CAN bus communication system and communication method
CN109584105B (en) Service response method and system
CN112735104A (en) Abnormal alarm processing method and device
CN113206875B (en) Data transmission method, device and storage medium
CN113282587B (en) Method and device for transmitting state data, storage medium and electronic device
CN115243308B (en) Signal measurement method, device, system, terminal and network equipment
CN113452576A (en) Network environment monitoring method and device, storage medium and electronic device
CN116400232A (en) Battery pack data acquisition method and device, electronic equipment and storage medium
CN115866676A (en) Internet-based big data automatic acquisition and analysis system and method
CN111935027B (en) Method and system for optimizing load of whole vehicle network
CN114980195A (en) Multi-terminal data sending method and system
CN116389584B (en) Cloud edge data transmission method for electrochemical energy storage station
CN111817307B (en) Power load switching control method and device, computer equipment and storage medium
US20230359190A1 (en) Process capability index warning system and warning method for the same
CN118316794B (en) Communication optimization method, system and equipment for industrial Internet of things
CN111506446B (en) Interface fault detection method and server
CN116527729B (en) Distributed data management system based on Web3
CN114189565B (en) Head area restoration system, method and related equipment
CN112312445B (en) Voice call processing method and device, storage medium and server

Legal Events

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