A device fingerprinting method based on earphone inertial sensor calibration features
Patent Information
- Application Number
- CN202611008531.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-07-08
- Publication Date
- 2026-10-20
AI Technical Summary
此类方案存在致命缺陷:在系统API受限环境下,苹果无线耳机的惯性传感器(IMU)采样率被强制限制在极低的25Hz左右
[0047]本发明通过相邻采样点时域差分运算直接消除传感器固定偏置干扰,保留与出厂校准强相关的量化特征,无需额外滤波与去偏处理,简化流程、提升运算效率、降低噪声影响,保障低采样率条件下校准增益矩阵提取的准确性与稳定性。
Smart Images

Figure FT_1 
Figure FT_2 
Figure QLYQS_26
Abstract
Description
Technical Field
[0001] This invention relates to the field of device identification and social graph collaboration technology, specifically a device fingerprint recognition method based on the calibration features of an earphone inertial sensor. Background Technology
[0002] With the widespread adoption of wireless headphones, exemplified by Apple's AirPods, these wearable devices have evolved from simple audio playback tools into core hubs connecting users' offline social interactions and facilitating multi-device collaboration. In cutting-edge applications such as offline social graph node discovery, seamless cross-device authentication, building networks of familiar relationships, and multi-device collaborative resource scheduling, accurate and stable device identification technology plays a fundamental role. Existing device identification technologies are mainly divided into three categories: hardware identification, software feature identification, and sensor feature identification. All of these have significant technical shortcomings in the wireless headphone scenario.
[0003] Hardware-based fingerprint identification, including MAC addresses and hardware serial numbers, is a traditional method for uniquely identifying devices. However, with the increasing tightening of user privacy protections in iOS and macOS, Apple's wireless headphones now use a randomized MAC address by default, and hardware serial numbers are strictly restricted to system-level access. These high-privilege identifiers are prohibited from being obtained by ordinary applications without authorization and cannot be used in lightweight application scenarios such as social graph discovery.
[0004] Software-based fingerprints include browser user agents (UA), Canvas fingerprints, and WebGL fingerprints. However, these fingerprints are easily tampered with or spoofed by browser privacy plugins, resulting in extremely poor stability. Furthermore, software features only work on the web page of the host device (such as an iPhone) and cannot be directly transmitted to the headset, failing to achieve a unified node identifier across platforms such as headset, mobile phone, and web page, severely limiting their application scenarios.
[0005] Fingerprinting solutions based on motion sensors. Existing technologies mostly employ machine learning methods to directly extract and classify features from the raw vibration data of the sensors. This approach has a fatal flaw: in environments with limited system APIs, the sampling rate of the inertial measurement unit (IMU) in Apple's wireless headphones is forcibly limited to an extremely low 25Hz. At such a stringent low sampling rate, traditional machine learning solutions that rely on high sampling rates (typically >200Hz) completely fail due to insufficient information, unable to generate effective device features. Furthermore, traditional solutions can only achieve device clustering, failing to generate globally unique persistent identifiers, resulting in extremely low entropy values that cannot support accurate differentiation of nodes in large-scale social networks.
[0006] Wireless earbuds, such as Apple's AirPods, incorporate MEMS inertial sensors (accelerometers and gyroscopes) that undergo factory calibration to eliminate deterministic errors such as scale factor errors, non-orthogonality errors, and bias errors introduced during manufacturing. The calibration parameters (gain matrix) are embedded in the device firmware, offering four core advantages: device-specific uniqueness, globally high entropy, persistent invariance, and accessibility without permissions. The calibration parameters are determined by random physical errors in the manufacturing process, ensuring a unique gain matrix for each earbud. They remain unchanged throughout the device's lifespan, unaffected by system updates or factory resets. Sensor data can be accessed via a zero-permission API, requiring no requests for privacy permissions such as microphone or contact access.
[0007] However, existing technologies have not yet found a complete solution to directly extract the factory calibration gain matrix from the raw output data of low sampling rate sensors to generate device fingerprints. This makes it impossible to achieve globally unique, persistent, stable, and cross-platform compatible node identifiers for wireless earphones in harsh scenarios with extremely low sampling rates of 25Hz and no system permissions, thus hindering the development of social graph and collaboration technologies based on wearable devices.
[0008] Furthermore, while existing technologies utilize smartphone inertial sensor calibration parameters to generate device fingerprints, these solutions are applied to smartphone IMUs, which typically have sampling rates of 100–200Hz and adjacent sampling intervals of only 5–10ms. The sensor reading change (ΔO) is naturally small, and rounding errors do not pose a bottleneck. The Nyquist frequency (>50Hz) covers the human motion frequency band, making aliasing negligible. However, in the extremely low sampling rate scenario of wireless headphones (25Hz), the adjacent sampling interval is as high as 40ms (4–8 times that of smartphones). The ΔO magnitude is amplified several times, simultaneously highlighting rounding errors, aliasing noise, and feature distortion. Existing solutions are therefore not directly applicable. Summary of the Invention
[0009] To address the core shortcomings of existing device identification technologies in wireless earphone applications, such as high permission dependence, susceptibility to randomization, and complete failure at extremely low sampling rates (25Hz), this invention proposes a device fingerprinting method based on the calibration features of the earphone's inertial sensor. By inversely extracting the factory-calibrated gain matrix features from the raw data of the low-sampling-rate sensor, a globally unique, persistent, and permission-independent device fingerprint is generated. This solves the technical challenge of accurate and stable node identification for wireless earphones in scenarios limited by extremely low sampling rates (25Hz), providing underlying support for social graph discovery and multi-device collaboration. The technical solution provided by this invention is as follows:
[0010] A device fingerprint recognition method based on the calibration features of an earphone inertial sensor includes the following steps:
[0011] S1, Collect raw time-series data from the MEMS inertial sensor built into the target wireless earphone. The MEMS inertial sensor includes a gyroscope and an accelerometer. The raw time-series data includes a timestamp and the output values of the X, Y, and Z axes sensors.
[0012] S2, calculate the difference between adjacent sampling points directly along the time dimension of the collected raw time series data to obtain differential data;
[0013] S3, initialize a 3×3 initial gain matrix, set initial threshold coefficients, filter differential data from smallest to largest threshold, estimate the corresponding ADC integer difference for each batch of filtered differential data through the inverse matrix of the current gain matrix, filter reliable differential data based on rounding error, and iteratively solve the gain matrix using the least squares method until the matrix converges or the full data processing is completed to obtain the calibration gain matrix.
[0014] S4. Perform an invertibility check on the calibration gain matrix obtained through iteration. Determine whether the matrix is invertible by calculating the matrix condition number. Eliminate invalid matrices with an excessive condition number and retain calibration gain matrices that meet the invertibility requirements.
[0015] S5, based on the verified calibration gain matrix, generates a gyroscope calibration fingerprint and an accelerometer calibration fingerprint that are uniquely bound to the target wireless earphone, and combines the two in a dimension to generate a comprehensive device fingerprint;
[0016] S6 performs Euclidean distance matching between the device fingerprint generated by the wireless earphone to be identified and the fingerprint sample, outputs the unique device identifier result, and completes the device identity determination.
[0017] Preferably, the specific steps of S1 are as follows:
[0018] S11 deploys a data acquisition application on a smart device and connects to the target wireless earphone;
[0019] S12 calls the system's open, unauthorized sensor interface to collect raw timing data from the gyroscope and accelerometer at a fixed sampling rate of 25Hz;
[0020] S13, record each piece of data collected as text data, including timestamp, X-axis value, Y-axis value and Z-axis value;
[0021] S14, store the collected text data to the local file system in timestamp order.
[0022] Preferably, the specific steps of S2 are as follows:
[0023] S21: Read all the raw timing data of the target wireless earphone from the storage file, sort it by timestamp, and extract the three-axis values to form... The original data matrix ,in This represents the total number of sampling points;
[0024] S22, for the original data matrix The element-wise difference between adjacent sampling points is calculated directly along the time dimension to obtain the difference data matrix. .
[0025] Preferably, the specific steps of S3 are as follows:
[0026] S31, Construct the initial gain matrix ,in For nominal gain, It is a 3-order identity matrix;
[0027] S32, Set the initial threshold coefficient Calculate the current batch The current batch difference data matrix is obtained. ;
[0028] S33, for the current batch difference data matrix Through the gain inverse matrix Estimate the corresponding ADC integer difference matrix The calculation formula is: ,in, This is the rounding function. This is a matrix multiplication operation. for The transpose of the matrix;
[0029] S34, Calculate the rounding error matrix Reliable data rows whose three-axis rounding errors are all less than the preset strictness threshold are retained to obtain reliable differential data;
[0030] S35, determine whether the initial gain matrix calculation has been completed. If the initial calculation has not been completed, accumulate reliable difference data. When the total number of accumulated reliable difference data reaches the preset minimum number of samples and the matrix rank is not less than 3, execute the least squares method to solve and update the gain matrix. If the initial calculation has been completed, directly execute the least squares method to update the gain matrix for the current batch of reliable difference data.
[0031] S36, Amplify the threshold coefficient by a preset magnification of 1.5, and repeat steps S32 to S35;
[0032] S37. When the change in the gain matrix in adjacent rounds is less than the preset convergence threshold, the matrix is determined to have converged and the iteration is terminated; or when the threshold covers the entire difference data, the iteration ends.
[0033] S38, obtain the calibration gain matrix .
[0034] Preferably, in S31, for the gyroscope, the nominal gain is... The value is 0.061 degrees / second; for the accelerometer, the nominal gain is... The value is 0.000598 m / s 2 .
[0035] Preferably, the specific steps of S4 are as follows:
[0036] S41, Calculate the calibration gain matrix If the condition number is less than the reciprocal threshold of floating-point precision, the matrix is determined to be numerically invertible, and the process proceeds to the next step; otherwise, it is determined to be an invalid matrix, the matrix is discarded, and data is collected again to perform iterative estimation.
[0037] S42, Record the calibration gain matrix that meets the requirements. The conditional values and fitting residuals are used for subsequent fingerprint quality assessment.
[0038] Preferably, the specific steps of S5 are as follows:
[0039] S51, for the gyroscope calibration gain matrix, the 9 floating-point elements in its 3×3 matrix serve as the unique fingerprint of the gyroscope;
[0040] S52, for the accelerometer calibration gain matrix, the 9 floating-point elements in its 3×3 matrix are directly used as the unique fingerprint of the accelerometer;
[0041] S53 directly concatenates the 9-dimensional vector of the gyroscope's unique fingerprint with the 9-dimensional vector of the accelerometer's unique fingerprint in terms of dimensions to generate an 18-dimensional comprehensive device fingerprint.
[0042] Preferably, the specific steps of S6 are as follows:
[0043] S61, Calculate the Euclidean distance between the integrated device fingerprint of the device to be identified and the integrated device fingerprints of each registered sample in the fingerprint database: , This is the comprehensive fingerprint vector of the device to be identified. This is a comprehensive fingerprint vector of devices that have been registered in the fingerprint database;
[0044] S62, set the matching judgment threshold. When the Euclidean distance is less than the preset threshold, it is judged as the same device and the corresponding device unique identifier is output.
[0045] S63, when there is no matching sample in the fingerprint database, the comprehensive fingerprint of the device to be identified is added to the fingerprint database as a new entry, and a new unique device identifier is assigned.
[0046] Compared with the prior art, the beneficial effects achieved by the present invention are:
[0047] This invention directly eliminates sensor fixed bias interference through time-domain difference operations of adjacent sampling points, retains quantization characteristics strongly correlated with factory calibration, eliminates the need for additional filtering and debiasing processing, simplifies the process, improves computational efficiency, reduces noise impact, and ensures the accuracy and stability of calibration gain matrix extraction under low sampling rate conditions.
[0048] This invention initializes the gain matrix with nominal gain, uses progressive thresholds from small to large to filter small-amplitude differential data in batches, and combines least squares method for iterative updates to solve the technical problems of large rounding errors, insufficient estimation accuracy, and feature distortion caused by signal aliasing at a low sampling rate of 25Hz.
[0049] This invention uses the matrix condition number to determine the invertibility of the gain matrix value, automatically eliminates abnormal and invalid matrices, ensures that the generated fingerprint is valid, reliable, and computable, avoids recognition failure due to matrix singularities, and builds a solid quality guarantee for the unique identification of the device. Attached Figure Description
[0050] The accompanying drawings are provided to further illustrate the invention and form part of the specification. They are used in conjunction with embodiments of the invention to explain the invention and do not constitute a limitation thereof. In the drawings:
[0051] Figure 1 This is an overall flowchart of the identification method proposed in this invention;
[0052] Figure 2 This is the iterative estimation process for the progressive threshold of the gain matrix. Detailed Implementation
[0053] The technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.
[0054] To make the above-mentioned objectives, features and effects of the present invention more apparent and understandable, the present invention will be further described in detail below with reference to the accompanying drawings and specific embodiments.
[0055] Example 1: A device fingerprint recognition method based on the calibration features of an earphone inertial sensor, such as... Figure 1 As shown, it includes the following steps:
[0056] S1, the target wireless earphone is connected via Bluetooth through a data acquisition application to collect the raw time-series data of its built-in MEMS inertial sensor. The MEMS inertial sensor includes at least one of a gyroscope and an accelerometer. The raw time-series data includes a timestamp and the output values of the X, Y, and Z axis sensors.
[0057] S2 calculates the difference between adjacent sampling points directly along the time dimension of the collected raw time-series data to obtain differential data. This eliminates the interference of fixed bias terms on the extraction of the calibration gain matrix;
[0058] S3, Initialize the 3×3 initial gain matrix ,in For nominal gain, It is a 3x3 identity matrix; set the initial threshold coefficient. Differential data are filtered from smallest to largest based on a threshold. For each batch of filtered differential data, the corresponding ADC integer difference is estimated using the inverse of the current gain matrix. Reliable differential data are then filtered based on rounding errors. The gain matrix is iteratively solved using the least squares method until the matrix converges or all data is processed, resulting in the calibration gain matrix. ;
[0059] S4, the calibration gain matrix obtained through iteration Perform reversibility verification by calculating the matrix condition number to determine whether the matrix is invertible, discard invalid matrices with excessive condition numbers, and retain calibration gain matrices that meet the reversibility requirements;
[0060] S5, based on the verified calibration gain matrix, generates gyroscope calibration fingerprints that are uniquely bound to the target wireless earphone. accelerometer calibration fingerprint The two are then combined in a dimensional manner to generate a high-entropy comprehensive device fingerprint. ;
[0061] S6 performs Euclidean distance matching between the calibrated fingerprint generated by the wireless earphone to be identified and the fingerprint sample, outputs the unique device identifier result, and completes the device identity determination.
[0062] In practice, the specific steps of S1 are as follows:
[0063] S11 deploys a data acquisition application on a smart device and connects to the target wireless earphone;
[0064] S12 calls the system's open, unauthorized sensor interface to collect raw timing data from the built-in gyroscope and accelerometer at a fixed sampling rate of 25Hz;
[0065] S13, record each collected data point as a text line in the format of "timestamp, X-axis value, Y-axis value, Z-axis value";
[0066] S14, store the collected text data to the local file system in timestamp order.
[0067] In practice, the specific steps of S2 are as follows:
[0068] S21: Read all the raw timing data of the target wireless earphone from the storage file, sort it by timestamp, and extract the three-axis values to form... The original data matrix ,in This represents the total number of sampling points;
[0069] S22, for the original data matrix The element-wise difference between adjacent sampling points is calculated directly along the time dimension (row direction) to obtain the difference data matrix. The calculation formula is:
[0070]
[0071] The original data matrix has one sampling point per row. Three-axis numerical values The differential data matrix is a differential operation that directly eliminates the fixed bias vector preset in the sensor firmware, so that the differential data only contains quantization features related to the calibration gain matrix, without the need for additional mean filtering or bias removal preprocessing.
[0072] In specific implementation, such as Figure 2 As shown, the specific steps of S3 are as follows:
[0073] S31, Construct the initial gain matrix ,in It is a 3rd order identity matrix; for a gyroscope, the nominal gain is... The value is 0.061 degrees / second; for the accelerometer, the nominal gain is... The value is 0.000598 m / s 2 ;
[0074] S32, Set the initial threshold coefficient According to the formula Calculate the screening threshold for the current batch to obtain the difference data matrix for the current batch. ;
[0075] S33, for the current batch difference data matrix Through the inverse matrix Estimate the corresponding ADC integer difference matrix The calculation formula is: ,in, This is the rounding function. This is a matrix multiplication operation. for The transpose of the matrix;
[0076] S34, Calculate the rounding error matrix All three-axis rounding errors are kept below the preset strictness threshold. From reliable data rows, reliable differential data is obtained;
[0077] S35, determine whether the initial gain matrix calculation has been completed. If the initial calculation has not been completed, accumulate reliable difference data. When the total number of accumulated reliable difference data reaches the preset minimum number of samples and the matrix rank is not less than 3, execute the least squares method to solve and update the gain matrix. If the initial calculation has been completed, directly execute the least squares method to update the gain matrix for the current batch of reliable difference data.
[0078] S36, magnify the threshold coefficient by a preset magnification of 1.5. Repeat steps S32 to S35;
[0079] S37, when the change in the gain matrix between adjacent rounds Less than the convergence threshold 10 -7 hour( Let Frobenius norm be the matrix. The difference between the gain matrices of two adjacent iterations is used to determine if the matrix has converged, and the iteration terminates; or the iteration ends when the threshold covers all the difference data.
[0080] S38, obtain the calibration gain matrix .
[0081] The design principle of the threshold batch screening mechanism is as follows: First, differential data is screened with an extremely small initial threshold. At this time, only the extremely small amplitude differential data in the near-static state of the sensor is retained. The true integer value of this type of data is extremely small (usually 0 or ±1), and the rounding error is minimal, so the initial value of the gain matrix can be estimated with high accuracy. Then, the threshold is increased by 1.5 times in each round to gradually include differential data with larger amplitudes. Based on the already better initial estimate, the gain matrix is further refined. This progressive strategy from small to large effectively avoids the gain matrix estimation deviation caused by the large rounding error of large amplitude differential data when using the full data directly. More importantly, it solves the three major technical problems of rounding error amplification, aliasing noise pollution and feature distortion in the 25Hz extremely low sampling rate scenario.
[0082] In practice, the specific steps of S4 are as follows:
[0083] S41, Calculate the calibration gain matrix condition number If the condition number is less than the reciprocal threshold of the floating-point precision, that is... ,in For floating-point machine precision (single precision is approximately...) Double precision is approximately If the matrix is numerically invertible, proceed to the next step; otherwise, it is considered an invalid matrix, discarded, and data is collected again to perform iterative estimation.
[0084] S42, Record the calibration gain matrix that meets the requirements. The conditional values and fitting residuals are used for subsequent fingerprint quality assessment.
[0085] In practice, the specific steps of S5 are as follows:
[0086] S51, for gyroscope calibration gain matrix The nine floating-point elements in its 3×3 matrix serve as the unique fingerprint of the gyroscope. ;
[0087] S52, accelerometer gain matrix calibration The nine floating-point elements in its 3×3 matrix are directly used as the unique fingerprint of the accelerometer. ;
[0088] S53, 9-dimensional vector and The 9-dimensional vectors are directly concatenated in terms of dimension to generate an 18-dimensional comprehensive device fingerprint. .
[0089] In practice, the specific steps of S6 are as follows:
[0090] S61, Calculate the device to be identified Compared with each registered sample in the fingerprint database Euclidean distance: , 18-dimensional representation of the device to be identified vector, For samples already registered in the fingerprint database vector;
[0091] S62, set the matching judgment threshold. When the Euclidean distance is less than the preset threshold, it is judged as the same device and the corresponding device unique identifier is output.
[0092] S63, when there is no matching sample in the fingerprint database, then... As a new entry, it is added to the fingerprint database and assigned a new unique device identifier, enabling dynamic incremental updates to the fingerprint database.
[0093] The threshold iteration in step S3 of this invention serves as the core of the calibration gain matrix estimation. It initializes a 3×3 gain matrix with the nominal gain, uses progressively increasing thresholds to filter small-amplitude differential data in batches, and combines this with least squares iterative updates to solve the technical challenges of large rounding errors, insufficient estimation accuracy, and feature distortion caused by signal aliasing at a low sampling rate of 25Hz. Its specific technical mechanism includes the following three causal links:
[0094] 1. Counteracting rounding error amplification. At an extremely low sampling rate of 25Hz, the interval between adjacent samples is as high as 40ms (8 times the 5ms interval in a typical 200Hz scenario). The change in sensor readings within this time window... Naturally large. ADC difference recovery formula. Rounding error and Exhibits linear positive correlation – only the nominal gain approximation matrix is available during the initial iteration. Its relationship with the true gain matrix deviation This causes rounding error .when When the critical value is exceeded, Rounding can lead to incorrect integer estimates. This led to If the data is contaminated, subsequent least squares estimation becomes completely invalid. This invention uses an extremely small initial threshold ( Only small-amplitude difference data in a near-static state are selected. Rounding is almost always correct; using this batch of high-confidence data, the first reliable gain matrix estimate was obtained through the least squares method. Then, in each round, the threshold is increased by a factor of 1.5 and the currently optimized gain matrix is utilized. Rounding again - because It is now closer to the true inverse matrix. Calculation The rounding error was significantly reduced compared to the previous round. Large-value data that could not be rounded correctly under the initial approximation had a significantly improved rounding accuracy under the corrected gain matrix. This positive feedback iterative strategy of "small to large, stepwise refinement" transforms the large rounding error that is inevitably caused by the low sampling rate from an absolute obstacle in a single calculation into a controllable progressive convergence process, so that all the difference data can be used correctly in the end.
[0095] 2. Ensure estimation accuracy at low sampling rates. A 25Hz sampling rate corresponds to a Nyquist frequency of only 12.5Hz, while high-frequency components of head movements (such as jaw joint vibrations at 15–25Hz and gait-induced vibrations at 20–30Hz) far exceed this limit. According to the sampling theorem... The frequency components of the super Nyquist spectrum are aliased to the [0, 12.5] Hz baseband through spectral folding, in the differential data. Structured aliasing noise is introduced—this noise is not random white noise, but a pseudo-signal with a deterministic folding relationship to the original physical motion, which cannot be eliminated by simple time averaging. If least squares are directly performed on the full data containing aliasing noise, the aliasing components will be incorrectly attributed to the elements of the gain matrix, causing the gain matrix estimate to deviate significantly from the true value. The initial batch of the progressive threshold in this invention only filters... Extremely small data points—in a physical sense, small amplitude. For low-frequency, slowly varying motion components (whose frequency is naturally lower than the Nyquist frequency), the gain matrix extracted at this stage is completely unaffected by aliasing noise, and the initial value accuracy is far superior to direct full estimation. In subsequent iterations, the obtained high-precision gain matrix enables rounding error verification (all three-axis errors are less than the strictness threshold of 0.2) to effectively identify and eliminate linear models caused by aliasing. Mismatched outlier data points: aliasing artifacts do not satisfy this linear relationship, and their rounding errors will inevitably exceed the limit and be automatically filtered out; only the true calibration signal is retained to participate in the least squares estimation. This mechanism essentially implements an implicit anti-aliasing filter—indirectly achieving frequency filtering through amplitude screening (small amplitude ≈ low frequency ≈ no aliasing), and directly achieving model consistency screening through rounding error verification (only retaining data that conforms to the physical model), thus providing dual protection for high-precision convergence of the gain matrix at low sampling rates.
[0096] 3. Preventing feature distortion caused by signal aliasing. The fingerprint feature of the calibration gain matrix is carried in the quantization step structure of the sensor output—the physical output difference corresponding to adjacent ADC integer values is the gain matrix element of that axis and the coupling between axes. This quantization structure is determined by random physical errors in the manufacturing process and is a unique physical fingerprint of the device. At 25Hz, the motion component of the super Nyquist frequency generates a false quasi-quantization periodic pattern in the time domain through spectral folding—the step-like structure formed by aliasing folding is very similar in appearance to the real calibration quantization feature, but in reality it is a beat frequency product of the instantaneous motion frequency and the sampling frequency, and is completely unrelated to the factory calibration parameters of the device. If this aliasing artifact is included in the least squares estimation, the estimated gain matrix will systematically deviate from the real factory calibration parameters, resulting in feature distortion. The distorted fingerprint is inconsistent between different batches because the aliasing mode depends on the instantaneous motion state at the time of acquisition, losing the most core lifelong invariance and cross-batch reproducibility of the device fingerprint. This invention utilizes the real calibration features to necessarily satisfy The fundamental difference lies in the fact that linear models (i.e., rounding errors approaching zero) and aliasing artifacts, which significantly increase rounding errors due to disrupting this linearity, use the rounding error threshold as a natural discriminator between true calibration features and aliasing artifacts: the former, due to its minimal rounding error, is retained and participates in gain matrix estimation, while the latter, due to excessive rounding errors, is automatically discarded. As the gain matrix gradually converges to the true value during iteration, the discriminator's sensitivity continuously improves. The final calibration gain matrix strictly reflects the device's factory physical calibration parameters, without containing any aliasing artifacts introduced by instantaneous motion, ensuring the fingerprint's lifetime invariance, cross-batch reproducibility, and device uniqueness.
[0097] The synergistic effect of the aforementioned triple causal chain enables this invention to overcome three unique technical barriers caused by low sampling rates—rounding error amplification, aliasing noise pollution, and feature distortion—compared to the progressive iterative solutions used in smartphones with high sampling rates of 100–200Hz, in the extremely low sampling rate scenario of 25Hz headphones. Rounding error amplification prevents initial estimation from starting, aliasing noise pollution compromises estimation accuracy, and feature distortion makes fingerprints unreproducible—these three factors are interconnected, forming an impossible triangle for calibrating fingerprint extraction in the 25Hz low sampling rate scenario. This invention uses progressive threshold iteration as a positive feedback engine and rounding error verification as a data quality gatekeeper to systematically break this impossible triangle, ultimately achieving high-precision convergence and stable extraction of the device's unique factory calibration parameters.
[0098] Example 2: The computer-readable storage medium of this example stores a computer program that, when executed by a processor, implements the steps of the device fingerprint recognition method based on the calibration features of an earphone inertial sensor in Example 1.
[0099] The computer-readable storage medium in this embodiment can be an internal storage unit of the terminal, such as the terminal's hard disk or memory; the computer-readable storage medium in this embodiment can also be an external storage device of the terminal, such as a plug-in hard disk, smart memory card, secure digital card, flash memory card, etc. equipped on the terminal; furthermore, the computer-readable storage medium can include both the terminal's internal storage unit and external storage devices.
[0100] The computer-readable storage medium of this embodiment is used to store computer programs and other programs and data required by the terminal. The computer-readable storage medium can also be used to temporarily store data that has been output or will be output.
[0101] Example 3: The computer device of this example includes a processor, a memory, a Bluetooth communication module, and a computer program stored in the memory and executable on the processor. When the processor executes the program, it implements the steps of the device fingerprint recognition method based on the calibration features of an earphone inertial sensor in Example 1.
[0102] In this embodiment, the processor can be a central processing unit, or other general-purpose processors, digital signal processors, application-specific integrated circuits, off-the-shelf programmable gate arrays or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. The general-purpose processor can be a microprocessor or any conventional processor, etc. The memory can include read-only memory and random access memory, and provides instructions and data to the processor. A portion of the memory can also include non-volatile random access memory. For example, the memory can also store device type information.
[0103] Those skilled in the art will clearly understand that each implementation can be achieved using software plus the necessary general-purpose hardware platform, or of course, hardware. Based on this understanding, the above technical solutions, in essence or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product can be stored in a computer-readable storage medium, such as ROM / RAM, magnetic disk, optical disk, etc., and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute the methods described in the various embodiments or some parts of the embodiments.
[0104] The above description is merely a preferred embodiment of the present invention and is not intended to limit the present invention. Although the present invention has been described in detail with reference to the foregoing embodiments, those skilled in the art can still modify the technical solutions described in the foregoing embodiments or make equivalent substitutions for some of the technical features. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the protection scope of the present invention.
Claims
1. A device fingerprint recognition method based on the calibration features of an earphone inertial sensor, characterized in that, Includes the following steps: S1, Collect raw time-series data from the MEMS inertial sensor built into the target wireless earphone. The MEMS inertial sensor includes a gyroscope and an accelerometer. The raw time-series data includes a timestamp and the output values of the X, Y, and Z axes sensors. S2, calculate the difference between adjacent sampling points directly along the time dimension of the collected raw time series data to obtain differential data; S3, initialize a 3×3 initial gain matrix, set initial threshold coefficients, filter differential data from smallest to largest threshold, estimate the corresponding ADC integer difference for each batch of filtered differential data through the inverse matrix of the current gain matrix, filter reliable differential data based on rounding error, and iteratively solve the gain matrix using the least squares method until the matrix converges or the full data processing is completed to obtain the calibration gain matrix. S4. Perform an invertibility check on the calibration gain matrix obtained through iteration. Determine whether the matrix is invertible by calculating the matrix condition number. Eliminate invalid matrices with an excessive condition number and retain calibration gain matrices that meet the invertibility requirements. S5, based on the verified calibration gain matrix, generates a gyroscope calibration fingerprint and an accelerometer calibration fingerprint that are uniquely bound to the target wireless earphone, and combines the two in a dimension to generate a comprehensive device fingerprint; S6 performs Euclidean distance matching between the device fingerprint generated by the wireless earphone to be identified and the fingerprint sample, outputs the unique device identifier result, and completes the device identity determination.
2. The device fingerprint recognition method based on the calibration features of an earphone inertial sensor according to claim 1, characterized in that, The specific steps of S1 are as follows: S11 deploys a data acquisition application on a smart device and connects to the target wireless earphone; S12 calls the system's open, unauthorized sensor interface to collect raw timing data from the gyroscope and accelerometer at a fixed sampling rate of 25Hz; S13, record each piece of data collected as text data, including timestamp, X-axis value, Y-axis value and Z-axis value; S14, store the collected text data to the local file system in timestamp order.
3. The device fingerprint recognition method based on the calibration features of an earphone inertial sensor according to claim 2, characterized in that, The specific steps of S2 are as follows: S21: Read all the raw timing data of the target wireless earphone from the storage file, sort it by timestamp, and extract the three-axis values to form... The original data matrix ,in This represents the total number of sampling points; S22, for the original data matrix The element-wise difference between adjacent sampling points is calculated directly along the time dimension to obtain the difference data matrix. .
4. The device fingerprint recognition method based on the calibration features of an earphone inertial sensor according to claim 3, characterized in that, The specific steps for S3 are as follows: S31, Construct the initial gain matrix ,in For nominal gain, It is a 3-order identity matrix; S32, Set the initial threshold coefficient Calculate the current batch The current batch difference data matrix is obtained. ; S33, for the current batch difference data matrix Through the gain inverse matrix Estimate the corresponding ADC integer difference matrix The calculation formula is: ,in, This is the rounding function. This is a matrix multiplication operation. for The transpose of the matrix; S34, Calculate the rounding error matrix Reliable data rows whose three-axis rounding errors are all less than the preset strictness threshold are retained to obtain reliable differential data; S35, determine whether the initial gain matrix calculation has been completed. If the initial calculation has not been completed, accumulate reliable difference data. When the total number of accumulated reliable difference data reaches the preset minimum number of samples and the matrix rank is not less than 3, execute the least squares method to solve and update the gain matrix. If the initial calculation has been completed, directly execute the least squares method to update the gain matrix for the current batch of reliable difference data. S36, Amplify the threshold coefficient by a preset magnification of 1.5, and repeat steps S32 to S35; S37. When the change in the gain matrix in adjacent rounds is less than the preset convergence threshold, the matrix is determined to have converged and the iteration is terminated; or when the threshold covers the entire difference data, the iteration ends. S38, obtain the calibration gain matrix .
5. A device fingerprint recognition method based on the calibration features of an earphone inertial sensor according to claim 4, characterized in that, In S31, for the gyroscope, the nominal gain The value is 0.061 degrees / second; For accelerometers, nominal gain The value is 0.000598 m / s 2 .
6. The device fingerprint recognition method based on the calibration features of an earphone inertial sensor according to claim 4, characterized in that, The specific steps of S4 are as follows: S41, Calculate the calibration gain matrix If the condition number is less than the reciprocal threshold of floating-point precision, the matrix is determined to be numerically invertible, and the process proceeds to the next step; otherwise, it is determined to be an invalid matrix, the matrix is discarded, and data is collected again to perform iterative estimation. S42, Record the calibration gain matrix that meets the requirements. The conditional values and fitting residuals are used for subsequent fingerprint quality assessment.
7. A device fingerprint recognition method based on the calibration features of an earphone inertial sensor according to claim 6, characterized in that, The specific steps of S5 are as follows: S51, for the gyroscope calibration gain matrix, the 9 floating-point elements in its 3×3 matrix serve as the unique fingerprint of the gyroscope; S52, for the accelerometer calibration gain matrix, the 9 floating-point elements in its 3×3 matrix are directly used as the unique fingerprint of the accelerometer; S53 directly concatenates the 9-dimensional vector of the gyroscope's unique fingerprint with the 9-dimensional vector of the accelerometer's unique fingerprint in terms of dimensions to generate an 18-dimensional comprehensive device fingerprint.
8. A device fingerprint recognition method based on the calibration features of an earphone inertial sensor according to claim 7, characterized in that, The specific steps of S6 are as follows: S61, Calculate the Euclidean distance between the integrated device fingerprint of the device to be identified and the integrated device fingerprints of each registered sample in the fingerprint database: , This is the comprehensive fingerprint vector of the device to be identified. This is a comprehensive fingerprint vector of devices that have been registered in the fingerprint database; S62, set the matching judgment threshold. When the Euclidean distance is less than the preset threshold, it is judged as the same device and the corresponding device unique identifier is output. S63, when there is no matching sample in the fingerprint database, the comprehensive fingerprint of the device to be identified is added to the fingerprint database as a new entry, and a new unique device identifier is assigned.
9. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the program is executed by the processor, it implements the steps in the device fingerprint recognition method based on the calibration features of an earphone inertial sensor as described in any one of claims 1-8.
10. A computer device, comprising a processor, a memory, a Bluetooth communication module, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the steps in the device fingerprint recognition method based on the calibration features of an earphone inertial sensor as described in any one of claims 1-8.