Earphone control method, earphone, and computer-readable storage medium
By integrating a sensor module into the headphones to collect and process acceleration and angular velocity signals and calculate swimming parameters, the problem of headphones being unable to analyze swimming strokes is solved. This enables the analysis and acquisition of swimming stroke indicators, expanding the application scenarios of headphones.
Patent Information
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Filing Date
- 2025-08-29
- Publication Date
- 2026-03-05
AI Technical Summary
Existing headphones cannot analyze a user's swimming style or obtain various indicators under different swimming styles, which limits the application scenarios of the headphones.
By integrating sensor modules, including accelerometers and gyroscopes, into the headphones, three-axis acceleration signals and three-axis angular velocity signals are collected, and complementary filtering and fusion processing is performed to obtain resultant acceleration signals, resultant angular velocity signals, and attitude angle signals. Swimming parameters, including breathing angles and gliding angles for freestyle and breaststroke, are calculated to determine the swimming posture and provide swimming posture evaluation and correction suggestions.
It enables the analysis of users' swimming strokes and the acquisition of various indicators, expanding the application scenarios of the headphones and improving swimming efficiency and safety.
Smart Images

Figure CN2025117799_05032026_PF_FP_ABST
Abstract
Description
Headphone control method, headphones and computer-readable storage medium
[0001] Priority information
[0002] This application claims priority and benefits to patent application No. 202411218168.X, filed with the China National Intellectual Property Administration on August 30, 2024, the entire contents of which are incorporated herein by reference. Technical Field
[0003] This application relates to the field of headphone control technology, and more specifically, to a headphone control method, a headphone, and a computer-readable storage medium. Background Technology
[0004] As a new type of smart terminal, headphones accompany users in many activities, such as exercise and rest, and can effectively record users' activity trajectories and status information. However, current headphones have limited functionality and cannot analyze a user's swimming style or obtain various indicators under different swimming styles, which limits the application scenarios of headphones. Summary of the Invention
[0005] This application provides a method for controlling headphones, headphones, and a computer-readable storage medium.
[0006] This application discloses a method for controlling headphones, characterized by comprising: activating a swimming mode on the headphones; acquiring detection data collected by a sensor module; acquiring swimming parameters of a user wearing the headphones while swimming based on the detection data; and acquiring the user's swimming posture based on the detection data.
[0007] In some implementations, the control method further includes issuing a prompt message to guide the user to calibrate the posture of the headphones.
[0008] In some embodiments, the sensor module includes a gyroscope, and the detection data includes a three-axis angular velocity signal detected by the gyroscope; the control method further includes: determining whether the attitude of the earphone is successfully calibrated; if the attitude of the earphone is successfully calibrated, calibrating the three-axis angular velocity signal detected by the gyroscope; and if the attitude of the earphone is not successfully calibrated, turning off the swimming mode of the earphone.
[0009] In some embodiments, the sensor module further includes an accelerometer, and the detection data includes triaxial acceleration signals detected by the accelerometer; determining whether the attitude of the headphones has been successfully calibrated includes: fusing the triaxial acceleration signals at each preset moment within a preset calibration window to obtain a resultant acceleration signal at the preset moment; calculating the maximum, minimum, and average values of the resultant acceleration signals at all preset moments within the calibration window; and determining whether the attitude of the headphones has been successfully calibrated based on the maximum, minimum, and average values of the resultant acceleration signals.
[0010] In some embodiments, the sensor module includes an accelerometer and a gyroscope, and the detection data includes a three-axis acceleration signal detected by the accelerometer and a three-axis angular velocity signal detected by the gyroscope; obtaining swimming parameters of a user wearing the headphones while swimming based on the detection data includes: performing complementary filtering and fusion processing on the three-axis acceleration signal and the three-axis angular velocity signal to obtain a resultant acceleration signal, a resultant angular velocity signal, and quaternion data; solving the quaternion data to obtain the attitude angle signal of the headphones; and determining the swimming parameters based on the resultant acceleration signal, the resultant angular velocity signal, and the attitude angle signal.
[0011] In some embodiments, the sensor module includes an accelerometer and a gyroscope, and the detection data includes a three-axis acceleration signal detected by the accelerometer and a three-axis angular velocity signal detected by the gyroscope; obtaining swimming parameters of a user wearing the headphones during swimming based on the detection data includes: processing the three-axis acceleration signal and the three-axis angular velocity signal at each preset moment within a preset swimming window to obtain a resultant acceleration signal, a resultant angular velocity signal, and an attitude angle signal of the headphones at multiple preset moments within the swimming window; and determining the swimming parameters based on the resultant acceleration signal, the resultant angular velocity signal, and the attitude angle signal.
[0012] In some embodiments, the swimming parameters include the freestyle breathing angle, the attitude angle signal includes the roll angle signal, and determining the swimming parameters based on the resultant acceleration signal, the resultant angular velocity signal, and the attitude angle signal includes: obtaining the peak maximum value and trough average value of the resultant acceleration signal and the resultant angular velocity signal; and within a first preset period, if the roll angle signal first rises and then falls, and both the resultant acceleration signal and the resultant angular velocity signal have at least two peak maximum values greater than a first preset peak threshold and at least two trough average values less than a first preset trough threshold, determining the maximum roll angle within the first preset period as the freestyle breathing angle.
[0013] In some embodiments, the swimming parameters include the freestyle gliding angle, and the attitude angle signal includes a roll angle signal and a pitch angle signal. Determining the swimming parameters based on the resultant acceleration signal, the resultant angular velocity signal, and the attitude angle signal includes: obtaining the maximum peak value and the average trough value of the resultant acceleration signal and the resultant angular velocity signal; and determining the average pitch angle value within the first preset period as the freestyle gliding angle if the fluctuation amplitude of the roll angle signal is less than a preset first fluctuation threshold within a first preset period.
[0014] In some embodiments, the swimming parameters include the breaststroke breathing angle, the attitude angle signal includes the pitch angle signal, and determining the swimming parameters based on the resultant acceleration signal, the resultant angular velocity signal, and the attitude angle signal includes: obtaining the peak maximum value and trough average value of the resultant acceleration signal and the resultant angular velocity signal; and within a second preset period, when the resultant acceleration signal, the resultant angular velocity signal, and the pitch angle signal all rise, determining the current pitch angle as the breaststroke breathing angle.
[0015] In some embodiments, the swimming parameters include breaststroke gliding time, the attitude angle signal includes pitch angle signal, and determining the swimming parameters based on the resultant acceleration signal, the resultant angular velocity signal, and the attitude angle signal includes: obtaining the peak maximum value and trough average value of the resultant acceleration signal and the resultant angular velocity signal; and within a second preset period, when the fluctuation amplitude of the pitch angle signal is less than a preset second fluctuation threshold, and the attitude angle signal is within a preset breaststroke gliding pitch angle threshold range, determining the time during which the pitch angle signal is within the preset breaststroke gliding pitch angle threshold range as the breaststroke gliding time.
[0016] In some embodiments, obtaining the swimming stroke of a user wearing the headphones based on the detection data includes: obtaining the number of breathing angles within a preset swimming window; determining the swimming stroke as freestyle when, during the swimming window, both the resultant acceleration signal and the resultant angular velocity signal have at least two peak averages greater than a first preset peak threshold, and the number of breathing angles is greater than a preset first quantity threshold; and determining the swimming stroke as breaststroke when, during the swimming window, both the resultant acceleration signal and the resultant angular velocity signal rise, and the number of breathing angles is greater than a preset second quantity threshold.
[0017] In some embodiments, the control method further includes: acquiring the standard parameters corresponding to different standard swimming strokes stored in a database; and providing swimming stroke evaluation or correction suggestions based on the swimming parameters, the user's swimming stroke, and the standard parameters.
[0018] In some implementations, providing swimming posture evaluation or correction suggestions based on the swimming parameters, the user's swimming posture, and the standard parameters includes: obtaining the swimming parameters corresponding to the user's actual swimming posture and the standard parameters corresponding to the swimming posture; and comparing the swimming parameters corresponding to the swimming posture and the standard parameters corresponding to the swimming posture to determine the degree of standard of the user's swimming posture.
[0019] In some implementations, providing swimming posture evaluation or correction suggestions based on the swimming parameters, the user's swimming posture, and the standard parameters includes: obtaining the swimming parameters corresponding to the user's actual swimming posture and the standard parameters corresponding to the swimming posture; comparing the swimming parameters corresponding to the swimming posture and the standard parameters corresponding to the swimming posture to obtain an actual difference; and providing correction suggestions based on the actual difference.
[0020] In some embodiments, the control method further includes: storing the historical swimming parameters and historical swimming strokes generated by the user's historical swimming as historical swimming data into the user's personal database; and obtaining the changing trend of the user's swimming parameters based on the current swimming parameters generated by the user's current swimming and the historical swimming parameters.
[0021] This application also provides an earphone, the earphone including a sensor module and a control module, the sensor module being used to collect detection data; and the control module being communicatively connected to the sensor module and used to execute the control method described in any of the above embodiments.
[0022] In some embodiments, the headphones described above are bone conduction headphones.
[0023] This application also provides a computer-readable storage medium having a program stored thereon, which, when executed by a processor, implements the control method described in any of the above embodiments.
[0024] The control method for headphones, headphones, and computer-readable storage medium provided in this application, when the headphones are in swimming mode, acquire swimming parameters and swimming strokes of the user while swimming based on detection data collected by the sensor module, thereby increasing the functionality of the headphones and expanding their application scenarios.
[0025] Additional aspects and advantages of embodiments of this application will be set forth in part in the description which follows, and in part will be obvious from the description, or may be learned by practice of embodiments of this application.
[0026] Additional aspects and advantages of this application will be set forth in part in the description which follows, and in part will be obvious from the description, or may be learned by practice of this application. Attached Figure Description
[0027] The above and / or additional aspects and advantages of this application will become apparent and readily understood from the description of the embodiments taken in conjunction with the following drawings, wherein:
[0028] Figure 1 is a flowchart illustrating a headphone control method according to some embodiments of this application;
[0029] Figure 2 is a schematic diagram of the structure of the earphone according to some embodiments of this application;
[0030] Figure 3 is a flowchart illustrating the control method of the headphones according to some other embodiments of this application;
[0031] Figure 4 is a structural schematic diagram of the earphone according to some other embodiments of this application;
[0032] Figure 5 is a flowchart illustrating the process of determining whether the posture of the headphones has been successfully calibrated in the headphone control method of some embodiments of this application.
[0033] Figure 6 is a flowchart illustrating the process of obtaining swimming parameters of a user wearing headphones while swimming based on detection data in the headphone control method of some embodiments of this application.
[0034] Figure 7 is a flowchart illustrating the process of determining swimming parameters based on the resultant acceleration signal, resultant angular velocity signal, and attitude angle signal in the headphone control method of some embodiments of this application.
[0035] Figure 8 is a schematic diagram of the freestyle breathing angle in some embodiments of this application;
[0036] Figure 9 is a schematic diagram of freestyle gliding angles according to certain embodiments of this application;
[0037] Figure 10 is a schematic diagram of the breathing angle in frog swimming according to certain embodiments of this application;
[0038] Figure 11 is a flowchart illustrating the process of obtaining the swimming posture of a user wearing headphones while swimming based on detection data in the headphone control method of some embodiments of this application.
[0039] Figure 12 is a flowchart illustrating the process of providing swimming posture evaluation or correction suggestions based on swimming parameters, the user's swimming posture, and standard parameters in the headphone control method of some embodiments of this application.
[0040] Figure 13 is a schematic diagram of the connection state between a computer-readable storage medium and a processor according to certain embodiments of this application. Detailed Implementation
[0041] The embodiments of this application will be further described below with reference to the accompanying drawings. The same or similar reference numerals in the drawings denote the same or similar elements or elements having the same or similar functions throughout.
[0042] Furthermore, the embodiments of this application described below in conjunction with the accompanying drawings are exemplary and are only used to explain the embodiments of this application, and should not be construed as limiting this application.
[0043] In this application, unless otherwise expressly specified and limited, "above" or "below" the second feature can mean that the first feature is in direct contact with the second feature, or that the first feature is in indirect contact with the second feature through an intermediate medium. Furthermore, "above," "on top of," and "over" the second feature can mean that the first feature is directly above or diagonally above the second feature, or simply that the first feature is at a higher horizontal level than the second feature. "Below," "below," and "under" the second feature can mean that the first feature is directly below or diagonally below the second feature, or simply that the first feature is at a lower horizontal level than the second feature.
[0044] With the popularization and development of portable electronic products and smart terminals, headphones, as a new type of smart terminal, accompany users in many activities, such as exercise and rest, and can effectively record users' exercise data, activity trajectories, and activity status information. However, current headphones have limited functions and cannot analyze the user's swimming stroke or obtain various indicators under different swimming strokes, which limits the application scenarios of headphones. How to solve the problem of not being able to analyze the user's swimming stroke and obtain various indicators under different swimming strokes due to the limited functions of headphones has become a problem that urgently needs to be solved by those skilled in the art. To solve this problem, this application provides a headphone control method (as shown in Figure 1), a headphone 10 (as shown in Figures 2 and 4), and a computer-readable storage medium 200 (as shown in Figure 13).
[0045] Please refer to Figures 1 and 2. The headphone control method according to an embodiment of this application includes:
[0046] 02: Activate swimming mode on headphones;
[0047] 03: Acquire the detection data collected by sensor module 12;
[0048] 04: Obtain swimming parameters of users wearing headphones while swimming based on the test data; and
[0049] 05: Obtain the user's swimming posture based on the detection data.
[0050] The control method described above can be applied to the earphone 10. The earphone 10 in this embodiment includes a control module 11 and a sensor module 12. The control module 11 is used to start the swimming mode; acquire the detection data collected by the sensor module 12; acquire the swimming parameters of the user wearing the earphone when swimming based on the detection data; and acquire the swimming stroke of the user when swimming based on the detection data.
[0051] Headphones 10 are an audio device primarily used for sound-to-electrical conversion, such as converting audio signals into sound, allowing users to hear music, movies, games, or other audio content, or converting sound into electrical signals. Headphones 10 are designed to provide a private listening environment, allowing users to enjoy audio content alone without disturbing those around them. In this application, headphones 10 are enhanced with the ability to analyze the swimming stroke of the user wearing the headphones and measure various indicators of the user under different swimming strokes. Therefore, headphones 10 also need to monitor and record various data during swimming, and possess strong waterproof capabilities to ensure that headphones 10 can be completely submerged in water and used underwater for extended periods. This ensures that headphones 10 can collect various detection data and determine swimming parameters and strokes during prolonged swimming by the user wearing the headphones. The earphone 10 in this application can be a bone conduction earphone. Bone conduction earphones use the bones of the human body to conduct sound, rather than traditional earphones that transmit sound waves through the air. Bone conduction earphones do not block the ears when worn by the user. Compared to in-ear earphones, bone conduction earphones can avoid hearing damage caused by prolonged use, while ensuring that the user can hear external sounds, thus improving the user's safety during outdoor activities. Therefore, in this application, the earphone 10 can also be a bone conduction earphone containing a storage module.
[0052] Specifically, the earphone 10 includes a control module 11 and a sensor module 12. The control module 11 and the sensor module 12 can be connected via a wired communication connection formed by data lines or a wireless communication connection formed by wireless signals. In the earphone control method provided in this application, steps 02, 03, 04, and 05 are all executed by the control module 11. The control module 11 is the module inside the earphone 10 responsible for processing various data and coordinating various functions (including but not limited to audio processing, device connection, power management, user interaction, etc.). In this application, the control module 11 is used to allow the user wearing the earphone to select the mode of the earphone 10, and to obtain the user's swimming parameters and swimming stroke based on the detection data obtained by the sensor module 12. The sensor module 12 provides additional functional support for the earphone 10 and is the module in the earphone 10 that obtains external information and / or the earphone 10's own parameters. The sensor module 12 can be an accelerometer (for detecting the three-axis acceleration of the earphone 10), a gyroscope (for detecting the three-axis angular velocity of the earphone 10), a magnetometer (also known as a compass sensor, used to detect the direction of the Earth's magnetic field, helping the earphone 10 determine its orientation, which is very important for the positioning and navigation applications of the earphone 10), a heart rate sensor (to measure the user's heart rate through skin contact), and a pressure sensor (for detecting the pressure exerted by the user on the earphones when wearing them, which can be used for functions such as adjusting volume, controlling playback, or answering phone calls). In this application, the sensor module 12 is used to collect various data from the user wearing the earphone 10 while swimming, thereby helping the control module 11 obtain the user's swimming parameters and swimming style.
[0053] Specifically, referring to Figure 2, the earphone 10 also includes a battery compartment 117 for housing batteries and / or a control box 119 with control functions. The control box 119 can be used to control the power on / off of the earphone 10 and adjust the volume of the earphone 10. Specifically, the control box 119 includes a first housing, a control module 11, and a sensor module 12. The control module 11 and the sensor module 12 can be installed in the first housing. The battery compartment 117 includes a second housing and a battery, which is installed in the second housing and is used to power the earphone 10 so that the earphone 10 can work normally.
[0054] Specifically, the earphone 10 also includes a connector 13, which includes an ear hook 137 and / or a back hook 139. When the user wears the earphone 10, the back hook 139 is worn on the head, and the ear hook 137 is worn behind the ear, thereby improving the stability of the earphone 10 and making it less likely to fall off when the user is outdoors or exercising. The back hook 139 is used to connect the battery box 117 and the control box 119. The earphone 10 also includes a transducer assembly 30. The ear hook 137 is used to connect the battery box 117 and the transducer assembly 30, and to connect the control box 119 and the transducer assembly 30. The transducer assembly 30 is designed to fit in contact with the skin. When the earphone 10 is in use, the transducer assembly 30 enables the user to hear sound through mechanical vibration.
[0055] Specifically, in steps 02 and 03, the user wearing headphones 10 can activate the swimming mode of headphones 10 through the control module 11 and control the sensor module 12 to collect detection data related to the user's swimming. In step 04, the control module 11 obtains the user's swimming parameters based on the detection data. More specifically, the swimming parameters include freestyle real-time breathing angle, freestyle real-time gliding angle, breaststroke real-time breathing angle, breaststroke real-time gliding time, breathing frequency, freestyle breathing angle, freestyle maximum breathing angle, freestyle pitch angle, breaststroke breathing angle, breaststroke maximum breathing angle, breaststroke total gliding time, freestyle total duration, and breaststroke total duration. Among these, the breathing angle refers to the relative position and direction of the head to the water surface when breathing above the water during swimming. Therefore, maintaining the correct breathing angle is crucial for maintaining body balance, improving swimming efficiency, and avoiding choking on water during swimming. Pitch angle typically refers to the angle change of a swimmer's body posture and head position relative to the water surface. Therefore, maintaining a good pitch angle during swimming is crucial for improving swimming efficiency, reducing drag, maintaining correct breathing, and enhancing overall performance. Gliding angle refers to the angle between the swimmer's head and the vertical plane during swimming. An ideal gliding angle helps reduce water resistance and improve swimming efficiency. In step 05, the control module 11 acquires the user's swimming parameters based on these detection data and also determines the type of swimming stroke, which includes, but is not limited to, freestyle, breaststroke, backstroke, and butterfly. The control module 11 can determine the proportion of each stroke based on the type of stroke and swimming parameters.
[0056] In some embodiments, referring to Figures 2 and 3, the control method of this application further includes:
[0057] 01: Issue a prompt message to guide the user to calibrate the posture of the headphones 10.
[0058] The control method described above can be applied to the earphone 10. The control module 11 is also used to issue prompts to guide the user to calibrate the posture of the earphone 10.
[0059] Understandably, in some implementations, before the control sensor module 12 collects data, a prompt message may be issued to the user to guide the user in calibrating the posture of the earphone 10. Specifically, the control module 11 guides the user to look forward through voice prompts or vibration prompts, thereby determining the reference angle in the subsequent posture angle detection process to calibrate the posture of the earphone 10 and ensure the accuracy of the posture angles collected in subsequent steps.
[0060] Please refer to Figures 3 and 4. In some embodiments, the sensor module 12 includes a gyroscope 121, and the detected data includes the three-axis angular velocity signal detected by the gyroscope 121. The control method of this application further includes:
[0061] 021: Confirm whether the posture of the earphone 10 has been successfully calibrated;
[0062] 023: With the attitude calibration of the earphone 10 successful, calibrate the three-axis angular velocity signals detected by the gyroscope 121; and
[0063] 025: If the attitude calibration of the earphone 10 fails, the swimming mode of the earphone 10 will be turned off.
[0064] The above-mentioned control method for headphones can be applied to headphones 10. The control module 11 is also used to: determine whether the attitude of headphones 10 has been successfully calibrated; if the attitude of headphones 10 has been successfully calibrated, calibrate the three-axis angular velocity signal detected by the gyroscope 121; and if the attitude of headphones 10 has not been successfully calibrated, turn off the swimming mode of headphones 10.
[0065] Specifically, in step 021, after the earphone 10 activates swimming mode, before the control module 11 controls the sensor module 12 to collect detection data, it first needs to ensure the accuracy of the detection data collected by the sensor module 12. Therefore, the control module 11 first determines whether the attitude of the earphone 10 has been successfully calibrated. In steps 023 and 025, if the attitude of the earphone 10 is successfully calibrated, the control module 11 continues with subsequent steps, namely, calibrating the three-axis angular velocity signal detected by the gyroscope 121 to further ensure the accuracy of the three-axis angular velocity signal measured by the gyroscope 121. However, if the attitude calibration of the earphone 10 is unsuccessful, the control module 11 needs to control the earphone 10 to deactivate swimming mode. After the user wearing the earphone recalibrates the attitude of the earphone 10 and activates swimming mode again, the control module 11 re-determines whether the attitude calibration of the earphone 10 has been successful.
[0066] In some embodiments, referring to Figures 4 and 5, step 021 includes:
[0067] 0211: Combine the triaxial acceleration signals at each preset moment within the preset calibration window to obtain the resultant acceleration signal at the preset moment;
[0068] 0213: Calculate the maximum, minimum, and average values of the resultant acceleration signal at all preset times within the calibration window; and
[0069] 0215: Determine whether the headphone's attitude has been successfully calibrated based on the maximum, minimum, and average values of the combined acceleration signal.
[0070] The control method described above can be applied to the earphone 10. The control module 11 is also used to: fuse the triaxial acceleration signals at each preset moment during the preset calibration window to obtain the resultant acceleration signal at the preset moment; calculate the maximum value, minimum value and average value of the resultant acceleration signal at all preset moments during the calibration window; and determine whether the attitude of the earphone has been successfully calibrated based on the maximum value, minimum value and average value of the resultant acceleration signal.
[0071] Specifically, in step 0211, the preset calibration window period can be a time window period set in advance by the user, or a time window period preset based on empirical values before the headphones 10 leave the factory. The control module 11 obtains the user's swimming parameters and swimming stroke based on the detection data collected by the sensor module 12 during this time window period. Therefore, before collecting the detection data, the control module 11 needs to fuse the triaxial acceleration signals at each preset moment within this window period to obtain the resultant acceleration signal at the preset moment. Compared to the acceleration signal of a single axis, the resultant acceleration signal can more accurately reflect the attitude of the headphones 10. In steps 0213 and 0215, the control module 11 calculates the maximum, minimum, and average values of the resultant acceleration signals at all preset moments within the calibration window period, thereby determining whether the attitude of the headphones 10 has been successfully calibrated based on the maximum, minimum, and average values of the resultant acceleration signals. More specifically, the earphone 10 stores a total acceleration calibration threshold for determining whether the attitude of the earphone 10 has been successfully calibrated. This total acceleration calibration threshold includes three sets: a maximum total acceleration calibration threshold, a minimum total acceleration calibration threshold, and a range of average total acceleration calibration thresholds. During the calibration window, if the maximum value of the total acceleration signal is less than the maximum total acceleration calibration threshold, the minimum value of the total acceleration signal is greater than the minimum total acceleration calibration threshold, and the average value of the total acceleration is within the range of the average total acceleration calibration threshold, then the attitude of the earphone 10 meets the characteristic that the user wearing the earphone 10 is looking forward and remaining stationary, and the attitude calibration of the earphone 10 is determined to be successful. Conversely, during the calibration window, if the maximum value of the total acceleration signal is greater than the maximum total acceleration calibration threshold, or the minimum value of the total acceleration signal is less than the minimum total acceleration calibration threshold, or the average value of the total acceleration is not within the range of the average total acceleration calibration threshold, then the attitude of the earphone 10 does not meet the characteristic that the user wearing the earphone 10 is looking forward and remaining stationary, and the attitude calibration of the earphone 10 is determined to be unsuccessful.
[0072] Referring to Figures 4 and 6, in some embodiments, the sensor module 12 includes an accelerometer 122 and a gyroscope 121. The detected data includes triaxial acceleration signals detected by the accelerometer 122 and triaxial angular velocity signals detected by the gyroscope 121. Step 04 includes:
[0073] 041: Complementary filtering and fusion processing is performed on the triaxial acceleration signal and triaxial angular velocity signal to obtain the resultant acceleration signal, resultant angular velocity signal, and quaternion data;
[0074] 042: Solve the quaternion data to obtain the headphone's attitude angle signal; and
[0075] 044: Determine swimming parameters based on the resultant acceleration signal, resultant angular velocity signal, and attitude angle signal.
[0076] The control method described above can be applied to the earphone 10. The control module 11 is also used to: perform complementary filtering and fusion processing on the triaxial acceleration signal and the triaxial angular velocity signal to obtain the resultant acceleration signal, the resultant angular velocity signal, and quaternion data; solve the quaternion data to obtain the attitude angle signal of the earphone; and determine the swimming parameters based on the resultant acceleration signal, the resultant angular velocity signal, and the attitude angle signal.
[0077] Specifically, in step 041, the control module 11 filters and fuses the triaxial acceleration and triaxial angular velocity signals. Filtering eliminates noise in the signals, further ensuring their accuracy. Simultaneously, the triaxial acceleration and angular velocity signals are fused separately to obtain a resultant acceleration signal and a resultant angular velocity signal. Compared to single-axis acceleration or angular velocity signals, the resultant acceleration and resultant angular velocity signals more comprehensively reflect the attitude of the earphone 10. In conjunction with step 042, the control module 11 also performs complementary filtering and fusion processing on the triaxial acceleration and angular velocity signals to obtain quaternion data. A quaternion consists of one real part and three imaginary parts, which can be used to represent mathematical concepts of rotation and direction in three-dimensional space. By solving the quaternion data, the control module 11 obtains the attitude angle signal reflecting the attitude of the earphone 10. Then, in step 044, swimming parameters are determined based on the resultant acceleration signal, resultant angular velocity signal, and attitude angle signal.
[0078] Referring to Figures 4 and 6, in some embodiments, the sensor module 12 includes an accelerometer 122 and a gyroscope 121. The detected data includes triaxial acceleration signals detected by the accelerometer 122 and triaxial angular velocity signals detected by the gyroscope 121. Step 04 further includes:
[0079] 043: Process the triaxial acceleration and triaxial angular velocity signals at each preset moment within a preset swimming window to obtain the resultant acceleration signal, resultant angular velocity signal, and attitude angle signal of the headphones at multiple preset moments within the swimming window; and
[0080] 044: Determine swimming parameters based on the resultant acceleration signal, resultant angular velocity signal, and attitude angle signal.
[0081] The control method described above can be applied to the headphones 10. The control module 11 is also used to: process the triaxial acceleration signal and triaxial angular velocity signal at each preset moment during the preset swimming window to obtain the resultant acceleration signal, resultant angular velocity signal and attitude angle signal of the headphones at multiple preset moments during the swimming window; and determine the swimming parameters based on the resultant acceleration signal, resultant angular velocity signal and attitude angle signal.
[0082] Understandably, when the sensor module 12 acquires high-quality data, the triaxial acceleration signal and triaxial angular velocity signal can be used directly without filtering. That is, the control module 11 directly processes the triaxial acceleration signal and triaxial angular velocity signal at each preset moment within the preset swimming window to obtain the resultant acceleration signal, resultant angular velocity signal, and attitude angle signal of the headphones at multiple preset moments within the swimming window, and determines the swimming parameters based on the resultant acceleration signal, resultant angular velocity signal, and attitude angle signal.
[0083] Please refer to Figures 4 and 7. In some embodiments, swimming parameters include freestyle breathing angle, and attitude angle signals include roll angle signals. Step 044 includes:
[0084] 0441: Obtain the peak value and trough average value of the resultant acceleration signal and the resultant angular velocity signal; and
[0085] 0442: Within the first preset period, if the roll angle signal rises and then falls, and both the resultant acceleration signal and the resultant angular velocity signal have at least two peak values greater than the first preset peak threshold and at least two trough average values less than the first preset trough threshold, the maximum roll angle within the first preset period is determined as the freestyle breathing angle.
[0086] The control method described above can be applied to the earphone 10. The control module 11 is also used to: acquire the peak maximum value and trough average value of the resultant acceleration signal and the resultant angular velocity signal; and within a first preset period, when the roll angle signal first rises and then falls, and both the resultant acceleration signal and the resultant angular velocity signal have at least two peak maximum values greater than the first preset peak threshold and at least two trough average values less than the first preset trough threshold, determine the maximum roll angle within the first preset period as the freestyle breathing angle.
[0087] Specifically, the formula for calculating the roll angle signal is: Roll=atan2(2*q2*q3+2*q0*q1,-2*q1*q1-2*q2*q2);
[0088] In the above formula, q0, q1, q2, and q3 are quaternion data, and Roll is the roll angle. In step 0441, the swimming parameters need to be obtained based on the peak maximum value and trough average value of the resultant acceleration signal and the resultant angular velocity signal. More specifically, in step 0442, the first preset period is a signal detection period preset inside the earphone 10. Within the first preset period, if the roll angle signal first rises and then falls, and both the resultant acceleration signal and the resultant angular velocity signal have at least two peak maximum values greater than the first preset peak threshold and at least two trough average values less than the first preset trough threshold, the control module 11 determines the maximum roll angle within the first preset period as the freestyle breathing angle. Referring to Figure 8, angle α in Figure 8 is the breathing angle. The breathing angle refers to the relative position and direction of the head and the water surface when the head is above the water surface to breathe during swimming. Therefore, the breathing angle can be determined by the roll angle.
[0089] Please refer to Figures 4 and 7. In some embodiments, swimming parameters include freestyle gliding angles, and attitude angle signals include roll angle and pitch angle signals. Step 044 includes:
[0090] 0441: Obtain the peak value and trough average value of the resultant acceleration signal and the resultant angular velocity signal; and
[0091] 0443: Within the first preset period, if the fluctuation amplitude of the roll angle signal is less than the preset first fluctuation threshold, the average pitch angle within the first preset period is determined as the freestyle gliding angle.
[0092] The control method described above can be applied to the earphone 10. The control module 11 is also used to: acquire the peak value and trough value of the resultant acceleration signal and the resultant angular velocity signal; and determine the average pitch angle within the first preset period as the freestyle gliding angle when the fluctuation amplitude of the roll angle signal is less than the preset first fluctuation threshold.
[0093] Specifically, the formula for calculating the pitch angle signal is: Pitch = asin(-2*q1*q3 + 2*q0*q2);
[0094] In the above formula, q0, q1, q2, and q3 are quaternion data, and Pitch is the pitch angle. In step 0441, the swimming parameters need to be obtained based on the peak maximum value and trough average value of the resultant acceleration signal and the resultant angular velocity signal. More specifically, in step 0443, the first preset period is a signal detection period preset inside the earphone 10. Within the first preset period, if the fluctuation amplitude of the roll angle signal is less than the preset first fluctuation threshold, the control module 11 determines the average pitch angle within the first preset period as the freestyle gliding angle. Referring to Figure 9, angle β in Figure 9 is the gliding angle. The gliding angle refers to the angle between the user's head and the vertical plane during swimming. An ideal gliding angle can help the user reduce water resistance and improve swimming efficiency. Therefore, the gliding angle can be determined by the roll angle and the pitch angle.
[0095] Please refer to Figures 4 and 7. In some embodiments, swimming parameters include the breaststroke breathing angle, and the attitude angle signal includes the pitch angle signal. Step 044 includes:
[0096] 0441: Obtain the peak value and trough average value of the resultant acceleration signal and the resultant angular velocity signal; and
[0097] 0444: Within the second preset cycle, when the resultant acceleration signal, resultant angular velocity signal, and pitch angle signal all increase, determine the current pitch angle as the breathing angle for breaststroke.
[0098] The control method described above can be applied to the earphone 10. The control module 11 is also used to: acquire the peak value and trough value of the resultant acceleration signal and the resultant angular velocity signal; and within the second preset period, when the resultant acceleration signal, the resultant angular velocity signal and the pitch angle signal all rise, determine the current pitch angle as the breathing angle for breaststroke.
[0099] Specifically, in step 0441, the swimming parameters need to be obtained based on the peak maximum value and trough average value of the resultant acceleration signal and the resultant angular velocity signal. More specifically, in step 0444, the second preset period is a signal detection period preset inside the earphone 10. Within the second preset period, referring to Figure 10, where angle γ is the breathing angle of the breaststroke, if the resultant acceleration signal, resultant angular velocity signal, and pitch angle signal all rise, it indicates that the user wearing the earphone is lifting their head relative to the horizontal plane, i.e., breathing action during the breaststroke. The control module 11 determines the current pitch angle as the breaststroke breathing angle.
[0100] Please refer to Figures 4 and 7. In some embodiments, swimming parameters include breaststroke gliding time, attitude angle signals include pitch angle signals, and step 044 includes:
[0101] 0441: Obtain the peak value and trough average value of the resultant acceleration signal and the resultant angular velocity signal; and
[0102] 0445: Within the second preset period, when the fluctuation amplitude of the pitch angle signal is less than the preset second fluctuation threshold, and the attitude angle signal is within the preset range of the breaststroke gliding pitch angle threshold, the time during which the pitch angle signal is within the preset range of the breaststroke gliding pitch angle threshold is determined as the breaststroke gliding time.
[0103] The control method described above can be applied to the earphone 10. The control module 11 is also used to: acquire the peak value and trough value of the resultant acceleration signal and the resultant angular velocity signal; and within a second preset period, when the fluctuation amplitude of the pitch angle signal is less than a preset second fluctuation threshold and the attitude angle signal is within a preset range of the breaststroke gliding pitch angle threshold, determine the time when the pitch angle signal is within the preset range of the breaststroke gliding pitch angle threshold as the breaststroke gliding time.
[0104] Specifically, in step 0441, the swimming parameters need to be obtained based on the peak maximum value and trough average value of the resultant acceleration signal and the resultant angular velocity signal. More specifically, in step 0445, the second preset period is a signal detection period preset inside the earphone 10. Within the second preset period, if the fluctuation amplitude of the pitch angle signal is less than the preset second fluctuation threshold, and the attitude angle signal is within the preset breaststroke gliding pitch angle threshold range, it indicates that the head of the user wearing the earphone is below the water surface and is looking at the bottom of the water. That is, the user wearing the earphone is in the non-breathing action process of gliding underwater during breaststroke. The control module 11 determines the time when the pitch angle signal is within the preset breaststroke gliding pitch angle threshold range as the breaststroke gliding time.
[0105] Please refer to Figures 4 and 11. In some embodiments, step 05 includes:
[0106] 051: Obtain the number of breathing angles during the preset swimming window;
[0107] 053: During the swimming window, if both the resultant acceleration signal and the resultant angular velocity signal have at least two peaks whose average value is greater than a first preset peak threshold, and the number of breathing angles is greater than a preset first quantity threshold, then the swimming stroke is determined to be freestyle; and
[0108] 055: During the swimming window, if both the combined acceleration signal and the combined angular velocity signal increase, and the number of breathing angles is greater than the preset second quantity threshold, the swimming stroke is determined to be breaststroke.
[0109] The control method described above can be applied to the earphone 10. The control module 11 is further configured to: obtain the number of breathing angles during a preset swimming window; during the swimming window, if both the resultant acceleration signal and the resultant angular velocity signal have at least two peak average values greater than a first preset peak threshold, and the number of breathing angles is greater than a preset first quantity threshold, determine the swimming style as freestyle; during the swimming window, if both the resultant acceleration signal and the resultant angular velocity signal rise, and the number of breathing angles is greater than a preset second quantity threshold, determine the swimming style as breaststroke.
[0110] Specifically, since different swimming strokes have different breathing frequencies, before determining the swimming stroke, the control module 11 first obtains the number of breathing angles within a preset swimming window period. That is, the number of breaths is determined by the number of breathing angles, and then the breathing frequency is determined. In steps 053 and 055, if, within the swimming window period, both the resultant acceleration signal and the resultant angular velocity signal have at least two peak average values greater than the first preset peak threshold, and the number of breathing angles is greater than the preset first quantity threshold, it indicates that the resultant acceleration signal and the resultant angular velocity signal meet the posture characteristics of freestyle swimming, and the current user's breathing frequency also meets the breathing characteristics of freestyle swimming. The control module 11 determines the swimming stroke to be freestyle. If, within the swimming window period, both the resultant acceleration signal and the resultant angular velocity signal increase, and the number of breathing angles is greater than the preset second quantity threshold, it indicates that the resultant acceleration signal and the resultant angular velocity signal meet the posture characteristics of breaststroke swimming, and the current user's breathing frequency also meets the breathing characteristics of breaststroke swimming. The control module 11 determines the swimming stroke to be breaststroke swimming. In addition, if the resultant acceleration signal or resultant angular velocity signal does not meet the above conditions, or if the breathing frequency does not meet the above conditions, the control module 11 determines that the swimming stroke is another swimming stroke type, such as butterfly or backstroke.
[0111] In some implementations, swimming parameters include freestyle breathing angle, freestyle gliding angle, breaststroke breathing angle, breaststroke gliding time, breathing frequency, freestyle maximum breathing angle, freestyle pitch angle, breaststroke maximum breathing angle, breaststroke total gliding time, freestyle total duration, and breaststroke total duration.
[0112] It is understood that, through the above implementation method, the swimming stroke of a user can be determined, as well as the breathing angle, gliding angle, and gliding time of freestyle and breaststroke, and the breathing frequency of breaststroke. The maximum breathing angle of freestyle or breaststroke is the maximum value among the breathing angles of freestyle or breaststroke within a preset swimming time window. The pitch angle of freestyle can be directly determined by the pitch angle signal. In addition, since the swimming process consists of gliding and breathing processes, the total gliding time and total duration of freestyle or breaststroke can be directly determined by the signal curve, thereby determining the proportion of freestyle or breaststroke strokes.
[0113] Please refer to Figures 3 and 4. In some embodiments, the control method of this application further includes:
[0114] 06: Retrieve the standard parameters corresponding to different standard swimming strokes stored in the database;
[0115] 07: Provide swimming posture evaluation or correction suggestions based on swimming parameters, the user's swimming posture, and standard parameters.
[0116] The control method described above can be applied to the earphone 10. The control module 11 is also used to: obtain standard parameters corresponding to different standard swimming strokes stored in the database; and provide swimming stroke evaluation or correction suggestions based on swimming parameters, the user's swimming stroke and standard parameters.
[0117] Specifically, the database contains standard parameters for different swimming strokes. After obtaining the swimming parameters and the user's swimming stroke, the control module 11 compares the user's swimming parameters for the corresponding stroke with the standard parameters to obtain an evaluation of the user's swimming performance and suggestions for correcting the swimming stroke.
[0118] Please refer to Figures 4 and 12. In some embodiments, step 07 includes:
[0119] 071: Obtain swimming parameters corresponding to the user's actual swimming stroke and standard parameters corresponding to the swimming stroke;
[0120] 073: Compare the swimming parameters corresponding to the swimming stroke with the standard parameters corresponding to the swimming stroke to determine the standard of the user's swimming stroke.
[0121] The control method described above can be applied to the earphone 10. The control module 11 is also used to: acquire swimming parameters corresponding to the user's actual swimming stroke and standard parameters corresponding to the swimming stroke; compare the swimming parameters corresponding to the swimming stroke and standard parameters corresponding to the swimming stroke to determine the standard of the user's swimming stroke.
[0122] Specifically, the standardity of a user's swimming posture is determined by comparing the swimming parameters corresponding to the user's actual swimming stroke with the standard parameters corresponding to the swimming stroke.
[0123] Please refer to Figures 4 and 12. In some embodiments, step 07 includes:
[0124] 071: Obtain swimming parameters corresponding to the user's actual swimming stroke and standard parameters corresponding to the swimming stroke;
[0125] 075: Compare the swimming parameters corresponding to the swimming stroke with the standard parameters corresponding to the swimming stroke to obtain the actual difference; and
[0126] 077: Provide corrective suggestions based on the actual difference.
[0127] The control method described above can be applied to the earphone 10. The control module 11 is also used to: acquire swimming parameters corresponding to the user's actual swimming stroke and standard parameters corresponding to the swimming stroke; compare the swimming parameters corresponding to the swimming stroke and standard parameters corresponding to the swimming stroke to obtain the actual deviation; and provide correction suggestions based on the actual difference.
[0128] Specifically, by comparing the swimming parameters corresponding to the user's actual swimming stroke with the standard parameters corresponding to the swimming stroke, the deviation value between the two sets of parameters is obtained, namely the actual deviation in step 075. This quantifies the degree of deviation between the user's actual swimming stroke and the standard swimming stroke, and then provides correction suggestions based on this actual difference. For example, if the user's breathing angle and pitch angle in freestyle are larger than those in standard freestyle, it indicates that the most effective power generation techniques have not been learned during current freestyle breathing and gliding. The headset 10 sends correction suggestions to the user via voice or display screen to help the user correct their freestyle stroke posture.
[0129] Please refer to Figures 3 and 4. In some embodiments, the control method of this application further includes:
[0130] 08: Store the user's historical swimming parameters and swimming strokes as historical swimming data in the user's personal database;
[0131] 09: Based on the current swimming parameters generated by the user's current swimming and the historical swimming parameters, obtain the trend of the user's swimming parameters.
[0132] The control method described above can be applied to the earphone 10. The control module 11 is also used to: store the historical swimming parameters and historical swimming strokes generated by the user's historical swimming as historical swimming data into the user's personal database; and obtain the changing trend of the user's swimming parameters based on the current swimming parameters generated by the user's current swimming and the historical swimming parameters.
[0133] Specifically, the control module 11 also stores the user's historical swimming parameters and swimming strokes in the user's personal database. When the user swims subsequently, the control module 11 compares the current swimming parameters with the historical parameters to obtain the trend of the user's swimming parameters. For example, if the user's current breaststroke breathing angle is smaller than the historical average, it indicates that the current breaststroke breathing is becoming more stable; if the current glide time is longer than the historical average, it indicates that the body is more extended during the current breaststroke glide phase, resulting in less resistance. By comparing the current swimming parameters with the historical parameters, the user can track their swimming stroke learning progress at any time, thereby further expanding the application scenarios of the headphones 10.
[0134] In summary, the headphone control method provided in this application, when the headphone 10 starts swimming mode, obtains the swimming parameters of the user wearing the headphone 10 and the user's swimming stroke based on the detection data collected by the sensor module 12, thereby increasing the functionality of the headphone 10 and expanding the usage scenarios of the headphone 10.
[0135] Please refer to Figures 2, 3 and 13. In some embodiments, this application also provides a computer-readable storage medium 200 storing a computer program 202, which, when executed by a processor, implements the control method in any of the above embodiments.
[0136] For example, when computer program 202 is executed by processor 20, the following control method is implemented:
[0137] 02: Activate swimming mode on headphones;
[0138] 03: Acquire the detection data collected by sensor module 12;
[0139] 04: Obtain swimming parameters of users wearing headphones while swimming based on the detection data;
[0140] 05: Obtain the user's swimming posture based on the detection data.
[0141] For example, when computer program 202 is executed by processor 20, the following control method is implemented:
[0142] 01: Issue a prompt message to guide the user to calibrate the posture of the headphones 10.
[0143] For example, when computer program 202 is executed by processor 20, it can also implement the control methods in 021, 0211, 0213, 0215, 023, 025, 041, 042, 043, 044, 0441, 0442, 0443, 0444, 0445, 051, 053, 055, 06, 07, 071, 073, 075, 077, 08 and 09.
[0144] In the computer-readable storage medium 200 of this application, by decoding video stream data, when the earphone 10 starts swimming mode, the swimming parameters of the user wearing the earphone 10 and the swimming stroke of the user are obtained according to the detection data collected by the sensor module 12, thereby increasing the function of the earphone 10 and expanding the usage scenarios of the earphone 10.
[0145] In the description of this specification, the references to terms such as "certain embodiments," "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., refer to specific features, structures, materials, or characteristics described in connection with that embodiment or example, which are included in at least one embodiment or example of this application. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described may be combined in a suitable manner in any one or more embodiments or examples. Moreover, without contradiction, those skilled in the art can combine and integrate the different embodiments or examples described in this specification, as well as the features of different embodiments or examples.
[0146] Furthermore, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of indicated technical features. Thus, a feature defined as "first" or "second" may explicitly or implicitly include at least one of the stated features. In the description of this application, "multiple" means at least two, such as two or three, unless otherwise explicitly specified.
[0147] Although embodiments of this application have been shown and described above, it is understood that the above embodiments are exemplary and should not be construed as limiting this application. Those skilled in the art can make changes, modifications, substitutions and variations to the above embodiments within the scope of this application, the scope of which is defined by the claims and their equivalents.
Claims
1. A method for controlling headphones, wherein, include: The headphones are activated in swimming mode; Acquire detection data collected by the sensor module; Based on the detection data, swimming parameters of the user wearing the headphones are obtained during swimming. and The user's swimming posture during swimming is obtained based on the detection data.
2. The control method according to claim 1, wherein, Also includes: A prompt message is issued to guide the user in calibrating the posture of the headphones.
3. The control method according to claim 2, wherein, The sensor module includes a gyroscope, and the detection data includes the three-axis angular velocity signals detected by the gyroscope; The control method further includes: Determine whether the orientation of the headphones has been successfully calibrated; If the headphone's attitude calibration is successful, calibrate the three-axis angular velocity signals detected by the gyroscope; and If the headset fails to perform attitude calibration, the headset will disable the swimming mode.
4. The control method according to claim 3, wherein, The sensor module also includes an accelerometer, and the detection data includes triaxial acceleration signals detected by the accelerometer; Determining whether the posture of the headphones has been successfully calibrated includes: The triaxial acceleration signals at each preset moment within a preset calibration window are fused to obtain the resultant acceleration signal at the preset moment; Calculate the maximum, minimum, and average values of the resultant acceleration signal at all preset times within the calibration window; and The headphone's attitude is determined to be successfully calibrated based on the maximum, minimum, and average values of the combined acceleration signal.
5. The control method according to claim 1, wherein, The sensor module includes an accelerometer and a gyroscope, and the detection data includes the triaxial acceleration signal detected by the accelerometer and the triaxial angular velocity signal detected by the gyroscope. The step of obtaining swimming parameters of a user wearing the headphones while swimming based on the detection data includes: The triaxial acceleration signal and the triaxial angular velocity signal are subjected to complementary filtering and fusion processing to obtain the resultant acceleration signal, the resultant angular velocity signal, and quaternion data; Solve the quaternion data to obtain the attitude angle signal of the earphone; and The swimming parameters are determined based on the resultant acceleration signal, the resultant angular velocity signal, and the attitude angle signal.
6. The control method according to claim 1, wherein, The sensor module includes an accelerometer and a gyroscope, and the detection data includes the triaxial acceleration signal detected by the accelerometer and the triaxial angular velocity signal detected by the gyroscope. The step of obtaining swimming parameters of a user wearing the headphones while swimming based on the detection data includes: The triaxial acceleration signal and the triaxial angular velocity signal are processed at each preset moment during a preset swimming window to obtain the resultant acceleration signal, resultant angular velocity signal, and attitude angle signal of the headphones at multiple preset moments during the swimming window. and The swimming parameters are determined based on the resultant acceleration signal, the resultant angular velocity signal, and the attitude angle signal.
7. The control method according to claim 5 or 6, wherein, The swimming parameters include the freestyle breathing angle, and the attitude angle signal includes the roll angle signal. Determining the swimming parameters based on the resultant acceleration signal, the resultant angular velocity signal, and the attitude angle signal includes: Obtain the peak value and trough average value of the resultant acceleration signal and the resultant angular velocity signal; and Within a first preset period, if the roll angle signal first rises and then falls, and both the resultant acceleration signal and the resultant angular velocity signal have at least two peak values greater than a first preset peak threshold and at least two trough average values less than a first preset trough threshold, the maximum roll angle within the first preset period is determined as the freestyle breathing angle.
8. The control method according to claim 5 or 6, wherein, The swimming parameters include the freestyle gliding angle, and the attitude angle signals include the roll angle signal and the pitch angle signal. Determining the swimming parameters based on the resultant acceleration signal, the resultant angular velocity signal, and the attitude angle signals includes: Obtain the peak value and trough average value of the resultant acceleration signal and the resultant angular velocity signal; and Within a first preset period, if the fluctuation amplitude of the roll angle signal is less than a preset first fluctuation threshold, the average pitch angle within the first preset period is determined as the freestyle gliding angle.
9. The control method according to claim 5 or 6, wherein, The swimming parameters include the breaststroke breathing angle, and the attitude angle signal includes the pitch angle signal. Determining the swimming parameters based on the resultant acceleration signal, the resultant angular velocity signal, and the attitude angle signal includes: Obtain the peak value and trough average value of the resultant acceleration signal and the resultant angular velocity signal; and Within the second preset period, when the resultant acceleration signal, the resultant angular velocity signal, and the pitch angle signal all increase, the current pitch angle is determined as the breathing angle for breaststroke.
10. The control method according to claim 5 or 6, wherein, The swimming parameters include breaststroke gliding time, and the attitude angle signal includes pitch angle signal. Determining the swimming parameters based on the resultant acceleration signal, the resultant angular velocity signal, and the attitude angle signal includes: Obtain the peak value and trough average value of the resultant acceleration signal and the resultant angular velocity signal; and Within a second preset period, if the fluctuation amplitude of the pitch angle signal is less than a preset second fluctuation threshold, and the attitude angle signal is within a preset range of the breaststroke gliding pitch angle threshold, the time during which the pitch angle signal is within the preset range of the breaststroke gliding pitch angle threshold is determined as the breaststroke gliding time.
11. The control method according to claim 5 or 6, wherein, The step of obtaining the swimming stroke of a user wearing the headphones during swimming based on the detection data includes: Obtain the number of breathing angles during the preset swimming window; During the swimming window, if both the resultant acceleration signal and the resultant angular velocity signal have at least two peak averages greater than a first preset peak threshold, and the number of breathing angles is greater than a preset first quantity threshold, then the swimming stroke is determined to be freestyle; and During the swimming window, if both the combined acceleration signal and the combined angular velocity signal increase, and the number of breathing angles is greater than a preset second threshold, the swimming stroke is determined to be breaststroke.
12. The control method according to claim 1, wherein, The control method further includes: Retrieve the standard parameters corresponding to different standard swimming strokes stored in the database; and Based on the swimming parameters, the user's swimming style, and the standard parameters, provide swimming style evaluation or correction suggestions.
13. The control method according to claim 12, wherein, The provision of swimming posture evaluation or correction suggestions based on the swimming parameters, the user's swimming posture, and the standard parameters includes: Obtain the swimming parameters corresponding to the swimming stroke the user actually uses while swimming, and the standard parameters corresponding to the swimming stroke; and By comparing the swimming parameters corresponding to the swimming stroke with the standard parameters corresponding to the swimming stroke, the standardity of the user's swimming stroke is determined.
14. The control method according to claim 12, wherein, The provision of swimming posture evaluation or correction suggestions based on the swimming parameters, the user's swimming posture, and the standard parameters includes: Obtain the swimming parameters corresponding to the swimming stroke the user actually swims with, and the standard parameters corresponding to the swimming stroke; By comparing the swimming parameters corresponding to the swimming stroke with the standard parameters corresponding to the swimming stroke, the actual difference is obtained; and Based on the actual difference, corrective recommendations are provided.
15. The control method according to claim 1, wherein, The control method further includes: The historical swimming parameters and swimming strokes generated from the user's historical swimming are stored as historical swimming data in the user's personal database; and Based on the current swimming parameters generated by the user's current swimming and the historical swimming parameters, the trend of the user's swimming parameters is obtained.
16. An earphone, wherein, The headphones include: The sensor module is used to collect detection data; and A control module is communicatively connected to the sensor module and is used to execute the control method according to any one of claims 1-15.
17. The headphones according to claim 16, wherein, The headphones are bone conduction headphones.
18. A computer-readable storage medium having a program stored thereon, wherein, When the program is executed by the processor, it implements the control method according to any one of claims 1-15.
Citation Information
Patent Citations
Method for monitoring swimming state by wearable device and wearable device
CN106175781A
Wearing condition detection method and apparatus of wireless earphone, and wireless earphone
CN108966087A
Swimming posture recognition method and device, wearable equipment and storage medium
CN111803902A
Swimming information statistical method, computer readable storage medium and electronic equipment
CN114602155A
Swimming posture recognition method and device based on intelligent wearable equipment
CN116229578A