Low-power rotation speed test device, electronic device and storage medium
By picking up the speed signal through the photoelectric sensor and constructing a low-power configuration space, the microcontroller parameter group is dynamically adjusted to solve the problems of high power consumption and low efficiency of the speed test device during low-speed measurement, and realize low-power, high-precision speed measurement.
Patent Information
- Application Number
- CN202510595940.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2025-05-09
- Publication Date
- 2025-09-09
- Estimated Expiration
- 2045-05-09
AI Technical Summary
Existing speed test devices have high power consumption and low efficiency when measuring at low speeds, and cannot be dynamically adjusted according to working conditions, resulting in wasted power consumption and low test accuracy.
The speed signal is picked up by the photoelectric sensor, a low-power configuration space is constructed, and the pulse counting parameter group of the microcontroller is dynamically adjusted to achieve low-power and high-precision speed measurement.
It significantly reduces power consumption and improves test accuracy during low-speed measurements, adapting to the speed variation characteristics of different test objects.
Smart Images

Figure CN120102921B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of intelligent detection technology, and in particular to a low-power rotation speed testing device, electronic equipment and storage medium. Background Art
[0002] With the rapid development of industrial automation and intelligent equipment, speed test devices have been widely used in various fields such as mechanical equipment, automobiles, and power tools. Traditional speed test devices generally rely on fixed pulse counting parameters and conventional clock frequency settings. They can provide relatively accurate measurement results when testing at high speeds, but when measuring at low speeds, the equipment has high power consumption and low efficiency. Especially in long-term operation or mobile application scenarios, the high power consumption of speed test devices has become a major problem restricting their widespread application. At the same time, the existing technology lacks an adaptive configuration adjustment mechanism when facing test objects of different types and models, resulting in an inability to flexibly respond to the changing speed characteristics and different testing requirements. Summary of the Invention
[0003] The present application provides a low-power rotational speed testing device, an electronic device and a storage medium, which are used to solve the technical problem that the power consumption of the existing rotational speed testing device is fixed and cannot be dynamically adjusted according to the working conditions, resulting in power consumption waste and low test accuracy.
[0004] In a first aspect of the present application, a low-power speed test device is provided, comprising: a speed test module configured to configure a standard pulse count parameter group for a single-chip microcomputer in a speed tester, pick up a speed signal of a target test object using a photoelectric sensor in a speed measuring instrument, transmit the obtained pulse signal to the single-chip microcomputer via a pin for speed testing, and obtain a speed test result sequence; a speed change feature analysis module configured to traverse the speed test result sequence to perform asynchronous analysis and fusion of speed change features to determine a fused speed change feature; a low-power configuration space construction module configured to pre-construct a low-power configuration space based on the type and model of the target test object, wherein each low-power configuration pulse count parameter group in the low-power configuration space has a low-power speed change feature identifier; and a configuration update module configured to traverse the low-power configuration space and match the low-power speed feature identifiers with the fused speed change feature. If a match is successful, the single-chip microcomputer is configured to be updated according to the corresponding low-power configuration pulse count parameter group, and the target test object is subjected to a speed test using the updated speed tester.
[0005] In a second aspect, the present application provides an electronic device, comprising: a processor, the processor being coupled to a memory, the memory being used to store a program, and when the stored program is executed by the processor, the apparatus of the first aspect is implemented.
[0006] In a third aspect, the present application provides a computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor, the apparatus of the first aspect is implemented.
[0007] One or more technical solutions provided in this application have at least the following technical effects or advantages:
[0008] The present application provides a low-power speed test device, electronic device, and storage medium, which relate to the field of intelligent detection technology. The speed signal is collected by a photoelectric sensor and transmitted to a single-chip microcomputer for speed measurement. The speed change feature analysis module extracts fusion features, the low-power configuration space construction module pre-constructs the configuration space according to the target object type, and the configuration update module updates the single-chip microcomputer configuration according to the matching low-power features, thereby achieving low-power, high-precision speed measurement. This solves the technical problem that the power consumption of existing speed test devices is fixed and cannot be dynamically adjusted according to working conditions, resulting in wasteful power consumption and low test accuracy. It achieves the technical effect of dynamically adjusting the power consumption configuration, performing real-time power consumption adjustment on the target test object, significantly reducing power consumption and improving test accuracy. BRIEF DESCRIPTION OF THE DRAWINGS
[0009] In order to more clearly illustrate the technical solutions in the embodiments of the present invention, the following briefly introduces the drawings required for use in the description of the embodiments. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0010] Figure 1 A schematic structural diagram of a low-power rotational speed test device provided in an embodiment of the present application;
[0011] Figure 2 A structural diagram of an electronic device is provided for this application.
[0012] Explanation of the accompanying symbols: speed testing module 10, speed change characteristic analysis module 20, low power configuration space construction module 30, configuration update module 40, electronic device 300, memory 301, processor 302, communication interface 303, bus architecture 304. DETAILED DESCRIPTION
[0013] The present application provides a low-power rotational speed testing device, an electronic device and a storage medium, which are used to solve the technical problem that the power consumption of the existing rotational speed testing device is fixed and cannot be dynamically adjusted according to the working conditions, resulting in power consumption waste and low test accuracy.
[0014] The following will be combined with the accompanying drawings in the embodiments of this application to clearly and completely describe the technical solutions in the embodiments of this application. Obviously, the embodiments described are only some of the embodiments of this application, not all of them. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative efforts are within the scope of protection of this application.
[0015] It should be noted that the terms "first", "second", etc. in the specification of the present application and the above-mentioned drawings are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable where appropriate, so that the embodiments of the present application described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or server that includes a series of steps or units is not necessarily limited to those steps or units clearly listed, but may include other steps or modules that are not clearly listed or inherent to these processes, methods, products or devices.
[0016] Example 1, as Figure 1 As shown, the present application provides a low-power rotation speed test device, which includes:
[0017] The speed test module 10 is used to configure a standard pulse counting parameter set for the microcontroller in the speed tester. The speed signal of the target test object is picked up by the photoelectric sensor in the speed measuring instrument. The obtained pulse signal is transmitted to the microcontroller via a pin for speed testing, thereby obtaining a speed test result sequence. The standard pulse counting parameter set includes a standard clock frequency and a standard sampling window.
[0018] It should be understood that the main function of the speed test module 10 of the present application is to configure the standard pulse counting parameter group of the microcontroller in the speed tester, and pick up the speed signal of the target test object through the photoelectric sensor, thereby completing the speed test and outputting the speed test result sequence.
[0019] Specifically, the speed test module 10 first configures the standard pulse counting parameter group for the single-chip microcomputer. The standard pulse counting parameter group is a set of key technical parameters for achieving accurate speed measurement, which mainly includes two important parameters: standard clock frequency and standard sampling window. Among them, the standard clock frequency refers to the clock signal frequency based on which the single-chip microcomputer counts pulses. This frequency directly determines the reference time unit of the single-chip microcomputer counting, thereby affecting the measurement accuracy and response speed. A higher standard clock frequency can provide finer time resolution, allowing the single-chip microcomputer to capture pulse signals more accurately, thereby improving the accuracy of speed measurement; however, too high a clock frequency will also increase the power consumption of the single-chip microcomputer. Therefore, during the design process, it is necessary to reasonably select the standard clock frequency based on the actual measurement requirements and power consumption requirements to achieve a balance between accuracy and power consumption.
[0020] The standard sampling window refers to the time interval within which the microcontroller counts pulse signals per unit time. The length of the sampling window directly affects the number of pulses counted and the stability of the speed calculation. A longer sampling window collects more pulse signals, thereby reducing the impact of random errors on measurement results and improving measurement accuracy. However, this also reduces the real-time performance of the measurement. Therefore, the setting of the standard sampling window requires a comprehensive consideration of the speed variation characteristics of the measurement object and the real-time performance requirements of the measurement device.
[0021] After configuring the standard pulse counting parameter set, the speed meter uses a photoelectric sensor to pick up the target test object's speed signal. The photoelectric sensor senses markings or reflective points on the rotating object's surface and converts them into pulse signals for output. The photoelectric sensor's output pulse frequency is proportional to the target object's rotational speed. The faster the rotational speed, the greater the number of pulses the sensor outputs per unit time. These pulse signals are transmitted to the microcontroller via the pins between the sensor and the microcontroller, where they undergo preliminary signal processing.
[0022] The pulse signal is then transmitted to the microcontroller via its pins. After receiving the pulse signal, the microcontroller performs a speed test based on a preconfigured set of standard pulse counting parameters. During this phase, the microcontroller counts the pulse signals received within each cycle according to the configured standard clock frequency and sampling window length, using sequential logic. The number of pulses within each cycle represents the speed value of the test object during that period. This process is performed by the microcontroller's counter module, which records the current pulse count at the end of each sampling window. After counting, the microcontroller converts the pulse count for each sampling cycle into the actual speed value of the test object and stores this speed value as part of the speed test results. This process continues, generating a series of speed test results, forming a speed test result sequence. This sequence contains the speed information of the test object at different time points, providing basic data for subsequent analysis of speed variation characteristics.
[0023] Through the above process, the speed test module 10 not only realizes the accurate measurement of the speed of the target test object, but also provides important data support for the low-power optimization and dynamic configuration update of the entire speed test device. It is a key link in achieving low-power and high-precision speed measurement.
[0024] The speed variation feature analysis module 20 is configured to traverse the speed test result sequence to perform asynchronous analysis and fusion of the speed variation features, and determine a fused speed variation feature.
[0025] Furthermore, when traversing the speed test result sequence to perform asynchronous analysis and fusion of speed change characteristics, the speed change characteristic analysis module 20 is further configured to:
[0026] P21: Obtain the first receptive field, and expand the first receptive field according to the preset increase in the number of layers, the preset update of the convolution kernel, and the preset increase in the step size to obtain the second receptive field; P22: Take the speed test result sequence as input, use the first receptive field and the second receptive field as feature analysis scales respectively, and use the speed change feature as output to construct a first feature analyzer and a second feature analyzer; P23: Use the first feature analyzer and the second feature analyzer to extract the speed change feature of the speed test result sequence to obtain the first speed change feature and the second speed change feature; P24: Perform asynchronous analysis and fusion on the first speed change feature and the second speed change feature to determine the fused speed change feature.
[0027] Optionally, the speed variation feature analysis module 20 of this application performs asynchronous analysis and fusion on the speed test result sequence to determine the fused speed variation feature. This process not only captures local speed variations but also reflects the global speed trend, providing a basis for subsequent low-power configuration updates.
[0028] During the specific implementation process, the speed change feature analysis module 20 first obtains the initial receptive field, which is called the first receptive field. The receptive field refers to the area range that the model can perceive in the input data. The larger the receptive field, the more global features the model can capture, but the features are relatively coarse; the smaller the receptive field, the more detailed the local features captured, but the global information may be ignored. In order to expand the range of the receptive field, the first receptive field is expanded. The expansion method includes increasing the number of layers according to the preset, updating the convolution kernel, and increasing the step size. By increasing the depth of the processing layer, adjusting the size or shape of the convolution kernel, and increasing the step size of the convolution operation, a second receptive field with a larger range is finally obtained.
[0029] The module then takes the speed test result sequence as input, uses the first and second receptive fields as feature analysis scales, and outputs the speed variation features to construct the first and second feature analyzers. The first feature analyzer, based on the first receptive field, primarily captures local features of speed variation, such as instantaneous speed fluctuations and local speed change rates. The second feature analyzer, based on the second receptive field, primarily captures global features of speed variation, such as average speed and overall speed fluctuation amplitude.
[0030] Using these two feature analyzers, the module extracts speed variation features from the speed test result sequence, generating the first and second speed variation features. The first speed variation feature primarily reflects local speed variation characteristics, such as instantaneous speed fluctuations and local speed change rates; the second speed variation feature primarily reflects global speed variation characteristics, such as average speed and overall speed fluctuation amplitude.
[0031] Finally, the first and second speed variation features are asynchronously analyzed and fused. This process integrates local and global features through techniques such as feature weighting, feature concatenation, or feature fusion algorithms to ultimately determine a fused speed variation feature. This fused speed variation feature more comprehensively reflects the speed variation of the target test object, providing a more accurate basis for subsequent low-power configuration updates.
[0032] Through the above steps, the speed change feature analysis module 20 realizes an in-depth analysis of the speed test result sequence, which can not only capture the local detailed changes in the speed, but also reflect the global trend of the speed, thereby providing key technical support for the intelligent operation of the entire low-power speed test device.
[0033] Furthermore, when asynchronously analyzing and fusing the first speed variation feature and the second speed variation feature, the speed variation feature analysis module 20 is further configured to:
[0034] P24-1: For the mapping similarity set between the first speed change feature and the second speed change feature, the mapping similarity set is normalized using the softmax function to determine the mapping similarity normalization value set; P24-2: Based on the mapping similarity normalization value set, the second speed change feature is enhanced to obtain the fused speed change feature.
[0035] Specifically, when the speed change characteristic analysis module 20 asynchronously analyzes and fuses the first speed change characteristic and the second speed change characteristic, it further performs the following operations to ensure that the fused speed change characteristic can more accurately reflect the actual operating status of the target test object, and at the same time provide a more reliable basis for subsequent low-power configuration updates.
[0036] First, the mapping similarity set between the first speed change feature and the second speed change feature is processed. The mapping similarity set reflects the degree of association between the two features. By calculating the similarity between the first speed change feature and the second speed change feature, the correlation between them can be quantified. In order to enable these similarity values to be used for subsequent fusion calculations, the mapping similarity set can be normalized using the softmax function. The softmax function is a commonly used normalization method that can map the input similarity value to the [0,1] interval and ensure that the sum of all normalized values is 1. The calculation of the softmax function ensures that each similarity value is proportionally enlarged or reduced so that its sum is 1, which facilitates subsequent weighted fusion and feature enhancement.
[0037] Subsequently, the second speed change feature is enhanced based on the mapping similarity normalized value set. The purpose of feature enhancement is to highlight the part of the second speed change feature that has a high correlation with the first speed change feature in a weighted manner, so as to obtain a more accurate fused speed change feature. The specific implementation method is to embed the mapping similarity normalized value set into an initially empty matrix, and then calculate the convolution result of the matrix and the second speed change feature set. The convolution operation is an effective feature extraction method. By convolving with the weight matrix (i.e., the matrix embedded with the normalized value), the second speed change feature can be weighted to achieve feature enhancement. Ultimately, the fused speed change feature obtained through this process not only contains the global information of the second speed change feature, but also incorporates important local information related to the first speed change feature through feature enhancement, making the fused feature more comprehensive and accurate.
[0038] This process fully considers the correlation between the two features and enhances the global features through weighted convolution, thereby ensuring that the fused speed change features can more accurately reflect the speed changes of the target test object, providing key technical support for the intelligent operation of the entire low-power speed test device.
[0039] The low power configuration space construction module 30 is used to pre-construct a low power configuration space based on the type and model of the target test object, wherein each low power configuration pulse count parameter group in the low power configuration space has a low power rotation speed change characteristic identifier.
[0040] Furthermore, when pre-building the low power configuration space based on the type and model of the target test object, the low power configuration space building module 30 is further configured to:
[0041] P31: Mining low-speed test records based on the type and model of the target test object, and filtering the mining results according to a preset test accuracy threshold and a preset power consumption threshold to obtain a set of filtered speed test records; P32: Traversing and extracting the pulse counting parameter group and speed characteristics of the filtered speed test record set to obtain a set of filtered speed characteristics and a set of filtered pulse record parameter groups, wherein the filtered speed characteristics and the filtered pulse record parameter groups correspond one to one; P33: Performing nearest neighbor clustering on the filtered speed feature set to obtain M nearest neighbor clustering filtered speed feature sets, wherein M is a positive integer; P34: Performing nearest neighbor clustering on the M nearest neighbor clustering filtered speed feature sets The neighbor clustering screening speed feature set is used for prototype extraction to determine M low-power speed features; P35: According to the one-to-one correspondence between the screening speed features and the screening pulse recording parameter groups, the screening pulse recording parameter group set is mapped and divided in combination with the M neighbor clustering screening speed feature sets to obtain M neighbor clustering screening pulse recording parameter group sets; P36: The M neighbor clustering screening pulse recording parameter group sets are averaged to determine M low-power configuration pulse recording parameter groups, and the M low-power configuration pulse recording parameter groups are identified using the M low-power speed features to obtain the low-power configuration space.
[0042] It should be understood that the low-power configuration space construction module 30 of the present application is used to optimize the power consumption of the speed test device. Its core function is to pre-construct a low-power configuration space based on the type and model of the target test object. Each low-power configuration pulse count parameter group in this space has a corresponding low-power speed change characteristic identifier.
[0043] During implementation, the low-power configuration space construction module 30 first mines low-speed test records based on the type and model of the target test object. During this stage, the module collects and analyzes historical speed test data related to the target object, based on its characteristics, such as its type (e.g., power tool, automobile engine, etc.) and model. The mining results are then filtered according to preset test accuracy and power consumption thresholds to obtain a set of filtered speed test records. The preset test accuracy threshold ensures that the filtered test records meet accuracy requirements, while the preset power consumption threshold ensures that these records have the potential for optimization in terms of power consumption. These thresholds can be set based on empirical data.
[0044] Next, the pulse count parameter groups and speed features in the filtered speed test record set are extracted. From each filtered record, the pulse count parameter group (i.e., configuration information related to speed measurement) and speed features (such as speed value and fluctuation) are extracted to obtain a filtered speed feature set and a filtered pulse record parameter group set. During this process, a one-to-one correspondence is maintained between the filtered speed features and the filtered pulse record parameter groups, ensuring that each parameter group has a clear description of the speed characteristics.
[0045] To further optimize the configuration space, nearest neighbor clustering is performed on the filtered speed feature set. The goal of nearest neighbor clustering is to group speed features based on similarity, thereby extracting representative features. This process determines similarity by calculating the distance between speed features (such as the Euclidean distance). Then, a clustering algorithm is used to group similar speed features together, resulting in M nearest neighbor clustered filtered speed feature sets, where M is a positive integer representing the number of clusters. Each cluster contains a group of features with similar speed performance, which better reflects the characteristics of the target test object at different speeds.
[0046] Subsequently, prototype extraction is performed on the speed feature set of the M nearest neighbor clusters, extracting a representative low-power speed feature from each cluster. This process is achieved by selecting the most representative or typical speed feature in each cluster, ensuring that the extracted feature fully covers the variability within the cluster and effectively represents the speed performance of the target test object.
[0047] Next, by mapping the one-to-one correspondence between the selected speed features and the selected pulse recording parameter groups, the M nearest neighbor clustering selected speed feature sets are combined to map and divide the selected pulse recording parameter group sets. The low-power speed features obtained by clustering are mapped to the corresponding pulse counting parameter groups to form a set of low-power configuration pulse recording parameter groups. Through this mapping, each low-power configuration pulse recording parameter group will be matched to a specific low-power speed feature, ensuring that these configurations can adapt to different speed variation characteristics in actual applications.
[0048] Finally, the M sets of pulse recording parameter groups filtered by nearest neighbor clustering are averaged, and by averaging each set of parameters, a representative low-power configuration pulse recording parameter group is obtained. These averaged configurations will be used for subsequent testing and application to ensure that they can provide stable performance in low-power mode. Then, the M low-power configuration pulse recording parameter groups are identified using the M low-power speed characteristics to construct a complete low-power configuration space. This low-power configuration space can intelligently adjust the configuration based on the speed change characteristics of different target test objects, thereby ensuring that the test device can complete accurate speed measurement tasks with the lowest power consumption under different operating conditions.
[0049] Furthermore, when performing prototype extraction on the M nearest neighbor cluster screening speed feature sets, the low power configuration space construction module 30 is further configured to:
[0050] P34-1: perform pairwise similarity identification on the M nearest neighbor clustering screening speed feature sets respectively, and calculate the identification similarity mean of each nearest neighbor clustering screening speed feature to obtain M nearest neighbor clustering screening speed feature similarity mean sets; P34-2: respectively use the nearest neighbor clustering screening speed feature corresponding to the maximum value in the M nearest neighbor clustering screening speed feature similarity mean sets as M initial prototypes; P34-3: construct the M nearest neighbor clustering screening speed feature sets in accordance with the preset neighborhood similarity threshold. M initial neighborhoods of an initial prototype; P34-4: perform edge expansion on the M initial neighborhoods based on a preset neighborhood expansion step to obtain M expanded neighborhoods; P34-5: determine whether the data volume of the M initial neighborhoods is less than or equal to the data volume of the M expanded neighborhoods, and if so, continue to expand the M expanded neighborhoods according to the preset neighborhood expansion step until the preset maximum number of expansions is met, and obtain M target neighborhoods; P34-6: traverse and calculate the feature mean of the M target neighborhoods to obtain M low-power speed features.
[0051] In a possible embodiment of the present application, the low-power configuration space construction module 30 may perform the following refinement when performing prototype extraction on the M nearest neighbor cluster screening speed feature sets to ensure that the extracted prototype can accurately represent the characteristics of each cluster set, thereby improving the optimization effect of the low-power configuration space.
[0052] First, the low-power configuration space construction module 30 performs pairwise similarity identification on each of the M nearest-neighbor clustering speed feature sets. This process quantifies the degree of correlation between the features by calculating the similarity between the speed features within each cluster set, for example, by calculating the Euclidean distance between the speed features. Subsequently, the mean similarity calculation is performed on each nearest-neighbor clustering speed feature, obtaining a set of M nearest-neighbor clustering speed feature mean similarity values. The mean similarity value reflects the consistency of the features within each cluster set. A higher mean value indicates more similar features within the set and a better clustering effect.
[0053] Next, the nearest neighbor clustering speed feature corresponding to the maximum value in the mean similarity value set of the speed feature selection of the M nearest neighbor clusters is used as the M initial prototypes. In other words, based on each maximum value in the mean similarity value set, the most representative or typical speed feature within each cluster is determined and used as the initial prototype. This prototype represents the most representative data point in the cluster and can reflect the central characteristics of the cluster.
[0054] Then, based on a preset neighborhood similarity threshold, M initial neighborhoods of the M initial prototypes are constructed from the M nearest neighbor clustering and filtering speed feature sets. A neighborhood is a region in feature space consisting of other feature points similar to the prototype features. Based on the preset similarity threshold, the module determines which speed features are sufficiently similar to the initial prototype and classifies them into the same neighborhood. This neighborhood contains speed features similar to the initial prototype.
[0055] Next, each initial neighborhood is expanded, extending its boundaries using a preset neighborhood expansion step size to obtain an expanded neighborhood. The goal of this expansion operation is to expand the neighborhood to encompass more potentially similar features. During this expansion process, the module gradually increases the neighborhood size based on the expansion step size to ensure that more speed features are included. This expansion process continues until the preset maximum number of expansions is reached, or until further neighborhood expansion is no longer possible, ultimately resulting in M expanded neighborhoods.
[0056] After the expansion is complete, the module determines whether the data volume of the M initial neighborhoods is less than or equal to the data volume of the M expanded neighborhoods. If so, the module continues to expand the expanded neighborhood according to the preset expansion step size until the required number of expansions is met, thereby obtaining a more representative dataset. If the data volume of the initial neighborhood is already greater than that of the expanded neighborhood, the expansion process is terminated and the current expanded neighborhood is retained.
[0057] Finally, the low-power configuration space construction module 30 traverses and calculates the mean of the features of the M target neighborhoods to obtain M low-power speed features. The calculation of the feature mean is a comprehensive processing of all features within the target neighborhood. Through the averaging operation, the differences in features within the neighborhood can be effectively balanced, thereby obtaining a more representative low-power speed feature.
[0058] Through the above steps, the low-power configuration space construction module 30 successfully extracts M representative low-power rotational speed features from the nearest neighbor clustering, and uses them for the subsequent construction of the low-power configuration pulse recording parameter group, and finally forms a complete low-power configuration space.
[0059] Furthermore, the low power configuration space construction module 30 is further configured to:
[0060] P34-5a: When the data volume of the M initial neighborhoods is greater than the data volume of the M expanded neighborhoods, calculate the data volume difference between the M initial neighborhoods and the M expanded neighborhoods, and determine whether the data volume difference meets the preset data volume difference. If so, use the M initial neighborhoods as M target neighborhoods.
[0061] Optionally, if the amount of data in the initial neighborhood is greater than that in the expanded neighborhood, the module performs the following operations: First, the data volume difference between the M initial neighborhoods and the M expanded neighborhoods is calculated. The data volume difference here refers to the difference in the number of features between the initial neighborhood and the expanded neighborhood. For example, the number of speed feature points in the initial neighborhood and the number of speed feature points in the expanded neighborhood are counted, and then the difference between the two is calculated.
[0062] Next, the module determines whether the calculated data volume difference meets the preset data volume difference. The preset data volume difference is a threshold value set by a person skilled in the art and is used to determine whether to accept the data volume of the initial neighborhood as the final target neighborhood data volume. If the data volume difference meets the preset requirements, it means that the initial neighborhood has an advantage in data volume and is sufficiently representative. At this time, the module will use the M initial neighborhoods as the M target neighborhoods. This operation means that although the neighborhood has been expanded, because the initial neighborhood has a sufficient amount of data and is highly representative, the expanded neighborhood will no longer be used, and the initial neighborhood will be directly selected as the target neighborhood for subsequent processing.
[0063] In this way, the module can ensure feature extraction and configuration updates within a neighborhood with large data volume, thereby enhancing the stability and reliability of the low-power configuration space.
[0064] Furthermore, the low power configuration space construction module 30 is further configured to:
[0065] P34-51a: When the data volume difference between the M initial neighborhoods and the M expanded neighborhoods does not meet the preset data volume difference, the M initial neighborhoods are edge-retreated according to half of the preset neighborhood expansion step to obtain M retracement neighborhoods; P34-52a: When the data volume of the M retracement neighborhoods is greater than or equal to the data volume of the M initial neighborhoods, and the data volume difference between the M retracement neighborhoods and the M initial neighborhoods meets the preset data volume difference, the M retracement neighborhoods are used as the M target neighborhoods.
[0066] Specifically, the low-power configuration space construction module 30 further refines the judgment and processing logic for neighborhood data volume when performing neighborhood expansion operations to ensure that neighborhood construction is more reasonable and meets optimization objectives. This process not only considers the necessity of neighborhood expansion but also introduces an edge pullback mechanism to avoid potential problems caused by excessive neighborhood expansion.
[0067] Specifically, first, the edges of the M initial neighborhoods are retracted. The retraction operation is to adjust the scope of the initial neighborhood to make it more compact and retain the most representative features. If the amount of expanded data in the initial neighborhood is insufficient or does not meet the preset data volume difference requirements, the module will retract according to half of the preset neighborhood expansion step. At this time, the scope of the initial neighborhood will be gradually reduced, and the coverage area of the initial neighborhood will be reduced by reducing the data points on the edge. Specifically, the retraction operation is to reduce the influence range of the neighborhood by gradually reducing the feature points on the neighborhood boundary. The retraction step is set to half the expansion step to ensure that the shrinkage of the neighborhood is more refined and gradual, avoiding overly drastic changes.
[0068] By retracting the edges, we obtain M retracted neighborhoods. These neighborhoods are smaller than the initial neighborhoods and are concentrated near more representative speed feature points. The retracted neighborhoods can better represent the key speed variation characteristics of the target test object.
[0069] Next, the data volume of the M retracted neighborhoods is checked. If the data volume of the M retracted neighborhoods is greater than or equal to the data volume of the M initial neighborhoods, and the difference between the data volume of the retracted neighborhood and the initial neighborhood meets the preset data volume difference, the data volume and representativeness of the retracted neighborhoods are considered sufficient and meet the requirements for further application. At this point, the M retracted neighborhoods are used as the M target neighborhoods for subsequent low-power configuration space construction.
[0070] This process ensures that even if the data volume difference between the initial neighborhood and the expanded neighborhood is too large, the range of the neighborhood can still be adjusted through edge retracement, so that the final selected target neighborhood not only has the advantage in data volume, but also can better represent the characteristics of the target test object, thereby optimizing the subsequent low-power configuration pulse recording parameter group.
[0071] The configuration update module 40 is used to traverse the low-power speed feature identifier of the low-power configuration space and match it with the fused speed change feature. If the match is successful, the configuration of the microcontroller is updated according to the corresponding low-power configuration pulse counting parameter group, and the speed tester is used to perform a speed test on the target test object.
[0072] It should be understood that the core function of the configuration update module 40 of the present application is to dynamically adjust the pulse counting parameter group of the microcontroller by matching the low-power speed feature identifier in the low-power configuration space and integrating the speed change characteristics, thereby achieving low-power operation.
[0073] During implementation, configuration update module 40 first traverses the low-power speed signature identifiers in the low-power configuration space. The low-power configuration space, pre-constructed by low-power configuration space construction module 30, contains multiple low-power configuration pulse count parameter groups, each corresponding to a low-power speed signature identifier. These signature identifiers are representative features derived through clustering and prototype extraction of the speed characteristics of the target test object, accurately reflecting speed variations under different operating conditions.
[0074] Subsequently, the configuration update module 40 matches these low-power speed feature identifiers with the fused speed change features output by the speed change feature analysis module 20. The matching process is based on a similarity or distance metric between features, such as Euclidean distance or cosine similarity, to determine which feature identifier in the low-power configuration space is most similar to the speed feature of the current target test object. If a match is successful, i.e., the low-power speed feature identifier with the highest similarity to the fused speed change feature is found, the MCU configuration is updated based on the low-power configuration pulse count parameter set corresponding to that identifier.
[0075] The configuration update involves adjusting key parameters such as the MCU's clock frequency and sampling window length. These adjustments are based on the settings in the low-power configuration pulse count parameter group and aim to optimize the MCU's power consumption under current operating conditions. For example, under conditions with slow speed changes, the clock frequency can be appropriately reduced and the sampling window length increased, thereby reducing power consumption without compromising test accuracy.
[0076] After the configuration update is complete, the updated tachometer is used to perform a tachometer test on the target test object. The tachometer now measures the target test object's tachometer speed according to the newly configured parameters. The collected test results are accurately measured based on the new configuration while maintaining low power consumption. The updated tachometer, operating with the new pulse count parameter set, can complete tachometer speed measurements with lower power consumption while ensuring accurate and reliable measurement results.
[0077] The entire execution process ensures that during the speed test, the test device can automatically adjust its configuration according to the real-time speed change characteristics, thereby minimizing power consumption and improving the energy efficiency of the test device while ensuring test accuracy.
[0078] In summary, the embodiments of the present application have at least the following technical effects:
[0079] The speed test module of the present application picks up the speed signal through a photoelectric sensor, transmits it to the microcontroller for speed measurement and generates a test result sequence; the speed change feature analysis module performs asynchronous analysis on the results and extracts fusion features; the low-power configuration space construction module pre-builds a low-power configuration space according to the target test object type and model; the configuration update module updates the microcontroller configuration according to the matching low-power features and performs accurate speed testing, thereby achieving low-power, high-precision speed measurement.
[0080] The technical effect of dynamically adjusting the power consumption configuration and adjusting the power consumption of the target test object in real time is achieved, which significantly reduces power consumption and improves test accuracy.
[0081] Example 2, refer to Figure 2 To describe the electronic device of the embodiment of the present application.
[0082] Based on the same inventive concept as a low-power rotational speed testing device in the aforementioned embodiment, the present application also provides an electronic device, comprising: a processor, the processor being coupled to a memory, the memory being used to store a program, and when the program is executed by the processor, the system executes the steps of the device described in embodiment one.
[0083] The electronic device 300 includes: a processor 302, a communication interface 303, and a memory 301. Optionally, the electronic device 300 may further include a bus architecture 304. The communication interface 303, the processor 302, and the memory 301 may be interconnected via the bus architecture 304; the bus architecture 304 may be a peripheral component interconnect (PCI) bus or an extended industry standard architecture (EISA) bus. The bus architecture 304 may be divided into an address bus, a data bus, a control bus, and the like. For ease of representation, Figure 2 Only one thick line is used in the diagram, but this does not mean that there is only one bus or one type of bus.
[0084] The processor 302 may be a CPU, a microprocessor, an ASIC, or one or more integrated circuits for controlling the execution of the program of the present application.
[0085] The communication interface 303 uses any transceiver or other device for communicating with other devices or communication networks, such as Ethernet, radio access network (RAN), wireless local area network (WLAN), wired access network, etc.
[0086] The memory 301 can be a ROM or other type of static storage device that can store static information and instructions, a RAM or other type of dynamic storage device that can store information and instructions, or an electrically erasable programmable read only memory (EEPROM), a compact disc (CD ROM) or other optical disc storage, an optical disc storage (including a compact disc, a laser disc, an optical disc, a digital versatile disc, a Blu-ray disc, etc.), a magnetic disk storage medium or other magnetic storage device, or any other medium that can be used to carry or store desired program code in the form of instructions or data structures and can be accessed by a computer, but is not limited thereto. The memory can exist independently and be connected to the processor via the bus architecture 304. The memory can also be integrated with the processor.
[0087] The memory 301 is used to store computer-executable instructions for executing the solution of the present application, and the execution is controlled by the processor 302. The processor 302 is used to execute the computer-executable instructions stored in the memory 301, thereby realizing a low-power rotation speed test device provided by the above embodiment of the present application.
[0088] Example three, based on the same inventive concept as a low-power rotational speed testing device in the aforementioned example, the present application also provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, it is like the device in Example one.
[0089] Through the detailed description of a low-power rotational speed test device described above, those skilled in the art can clearly understand the low-power rotational speed test device of this embodiment. Therefore, for the sake of brevity of the specification, it will not be described in detail here. As for the storage medium disclosed in the embodiment, since it corresponds to the device disclosed in the embodiment, the description is relatively simple. For relevant details, please refer to the device description.
[0090] The above description of the disclosed embodiments is intended to enable one skilled in the art to implement or use the present application. Various modifications to these embodiments will be readily apparent to one skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present application. Therefore, the present application is not limited to the embodiments shown herein, but is intended to conform to the widest scope consistent with the principles and novel features disclosed herein.
[0091] It should be noted that the order in which the embodiments of the present application are presented is for illustrative purposes only and does not necessarily represent the superiority or inferiority of the embodiments. Furthermore, the foregoing descriptions of specific embodiments of this specification are provided. Furthermore, the processes depicted in the accompanying drawings do not necessarily require the specific order or sequential sequence shown to achieve the desired results. In certain embodiments, multitasking and parallel processing are also possible or may be advantageous.
[0092] The above description is only a preferred embodiment of the present application and is not intended to limit the present application. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principles of the present application should be included in the scope of protection of the present application.
[0093] This specification and drawings are merely illustrative of the present application and are intended to cover any and all modifications, variations, combinations, or equivalents within the scope of this application. Obviously, those skilled in the art may make various modifications and variations to this application without departing from the scope of this application. Thus, this application is intended to include such modifications and variations as fall within the scope of this application and its equivalents.
Claims
1. A low-power rotation speed test device, characterized in that: The device comprises: The speed test module is used to configure the standard pulse counting parameter group for the single-chip microcomputer in the speed tester, use the photoelectric sensor in the speed measuring instrument to pick up the speed signal of the target test object, transmit the obtained pulse signal to the single-chip microcomputer through the pin for speed testing, and obtain the speed test result sequence; A speed change feature analysis module is used to traverse the speed test result sequence to perform asynchronous analysis and fusion of the speed change features to determine the fused speed change features; A low-power configuration space construction module is used to pre-construct a low-power configuration space based on the type and model of the target test object, wherein each low-power configuration pulse count parameter group in the low-power configuration space has a low-power speed change characteristic identifier; a configuration update module, configured to traverse the low-power rotational speed feature identifiers in the low-power configuration space and match them with the fused rotational speed change feature; if a match is successful, update the configuration of the single-chip microcomputer according to the corresponding low-power configuration pulse count parameter group, and use the updated rotational speed tester to perform a rotational speed test on the target test object; Wherein, when traversing the speed test result sequence to perform asynchronous analysis and fusion of speed change characteristics, the speed change characteristic analysis module is further used to: Obtain the first receptive field, and expand the first receptive field according to the preset increase in the number of layers, the preset update of the convolution kernel, and the preset increase in the step size to obtain the second receptive field; Taking the speed test result sequence as input, the first receptive field and the second receptive field as feature analysis scales respectively, and the speed change feature as output, the first feature analyzer and the second feature analyzer are constructed; Using the first feature analyzer and the second feature analyzer, extracting a speed change feature from the speed test result sequence to obtain a first speed change feature and a second speed change feature; Asynchronously analyzing and fusing the first speed variation feature and the second speed variation feature to determine the fused speed variation feature; Wherein, when the speed change characteristic analysis module asynchronously analyzes and fuses the first speed change characteristic and the second speed change characteristic, it is further configured to: Normalizing a mapping similarity set between the first speed change feature and the second speed change feature using a softmax function to determine a mapping similarity normalization value set; Performing feature enhancement on the second speed change feature based on the mapping similarity normalized value set to obtain the fused speed change feature; Wherein, when pre-building the low power configuration space based on the type and model of the target test object, the low power configuration space construction module is further used to: Mining low-speed test records based on the type and model of the target test object, and filtering the mining results according to a preset test accuracy threshold and a preset power consumption threshold to obtain a filtered speed test record set; Traversing and extracting the pulse counting parameter group and the speed characteristics of the screening speed test record set to obtain a screening speed characteristic set and a screening pulse record parameter group set, wherein the screening speed characteristics and the screening pulse record parameter group have a one-to-one correspondence; Performing nearest neighbor clustering on the screening speed feature set to obtain M nearest neighbor clustering screening speed feature sets, where M is a positive integer; Prototype extraction is performed on the M nearest neighbor clustering screening speed feature sets to determine M low-power speed features; According to the one-to-one correspondence between the screening speed characteristics and the screening pulse recording parameter groups, the screening pulse recording parameter group set is mapped and divided in combination with the M nearest neighbor clustering screening speed characteristic sets to obtain M nearest neighbor clustering screening pulse recording parameter group sets; The M nearest neighbor clustering screening pulse recording parameter group sets are averaged to determine M low-power configuration pulse recording parameter groups, and the M low-power configuration pulse recording parameter groups are identified using the M low-power rotational speed features to obtain the low-power configuration space.
2. A low power consumption rotation speed test device as claimed in claim 1, characterized in that: When performing prototype extraction on the M nearest neighbor cluster screening speed feature sets, the low-power configuration space construction module is further used to: Performing pairwise similarity identification on the M nearest neighbor clustering screening speed feature sets respectively, and calculating the mean similarity of identification for each nearest neighbor clustering screening speed feature, to obtain a mean similarity set of M nearest neighbor clustering screening speed feature; The nearest neighbor clustering screening speed feature corresponding to the maximum value in the set of mean values of the similarities of the M nearest neighbor clustering screening speed features is respectively used as M initial prototypes; According to a preset neighborhood similarity threshold, constructing M initial neighborhoods of the M initial prototypes in the M nearest neighbor clustering screening speed feature sets; Performing edge expansion on the M initial neighborhoods based on a preset neighborhood expansion step size to obtain M expanded neighborhoods; Determine whether the amount of data in the M initial neighborhoods is less than or equal to the amount of data in the M expanded neighborhoods. If so, continue expanding the M expanded neighborhoods according to a preset neighborhood expansion step size until a preset maximum number of expansions is met, thereby obtaining M target neighborhoods. The feature means of the M target neighborhoods are traversed and calculated to obtain M low-power rotation speed features.
3. A low-power rotation speed test device as claimed in claim 2, characterized in that: The low power configuration space building block is further configured to: When the data volume of the M initial neighborhoods is greater than the data volume of the M expanded neighborhoods, the data volume difference between the M initial neighborhoods and the M expanded neighborhoods is calculated, and it is determined whether the data volume difference meets the preset data volume difference. If so, the M initial neighborhoods are used as M target neighborhoods.
4. A low-power rotation speed test device as claimed in claim 3, characterized in that: The low power configuration space building block is further configured to: When the data volume difference between the M initial neighborhoods and the M expanded neighborhoods does not meet the preset data volume difference, the M initial neighborhoods are edge-retreated according to half of the preset neighborhood expansion step length to obtain M retracted neighborhoods; When the data volume of the M retracted neighborhoods is greater than or equal to the data volume of the M initial neighborhoods, and the data volume difference between the M retracted neighborhoods and the M initial neighborhoods meets the preset data volume difference, the M retracted neighborhoods are used as the M target neighborhoods.
5. The low-power rotation speed test device according to claim 1, characterized in that: In the rotation speed test module, the standard pulse counting parameter group includes a standard clock frequency and a standard sampling window.
6. An electronic device, characterized in that: include: A processor, the processor is coupled to a memory, the memory is used to store a program, and when the stored program is executed by the processor, a low-power rotation speed test device as described in any one of claims 1 to 5 is implemented.
7. A computer-readable storage medium, characterized in that The storage medium stores a computer program, and when the computer program is executed by the processor, the low-power consumption rotation speed test device according to any one of claims 1 to 5 is implemented.
Citation Information
Patent Citations
Microcontroller-based disk loading rotation speed power consumption tester
CN104931100A
All-weather human shape monitoring method and device for low-power-consumption monitoring equipment
CN118968559A