CN117648026B - I2C master-slave chip switching method and system based on watch wearing application - Google Patents
I2C master-slave chip switching method and system based on watch wearing application Download PDFInfo
- Publication number
- CN117648026B CN117648026B CN202410107890.XA CN202410107890A CN117648026B CN 117648026 B CN117648026 B CN 117648026B CN 202410107890 A CN202410107890 A CN 202410107890A CN 117648026 B CN117648026 B CN 117648026B
- Authority
- CN
- China
- Prior art keywords
- active
- interaction
- activation
- short
- sequence
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
- 238000000034 method Methods 0.000 title claims abstract description 58
- 230000003993 interaction Effects 0.000 claims abstract description 267
- 230000004913 activation Effects 0.000 claims abstract description 103
- 239000011159 matrix material Substances 0.000 claims abstract description 35
- 238000011156 evaluation Methods 0.000 claims abstract description 22
- 230000000694 effects Effects 0.000 claims abstract description 15
- 230000008569 process Effects 0.000 claims description 12
- 230000006870 function Effects 0.000 claims description 11
- 238000004590 computer program Methods 0.000 claims description 6
- 238000010606 normalization Methods 0.000 claims description 4
- 238000012545 processing Methods 0.000 abstract description 2
- 230000008859 change Effects 0.000 description 4
- 230000002452 interceptive effect Effects 0.000 description 4
- 230000005540 biological transmission Effects 0.000 description 2
- 238000004364 calculation method Methods 0.000 description 2
- 238000004377 microelectronic Methods 0.000 description 2
- 238000012986 modification Methods 0.000 description 2
- 230000004048 modification Effects 0.000 description 2
- 230000004044 response Effects 0.000 description 2
- 241000764238 Isis Species 0.000 description 1
- 238000004458 analytical method Methods 0.000 description 1
- 230000009286 beneficial effect Effects 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 238000010586 diagram Methods 0.000 description 1
- 230000005611 electricity Effects 0.000 description 1
- 238000005265 energy consumption Methods 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 230000035800 maturation Effects 0.000 description 1
- 238000012544 monitoring process Methods 0.000 description 1
- 230000000750 progressive effect Effects 0.000 description 1
- 238000006467 substitution reaction Methods 0.000 description 1
Landscapes
- User Interface Of Digital Computer (AREA)
Abstract
The invention relates to the technical field of data processing, and provides an I2C master-slave chip switching method and system based on watch wearing application, wherein the method comprises the following steps: acquiring a wearable watch interaction activation matrix at each moment, and acquiring the chip frequency of the wearable watch at each moment; acquiring a short activation interaction time segment, calculating an active interaction index according to an interaction activation matrix, acquiring an active interaction index sequence, calculating the active interval length of the active interaction index sequence at different moments, calculating the active interaction probability of different short active intervals, acquiring the active interaction index mean value of the active interaction index sequence at different moments, dividing the active interaction index mean value into a left sequence and a right sequence, calculating the active evaluation distance at different moment positions, and further acquiring the optimal active activation threshold of the wearable watch; and switching the master chip and the slave chip of the wearable watch according to the optimal active activation threshold of the wearable watch at different moments. The invention realizes the effect of accurately switching the I2C master chip and the slave chip of the wearable watch.
Description
Technical Field
The invention relates to the technical field of data processing, in particular to an I2C master-slave chip switching method and system based on watch wearing application.
Background
Along with the continuous development and the gradual maturation of microelectronic integrated chips and sensor technologies, wearable watches taking microelectronic chips and related sensors as cores are rapidly developed, are widely applied to various different life fields of medical treatment, education, entertainment, military, industry and the like, and bring great revolution to daily life.
In order to meet the various different requirements of the user market on the function application of the wearable watch, the currently mainstream function application of the wearable watch improves the function application and performance of the wearable watch by integrating various different sensors and chips. But is limited by the external dimension of the wearable watch, the chip energy consumption is too high and a large amount of electricity is consumed due to long-time operation of the high-performance chip, so that the long-time endurance requirement of the wearable watch is difficult to meet. Therefore, the chip needs to be switched according to the running performance of different chips in the wearing watch so as to adapt to the endurance requirement of the wearing watch.
Disclosure of Invention
The invention provides an I2C master-slave chip switching method and system based on a wearable watch application, which are used for solving the problem of inaccurate judgment of an active state of a user caused by frequent inquiry of the active state when the master-slave chip of the traditional wearable watch is switched, and the adopted technical scheme is as follows:
in a first aspect, an embodiment of the present invention provides an I2C master-slave chip switching method based on a wearable watch application, the method including the steps of:
acquiring a wearable watch interaction activation matrix at each moment, and acquiring the chip frequency of the wearable watch at each moment;
acquiring short activation interaction time segments, and calculating an active interaction index of each short activation interaction time segment according to the watch wearing interaction activation matrix at each moment;
acquiring an active interaction index sequence according to the active interaction index of each short active interaction time segment, calculating the active interval length of the active interaction index sequence at different moments according to each different active interaction index, acquiring a short active interval according to the active interval length, calculating the active interaction probability of different short active intervals, acquiring the active interaction index mean value of the active interaction index sequence at different moments, dividing the active interaction index mean value into a left sequence and a right sequence, calculating the active evaluation distance at different moment positions according to the active interaction probability, and calculating the optimal wearable watch active activation threshold according to the active evaluation distance at different moments;
and switching the master chip and the slave chip of the wearable watch according to the optimal active activation threshold of the wearable watch at different moments.
Preferably, the mathematical expression for calculating the active interaction index of each short active interaction time segment according to the wearable watch interaction activation matrix at each moment is:
;
in the method, in the process of the invention,the average of the chip frequencies at different time positions in the short active interaction segment is shown,the length of the short active interaction time segment is shown,is shown at the firstThe first short active interaction segmentThe total number of high levels in the interaction activation matrix at each instant,the size of the pixel point of the screen of the wearing watch is shown,the euclidean distance between two different coordinates is shown,represents the firstThe minimum coordinates of the high level data points in the interaction activation matrix at the start time position in the short-activation interaction segment,represents the firstTime of day in a short active interaction segmentThe minimum coordinates of the high level data points in the interaction activation matrix at the location,represents the firstThe maximum coordinates of the high level data points in the interaction activation matrix at the start time position in the short-activation interaction segment,represents the firstTime of day in a short active interaction segmentThe maximum coordinates of the high level data points in the interaction activation matrix at the location,represents the firstAn application active interaction index for a short active interaction time segment.
Preferably, the method for acquiring the active interaction index sequence according to the active interaction index of each short active interaction time segment comprises the following steps:
and arranging the application active interaction indexes calculated in all different short activation interaction time slices in front of each different time position according to the time sequence to obtain a short activation interaction index sequence.
Preferably, the mathematical expression for calculating the active interval length of the active interaction index sequence at different time points according to each different active interaction index is as follows:
;
in the method, in the process of the invention,the normalization function is shown as such,indicating the time of dayThe variance size of the active interaction index is applied in the sequence of active interaction indices,indicating the time of dayThe mean size of the active interaction index is applied in the sequence of active interaction indices,indicating the time of dayThe maximum value of the active interaction index is applied in the sequence of active interaction indices,indicating the time of dayThe minimum value of the active interaction index is applied in the sequence of active interaction indices,indicating the time of dayThe total number of active interaction indices applied in the sequence of active interaction indices,indicating the time of dayActive interval length of the active interaction index sequence.
Preferably, the method for acquiring the short active section according to the active section length and calculating the active interaction probability of different short active sections comprises the following steps:
dividing the active interaction index sequence into different sections by using the length of the active section at different moments, marking each section as a short active section, and marking the ratio of the number of data points in each active section to the total number of different data points at the current moment as the active interaction probability of each short active section.
Preferably, the mathematical expression for calculating the active evaluation distances at different time positions according to the active interaction probability is:
;
in the method, in the process of the invention,,respectively indicate the time of dayActive interaction index sequence at locationDynamic active weights for left and right data after sub-division,,respectively indicate the time of dayLiving in placeInteractive index sequence of leapThe number of short active intervals of the left and right data after sub-division,indicating the time of dayActive interaction index sequence at positionThe probability of a short active interval,expressed in numbersAs a logarithmic function of the base,time of dayActive interaction index sequence at locationActive evaluation distance after sub-division.
Preferably, the method for calculating the dynamic activity weights of the left data and the right data is as follows:
and marking the normalized result of the product of the kurtosis of the left sequence data of the active interaction index sequence and the average value of the active interaction index at different moments as the dynamic active weight of the left sequence data, and marking the normalized result of the product of the kurtosis of the right sequence data of the active interaction index sequence and the average value of the active interaction index at different moments as the dynamic active weight of the right sequence data.
Preferably, the method for calculating the optimal activity activation threshold of the wearable watch according to the activity evaluation distances at different moments is as follows:
and enabling the initial value of the active activation threshold of the wearable watch to be the average value of the active interaction index sequence, continuously adding the active activation threshold of the wearable watch until the active activation threshold of the wearable watch is equal to the maximum active interaction index, dividing the active interaction index sequence into a left sequence and a right sequence by utilizing different active activation thresholds of the wearable watch, calculating the active evaluation distance, and taking the active activation threshold of the wearable watch corresponding to the active interaction index corresponding to the maximum active evaluation distance as the optimal active activation threshold of the wearable watch.
Preferably, the method for switching the master-slave chip of the wearable watch according to the optimal active activation threshold of the wearable watch at different moments comprises the following steps:
setting the activation signal quantity of the short activation interaction segment larger than the optimal wearable watch active activation threshold to be digital 1, setting the activation signal quantity of the short activation interaction segment smaller than or equal to the optimal wearable watch active activation threshold to be digital 0, updating the data frame of the I2C data bus once every time the time length of the short activation interaction segment is spaced, and when the activation signal quantity is digitalWhen the chip is used, the high-performance chip is activated as a master chip, and the low-performance chip is used as a slave chip; when the activation signal is digitalWhen the chip is activated, the low-performance chip is used as a master chip, and the high-performance chip is used as a slave chip.
In a second aspect, an embodiment of the present invention further provides an I2C master-slave chip switching system based on a wearable watch application, including a memory, a processor, and a computer program stored in the memory and running on the processor, where the processor implements the steps of any one of the methods described above when the processor executes the computer program.
The beneficial effects of the invention are as follows: according to the method, the active interaction indexes of different short-time segments are obtained through calculating the change states of the interaction activation matrix in the short-time interaction time segments, the problem of low calculation efficiency caused by repeatedly monitoring the active state of the wearable watch at different moments is avoided while the active state of the wearable watch in the current short-time segment is effectively monitored, meanwhile, the active interval length of the active interaction index sequence and the active evaluation distance of the active interaction index sequence are obtained through calculating according to the active interaction indexes, and the optimal active activation threshold of the wearable watch is obtained according to the active evaluation distance, so that misjudgment of the active state of the user of the wearable watch due to false touch of the user is effectively avoided, and the accuracy of judging the active state of the user by the wearable watch application and further switching the master chip and the slave chip by using the I2C bus is ensured.
Drawings
In order to more clearly illustrate the embodiments of the invention or the technical solutions of the prior art, the drawings which are used in the description of the embodiments or the prior art will be briefly described, it being obvious that the drawings in the description below are only some embodiments of the invention, and that other drawings can be obtained according to these drawings without inventive faculty for a person skilled in the art.
Fig. 1 is a schematic flow chart of an I2C master-slave chip switching method based on a wearable watch application according to an embodiment of the present invention;
fig. 2 is a schematic diagram of a master-slave chip switch of an I2C data bus for a wearable watch application.
Detailed Description
The following description of the embodiments of the present invention will be made clearly and completely with reference to the accompanying drawings, in which it is apparent that the embodiments described are only some embodiments of the present invention, but not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the invention without making any inventive effort, are intended to be within the scope of the invention.
Referring to fig. 1, a flowchart of an I2C master-slave chip switching method based on a wearable watch application according to an embodiment of the present invention is shown, where the method includes the following steps:
step S001, acquiring a wearable watch interaction activation matrix at each moment, and acquiring the frequency of a wearable watch chip at each moment.
It should be noted that there are two different chips during the operation of the wearable watch of the present invention, wherein the chip responsible for supporting the application functions of the wearable watch is denoted asThe chip is a chip with relatively high performance and relatively high power consumption; the chip responsible for data mounting transmission and maintaining sensor state update is recorded asThe chip is a chip with relatively low performance and relatively low power consumption. In order to meet the normal endurance of the wearing watch in the actual running process, the master-slave states of two different chips are required to be switched and adjusted according to different states of the wearing watch. Intuitively, when a user is in an interaction state with the wearable watch, in order to respond to the user interaction requirement in time, a smoother interaction experience is provided, and a high-performance chip is required to be used as a main support; when the wearable watch and the user are in a state without interaction response, the bottom performance chip is required to be used as a main support, so that the purpose of prolonging the duration of the wearable watch is achieved.
Specifically, assume that the pixel dot size of the currently worn watch screen isThe level state of each different pixel point position at each moment is obtained to form an interactive activation matrix, and the moment is assumedThe interaction activation matrix is. In the matrix, the values areOr (b)In an interactive activation matrixThe numerical value isIs considered to be a high level response state, i.e. a state in which the user has interaction with the watch wearing screen.
Step S002, obtaining short activation interaction time segments, and calculating the active interaction index of each short activation interaction time segment according to the wearable watch interaction activation matrix at each moment.
It should be noted that, in the state of different moments, when the user and the wearable watch are in the frequently active interaction state, the numerical states at different positions in the interaction activation matrix should have a larger difference from the numerical states at different positions in the interaction activation matrix in the non-frequently active interaction state, so that the frequently active interaction state of the user and the wearable watch needs to be acquired in combination with the interaction activation matrix in the continuous short-moment segment.
Specifically, in order to facilitate analysis and calculation, the invention takes each position at different time as a starting point and takes the length of a data point backwards asIs noted as a short active interaction time segment,take the empirical value asAnd calculating and analyzing numerical value change conditions at different positions in the interactive activation matrix in the short-time active interaction time segment, and calculating the change states of the interactive activation matrix at different time positions in the short-time active interaction time segment.
;
In the method, in the process of the invention,representing the chip at different time positions in a short active interaction segmentThe average value of the frequency is used to determine,the length of the short active interaction time segment is shown,is shown at the firstThe first short active interaction segmentThe total number of high levels in the interaction activation matrix at each instant,the size of the pixel point of the screen of the wearing watch is shown,the euclidean distance between two different coordinates is shown,represents the firstThe minimum coordinates of the high level data points in the interaction activation matrix at the start time position in the short-activation interaction segment,represents the firstTime of day in a short active interaction segmentThe minimum coordinates of the high level data points in the interaction activation matrix at the location,represents the firstThe maximum coordinates of the high level data points in the interaction activation matrix at the start time position in the short-activation interaction segment,represents the firstTime of day in a short active interaction segmentThe maximum coordinates of the high level data points in the interaction activation matrix at the location,represents the firstActive interaction index for each short active interaction time segment.
The active interaction indexes of the wearable watch with different short activation interaction time segments can be calculated through the method, in the short activation interaction time segments, if the frequency of the high-performance chip of the wearable watch is higher, the high-performance chip is in an occupied state in the current state, the high-level quantity of different data point positions in the interaction activation matrix is larger in duty ratio, meanwhile, the distance between the maximum coordinates and the minimum coordinates of the high-level data points is calculated at different moments, the calculated active interaction indexes of the wearable watch are relatively larger, and the fact that the user and the wearable watch are subjected to more frequent active interaction in the current short activation interaction time segments is indicated.
Step S003, an active interaction index sequence is obtained according to the active interaction index of each short active interaction time segment, the active interval length of the active interaction index sequence at different moments is calculated according to each different active interaction index, the short active interval is obtained according to the active interval length, the active interaction probability of different short active intervals is calculated, the active interaction index mean value of the active interaction index sequence at different moments is obtained and divided into a left sequence and a right sequence, the active evaluation distance at different moment positions is calculated according to the active interaction probability, and the optimal wearable watch active activation threshold is calculated according to the active evaluation distance at different moments.
It should be noted that, when the wearable watch application is in the active interaction state, the active interaction index calculated in the short active interaction time segment is relatively large, whereas when the wearable watch application is in the inactive state, the active interaction index calculated in the short active interaction time segment is relatively small, so that the active-slave state of the chip is dynamically switched and adjusted according to the active index of the short active interaction time segment.
In particular, assume that the short active interaction time segment at the current time is preceded by a commonDifferent short activation interaction time segments can be calculatedDifferent application active interaction indexes are calculatedThe indexes of different application active interaction values are arranged in time sequence to obtain the momentActive interaction index sequence at.
;
In the method, in the process of the invention,the normalization function is shown as such,indicating the time of dayThe variance size of the active interaction index is applied in the sequence of active interaction indices,indicating the time of dayThe mean size of the active interaction index is applied in the sequence of active interaction indices,indicating the time of dayThe maximum value of the active interaction index is applied in the sequence of active interaction indices,indicating the time of dayThe minimum value of the active interaction index is applied in the sequence of active interaction indices,indicating the time of dayThe total number of active interaction indices applied in the sequence of active interaction indices,indicating the time of dayActive interval length of the active interaction index sequence.
For the moment of timeAn active interaction index sequence, if the ratio of the variance to the mean value of the data in different short-activation interaction time segments is larger and the difference between the maximum and minimum values in different short-activation interaction time segments is larger, the current moment is describedActive interaction index sequence atIn the column, the larger the numerical variation is, the relatively discrete data point distribution is, and in order to reflect the numerical variation condition of the active interaction index more accurately, the length of the active section is calculated to be relatively smaller.
The active interval length at different time positions can be calculated through the formula, the active interval length is utilized to divide the active interaction index sequence into different active short intervals, and the change condition of the active interaction index in each different active short interval is further analyzed, so that the judging threshold value of the active interaction index is obtained.
In particular, assume that the active interval length is utilized to divide the data at different times in the active interaction index sequence into a plurality of different short active intervals for the firstWith active interaction probability in each interval,Represents the post-division thThe total number of data points in each interval,indicating the time of dayThe total number of all active interaction indexes at the location.
Calculating the time of dayThe average value of the active interaction indexes of the active interaction index sequence at the position is recorded as the initial value of the active activation threshold value of the wearable watchThe active interaction index sequence can be divided into the following parts by taking the activity judgment threshold value of the wearable watch as the centerThe left and right different sequences can be calculated to obtain different information entropies for the divided left and right different sequences.
;
In the method, in the process of the invention,the normalization function is shown as such,indicating the time of dayActive interaction index sequence at locationKurtosis of the left active interaction index data after sub-division,indicating the time of dayActive interaction index sequence at locationThe mean value of the active interaction index data on the left after the subdivision,indicating the time of dayActive interaction index sequence at locationKurtosis of the right active interaction index data after sub-division,indicating the time of dayActive interaction index sequence at locationThe mean value of the right active interaction index data after sub-division,,respectively indicate the time of dayActive interaction index sequence at locationDynamic active weights for left and right data after sub-division.
The time can be calculated by the above methodDynamic active weights at location, if at timeWhen the wearable watch is in an inactive state, the numerical distribution of the left active interaction index is relatively gentle, the calculated data kurtosis is relatively smaller than the right data kurtosis, and meanwhile, the data average value of the active interaction index is relatively smaller, so that the calculated dynamic activity weight is relatively smaller than the calculated numerical value in the active state of the wearable watch.
;
In the method, in the process of the invention,,respectively indicate the time of dayActive interaction index sequence at locationDynamic active weights for left and right data after sub-division,,respectively indicate the time of dayActive interaction index sequence at locationThe number of short active intervals of the left and right data after sub-division,indicating the time of dayActive interaction index sequence at positionThe probability of a short active interval,expressed in numbersAs a logarithmic function of the base,time of dayActive interaction index sequence at locationActive evaluation distance after sub-division.
The time can be calculated by the above methodWhen the non-active state is changed into the active interaction state between the user and the wearable watch, the information entropy and the dynamic activity weight value in the left non-active interaction sequence obtained by dividing the active judgment threshold value of the wearable watch are smaller than those in the right active state, so that the calculated active evaluation distance value in the optimal dividing state is the largest.
Because the variation condition of the numerical value in the active interaction index sequences calculated under different time conditions is different, when the average value is taken as the active judgment threshold value of the wearable watch in the initial state, the optimal dividing result cannot be obtained, so that the active judgment threshold value of the wearable watch is continuously added until the active judgment threshold value is equal to the maximum active interaction index, and the active judgment threshold value of the wearable watch in the state with the maximum active evaluation distance is taken as the optimal active activation threshold value of the wearable watch.
And S004, switching the master chip and the slave chip of the wearable watch according to the optimal active activation threshold of the wearable watch at different moments.
It should be noted that, in the operation process of the wearable watch, the master-slave states of two different chips are switched through the I2C data bus signals, so that the transmission process of the I2C data bus data frames needs to be controlled by combining the active activation threshold of the wearable watch, thereby achieving the purpose of master-slave switching of the wearable watch chips.
Specifically, as shown in fig. 2, during the operation of the wearable watch, the application activity interaction index of the data in each different short activation interaction segment and the optimal wearable watch activity activation threshold are calculated, and when the application activity interaction index is assumed to be greater than the current optimal wearable watch activity interaction threshold, the wearable watch is considered to be in an active activation state at this time, so that the value of the activation signal quantity is set to beThe method comprises the steps of carrying out a first treatment on the surface of the Otherwise, consider wearing the watch inactiveThe active state is skipped, and the active signal quantity is set to。
Because the application data is transmitted on the I2C data bus through the I2C data frame, the active running state of the wearable watch is updated and calculated once every short active interaction time segment length of the I2C data frame, and if the active interaction index of the wearable watch is larger than the active interaction threshold of the current short active interaction time segment length, the wearable watch is considered to be in the active running state at the moment, and the high-performance chip is enabled to be in the active running stateIs set as a main chip and a low-performance chipThe slave chip is used for switching the master-slave state of the chip according to the state of the activation signal quantity, so that normal operation of the wearing watch is ensured.
Based on the same inventive concept as the above method, the embodiment of the invention further provides an I2C master-slave chip switching system based on a wearable watch application, which comprises a memory, a processor and a computer program stored in the memory and running on the processor, wherein the processor realizes the steps of any one of the above I2C master-slave chip switching methods based on the wearable watch application when executing the computer program.
In this specification, each embodiment is described in a progressive manner, and identical and similar parts of each embodiment are all referred to each other, and each embodiment mainly describes differences from other embodiments. The foregoing description of the preferred embodiments of the present invention is not intended to be limiting, but rather, any modifications, equivalents, improvements, etc. that fall within the principles of the present invention are intended to be included within the scope of the present invention.
The above description is only of the preferred embodiments of the present invention and is not intended to limit the invention, but any modifications, equivalent substitutions, improvements, etc. within the principles of the present invention should be included in the scope of the present invention.
Claims (7)
1. The I2C master-slave chip switching method based on the application of the wearable watch is characterized by comprising the following steps of:
acquiring a wearable watch interaction activation matrix at each moment, and acquiring the chip frequency of the wearable watch at each moment;
acquiring short activation interaction time segments, and calculating an active interaction index of each short activation interaction time segment according to the watch wearing interaction activation matrix at each moment;
acquiring an active interaction index sequence according to the active interaction index of each short active interaction time segment, calculating the active interval length of the active interaction index sequence at different moments according to each different active interaction index, acquiring a short active interval according to the active interval length, calculating the active interaction probability of different short active intervals, acquiring the active interaction index mean value of the active interaction index sequence at different moments, dividing the active interaction index mean value into a left sequence and a right sequence, calculating the active evaluation distance at different moment positions according to the active interaction probability, and calculating the optimal wearable watch active activation threshold according to the active evaluation distance at different moments;
switching the master chip and the slave chip of the wearable watch according to the optimal active activation threshold of the wearable watch at different moments;
the mathematical expression for calculating the active interaction index of each short activation interaction time segment according to the wearable watch interaction activation matrix at each moment is as follows:
;
in the method, in the process of the invention,represents the mean value of the chip frequency at different time positions in the short activation interaction segment, +.>Representing the length of the short active interaction time segment, < >>Indicating at->The>Total number of high levels in the interaction activation matrix at each moment,/->Represents the size of the pixel point of the screen of the wearing watch, < >>Representing the Euclidean distance between two different coordinates,/->Represents +.>Minimum coordinates of high level data points in the interaction matrix at the start time position in the short-active interaction segment, #>Represents +.>Time in the short activation interaction segment>Minimum coordinates of high level data points in interaction activation matrix at location, +.>Represents +.>Maximum coordinates of high level data points in the interaction matrix at the starting moment position in the short-actuation interaction segment,/and>represents +.>Time in the short activation interaction segment>Maximum coordinates of high level data points in interaction activation matrix at location, +.>Represents +.>An application active interaction index of the short active interaction time segments;
the method for acquiring the active interaction index sequence according to the active interaction index of each short active interaction time segment comprises the following steps:
the application active interaction indexes calculated in all different short activation interaction time slices before each different time position are arranged according to the time sequence to obtain a short activation interaction index sequence;
the mathematical expression for calculating the active interval length of the active interaction index sequence at different moments according to each different active interaction index is as follows:
;
in the method, in the process of the invention,representing a normalization function, ++>Time +.>Variance size of applied active interaction index in sequence of active interaction index>Time +.>Average size of application active interaction index in sequence of active interaction index>Time +.>Maximum value of the applied active interaction index in the sequence of active interaction indexes,/->Time +.>Applying a minimum value of the active interaction index in the sequence of active interaction indices, < >>Time +.>Total number of applied active interaction indices in the sequence of active interaction indices, +.>Time +.>Active interval length for active interaction index sequencesDegree.
2. The method for switching between the I2C master and slave chips based on the wearable watch application according to claim 1, wherein the method for acquiring the short active intervals according to the active interval length and calculating the active interaction probabilities of different short active intervals is as follows:
dividing the active interaction index sequence into different sections by using the length of the active section at different moments, marking each section as a short active section, and marking the ratio of the number of data points in each active section to the total number of different data points at the current moment as the active interaction probability of each short active section.
3. The wearable watch application-based I2C master-slave chip switching method of claim 2, wherein the mathematical expression for calculating active evaluation distances at different time positions according to active interaction probabilities is:
;
in the method, in the process of the invention,,/>respectively indicate the time +.>Active interaction index sequence at position +.>Dynamic active weights of left and right data after sub-division, +.>,/>Respectively indicate the time +.>Active interaction index sequence at position +.>The number of short active intervals of left and right data after sub-division, < >>Time +.>Active interaction index sequence at position +.>Probability of a short active interval, +.>Expressed in numbers +.>Logarithmic function of the base>Time->Active interaction index sequence at position +.>Active evaluation distance after sub-division.
4. The wearable watch application-based I2C master-slave chip switching method of claim 3, wherein the method for calculating the dynamic activity weights of the left side data and the right side data is as follows:
and marking the normalized result of the product of the kurtosis of the left sequence data of the active interaction index sequence and the average value of the active interaction index at different moments as the dynamic active weight of the left sequence data, and marking the normalized result of the product of the kurtosis of the right sequence data of the active interaction index sequence and the average value of the active interaction index at different moments as the dynamic active weight of the right sequence data.
5. The wearable watch application-based I2C master-slave chip switching method according to claim 3, wherein the method for calculating the optimal wearable watch activity activation threshold according to the activity evaluation distances at different moments is as follows:
and enabling the initial value of the active activation threshold of the wearable watch to be the average value of the active interaction index sequence, continuously adding the active activation threshold of the wearable watch until the active activation threshold of the wearable watch is equal to the maximum active interaction index, dividing the active interaction index sequence into a left sequence and a right sequence by utilizing different active activation thresholds of the wearable watch, calculating the active evaluation distance, and taking the active activation threshold of the wearable watch corresponding to the active interaction index corresponding to the maximum active evaluation distance as the optimal active activation threshold of the wearable watch.
6. The method for switching between the I2C master and slave chips based on the wearable watch application according to claim 1, wherein the method for switching between the master and slave chips based on the optimal wearable watch activity activation threshold at different moments is as follows:
setting the activation signal quantity of the short activation interaction segment larger than the optimal wearable watch active activation threshold to be digital 1, setting the activation signal quantity of the short activation interaction segment smaller than or equal to the optimal wearable watch active activation threshold to be digital 0, updating the data frame of the I2C data bus once every time the time length of the short activation interaction segment is spaced, and when the activation signal quantity is digitalWhen the chip is used, the high-performance chip is activated as a master chip, and the low-performance chip is used as a slave chip; when the activation signal is digital +.>When the chip is activated, the low-performance chip is used as a master chip, and the high-performance chip is used as a slave chip.
7. An I2C master-slave chip switching system based on a wearable watch application, comprising a memory, a processor and a computer program stored in said memory and running on said processor, characterized in that said processor implements the steps of the method according to any one of claims 1-6 when said computer program is executed.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202410107890.XA CN117648026B (en) | 2024-01-26 | 2024-01-26 | I2C master-slave chip switching method and system based on watch wearing application |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202410107890.XA CN117648026B (en) | 2024-01-26 | 2024-01-26 | I2C master-slave chip switching method and system based on watch wearing application |
Publications (2)
Publication Number | Publication Date |
---|---|
CN117648026A CN117648026A (en) | 2024-03-05 |
CN117648026B true CN117648026B (en) | 2024-04-12 |
Family
ID=90049775
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202410107890.XA Active CN117648026B (en) | 2024-01-26 | 2024-01-26 | I2C master-slave chip switching method and system based on watch wearing application |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN117648026B (en) |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN108053855A (en) * | 2017-11-29 | 2018-05-18 | 北京时代民芯科技有限公司 | A kind of matrix transposition method based on SDRAM chips |
CN108169716A (en) * | 2017-11-29 | 2018-06-15 | 北京时代民芯科技有限公司 | SAR imaging system matrix transposition devices and pattern deinterleaving method based on SDRAM chips |
CN117421539A (en) * | 2023-12-18 | 2024-01-19 | 深圳市魔样科技有限公司 | Brain-computer interface system data optimization processing method |
-
2024
- 2024-01-26 CN CN202410107890.XA patent/CN117648026B/en active Active
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN108053855A (en) * | 2017-11-29 | 2018-05-18 | 北京时代民芯科技有限公司 | A kind of matrix transposition method based on SDRAM chips |
CN108169716A (en) * | 2017-11-29 | 2018-06-15 | 北京时代民芯科技有限公司 | SAR imaging system matrix transposition devices and pattern deinterleaving method based on SDRAM chips |
CN117421539A (en) * | 2023-12-18 | 2024-01-19 | 深圳市魔样科技有限公司 | Brain-computer interface system data optimization processing method |
Also Published As
Publication number | Publication date |
---|---|
CN117648026A (en) | 2024-03-05 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US10275200B2 (en) | Activity information processing method and electronic device supporting the same | |
US10623932B2 (en) | Detecting trigger conditions to dynamically update a model based on sensor data in a fog computing environment | |
CN105813558B (en) | System and method for determining sleep stages based on sleep cycle | |
EP2889790A1 (en) | Vital information measuring device, processing system, vital information processing method, and program | |
US8041974B2 (en) | Power management method for input device | |
US20130231575A1 (en) | Monitoring accumulated activity | |
KR20170019040A (en) | Organism condition information providing method and electronic device supporting the same | |
EP3748470A1 (en) | Resource scheduling method and terminal device | |
US20150254875A1 (en) | Information processing method and electronic device | |
KR20200104248A (en) | Methods and apparatus to improve performance data collection of a high performance computing application | |
US20170080288A1 (en) | Activity information providing method and electronic device supporting the same | |
CN105708440A (en) | Resting heart rate measuring method and terminal | |
CN115755564A (en) | Alarm clock control method based on sleep stage prediction, radar and storage medium | |
CN114732391A (en) | Microwave radar-based heart rate monitoring method, device and system in sleep state | |
US20180338698A1 (en) | Measurement apparatus and recording medium recording measurement program | |
CN111387936A (en) | Sleep stage identification method, device and equipment | |
CN117648026B (en) | I2C master-slave chip switching method and system based on watch wearing application | |
KR102344875B1 (en) | Method and apparatus for determining a frequency band and illuminance according to the sleeping state, and providing music according to the determined frequency band and lighting according to the illuminance | |
CN108937860B (en) | Motion state monitoring method, system and equipment and storage medium | |
CN106445698B (en) | Method and device for acquiring step counting data | |
CN112190241A (en) | Heart beat respiration detection method and device | |
CN105662394B (en) | A kind of method and apparatus prompting the user with information | |
CN111227817A (en) | Heart rate monitoring method and device and storage medium | |
CN113995390B (en) | Working mode control method of wearable device, wearable device and medium | |
CN110236542B (en) | Human body moisture state prompting method and device and mouse |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |