Smart wearable device testing method, device, smart wearable device and storage medium

By adding test module storage and sending test data in smart wearable devices, the problems of low efficiency, high cost and high risk in existing test methods are solved, and efficient simulation testing is achieved.

CN114740298BActive Publication Date: 2025-08-12SHENZHEN DO INTELLIGENT TECH CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202210410339.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-04-19
Publication Date
2025-08-12
Estimated Expiration
2042-04-19

AI Technical Summary

Technical Problem

The existing smart wearable device testing methods are inefficient, costly and risky, mainly because the data in the test process cannot be reused, and testers need to repeat the tests multiple times.

Method used

Add a test module to the smart wearable device to store the test data during actual testing, and send it to the driver module for simulation tests when needed to simulate the data source of the real sensor.

Benefits of technology

Without increasing the labor costs of testers, the testing efficiency is improved and the labor costs and risks required for testing are reduced.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114740298B_ABST
    Figure CN114740298B_ABST
Patent Text Reader

Abstract

The present invention relates to the field of smart wearable technology and provides a method for testing a smart wearable device. The method is applied to a test module of the smart wearable device. The smart wearable device includes a controller and a sensor, the controller is in communication with the sensor, and the controller of the smart wearable device runs a driver module for the test module and the sensor. The method includes: obtaining test data, wherein the test data includes a sampling frequency and sampling data. The sampling data is sent to the test module for storage after the driver module drives the controller to sample the sensor according to the sampling frequency during actual testing of the smart wearable device; the sampling data is sent to the driver module according to the sampling frequency to simulate testing the smart wearable device through the driver module. The actual test and the simulated test are functional tests. The embodiments of the present invention improve test efficiency while not increasing the labor cost of testers.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of smart wearable technology, and in particular to a smart wearable device testing method and apparatus, a smart wearable device, and a storage medium. Background Art

[0002] Smart wearable devices are becoming increasingly popular. In addition to receiving messages and calls from mobile phones, smart wearable devices can also perform daily health monitoring such as heart rate and sleep, and help users monitor and manage exercise. Exercise and health are important application scenarios for smart wearable devices.

[0003] In order to verify the various monitoring and management functions provided by smart wearable devices, the existing technology uses testers wearing smart wearable devices to simulate real user scenarios for verification. In some cases, the testers' sports physiological indicators need to reach a critical value to trigger the corresponding functions of the smart wearable devices. In other cases, some functions provided by the smart wearable devices need to be repeatedly verified, and the testers need to repeatedly perform specified operations or multiple testers need to perform specified operations. This testing method is inefficient and has high labor costs for testers. Summary of the Invention

[0004] The present invention aims to provide a method and apparatus for testing a smart wearable device, a smart wearable device, and a storage medium, which can improve test efficiency without increasing the labor cost of testers.

[0005] In order to achieve the above objectives, the technical solutions adopted in the embodiments of the present invention are as follows:

[0006] In a first aspect, an embodiment of the present invention provides a method for testing a smart wearable device, which is applied to a test module of a smart wearable device, wherein the smart wearable device includes a controller and a sensor, the controller is communicatively connected to the sensor, and the controller of the smart wearable device runs a test module and a driver module of the sensor. The method includes: obtaining test data, wherein the test data includes a sampling frequency and sampling data, and the sampling data is sent to the test module and stored by the test module after the driver module drives the controller to sample the sensor according to the sampling frequency when the smart wearable device is actually tested in advance; the sampling data is sent to the driver module according to the sampling frequency to simulate the test of the smart wearable device through the driver module, and the actual test and the simulation test are functional tests.

[0007] Furthermore, there are multiple sensors, and the sensors are of at least one type. The controller of the smart wearable device runs a driver module for each type of the sensor. The test module pre-stores test data of each sensor when the smart wearable device is actually tested. The step of sending the sampled data to the driver module according to the sampling frequency includes:

[0008] Acquire a data queue of each sensor, wherein the data queue of each sensor is used to temporarily store test data sent by the test module to the driver module corresponding to each sensor;

[0009] The sampling data of each sensor is sent to the data queue of each sensor according to the sampling frequency of each sensor, so that the driving module of each sensor obtains the sampling data of each sensor from the data queue of each sensor.

[0010] Furthermore, the method further comprises:

[0011] When actually testing the smart wearable device, receiving sampling data obtained by the driving module driving the controller to sample from the sensor at the sampling frequency;

[0012] Using the acquisition time of the sampled data as the sampling time of the sampled data;

[0013] The sampling data and the sampling time of the sampling data are stored.

[0014] Furthermore, the sampling time is multiple, and the step of obtaining test data includes:

[0015] Read any two stored sampling times;

[0016] Calculating a sampling frequency according to the arbitrary two sampling times and the number of sampled data between the arbitrary two sampling times;

[0017] The sampling frequency and the sampling data are used as the test data.

[0018] Furthermore, the smart wearable device includes a memory electrically connected to the controller, and the step of storing the sampled data and the sampling time of the sampled data includes:

[0019] The sampling data and the sampling time of the sampling data are stored in the memory.

[0020] Furthermore, the smart wearable device is communicatively connected to a terminal device, and the step of storing the sampled data and the sampling time of the sampled data further includes:

[0021] The sampling data and the sampling time of the sampling data are sent to the terminal device, so that the terminal device stores the sampling data and the sampling time of the sampling data.

[0022] Furthermore, the step of storing the sampled data and the sampling time of the sampled data further includes:

[0023] The sampling data and the sampling time of the sampling data are stored in a file format.

[0024] Furthermore, the step of storing the sampled data and the sampling time of the sampled data further includes:

[0025] Evaluating the sampled data to obtain a score for the sampled data;

[0026] If the score is greater than a preset value, the sampling data and the sampling time of the sampling data are stored.

[0027] Furthermore, the test data includes first test data and second test data, the first test data includes a first sampling frequency and first sampling data, the second test data includes a second sampling frequency and second sampling data, the first test data and the second test data are sent to the test module and stored by the test module after the driver module drives the controller to sample the same sensor according to the first sampling frequency and the second sampling frequency respectively under different test conditions, and the step of sending the sampled data to the driver module according to the sampling frequency further includes:

[0028] Sending the first sampling data to the driving module according to the first sampling frequency;

[0029] The second sampling data is sent to the driving module according to the second sampling frequency.

[0030] In the second aspect, an embodiment of the present invention provides a smart wearable device testing device, which is applied to a test module of a smart wearable device. The smart wearable device includes a controller and a sensor, and the controller is communicatively connected to the sensor. The controller of the smart wearable device runs a test module and a driver module of the sensor. The device includes: an acquisition module for acquiring test data, wherein the test data includes a sampling frequency and sampling data, and the sampling data is sent to the test module and stored by the test module after the driver module drives the controller to sample the sensor according to the sampling frequency when actually testing the smart wearable device; a sending module for sending the sampling data to the driver module according to the sampling frequency, so as to simulate the test of the smart wearable device through the driver module, and the actual test and simulation test are functional tests.

[0031] In a third aspect, an embodiment of the present invention provides a smart wearable device, comprising a controller and a memory; the memory is used to store a program; and the controller is used to implement the smart wearable device testing method of the first aspect described above when executing the program.

[0032] In a fourth aspect, an embodiment of the present invention provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a controller, implements the smart wearable device testing method according to the first aspect.

[0033] In an embodiment of the present invention, when actually testing a smart wearable device in advance, the driving module drives the controller to sample data from the sensor according to the sampling frequency and then sends the data to the test module for storage; when the smart wearable device needs to be tested, the sampled data is sent to the driving module according to the sampling frequency, so that the smart wearable device is simulated tested by the driving module, thereby improving the test efficiency without increasing the manpower cost of the testers. BRIEF DESCRIPTION OF THE DRAWINGS

[0034] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the following briefly introduces the drawings required for use in the embodiments. It should be understood that the following drawings only illustrate certain embodiments of the present invention and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other relevant drawings can be obtained based on these drawings without paying any creative work.

[0035] Figure 1 This is an example diagram of an application scenario provided by an embodiment of the present invention.

[0036] Figure 2 A block diagram of a smart wearable device provided by an embodiment of the present invention.

[0037] Figure 3 A system framework diagram of a prior art smart wearable device provided by an embodiment of the present invention.

[0038] Figure 4 This is a system framework diagram of the improved smart wearable device according to the embodiment of the present invention.

[0039] Figure 5 This is a flowchart illustrating a method for testing a smart wearable device according to an embodiment of the present invention.

[0040] Figure 6 This is a flowchart illustrating another method for testing a smart wearable device according to an embodiment of the present invention.

[0041] Figure 7 This is an example diagram of the scheduler scheduling process of the test module provided in an embodiment of the present invention.

[0042] Figure 8 This is a flowchart illustrating another method for testing a smart wearable device according to an embodiment of the present invention.

[0043] Figure 9 This is a flowchart illustrating another method for testing a smart wearable device according to an embodiment of the present invention.

[0044] Figure 10 This is a block diagram of an example of a smart wearable device testing device provided by an embodiment of the present invention.

[0045] Icons: 10-smart wearable device; 11-controller; 12-memory; 13-bus; 14-sensor; 15-communication interface; 20-terminal device; 30-cloud device; 100-smart wearable device test device; 110-test module. DETAILED DESCRIPTION

[0046] To make the objectives, technical solutions, and advantages of the embodiments of the present invention more clear, the technical solutions of the embodiments of the present invention will be clearly and completely described below in conjunction with the accompanying drawings of the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Generally, the components of the embodiments of the present invention described and shown in the drawings herein can be arranged and designed in various different configurations.

[0047] Therefore, the following detailed description of the embodiments of the present invention provided in the accompanying drawings is not intended to limit the scope of the invention as claimed, but rather merely represents selected embodiments of the present invention. All other embodiments derived by persons of ordinary skill in the art based on the embodiments of the present invention without creative effort shall fall within the scope of protection of the present invention.

[0048] It should be noted that similar reference numerals and letters denote similar items in the following drawings, and therefore, once an item is defined in one drawing, it does not need to be further defined or explained in subsequent drawings.

[0049] In the description of the present invention, it should be noted that if the terms "upper", "lower", "inside", "outside", etc. appear, the orientation or position relationship indicated is based on the orientation or position relationship shown in the accompanying drawings, or is the orientation or position relationship in which the product of the invention is usually placed when in use. It is only for the convenience of describing the present invention and simplifying the description, and does not indicate or imply that the device or element referred to must have a specific orientation, be constructed and operated in a specific orientation. Therefore, it should not be understood as a limitation on the present invention.

[0050] In addition, the terms "first", "second", etc., if used, are merely used to distinguish and describe, and should not be understood as indicating or implying relative importance.

[0051] It should be noted that, in the absence of conflict, the features in the embodiments of the present invention may be combined with each other.

[0052] Taking the sports monitoring and management function provided by smart wearable devices as an example, smart wearable devices and their supporting APP can monitor and manage the entire process of a single sports training, and can even manage multiple training needs within a cycle (such as a 3-month training cycle). Combined with human sports physiological data, it can provide more scientific sports guidance and analysis.

[0053] For example, the smart wearable system can monitor the real-time physiological data of a single user's exercise to guide the user on whether the intensity of the exercise is sufficient, whether it is excessive, whether the movement posture is correct, whether the user is prone to injury, whether the exercise duration is sufficient, and the degree of physical fatigue. If combined with multiple exercise records within a cycle, a more in-depth analysis can be given, for example, whether the rest after this exercise is sufficient (fatigue recovery), when to start the next training, what is the relationship between the intensity and duration of the next training and the previous training, whether the physical fitness has improved after multiple training sessions, whether the movement posture has improved, whether the exercise efficiency has improved, etc.

[0054] In order to monitor the aforementioned physiological indicators of exercise, smart wearable devices and their accompanying apps need to monitor the entire process of a single exercise and provide real-time guidance. For example, if a user exercises for too long or excessively, the smart wearable device will display a prompt such as "This exercise is excessive, you need to control the amount of exercise" on the screen; for example, if the user's exercise intensity is too high, the heart rate is too high, and there is a risk of sudden death, the smart wearable device needs to prompt the user to reduce the intensity of the exercise; for example, if the stride (step) of running is too large, it is easy to injure the knees and cause pain, the smart wearable device needs to prompt the user to reduce the stride to reduce the risk of injury, etc.

[0055] In the product development process of smart wearable devices, in addition to design and development, the various functions they provide also need to be tested and verified. Based on the characteristics of smart wearable devices, the existing solutions for testing smart wearable devices are usually: the tester wears the smart wearable device to simulate the scene verification of real users. In some cases, the tester's exercise physiological indicators need to reach a critical value to trigger the corresponding function of the smart wearable device. For example, in order to test the smart wearable device to display the prompt "This exercise is excessive, and the amount of exercise needs to be controlled", the test exercise requires wearing the device for a long time; for example, in order to test and verify the prompt of excessive heart rate, the tester needs to wear the device to exercise at a relatively high intensity, etc. There are similar situations in health features. For example, to test the sleep function, the tester needs to wear the device for real sleep, which takes about 6 to 9 hours.

[0056] Existing testing solutions have the following shortcomings: 1) Low efficiency and long verification times; some functions require repeated verification, which takes even longer. 2) High cost and requires a large number of testers. Since smart wearable devices detect human physiological data, the human body has its own routines, and testing and verification within a short period of time requires different personnel to complete. For example, if you complete a set of test cases after exercising for one hour in the morning and then exercise for another hour in the afternoon to perform a second set of test verification, because the body fatigue from the morning exercise has not yet fully recovered, the human body's indicators (such as heart rate and basal metabolic heat) will be different from usual. Therefore, the data from the afternoon test will not be accurate and rigorous, and different testers will need to be replaced. For example, if you have already done a sleep test last night, doing another set of sleep tests during the day will make you unable to sleep, so different testers will need to be replaced. 3) Risks exist. For example, verifying a scenario where the heart rate is too high during exercise and the exercise posture is incorrect, simulating such abnormal scenarios increases the risk posed by testers.

[0057] In view of the shortcomings of smart wearable devices in the product development and testing process, such as low efficiency, high cost, and risks, the inventors have conducted a careful study and analysis of the above defects and found that one of the reasons for the current low test efficiency is that the data from the test process cannot be reused, and the tester needs to re-test each time to meet the needs of repeated testing. Based on the above reasons, the inventors have used an ingenious idea: adding a test module to the smart wearable device. When the smart wearable device is actually tested, the test module stores the test data generated during the actual test. When the smart wearable device needs to be simulated, the test module directly sends the stored test data to the driver module. Since the driver module does not care about the source of the test data, that is, whether the test data comes from the sensor or from other modules, such as the test module, it directly sends the received test data to the upper-layer application module. This achieves the simulation test of the smart wearable device without the sensor being aware of whether it is a real sensor or a test module. Based on this idea, the present embodiment provides a smart wearable device testing method, apparatus, smart wearable device and storage medium to overcome the above shortcomings in the prior art, which will be described in detail below.

[0058] Please refer to Figure 1 , Figure 1 This is an example diagram of an application scenario provided by an embodiment of the present invention. The smart wearable device 10 communicates wirelessly with the terminal device 20. The wireless communication methods include, but are not limited to, Bluetooth, WIFI, etc. The terminal device 20 runs an APP that is compatible with the smart wearable device 10, which allows users to control the smart wearable device 10 and view the monitoring and management data of the smart wearable device 10 on the terminal device 20. The terminal device 20 is in communication with the cloud device 30, which facilitates sending the user's configuration information for the smart wearable device 10, or the monitoring and management data of the smart wearable device 10, to the cloud device 30 for analysis and storage. Of course, the user's configuration information for the smart wearable device 10, or the monitoring and management data of the smart wearable device 10, can also be stored directly on the terminal device 20.

[0059] The smart wearable device 10 can be a wearable device such as a smart bracelet, a smart watch, a smart helmet, or smart glasses.

[0060] The terminal device 20 can be a tablet computer, a laptop computer, a smart phone or the like.

[0061] The cloud device 30 can be a device in a public cloud, a device in a private cloud, a cloud server, a cloud server cluster, etc.

[0062] exist Figure 1 On the basis of Figure 1 For a block diagram of the smart wearable device 10, please refer to Figure 2 , Figure 2 This is a block diagram of a smart wearable device 10 provided in an embodiment of the present invention. The smart wearable device 10 includes a controller 11, a memory 12, a bus 13, a sensor 14, and a communication interface 15. The controller 11, the memory 12, the sensor 14, and the communication interface 15 communicate via the bus 13.

[0063] The controller 11 may be an integrated circuit chip with signal processing capabilities. During implementation, the steps of the above method may be completed by hardware integrated logic circuits in the controller 11 or by software instructions. The controller 11 may be a general-purpose processor, including a central processing unit (CPU), a network processor (NP), etc.; it may also be a digital signal processor (DSP), an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or other programmable logic devices, discrete gate or transistor logic devices, or discrete hardware components.

[0064] The memory 12 is used to store programs, for example, the smart wearable device testing device in the embodiment of the present invention. The smart wearable device testing device includes at least one software function module that can be stored in the memory 12 in the form of software or firmware. After receiving the execution instruction, the controller 11 executes the program to implement the smart wearable device testing method in the embodiment of the present invention.

[0065] The memory 12 may include a high-speed random access memory (RAM) or a non-volatile memory. Alternatively, the memory 12 may be a storage device built into the controller 11 or a storage device independent of the controller 11.

[0066] The bus 13 may be an ISA bus, a PCI bus, an EISA bus, or the like. Figure 2 It is represented by only one bidirectional arrow, but it does not mean that there is only one bus or one type of bus.

[0067] The sensor 14 is used to collect various human body data of the user of the smart wearable device, including motion data or physiological data. The sensor 14 can be at least one of a photoplethysmography (PPG) sensor, an accelerometer (ACC) sensor, a temperature sensor, a gyroscope sensor, a barometer sensor, and the like.

[0068] The PPG sensor is a type of photoelectric sensor that can detect the difference in intensity of reflected light after absorption by human blood and tissues, record the changes in blood vessel volume during the cardiac cycle, and calculate the heart rate from the obtained pulse waveform.

[0069] ACC sensors can achieve speed control and distance control.

[0070] The temperature sensor can collect the temperature of the human body.

[0071] A gyroscope sensor is an instrument that can accurately determine the orientation of a moving human body in a control system based on free-space movement and gesture positioning.

[0072] Barometer sensors are mainly used to measure gas pressure. A barometer sensor with an atmospheric pressure range is usually used to measure weather changes and measure altitude based on the correspondence between air pressure and altitude. This allows the location of users of smart wearable devices to be determined.

[0073] In order to more clearly describe the technical solution in this embodiment, the embodiment of the present invention also provides Figure 1 and Figure 2 Please refer to the system framework diagram of the smart wearable device 10 in the prior art. Figure 3 , Figure 3 This is a system framework diagram of a prior art smart wearable device provided by an embodiment of the present invention. Figure 3 In the paper, the system framework of smart wearable devices mainly includes the hardware layer and the software layer.

[0074] The hardware layer mainly includes various sensors, memories, controllers, communication interfaces and other hardware. The controllers and communication interfaces are Figure 3 The fact that they are not shown does not mean that there are no controllers and communication interfaces. It should be noted that, in order to facilitate interaction, the hardware layer may also include a display screen, a touch screen, etc.

[0075] The software layer includes operating system modules, driver modules, algorithm modules, communication modules, application modules, display interaction modules and other software modules.

[0076] The operating system module is used to manage the hardware and software modules in the smart wearable device and schedule resources, for example, the management of running tasks, I / O interfaces, files and storage resources.

[0077] The driver module is used to cooperate with the sensor to send the data collected by the sensor to the algorithm module. The hardware layer can include one or more types of sensors, and each type of sensor corresponds to its own sensor driver.

[0078] The algorithm module is used to process the data provided by the driver module. The processing method varies according to the different types of data. It can include a pedometer algorithm sub-module, a sleep algorithm sub-module, a gesture algorithm sub-module, a heart rate algorithm sub-module, a motion algorithm sub-module, etc.

[0079] The communication module is used to realize communication interaction between the smart wearable device 10 and the terminal device 20 or other external devices, and may include a Bluetooth low energy BLE (Bluetooth Low Energy, BLE) Bluetooth sub-module, a near field communication NFC (NearField Communication, NFC) sub-module, a BT (BlueTooth, BT) Bluetooth sub-module, etc.

[0080] The application module allows users to implement various types of applications, such as messaging, voice control, motion monitoring, blood oxygen monitoring, message notifications, sleep monitoring, and stress monitoring.

[0081] The display interaction module is used to realize the interaction between the user and the smart wearable device 10, including displaying the data required by the user through the display screen, or allowing the user to input operation instructions through the touch screen.

[0082] In order to implement the test of the smart wearable device 10 without increasing the manpower cost, the embodiment of the present invention is Figure 3 Based on the improvement, a specific implementation example is given, please refer to Figure 4 , Figure 4 This is a system framework diagram of the improved smart wearable device 10 according to the embodiment of the present invention. Figure 4 In the present invention, a test module that interacts with the driver module is added to the software layer. This test module is managed by the operating system module. The test module can store the sensor data file obtained from the driver module in the memory. In addition, the test module can also read data from the data file and send the read data to the driver module, so that the driver module sends the data to the algorithm module, thereby implementing the test of the smart wearable device 10. As an extension, the sensor data file can also be stored in the terminal device and / or stored in the cloud device through the terminal device.

[0083] based on Figure 4 The system framework diagram of the present invention provides a Figure 4 For the smart wearable device testing method implemented by the test module, please refer to Figure 5 , Figure 5 This is a flow chart of a method for testing a smart wearable device provided by an embodiment of the present invention, which is applied to Figures 1 and 2 The smart wearable device 10 includes the following steps:

[0084] Step S101, obtaining test data, wherein the test data includes a sampling frequency and sampling data. The sampling data is sampled from the sensor by the driving module driving the controller according to the sampling frequency when the smart wearable device is actually tested in advance, and then sent to the test module for storage by the test module.

[0085] In this embodiment, the driving module and the testing module are both software modules that implement corresponding functions. These modules all run on the controller. As a specific implementation method, when the smart wearable device is actually tested, the sensor puts the collected data into a pre-agreed data area, and the driving module takes out the data put into the data area by the sensor from the pre-agreed data area according to the sampling frequency, that is, the sampling data. At the same time, the driving module sends the sampling data to the testing module, and the testing module stores the sampling data. Since the driving module obtains the sampling data according to the sampling frequency, the testing module also stores the sampling data according to the sampling frequency.

[0086] In step S102 , the sampled data is sent to the driving module according to the sampling frequency, so as to perform a simulation test on the smart wearable device through the driving module. The actual test and the simulation test are functional tests.

[0087] In this embodiment, the sampling frequency used when performing actual testing on the smart wearable device is the same as the sampling frequency used when performing simulation testing on the smart wearable device using sampled data, so as to achieve the purpose of performing simulation testing more realistically.

[0088] In this embodiment, after completing an actual test of a smart wearable device, the test module can reuse the stored data and repeat the simulation test of the smart wearable device through the driver module. This avoids the need for testers to actually wear the smart wearable device each time the device is tested, greatly reducing the labor cost required for testing.

[0089] In this embodiment, based on Figure 4 As a specific implementation method, the test module sends the stored sampled data to the drive module, so that the drive module sends the data to the algorithm module, and the algorithm module uses the sampled data to test the smart wearable device 10.

[0090] The above method provided by the embodiment of the present invention, when the smart wearable device is actually tested in advance, drives the controller through the driving module to sample from the sensor according to the sampling frequency and sends it to the test module for storage; when the smart wearable device needs to be tested, the sampled data is sent to the driving module according to the sampling frequency, so that the smart wearable device is simulated tested through the driving module, thereby improving the test efficiency without increasing the manpower cost of the testers.

[0091] It should be noted that, in one possible application scenario, the above method provided by the embodiment of the present invention can also be carried out simultaneously with actual testing to further improve testing efficiency. In another possible application scenario, the method provided by the embodiment of the present invention can replace real people for testing in test scenarios with certain risks, thereby reducing the risks of testing to testers.

[0092] exist Figure 5 On the basis of this, the embodiment of the present invention also provides a specific implementation method for sending the sampled data to the driving module in a multiple sensor scenario, please refer to Figure 6 , Figure 6 This is a flowchart of another method for testing a smart wearable device provided by an embodiment of the present invention, where step S102 includes the following sub-steps:

[0093] Sub-step S1021 : obtaining a data queue of each sensor, wherein the data queue of each sensor is used to temporarily store test data sent by the test module to the driver module corresponding to each sensor.

[0094] Sub-step S1022 : sending the sampled data of each sensor to the data queue of each sensor according to the sampling frequency of each sensor, so that the driving module of each sensor obtains the sampled data of each sensor from the data queue of each sensor.

[0095] In this embodiment, there can be multiple sensors, and the controller runs a driver module for each sensor. Each sensor has corresponding test data. The test module includes a scheduler. In order to facilitate the dispatch of different sampled data to the driver module of the corresponding sensor, each sensor has a corresponding data queue created in advance. The scheduler of the test module sends the sampled data of each sensor to the data queue of the corresponding sensor. Please refer to Figure 7 , Figure 7 An example diagram of the scheduling process of the test module scheduler provided in an embodiment of the present invention, Figure 7 In the embodiment, the smart wearable device includes n sensors, each sensor corresponds to a data queue, the scheduler reads the sampling data of each sensor from the memory, and puts the sampling data into the data queue corresponding to each sensor according to the sampling frequency corresponding to each sensor, each sensor obtains the sampling data from its corresponding data queue, and sends it to the corresponding algorithm module for testing the smart wearable device. It should be noted that different sensor drivers can send their respective sampling data to the same algorithm module, so as to comprehensively analyze the sampling data of multiple sensors and test the corresponding application functions. For example, the driver of the temperature sensor and the driver of the gyroscope sensor send their respective sampling data to the motion algorithm submodule to test the motion-related application functions of the smart wearable device.

[0096] The above method provided in this embodiment can realize the transmission of the sampling data of multiple sensors at the same time to meet the test scenarios of smart wearable devices that require the cooperation of multiple sensors.

[0097] In this embodiment, in order to record the test data more conveniently and accurately, the embodiment of the present invention also provides a specific implementation method for storing the test data. Figure 8 , Figure 8 This is a flowchart of another method for testing a smart wearable device provided by an embodiment of the present invention, wherein the method further includes the following steps:

[0098] Step S201 : When performing actual testing on the smart wearable device, the receiving driving module drives the controller to sample the sensor according to the sampling frequency to obtain sampling data.

[0099] In this embodiment, the actual test can be the operation or action performed by the user after wearing the smart wearable device. The user can be the user of the smart wearable device or the tester of the smart wearable device. As a specific implementation method, the sensor sends the sampled data to a pre-agreed data area, and the driving module takes out the sampled data from the data area according to the sampling frequency. Each time the sampled data is taken out, the driving module will send the sampled data to the algorithm module. At the same time, the driving module will also send the sampled data taken out each time to the test module.

[0100] Step S202: The acquisition time of the sampled data is used as the sampling time of the sampled data.

[0101] In this embodiment, in order for the test module to subsequently send the sampled data to the driver module at a sampling frequency consistent with the actual test, the test module may record the sampling time for each acquisition of the sampled data.

[0102] Step S203: store the sampled data and the sampling time of the sampled data.

[0103] In this embodiment, each sampling data and the sampling time of each sampling data are stored.

[0104] In this embodiment, as a specific implementation method, the sampling data and sampling time can be stored in the memory of the smart wearable device, or sent by the smart wearable device to the terminal device for storage, or even sent to the cloud device through the terminal device for storage. Therefore, the method of storing the sampling data and the sampling time of each sampling data can be at least one of the following methods:

[0105] (1) The sampling data and the sampling time of the sampling data are stored in the memory.

[0106] (2) The sampling data and the sampling time of the sampling data are sent to the terminal device, so that the terminal device stores the sampling data and the sampling time of the sampling data.

[0107] In this embodiment, as a specific implementation, in order to facilitate the storage and management of the sampling data and sampling time, the sampling data and sampling time can be stored in the form of a file. Therefore, as a specific implementation method, the storage method can also be:

[0108] The sampling data and the sampling time of the sampling data are stored in the form of a file.

[0109] In this embodiment, as a specific implementation method, the sampling data and sampling time of all sensors can be stored in the same file. The format of the file can be as follows:

[0110] File Header

[0111] Time information

[0112] Version Information

[0113] Sensor 1 Model

[0114] Sensor 2 Model

[0115] sensor…

[0116] Wearable device product information

[0117] File body

[0118] Time 1 (T0)

[0119] {Sensor 1 data: xxxx}

[0120] {Sensor 2 data: xxxx}

[0121]

[0122] {Sensor m data: xxxx}

[0123] Time 2 (T0+1)

[0124] {Sensor 1 data: xxxx}

[0125] {Sensor 2 data: xxxx}

[0126]

[0127] {Sensor m data: xxxx}

[0128]

[0129] Time n (T0+n-1)

[0130] {Sensor 1 data: xxxx}

[0131] {Sensor 2 data: xxxx}

[0132]

[0133] {Sensor m data: xxxx}

[0134] End tag

[0135] As another specific implementation, each sensor may correspond to a file. The format of the file for each sensor may be adjusted with reference to the above file format, which will not be described in detail here.

[0136] In this embodiment, in order to avoid abnormal test data obtained due to various reasons during actual testing, which ultimately leads to inaccurate test results when using abnormal test data for simulation testing, the embodiment of the present invention also provides another method for storing test data, specifically:

[0137] First, the sampled data is evaluated to obtain the scores of the sampled data.

[0138] In this embodiment, the basis for evaluation includes, but is not limited to, the quality of the sensor signal waveform, the confidence level of the test data, and the like.

[0139] Secondly, if the score is greater than a preset value, the sampled data and the sampling time of the sampled data are stored.

[0140] In this embodiment, the preset value can be set according to the needs of the actual scenario. For example, when the test conditions are ideal, the test data is usually more reliable. In this case, the preset value can be set lower. Otherwise, the preset value can be set higher.

[0141] based on Figure 8 The method for storing test data provided by the present invention provides a specific implementation method for obtaining test data, please refer to Figure 9 , Figure 9 This is a flowchart of another method for testing a smart wearable device provided by an embodiment of the present invention, where step S101 includes the following sub-steps:

[0142] Sub-step S1011 , reading any two stored sampling times.

[0143] Sub-step S1012, calculating the sampling frequency according to any two sampling times and the number of sampled data between any two sampling times.

[0144] In this embodiment, when one data is obtained each time sampling, the sampling frequency can be calculated based on the number of data between any two sampling times. For example, the sampling data and sampling time are shown in Table 1:

[0145]

[0146]

[0147] If any two sampling times are: 2020-1-1 10:00:00 and 2020-1-1 10:00:03, and there are 4 data between the two sampling times, then the sampling frequency is: 1 data / s.

[0148] As another specific implementation, each sampling may also sample a group of data. In this case, the sampling frequency may be determined according to the number of groups sampled between any two sampling times.

[0149] Sub-step S1013: using the sampling frequency and the sampling data as test data.

[0150] The above method provided in this embodiment can accurately calculate the sampling frequency by reading the stored sampling data and sampling time, thereby ensuring that the sampling data can be sent at the same sampling frequency as the actual test, thereby ensuring the accuracy and consistency of the test results.

[0151] In this embodiment, in order to improve the diversity of data and make the final test results more comprehensive and accurate, the test data of actual tests under different test conditions can be used to simulate the test of the smart wearable device. The actual test is performed under test condition 1 to obtain the first test data, and the first test data includes the first sampling frequency and the first sampling data. The actual test is performed under test condition 2 to obtain the second test data, and the second test data includes the second sampling frequency and the second sampling data. The actual test is performed under test condition 3 to obtain the third test data, ..., and the actual test is performed under test condition N to obtain the Mth test data. Wherein, N is less than or equal to M. When N is less than M, there are at least two groups of test data corresponding to the same test condition; when N is equal to M, the same test condition corresponds to at least one group of test data. Therefore, the embodiment of the present invention also provides an implementation method for sending the sampling data to the driver module according to the sampling frequency, which is specifically:

[0152] First, first sampling data is sent to a driving module according to a first sampling frequency.

[0153] Next, the second sampling data is sent to the driving module according to the second sampling frequency.

[0154] or,

[0155] First, the second sample data is sent to the driving module according to the second sampling frequency.

[0156] Secondly, the first sampling data is sent to the driving module according to the first sampling frequency.

[0157] In this embodiment, the first sampling frequency and the second sampling frequency may be the same or different. It should be noted that after the smart wearable device has tested the first test data, the second test data is tested; or after the smart wearable device has tested the second test data, the first test data is tested.

[0158] It should also be noted that the test data can also include more than two sets of data, each with a corresponding sampling frequency and sampling data. Each set of data can be sent to the driver module in sequence, and all the data can be used to simulate the test of the smart wearable device. For example, when testing blood oxygen, it is necessary to collect data from users with different blood oxygen levels, such as hypoxia and normoxia, and obtain corresponding test data under hypoxic and normoxia conditions respectively. Then, the hypoxic and normoxia test data are used to simulate the test of the smart wearable device to overcome the problem of insufficient test data diversity.

[0159] In order to execute the corresponding steps in the above embodiment and various possible implementations, an implementation method of a smart wearable device testing device 100 is given below. Figure 10 , Figure 10 The block diagram of the smart wearable device testing device 100 provided in an embodiment of the present invention is shown. It should be noted that the basic principles and technical effects of the smart wearable device testing device 100 provided in this embodiment are the same as those in the above embodiments. For the sake of simplicity, they are not mentioned in this embodiment.

[0160] The smart wearable device testing device 100 includes a testing module 110, which is used to:

[0161] Acquire test data, where the test data includes sampling frequency and sampling data. The sampling data is sent to the test module and stored by the test module after the driver module drives the controller to sample the sensor according to the sampling frequency when the smart wearable device is actually tested in advance; the sampling data is sent to the driver module according to the sampling frequency to simulate the smart wearable device through the driver module. The actual test and the simulation test are functional tests.

[0162] Furthermore, there are multiple sensors, and the sensors are of at least one type. The controller of the smart wearable device runs a driver module for each type of sensor. The test module pre-stores the test data of each sensor when the smart wearable device is actually tested. The test module 110 is specifically used to: obtain a data queue for each sensor, wherein the data queue of each sensor is used to temporarily store the test data sent by the test module to the driver module corresponding to each sensor; send the sampling data of each sensor to the data queue of each sensor according to the sampling frequency of each sensor, so that the driver module of each sensor obtains the sampling data of each sensor from the data queue of each sensor.

[0163] Furthermore, the test module 110 is also used to: when performing actual testing on the smart wearable device, receive the sampling data obtained after the driving module drives the controller to sample the sensor according to the sampling frequency; use the acquisition time of the sampling data as the sampling time of the sampling data; and store the sampling data and the sampling time of the sampling data.

[0164] Furthermore, there are multiple sampling times, and the test module 110 is specifically used to obtain test data: read any two stored sampling times; calculate the sampling frequency based on any two sampling times and the number of sampling data between any two sampling times; and use the sampling frequency and sampling data as test data.

[0165] Furthermore, the smart wearable device includes a memory, which is electrically connected to the controller. The test module 110 is used to store the sampled data and the sampling time of the sampled data, specifically to store the sampled data and the sampling time of the sampled data in the memory.

[0166] Furthermore, the smart wearable device is communicatively connected to the terminal device, and the test module 110 is used to store the sampled data and the sampling time of the sampled data and is also used to: send the sampled data and the sampling time of the sampled data to the terminal device so that the terminal device stores the sampled data and the sampling time of the sampled data.

[0167] Furthermore, when the test module 110 is used to store the sampled data and the sampling time of the sampled data, it is specifically used to: store the sampled data and the sampling time of the sampled data in the form of a file.

[0168] Furthermore, when the test module 110 is used to store the sampled data and the sampling time of the sampled data, it is specifically used to: evaluate the sampled data to obtain a score of the sampled data; if the score is greater than a preset value, store the sampled data and the sampling time of the sampled data.

[0169] Furthermore, the test data includes first test data and second test data, the first test data includes a first sampling frequency and first sampling data, the second test data includes a second sampling frequency and second sampling data, the first test data and the second test data are sent to the test module and stored by the test module after the driving module drives the controller to sample the same sensor according to the first sampling frequency and the second sampling frequency under different test conditions. When the test module 110 is used to send the sampling data to the driving module according to the sampling frequency, it is specifically used to: send the first sampling data to the driving module according to the first sampling frequency; send the second sampling data to the driving module according to the second sampling frequency.

[0170] An embodiment of the present invention provides a computer-readable storage medium having a computer program stored thereon. When the computer program is executed by a controller, the smart wearable device testing method described above is implemented.

[0171] In summary, an embodiment of the present invention provides a method for testing a smart wearable device, which is applied to a test module of the smart wearable device. The smart wearable device includes a controller and a sensor, the controller being communicatively connected to the sensor, and the controller of the smart wearable device running a driver module for the test module and the sensor. The method comprises: obtaining test data, wherein the test data includes a sampling frequency and sampling data. The sampling data is sent to the test module for storage by the test module after the driver module drives the controller to sample the sensor according to the sampling frequency during a pre-test of the smart wearable device; the sampling data is sent to the driver module according to the sampling frequency to perform a simulated test on the smart wearable device through the driver module, wherein the actual test and the simulated test are functional tests. Compared with the prior art, the embodiment of the present invention, when the smart wearable device is pre-tested, the driver module drives the controller to sample data from the sensor according to the sampling frequency and then sends the data to the test module for storage; when the smart wearable device needs to be tested, the sampling data is sent to the driver module according to the sampling frequency to perform a simulated test on the smart wearable device through the driver module, thereby improving test efficiency without increasing the labor cost of testers.

[0172] The above description is merely a specific embodiment of the present invention, but the scope of protection of the present invention is not limited thereto. Any changes or substitutions that can be easily conceived by a person skilled in the art within the technical scope disclosed in the present invention should be included in the scope of protection of the present invention. Therefore, the scope of protection of the present invention should be based on the scope of protection of the claims.

Claims

1. A method for testing a smart wearable device, characterized in that: A test module applied to a smart wearable device, the smart wearable device including a controller and a sensor, the controller being communicatively connected to the sensor, the sensors being multiple and of at least one type, the controller of the smart wearable device running a test module and a driver module for each type of the sensor, the test module pre-storing test data for each sensor when actually testing the smart wearable device, the method comprising: Acquire test data, wherein the test data includes a sampling frequency and sampling data, and the sampling data is sent to the test module and stored by the test module after the driving module drives the controller to sample the sensor according to the sampling frequency when the smart wearable device is actually tested in advance; The sampling data is sent to the driving module according to the sampling frequency, so as to perform a simulation test on the smart wearable device through the driving module, wherein the actual test and the simulation test are functional tests, and the sampling data is sent to the driving module according to the sampling frequency, including: Acquire a data queue of each sensor, wherein the data queue of each sensor is used to temporarily store test data sent by the test module to the driver module corresponding to each sensor; The sampling data of each sensor is sent to the data queue of each sensor according to the sampling frequency of each sensor, so that the driving module of each sensor obtains the sampling data of each sensor from the data queue of each sensor.

2. The smart wearable device testing method according to claim 1, wherein: The method further comprises: When actually testing the smart wearable device, receiving sampling data obtained after the driving module drives the controller to sample the sensor according to the sampling frequency; Using the acquisition time of the sampled data as the sampling time of the sampled data; The sampling data and the sampling time of the sampling data are stored.

3. The smart wearable device testing method according to claim 2, wherein: The sampling time is multiple, and the step of obtaining test data includes: Read any two stored sampling times; Calculating a sampling frequency according to the arbitrary two sampling times and the number of sampled data between the arbitrary two sampling times; The sampling frequency and the sampling data are used as the test data.

4. The smart wearable device testing method according to claim 2, wherein: The smart wearable device includes a memory electrically connected to the controller, and the step of storing the sampled data and the sampling time of the sampled data includes: The sampling data and the sampling time of the sampling data are stored in the memory.

5. The smart wearable device testing method according to claim 2, wherein: The smart wearable device is communicatively connected to the terminal device, and the step of storing the sampled data and the sampling time of the sampled data further includes: The sampling data and the sampling time of the sampling data are sent to the terminal device, so that the terminal device stores the sampling data and the sampling time of the sampling data.

6. The smart wearable device testing method according to claim 2, wherein: The step of storing the sampled data and the sampling time of the sampled data further includes: The sampling data and the sampling time of the sampling data are stored in a file format.

7. The smart wearable device testing method according to claim 2, wherein: The step of storing the sampled data and the sampling time of the sampled data further includes: Evaluating the sampled data to obtain a score for the sampled data; If the score is greater than a preset value, the sampling data and the sampling time of the sampling data are stored.

8. The smart wearable device testing method according to claim 1, wherein: The test data includes first test data and second test data, the first test data includes a first sampling frequency and first sampling data, the second test data includes a second sampling frequency and second sampling data, the first test data and the second test data are sent to the test module and stored by the test module after the driver module drives the controller to sample the same sensor according to the first sampling frequency and the second sampling frequency respectively under different test conditions, and the step of sending the sampled data to the driver module according to the sampling frequency also includes: Sending the first sampling data to the driving module according to the first sampling frequency; The second sampling data is sent to the driving module according to the second sampling frequency.

9. A smart wearable device testing device, characterized in that: A test module for a smart wearable device is provided. The smart wearable device includes a controller and a sensor. The controller is in communication with the sensor. There are multiple sensors of at least one type. The controller of the smart wearable device runs the test module and a driver module for each type of sensor. The test module pre-stores test data for each sensor when the smart wearable device is actually tested. The test module is used to: Acquire test data, wherein the test data includes a sampling frequency and sampling data, and the sampling data is sent to the test module and stored by the test module after the driving module drives the controller to sample the sensor according to the sampling frequency when the smart wearable device is actually tested in advance; The sampled data is sent to the driving module according to the sampling frequency, so as to perform a simulation test on the smart wearable device through the driving module. The actual test and the simulation test are functional tests. The testing module is further used to: Acquire a data queue of each sensor, wherein the data queue of each sensor is used to temporarily store test data sent by the test module to the driver module corresponding to each sensor; The sampling data of each sensor is sent to the data queue of each sensor according to the sampling frequency of each sensor, so that the driving module of each sensor obtains the sampling data of each sensor from the data queue of each sensor.

10. A smart wearable device, characterized in that: It comprises a controller and a memory; the memory is used to store a program; the controller is used to implement the smart wearable device testing method according to any one of claims 1 to 8 when executing the program.

11. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by the controller, the smart wearable device testing method according to any one of claims 1 to 8 is implemented.

Citation Information

Patent Citations

  • Program testing method and device

    CN105975394A