WO2022165816A1 - 电容基线更新方法、芯片以及电容检测装置 - Google Patents

电容基线更新方法、芯片以及电容检测装置 Download PDF

Info

Publication number
WO2022165816A1
WO2022165816A1 PCT/CN2021/075882 CN2021075882W WO2022165816A1 WO 2022165816 A1 WO2022165816 A1 WO 2022165816A1 CN 2021075882 W CN2021075882 W CN 2021075882W WO 2022165816 A1 WO2022165816 A1 WO 2022165816A1
Authority
WO
WIPO (PCT)
Prior art keywords
capacitance
capacitance data
frame
raw
feature
Prior art date
Application number
PCT/CN2021/075882
Other languages
English (en)
French (fr)
Inventor
艾娟
Original Assignee
深圳市汇顶科技股份有限公司
Priority date (The priority date 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 date listed.)
Filing date
Publication date
Application filed by 深圳市汇顶科技股份有限公司 filed Critical 深圳市汇顶科技股份有限公司
Priority to EP21867867.0A priority Critical patent/EP4067912A4/en
Priority to PCT/CN2021/075882 priority patent/WO2022165816A1/zh
Priority to US17/695,351 priority patent/US20220260393A1/en
Publication of WO2022165816A1 publication Critical patent/WO2022165816A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G01MEASURING; TESTING
    • G01DMEASURING NOT SPECIALLY ADAPTED FOR A SPECIFIC VARIABLE; ARRANGEMENTS FOR MEASURING TWO OR MORE VARIABLES NOT COVERED IN A SINGLE OTHER SUBCLASS; TARIFF METERING APPARATUS; MEASURING OR TESTING NOT OTHERWISE PROVIDED FOR
    • G01D5/00Mechanical means for transferring the output of a sensing member; Means for converting the output of a sensing member to another variable where the form or nature of the sensing member does not constrain the means for converting; Transducers not specially adapted for a specific variable
    • G01D5/12Mechanical means for transferring the output of a sensing member; Means for converting the output of a sensing member to another variable where the form or nature of the sensing member does not constrain the means for converting; Transducers not specially adapted for a specific variable using electric or magnetic means
    • G01D5/14Mechanical means for transferring the output of a sensing member; Means for converting the output of a sensing member to another variable where the form or nature of the sensing member does not constrain the means for converting; Transducers not specially adapted for a specific variable using electric or magnetic means influencing the magnitude of a current or voltage
    • G01D5/24Mechanical means for transferring the output of a sensing member; Means for converting the output of a sensing member to another variable where the form or nature of the sensing member does not constrain the means for converting; Transducers not specially adapted for a specific variable using electric or magnetic means influencing the magnitude of a current or voltage by varying capacitance
    • G01D5/2403Mechanical means for transferring the output of a sensing member; Means for converting the output of a sensing member to another variable where the form or nature of the sensing member does not constrain the means for converting; Transducers not specially adapted for a specific variable using electric or magnetic means influencing the magnitude of a current or voltage by varying capacitance by moving plates, not forming part of the capacitor itself, e.g. shields
    • HELECTRICITY
    • H03ELECTRONIC CIRCUITRY
    • H03KPULSE TECHNIQUE
    • H03K17/00Electronic switching or gating, i.e. not by contact-making and –breaking
    • H03K17/94Electronic switching or gating, i.e. not by contact-making and –breaking characterised by the way in which the control signals are generated
    • H03K17/945Proximity switches
    • H03K17/955Proximity switches using a capacitive detector
    • HELECTRICITY
    • H03ELECTRONIC CIRCUITRY
    • H03KPULSE TECHNIQUE
    • H03K17/00Electronic switching or gating, i.e. not by contact-making and –breaking
    • H03K17/94Electronic switching or gating, i.e. not by contact-making and –breaking characterised by the way in which the control signals are generated
    • H03K17/96Touch switches
    • H03K17/962Capacitive touch switches
    • HELECTRICITY
    • H03ELECTRONIC CIRCUITRY
    • H03KPULSE TECHNIQUE
    • H03K2217/00Indexing scheme related to electronic switching or gating, i.e. not by contact-making or -breaking covered by H03K17/00
    • H03K2217/94Indexing scheme related to electronic switching or gating, i.e. not by contact-making or -breaking covered by H03K17/00 characterised by the way in which the control signal is generated
    • H03K2217/9401Calibration techniques
    • H03K2217/94031Calibration involving digital processing

Definitions

  • the embodiments of the present application relate to the technical field of capacitance detection, and in particular, to a capacitance baseline update method, a chip, and a capacitance detection device.
  • FIG. 1 is a schematic structural diagram of a typical capacitance detection device.
  • the capacitance detection device includes: a sensor (sensor) 101 , an amplifier (amplifier, AMP) 102 and an analog-to-digital converter (Analog Digital Converter, ADC) 103 .
  • the capacitance value of the capacitance Cx of the sensor 101 to the system ground GND will change, the sensor 101 can output the detected capacitance signal to the amplifier 102, and the amplified capacitance signal is input to the analog-to-digital conversion
  • the controller 103 can obtain the raw capacitance signal RawData.
  • the capacitance change signal Diff can be obtained; by comparing the signal value of the capacitance change signal Diff with a preset threshold, it can identify whether there is a human body or other conductors approaching or away from the capacitance detection device.
  • the baseline signal Ref is the signal output by the capacitance detection device without external input from the human body or other conductors.
  • Fig. 2 shows a schematic diagram of the fluctuation of the original capacitance signal RawData output by the above-mentioned typical capacitance detection device; it can be seen that at time t1 , the signal value of the original capacitance signal RawData is equal to the signal value of the baseline signal Ref, indicating that there is no human body or Other conductors are approaching the capacitance detection device; at time t 2 , the signal value of the original capacitance signal RawData reaches close to the threshold ON th , indicating that a human body or other conductors have approached the capacitance detection device; at time t 3 , the raw capacitance signal RawData The signal value falls away from the threshold OFF th , indicating that the human body or other conductors are moving away from the capacitive detection device.
  • the signal value of the baseline signal Ref is not updated in real time, it is easy to cause the signal value of the capacitance change signal Diff to be different from the actual value of the actual operation.
  • the event includes: the human body or other conductors approach the capacitance detection device, and the human body or other conductors are far away from the capacitance detection device.
  • a commonly used baseline update method is the first-order hysteresis filtering method, which can be described as:
  • Ref(n) Coef x *Ref(n-1)+(1-Coef x )*RawData(n)
  • Ref(n) is the baseline value of the current nth frame of the baseline signal Ref
  • Ref(n-1) is the baseline value of the (n-1)th frame of the baseline signal Ref
  • RawData(n) is the current raw capacitance signal RawData.
  • the raw capacitance data of n frames, Coef x is the filter coefficient.
  • the size of the filter coefficient Coef x can affect the smoothness and delay response of Ref(n), and by adjusting the size of the filter coefficient Coef x , the higher the smoothness, the greater the delay response; the smaller the delay response, the greater the smoothness lower.
  • the above-mentioned baseline updating method updates the partial data of the original capacitance signal RawData into the baseline signal Ref by weighting the current sampling value RawData(n) and the last output value Ref(n-1).
  • this method will partially update the effective data and noise in the original capacitance signal RawData to the baseline signal Ref, resulting in noise jitter in the calculated capacitance change signal Diff. If you want to reduce the jitter of the baseline signal Ref, then It will cause a larger delayed response, so the above baseline update method is difficult to adapt to the application scenarios that are sensitive to noise interference and delayed response.
  • Embodiments of the present application provide a capacitance baseline update method, a chip, and a capacitance detection device, which are used to effectively update capacitance baseline values in real time and reduce the influence of noise jitter and delayed response on capacitance detection performance.
  • an embodiment of the present application provides a capacitance baseline update method, which is applied to a capacitance detection device, and the method includes:
  • the nth frame of raw capacitance data RawData(n) and the (n-M)th frame of raw capacitance data RawData(n-M) output by the capacitance detection device determine the feature value Feature(n) corresponding to the nth frame of raw capacitance data;
  • the feature value Feature(n) corresponding to the raw capacitance data of the nth frame is used to indicate different stages in the process of the conductor approaching or moving away from the capacitance detection device;
  • the raw capacitance data of the nth frame is RawData(n) or the raw capacitance data of the (n-1)th frame
  • RawData (n-1) is determined as the baseline value Ref(n) corresponding to the raw capacitance data of the nth frame; for determining whether the conductor has approached the capacitance detection device; the first threshold Thr 1 is used to determine whether there is an external input of the conductor on the capacitance detection device;
  • n is a positive integer greater than 2
  • M is a positive integer greater than or equal to 1
  • M ⁇ n is a positive integer greater than or equal to 2
  • the characteristic value Feature(n) corresponding to the raw capacitance data of the nth frame and set the size of the characteristic value Feature(n). Comparing with the magnitude of the first threshold, it can be determined whether there is an external input from a human body or other conductors on the capacitance detection device.
  • the characteristic value Feature(n) corresponding to the raw capacitance data of the nth frame is smaller than the first threshold Thr 1 , and the capacitance change Diff(n) is smaller than the close threshold Thr on , it means that there is no human body or other conductors on the capacitance detection device.
  • Input that is, the capacitance detection device is in the empty state
  • set the baseline value Ref(n) corresponding to the raw capacitance data of the nth frame to be equal to the raw capacitance data of the nth frame RawData(n) or the (n-1) ) frame raw capacitance data RawData(n-1), which can offset part of the noise in the capacitance change signal Diff, and enable the capacitance change signal Diff to track the fluctuation changes of the original capacitance signal RawData in real time, thereby reducing noise jitter and delay response to capacitance detection performance impact.
  • the feature value Feature(n) corresponding to the raw capacitance data of the nth frame is greater than or equal to the first threshold Thr 1 , and the capacitance variation Diff(n) is less than the proximity threshold Thr on , according to the baseline value Ref(n-1) corresponding to the original capacitance data of the (n-1)th frame, determine the baseline value Ref(n) corresponding to the raw capacitance data of the nth frame.
  • the second threshold Thr 2 is smaller than the first threshold Thr 1 .
  • the characteristic value Feature(n) corresponding to the raw capacitance data of the nth frame is smaller than the second threshold Thr 2 or larger than the first threshold Thr 1 , and the capacitance change Diff(n) is larger than or equal to the approaching threshold Thr on , according to the baseline value Ref(n-1) corresponding to the raw capacitance data of the (n-1)th frame, determine the baseline value Ref(n) corresponding to the raw capacitance data of the nth frame ).
  • the feature corresponding to the nth frame of raw capacitance data is determined according to the nth frame of raw capacitance data RawData(n) and the (n-M)th frame of raw capacitance data RawData(n-M) output by the capacitance detection device
  • the value Feature(n) further including:
  • the difference between the raw capacitance data RawData(n) of the nth frame and the raw capacitance data RawData(n-M) of the (n-M)th frame is determined as the characteristic value Feature( n).
  • the The nth frame of raw capacitance data RawData(n) or the (n-1)th frame of raw capacitance data RawData(n-1) is determined as the baseline value Ref(n) corresponding to the nth frame of raw capacitance data, and further include:
  • the characteristic value Feature(n) corresponding to the raw capacitance data of the nth frame is greater than or equal to the third threshold Thr 3 , and the capacitance variation Diff(n) is less than the proximity threshold Thr on , the The sum of the baseline value Ref(n-1) corresponding to the original capacitance data of the (n-1)th frame and the second correction value Corr 2 is determined as the baseline value Ref(n) corresponding to the raw capacitance data of the nth frame;
  • the third threshold Thr 3 is used to determine the degree to which the conductor is approaching the capacitance detection device;
  • the first correction value Corr 1 and the second correction value Corr 2 are respectively used to represent the offset of the baseline value caused by environmental factors in the corresponding stage;
  • the third threshold Thr 3 is greater than the first threshold Thr 1 .
  • the capacitance change amount when Diff(n) is greater than or equal to the proximity threshold Thr on , according to the feature value Feature(n) corresponding to the raw capacitance data of the nth frame and the feature value Feature corresponding to the raw capacitance data of the (n-1)th frame (n-1), the baseline value Ref(n-1) corresponding to the raw capacitance data of the (n-1)th frame, and the baseline value corresponding to the (n-2)th frame of raw capacitance data output by the capacitance detection device Ref(n-2), determining the baseline value Ref(n) corresponding to the raw capacitance data of the nth frame, further comprising:
  • the value of the second variation Diff_Ref(n-1) is not zero.
  • the capacitance change Diff(n ) is greater than or equal to the proximity threshold Thr on
  • determine the baseline value Ref corresponding to the raw capacitance data of the nth frame (n) further including:
  • the characteristic value Feature(n) corresponding to the raw capacitance data of the nth frame is greater than the first threshold Thr 1 , and the capacitance variation Diff(n) is greater than or equal to the proximity threshold Thr on , the The sum of the baseline value Ref(n-1) corresponding to the raw capacitance data of the (n-1)th frame and the second correction value Corr 2 is determined as the baseline value Ref(n) corresponding to the raw capacitance data of the nth frame ;
  • the feature value Feature(n) corresponding to the raw capacitance data of the nth frame is smaller than the second threshold Thr 2 and the capacitance change Diff(n) is greater than or equal to the proximity threshold Thr on , the The sum of the baseline value Ref(n-1) corresponding to the (n-1)th frame original capacitance data and the third correction value Corr 3 is determined as the baseline value Ref(n) corresponding to the nth frame original capacitance data;
  • the third correction value Corr 3 is used to represent the deviation of the baseline value caused by environmental factors in the corresponding stage.
  • an embodiment of the present application provides a chip, including: a processor and a memory, the memory being coupled to the processor;
  • the memory for storing computer program instructions
  • the processor is configured to invoke the computer program instructions stored in the memory, so that the chip executes the capacitance baseline update method according to the first aspect or any optional manner of the first aspect.
  • an embodiment of the present application provides a capacitance detection device, including the chip described in the second aspect.
  • embodiments of the present application provide a computer-readable storage medium for storing a computer program, the computer program causing a computer to perform the capacitance baseline update according to the first aspect or any optional manner of the first aspect method.
  • the chip described in the second aspect, the capacitance detection device described in the third aspect, and the computer-readable storage medium described in the fourth aspect are all used to execute the corresponding method provided above, Therefore, for the beneficial effects that can be achieved, reference may be made to the beneficial effects in the corresponding methods provided above, which will not be repeated here.
  • FIG. 1 is a schematic structural diagram of a typical capacitance detection device
  • FIG. 2 is a schematic diagram of fluctuation of the raw capacitance signal RawData output by the capacitance detection device shown in FIG. 1;
  • FIG. 3 is a schematic block diagram of a method for updating a capacitance baseline provided by an embodiment of the present application
  • FIG. 4 is a schematic diagram of fluctuations of the original capacitance signal and the characteristic signal in the process of approaching and moving away from a conductor according to an embodiment of the present application;
  • FIG. 5 is a schematic update diagram of a baseline signal in the process of approaching and moving away from a conductor according to an embodiment of the present application
  • FIG. 6 is a schematic diagram of the fluctuation of a capacitance change signal in the process of approaching and moving away from a conductor according to an embodiment of the present application;
  • FIG. 7 is a schematic structural diagram of a chip according to an embodiment of the present application.
  • FIG. 3 it is a schematic block diagram of a method for updating a capacitance baseline provided by an embodiment of the present application.
  • the method can be applied to a capacitance detection device, and specifically includes the following steps:
  • Step S101 Determine the characteristic value Feature(n) corresponding to the nth frame of raw capacitance data according to the nth frame of raw capacitance data RawData(n) and the (n-M)th frame of raw capacitance data RawData(n-M) output by the capacitance detection device.
  • the feature value Feature(n) corresponding to the raw capacitance data of the nth frame may indicate different stages in the process of the conductor (human body or other conductors) approaching or moving away from the capacitance detection device.
  • Step S102 Calculate the difference between the raw capacitance data RawData(n) of the nth frame and the baseline value Ref(n-1) corresponding to the raw capacitance data of the (n-1)th frame output by the capacitance detection device to obtain the capacitance change amount Diff(n).
  • the capacitance change Diff(n) can be used to predict the capacitance change corresponding to the nth frame of raw capacitance data, so that The moving state of the conductor is determined; specifically, the moving state may include: approaching the capacitance detection device (approaching state) and not approaching the capacitance detecting device (not approaching state).
  • the capacitance change corresponding to the raw capacitance data of the nth frame is the difference between the raw capacitance data of the nth frame RawData(n) and its corresponding baseline value Ref(n), that is, RawData(n)-Ref(n ), which can be used to represent the current amount of capacitance change caused by the human body or other conductors.
  • Step S103a When the characteristic value Feature(n) corresponding to the raw capacitance data of the nth frame is less than the first threshold Thr 1 , and the capacitance change Diff(n) is less than the close threshold Thr on , the raw capacitance data of the nth frame RawData(n ) or the (n-1)th frame of raw capacitance data RawData(n-1), which is determined as the baseline value Ref(n) corresponding to the nth frame of raw capacitance data.
  • the proximity threshold Thr on can be used to determine whether the conductor has approached the capacitance detection device; the first threshold Thr 1 can be used to determine whether there is an external input of the conductor on the capacitance detection device.
  • the capacitance change Diff(n) By comparing the capacitance change Diff(n) with the approaching threshold Thr on , it can be determined whether the conductor has approached the capacitance detection device, that is, the moving state of the conductor; specifically, if the capacitance change Diff(n) reaches approaching the threshold Thr on , that is, greater than or equal to the approaching threshold Thr on , it can be determined that the conductor is in the approaching state; if the capacitance change Diff(n) does not reach the approaching threshold Thr on , that is, less than the approaching threshold Thr on , it can be determined that the conductor is in the approaching state; The conductor is not approached.
  • the size of the proximity threshold Thr on can be generated by a machine learning method based on training data.
  • the training data can include, but is not limited to: the capacitance variation Diff(n) corresponding to the contact of different types of conductors with the capacitance detection device to different degrees. , and the corresponding capacitance change Diff(n) when there are different distances between different types of conductors and the capacitance detection device; in addition, the size close to the threshold Thr on can also be adjusted according to the actual application of subsequent users, so as to be more Accurately distinguish whether a human body or other conductors have approached the capacitance detection device, which is better suited to different application scenarios.
  • Step S103b when the characteristic value Feature(n) corresponding to the original capacitance data of the nth frame is greater than or equal to the first threshold Thr 1 , and the capacitance change Diff(n) is less than the close threshold Thr on , according to the (n-1)th frame
  • the baseline value Ref(n-1) corresponding to the original capacitance data is determined, and the baseline value Ref(n) corresponding to the original capacitance data of the nth frame is determined.
  • Step S103c when the characteristic value Feature(n) corresponding to the raw capacitance data of the nth frame is greater than or equal to the second threshold Thr 2 and less than or equal to the first threshold Thr 1 , and the capacitance change Diff(n) is greater than or equal to the close threshold
  • Thr on according to the characteristic value Feature(n) corresponding to the original capacitance data of the nth frame, the characteristic value Feature(n-1) corresponding to the original capacitance data of the (n-1)th frame, and the original capacitance of the (n-1)th frame
  • the baseline value Ref(n-1) corresponding to the data and the baseline value Ref(n-2) corresponding to the (n-2) frame original capacitance data output by the capacitance detection device determine the baseline value Ref corresponding to the nth frame original capacitance data (n).
  • the second threshold Thr 2 is smaller than the first threshold Thr 1 , and the second threshold Thr 2 can be used to determine whether the conductor gradually comes out of contact with the capacitance detection device, and specifically, can be used to further determine that the conductor is in a close state The trend of movement is to maintain steady contact with the capacitive detection device, or to start moving away from the capacitive detection device.
  • Step S103d when the characteristic value Feature(n) corresponding to the raw capacitance data of the nth frame is less than the second threshold Thr 2 or greater than the first threshold Thr 1 , and the capacitance change Diff(n) is greater than or equal to the close threshold Thr on , according to The baseline value Ref(n-1) corresponding to the raw capacitance data of the (n-1)th frame is determined, and the baseline value Ref(n) corresponding to the raw capacitance data of the nth frame is determined.
  • n is a positive integer greater than 2
  • M is a positive integer greater than or equal to 1
  • M ⁇ n is a positive integer greater than or equal to 1
  • the value of Ref(1) or Ref(2) can be set equal to the signal value of the original capacitance signal output by the capacitance detection device without external input from the human body or other conductors.
  • the setting of the first threshold Thr 1 may also be generated by a machine learning method based on training data, and the training data may include but not limited to: the capacitance change amount when there is no external input from the human body or other conductors on the capacitance detection device , the capacitance change amount when a human body or other conductors begin to approach the capacitance detection device, and the capacitance change amount when the human body or other conductors begin to move away from the capacitance detection device.
  • the second threshold Thr 2 may be set to a negative value, and the absolute value of the second threshold Thr 2 may be 2-3 times of the first threshold Thr 1 .
  • the process of the human body or other conductors approaching or moving away from the capacitance detection device can be divided into different stages, according to the different movement states of the conductors in each stage (approaching/not approaching) and moving trends (approaching, keeping contact, leaving), Setting the corresponding capacitance baseline update mode can realize real-time and effective update of the baseline value.
  • Feature(n) ⁇ Thr 1 and Diff(n) ⁇ Thr on it can indicate that there is no additional input caused by a conductor on the capacitance detection device, including: no conductor begins to approach the capacitance detection device, and the conductor has Keep away from the capacitance detection device; the raw capacitance data RawData(n) in this stage only indicates the capacitance change amount caused by the environmental noise, so this stage can be called the noise stage.
  • Pre-approach stage When Feature(n) ⁇ Thr 1 and Diff(n) ⁇ Thr on , it can indicate that a conductor is slowly/quickly approaching the capacitance detection device, but the conductor is still not approaching, so this stage can be called Pre-approach stage.
  • Thr 2 When Thr 2 ⁇ Feature(n) ⁇ Thr 1 and Diff(n) ⁇ Thr on , it can indicate that a conductor maintains stable contact with the capacitance detection device and has reached the closest state; when Feature(n)>Thr 1 or Feature(n) ⁇ Thr 2 , and Diff(n) ⁇ Thr on , it means that the conductor is in a state of approaching, and is further approaching the capacitance detection device, or gradually out of contact with the capacitance detection device, that is, Beginning to move away from the capacitive detection device, these two phases may be referred to as the approach phase.
  • the above-mentioned feature values corresponding to the nth frame of raw capacitance data are determined according to the nth frame of raw capacitance data RawData(n) and the (n-M)th frame of raw capacitance data RawData(n-M) output by the capacitance detection device Feature(n), further comprising: determining the difference between the nth frame of raw capacitance data RawData(n) and the (n-M)th frame of raw capacitance data RawData(n-M) as the characteristic value corresponding to the nth frame of raw capacitance data Feature(n).
  • the value of M can be set according to the actual application scenario and the application goal to be achieved, and the minimum value can be 1, and the smaller the value of M, the better the real-time performance of the capacitor baseline update, but it will also lead to the amount of calculation. bigger.
  • the raw capacitance data of the nth frame is The capacitance data RawData(n) or the (n-1)th frame raw capacitance data RawData(n-1) is determined as the baseline value Ref(n) corresponding to the nth frame raw capacitance data, and further includes: The minimum value among the data RawData(n) and the (n-1)th frame raw capacitance data RawData(n-1) is determined as the baseline value Ref(n) corresponding to the nth frame raw capacitance data.
  • the noise in the capacitance change signal Diff can only be changed in one direction in this stage, thereby effectively reducing the noise of the reverse change in the capacitance change signal Diff.
  • First-order hysteresis filtering method the noise variance in the capacitance change signal Diff can be reduced by half in this stage, and the effective signal components in the capacitance change signal Diff will not be lost.
  • the baseline signal Ref can track the original capacitance in real time. The fluctuation of the signal RawData reduces the impact of noise jitter and delayed response on capacitance detection performance.
  • the characteristic value (n) corresponding to the raw capacitance data of the nth frame is greater than or equal to the first threshold Thr 1 , and the capacitance change Diff(n) is less than the close threshold Thr on , according to the (nth) -1)
  • the baseline value Ref(n-1) corresponding to the original capacitance data of the frame determine the baseline value Ref(n) corresponding to the raw capacitance data of the nth frame, and further include:
  • the ( n-1) The sum of the baseline value Ref(n-1) corresponding to the original capacitance data of the frame and the first correction value Corr 1 is determined as the baseline value Ref(n) corresponding to the original capacitance data of the nth frame;
  • the baseline value Ref corresponding to the (n-1)th frame original capacitance data The sum of (n-1) and the second correction value Corr 2 is determined as the baseline value Ref(n) corresponding to the raw capacitance data of the nth frame.
  • the third threshold Thr 3 can be used to determine the degree to which the conductor is approaching the capacitance detection device, and the third threshold Thr 3 is greater than the first threshold Thr 1 ; the first correction value Corr 1 and the second correction value Corr 2 can be respectively used It is used to characterize the offset of the baseline value caused by environmental factors in the corresponding stage.
  • the baseline drift noise caused by environmental factors such as temperature can be reduced, the signal-to-noise ratio of the capacitance change signal Diff can be improved, and the baseline signal Ref can be updated in real time. This reduces the impact of noise jitter and delayed response on capacitive sensing performance.
  • the second pre-proximity sub-stage is more closely spaced than the first pre-proximity sub-stage.
  • the size of the first correction value Corr 1 can be set close to about 20% of the threshold value Thr on
  • the second correction value Corr 2 can be set to be equal to the first correction value Corr 1 , or slightly smaller than the first correction value Corr 1 .
  • the third threshold Thr 3 may be set to be the opposite of the second threshold Thr 2 , that is, 2 to 3 times the first threshold Thr 1 .
  • the characteristic value Feature(n) corresponding to the raw capacitance data of the nth frame is greater than or equal to the second threshold Thr 2 and less than or equal to the first threshold Thr 1 , and the capacitance change Diff(n) When it is greater than or equal to close to the threshold Thr on , according to the characteristic value Feature(n) corresponding to the raw capacitance data of the nth frame, the characteristic value Feature(n-1) corresponding to the (n-1)th frame original capacitance data, and the (n- 1)
  • the baseline value Ref(n-1) corresponding to the original capacitance data of the frame and the baseline value Ref(n-2) corresponding to the original capacitance data of the (n-2)th frame output by the capacitance detection device determine the original capacitance data of the nth frame
  • the corresponding baseline value Ref(n) further includes:
  • the second variation Diff_Ref(n-1) ⁇ 0. If Ref(n-1) is equal to Ref(n-2) in this stage, the second variation Diff_Ref(n-1) can be set to a non-zero constant value, for example, it can be set to be the same as the previous value The values of the non-zero second variation Diff_Ref(n-1) in a certain frame are equal.
  • the conductors are stably kept in contact with the capacitance detection device and are in the closest state. Because the conductor generally shakes to a certain degree or has a temperature difference with the sensor in the capacitance detection device, it is easy to cause abnormal jitter changes in the original capacitance signal RawData, which in turn causes obvious noise components in the capacitance change signal Diff, which affects capacitance detection.
  • the accuracy of the results, and the real-time update of the capacitance baseline value in the above-mentioned method can extract the jitter variation in the original capacitance signal RawData during the process of the conductor continuously and stably contacting the capacitance detection device, and superimpose it to the baseline signal Ref. In this way, the low-frequency noise in the capacitance change signal Diff is reduced, and the probability of event misidentification or missed identification is effectively reduced.
  • the characteristic value Feature(n) corresponding to the raw capacitance data of the nth frame is smaller than the second threshold Thr 2 or larger than the first threshold Thr 1 , and the capacitance change Diff(n) is larger than or equal to the close threshold
  • Thr on according to the baseline value Ref(n-1) corresponding to the raw capacitance data of the (n-1) frame, determine the baseline value Ref(n) corresponding to the raw capacitance data of the nth frame, further including:
  • the (n-1)th frame raw capacitance data is The sum of the corresponding baseline value Ref(n-1) and the second correction value Corr 2 is determined as the baseline value Ref(n) corresponding to the original capacitance data of the nth frame; when the characteristic value Feature( When n) is less than the second threshold Thr 2 and the capacitance change Diff(n) is greater than or equal to the close threshold Thr on , compare the baseline value Ref(n-1) corresponding to the original capacitance data of the (n-1)th frame with the third The sum of the correction values Corr 3 is determined as the baseline value Ref(n) corresponding to the raw capacitance data of the nth frame.
  • the third correction value Corr 3 can represent the offset of the baseline value caused by environmental factors in the corresponding stage; specifically, the size of the third correction value Corr 3 can be set according to the actual application scenario, and can be consistent with the first The correction value Corr 1 and the second correction value Corr 2 are equal to or slightly smaller than the first correction value Corr 1 .
  • this stage can be further divided into two sub-stages.
  • the baseline drift noise caused by environmental factors such as temperature can be reduced, the signal-to-noise ratio of the capacitance change signal Diff can be improved, and the baseline signal Ref can quickly track the original capacitance signal RawData in real time. changes, reducing the impact of noise jitter and delayed response on capacitive sensing performance.
  • FIG. 4 a schematic diagram of fluctuations of the original capacitance signal and the characteristic signal during the process of approaching and moving away from a conductor according to an embodiment of the present application. It can be seen that by comparing Feature(n) with the size of the first threshold Thr 1 , the second threshold Thr 2 , and the third threshold Thr 3 , the process of the conductor approaching and moving away from the capacitance detection device can be divided into different stages, including noise Stages (T 1 and T 4 ), pre-approaching stage (T 2 ) and approaching stage (T 3 ), wherein, during the period T 1 of the noise stage, there is no additional input of conductors on the capacitance detection device, and the T 1 of the noise stage Within 4 time periods, the conductor has moved away from the capacitance detection device; and the pre-approaching stage can be further divided into two sub-stages according to different proximity degrees, and the approaching stage can be further divided into three sub-stages according to different moving trends.
  • the feature signal the feature signal
  • FIG. 5 a schematic diagram of updating the baseline signal in the process of approaching and moving away from the conductor provided by an embodiment of the application; wherein, in each stage of the conductor approaching and moving away from the capacitance detection device, the methods provided by the above embodiments are respectively adopted.
  • Capacitance baseline update method Capacitance baseline update method.
  • the baseline signal Ref can be updated in real time to track the change of the original capacitance signal RawData; in the T2 period (pre - closer stage), a human body or other conductor is approaching the capacitance detection device, but it is still not approaching, the baseline signal Ref can track the rise and change of the original capacitance signal RawData in time and update it in real time; in the T3 period (approaching stage), when there is a When the human body or other conductors are in close proximity and maintain stable contact with the capacitance detection device, the baseline signal Ref can also track the jitter change of the original capacitance signal RawData in real time, effectively reducing the low-frequency noise component in the capacitance change signal Diff.
  • the baseline The signal Ref can be updated in real time according to the change of the original capacitance signal RawData ; in the T4 period (noise stage), the human body or other conductors have been far away from the capacitance detection device, the baseline signal Ref can be quickly updated and quickly restored to the normal baseline level, thus Reduce the effect of delayed response on the sensitivity and accuracy of subsequent capacitance detection.
  • FIG. 6 a schematic diagram of the fluctuation of the capacitance change signal in the process of the conductor approaching and moving away provided by the embodiment of the application, wherein, in each stage of the conductor approaching and moving away from the capacitance detection device rapidly/slowly, the above-mentioned methods are respectively adopted.
  • the capacitor baseline update method provided by the embodiment. It can be seen that in the process of the human body or other conductors approaching and moving away from the capacitance detection device quickly and slowly, the capacitance change signal can quickly reach the target level, and it can accurately reflect whether the human body or other conductors are approaching the capacitance detection device in real time. The sensitivity and accuracy of capacitance detection are improved.
  • the capacitance baseline update method provided by the embodiments of the present application can be well adapted to this application scenario.
  • the baseline value is updated in real time and effectively to reduce the impact of noise jitter and delayed response on capacitance detection performance, improve the accuracy of capacitance detection results, and reduce event misidentification or leakage. probability of recognition.
  • the capacitance baseline update method provided in this embodiment of the present application can be adapted to various scenarios that require accurate capacitance detection, including wearing detection, touch detection, and SAR (Specific Absorption Rate) applications, for example, in Bluetooth headsets (such as TWS In the in-ear detection application of the headset), it can accurately identify whether the user has worn the Bluetooth headset.
  • wearing detection, touch detection, and SAR Specific Absorption Rate
  • the chip 20 includes a memory 201 and a processor 202; wherein, the memory 201 can store computer program instructions, and the processor 202 can call the computer program instructions stored in the memory 201, so that the chip 20 can execute the first aspect or any one of the first aspects.
  • a capacitance baseline update method provided by a possible implementation manner.
  • the memory 201 may be a volatile memory (Volatile Memory, VM), such as a random access memory (Random Access Memory, RAM), etc., or a non-volatile memory (Non-Volatile Memory, NVM), such as a hard disk ( Hard Disk Drive, HDD), Solid State Drive (Solid State Drive, SSD), etc., or a circuit or any other device that can realize a storage function.
  • VM volatile memory
  • RAM random access memory
  • NVM non-volatile memory
  • NVM non-Volatile Memory
  • the memory 201 is any other medium that can store or carry desired program code in the form of instructions or data structures and that can be accessed by a computer, and is not limited thereto.
  • the processor 202 may be a general-purpose processor (eg, a microprocessor), a digital signal processor, an application-specific integrated circuit, a transistor logic device, a field programmable gate array, or other programmable logic device, and is not limited thereto, and may implement or execute the present invention.
  • a general-purpose processor eg, a microprocessor
  • a digital signal processor e.g., a digital signal processor
  • an application-specific integrated circuit e.g., a digital signal processor
  • a transistor logic device e.g., a field programmable gate array, or other programmable logic device
  • the methods, steps, and logical block diagrams provided in the embodiments of the application.
  • the methods and steps provided in conjunction with the embodiments of the present application may be directly embodied as being executed by a hardware processor, or executed by a combination of hardware and software modules in the processor.
  • the chip 20 may also be referred to as a system-on-chip, a system-on-chip, a system-on-a-chip, or a system-on-chip, or the like.
  • an embodiment of the present application provides a capacitance detection device, including the chip provided in the second aspect above.
  • the capacitance detection apparatus may perform the capacitance baseline update method provided by the first aspect or any one of the possible implementation manners of the first aspect.
  • an embodiment of the present application provides a computer-readable storage medium, where the computer-readable storage medium can store a computer program, and the computer program can cause a computer to execute the first aspect or any one of the possible first aspects.
  • the capacitance baseline update method provided by the embodiment provided by the embodiment.
  • the computer-readable storage medium can be any available media that can be accessed by a computer, or a data storage device such as a server, a data center, or the like integrated with one or more available media.
  • the usable medium may be a magnetic medium (such as a hard disk, a floppy disk, a magnetic tape, etc.), a semiconductor medium (such as a solid-state disk, etc.), or an optical medium (such as a Digital Video Disk (DVD), etc.), and is not limited thereto.
  • the methods provided by the embodiments of the present application may be implemented in whole or in part by software, hardware, firmware, or any combination thereof.
  • software When implemented in software, it may be implemented in whole or in part in the form of a computer program product comprising one or more computer instructions.
  • the computer instructions When the computer instructions are loaded and executed on a computer, all or part of the processes or functions described in the embodiments of the present application may be generated, and the computer may be a general-purpose computer, a special-purpose computer, a computer network, a network device, user equipment, or other available Programming means, the computer instructions may be stored in or transmitted from one computer-readable storage medium to another computer-readable storage medium, for example, the computer instructions may be transferred from a computer, server, web site or data
  • the center transmits data to another computer, server, website or data center by wired (such as light, coaxial cable, Digital Subscriber Line, DSL, etc.) or wireless (such as microwave, millimeter wave, infrared, etc.) transmission.

Landscapes

  • Engineering & Computer Science (AREA)
  • Power Engineering (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Electronic Switches (AREA)
  • Measurement Of Length, Angles, Or The Like Using Electric Or Magnetic Means (AREA)

Abstract

一种电容基线更新方法、芯片以及电容检测装置。该方法应用于电容检测装置中,该方法包括:根据电容检测装置输出的第n帧原始电容数据和第(n-M)帧原始电容数据,确定第n帧原始电容数据对应的特征值;计算第n帧原始电容数据与电容检测装置输出的第(n-1)帧原始电容数据对应的基线值之间的差值,得到电容变化量;当第n帧原始电容数据对应的特征值小于第一阈值Thr 1,且电容变化量小于接近阈值Thr on时,将第n帧原始电容数据或第(n-1)帧原始电容数据,确定为第n帧原始电容数据对应的基线值。该方法和装置可以对电容基线值进行实时有效的更新。

Description

电容基线更新方法、芯片以及电容检测装置 技术领域
本申请实施例涉及电容检测技术领域,尤其涉及一种电容基线更新方法、芯片以及电容检测装置。
背景技术
电容检测装置能够根据电容值的变化量来识别是否有人体或其他导体靠近。图1所示为一种典型的电容检测装置的结构示意图,该电容检测装置包括:传感器(sensor)101,放大器(amplifier,AMP)102以及模数转换器(Analog Digital Converter,ADC)103。当有人体或其他导体靠近时,传感器101对***地GND的电容C x的电容值会发生改变,传感器101可以将检测到的电容信号输出至放大器102,放大后的电容信号输入至模数转换器103,可以得到原始电容信号RawData。通过计算原始电容信号RawData与基线信号Ref之间的差值,可以得到电容变化信号Diff;将电容变化信号Diff的信号值与预先设定的阈值进行比较,能够识别出是否有人体或其他导体靠近或远离该电容检测装置。其中,基线信号Ref为该电容检测装置在没有人体或其他导体外加输入的情况下输出的信号。
图2所示为上述典型的电容检测装置输出的原始电容信号RawData的波动示意图;可以看到,在t 1时刻,原始电容信号RawData的信号值等于基线信号Ref的信号值,表示未有人体或其他导体正在靠近该电容检测装置;在t 2时刻,原始电容信号RawData的信号值达到接近阈值ON th,表示有人体或其他导体已经靠近该电容检测装置;在t 3时刻,原始电容信号RawData的信号值下降至远离阈值OFF th,表示人体或其他导体正在远离该电容检测装置。
但是,由于在实际应用中,环境温度或噪声干扰等因素会导致基线漂移,因此,若未对基线信号Ref的信号值进行实时更新,则容易导致电容变化信号Diff的信号值相对于实际操作所产生的电容变化量存在偏差,进而导致事件的误识别或漏识别;所述事件包括:人体或其他导体靠近该电容检测装置,人体或其他导体远离该电容检测装置。
现有技术中,一种常用的基线更新方法为一阶磁滞滤波法,该方法通过公式可以描述为:
Ref(n)=Coef x*Ref(n-1)+(1-Coef x)*RawData(n)
其中,Ref(n)为基线信号Ref当前第n帧的基线值,Ref(n-1)为基线信号Ref第(n-1)帧的基线值,RawData(n)为原始电容信号RawData当前第n帧的原始电容数据,Coef x为滤波系数。滤波系数Coef x的大小能够影响Ref(n)的平稳度和延迟响应,并且通过调整滤波系数Coef x的大小使得平稳度越高时,则延迟响应越大;使得延迟响应越小时,则平稳度越低。
上述基线更新方法通过对本次采样值RawData(n)和上次输出值Ref(n-1)进行加权,将原始电容信号RawData的部分数据更新到基线信号Ref中。然而,这种方法会将原始电容信号RawData中的有效数据和噪声均部分更新至基线信号Ref中,导致计算得到的电容变化信号Diff存在噪声抖动,若想要减小基线信号Ref的抖动,则会造成更大的延迟响应,所以上述基线更新方法难以适应对噪声干扰和延迟响应较为敏感的应用场景。
发明内容
本申请实施例提供一种电容基线更新方法、芯片以及电容检测装置,用以对电容基线值进行实时有效的更新,降低噪声抖动和延迟响应对电容检测性能的影响。
第一方面,本申请实施例提供一种电容基线更新方法,应用于电容检测装置中,该方法包括:
根据所述电容检测装置输出的第n帧原始电容数据RawData(n)和第(n-M)帧原始电容数据RawData(n-M),确定所述第n帧原始电容数据对应的特征值Feature(n);所述第n帧原始电容数据对应的特征值Feature(n)用于指示导体在靠近或远离所述电容检测装置过程中的不同阶段;
计算所述第n帧原始电容数据RawData(n)与所述电容检测装置输出的第(n-1)帧原始电容数据对应的基线值Ref(n-1)之间的差值,得到电容变化量Diff(n);
当所述第n帧原始电容数据对应的特征值Feature(n)小于第一阈值Thr 1,且所述电容变化量Diff(n)小于接近阈值Thr on时,将所述第n帧原始电容数据RawData(n)或所述第(n-1)帧原始电容数据RawData(n-1),确定为所述第n帧原始电容数据对应的基线值Ref(n);所述接近阈值Thr on用于确定所述导体是否已经靠近所述电容检测装置;所述第一阈值Thr 1用于确定所述电容检测装置上是否有所述导体的外加输入;
其中,n为大于2的正整数,M为大于或等于1的正整数,并且M<n。
根据第n帧原始电容数据RawData(n)和第(n-M)帧原始电容数据RawData(n-M)设置第n帧原始电容数据对应的特征值Feature(n),并将特征值Feature(n)的大小与第一阈值的大小进行比较,可以判断出电容检测装置上是否有人体或其他导体的外加输入。当第n帧原始电容数据对应的特征值Feature(n)小于第一阈值Thr 1,且电容变化量Diff(n)小于接近阈值Thr on时,表示该电容检测装置上没有人体或其他导体的外加输入,即该电容检测装置处于对空的状态,在这一阶段内设置第n帧原始电容数据对应的基线值Ref(n)等于第n帧原始电容数据RawData(n)或第(n-1)帧原始电容数据RawData(n-1),能够抵消电容变化信号Diff中的部分噪声,并使得电容变化信号Diff能够实时追踪原始电容信号RawData的波动变化,从而降低噪声抖动和延迟响应对电容检测性能的影响。
可选地,当所述第n帧原始电容数据对应的特征值Feature(n)大于或等于所述第一阈值Thr 1,且所述电容变化量Diff(n)小于所述接近阈值Thr on时,根据所述第(n-1)帧原始电容数据对应的基线值Ref(n-1),确定所述第n帧原始电容数据对应的基线值Ref(n)。
可选地,当所述第n帧原始电容数据对应的特征值Feature(n)大于或等于第二阈值Thr 2,并小于或等于所述第一阈值Thr 1,且所述电容变化量Diff(n)大于或等于所述接近阈值Thr on时,根据所述第n帧原始电容数据对应的特征值Feature(n)、所述第(n-1)帧原始电容数据对应的特征值Feature(n-1)、所述第(n-1)帧原始电容数据对应的基线值Ref(n-1)以及所述电容检测装置输出的第(n-2)帧原始电容数据对应的基线值Ref(n-2),确定所述第n帧原始电容数据对应的基线值Ref(n);所述第二阈值Thr 2用于确定所述导体是否逐渐脱离与所述电容检测装置的接触;
其中,所述第二阈值Thr 2小于所述第一阈值Thr 1
可选地,当所述第n帧原始电容数据对应的特征值Feature(n)小于所述第二阈值Thr 2或大于所述第一阈值Thr 1,且所述电容变化量Diff(n)大于或等于所述接近阈值Thr on时,根据所述第(n-1)帧原始电容数据对应的基线值Ref(n-1),确定所述第n帧原始电容数据对应的基线值Ref(n)。
可选地,所述根据所述电容检测装置输出的第n帧原始电容数据RawData(n)和第(n-M)帧原始电容数据RawData(n-M),确定所述第n帧原始电容数据对应的特征值Feature(n),进一步包括:
将所述第n帧原始电容数据RawData(n)与所述第(n-M)帧原始电容数据RawData(n-M)之间的差值,确定为所述第n帧原始电容数据对应的特征值Feature(n)。
可选地,所述当所述第n帧原始电容数据对应的特征值Feature(n)小于第一阈值Thr 1,且所述电容变化量Diff(n)小于接近阈值Thr on时,将所述第n帧原始电容数据RawData(n)或所述第(n-1)帧原始电容数据RawData(n-1),确定为所述第n帧原始电容数据对应的基线值Ref(n),进一步包括:
将所述第n帧原始电容数据RawData(n)和所述第(n-1)帧原始电容数据RawData(n-1)中的最小值,确定为所述第n帧原始电容数据对应的基线值Ref(n)。
可选地,所述当所述第n帧原始电容数据对应的特征值Feature(n)大于或等于所述第一阈值Thr 1,且所述电容变化量Diff(n)小于所述接近阈值Thr on时,根据所述第(n-1)帧原始电容数据对应的基线值Ref(n-1),确定所述第n帧原始电容数据对应的基线值Ref(n),进一步包括:
当所述第n帧原始电容数据对应的特征值Feature(n)大于或等于所述第一阈值Thr 1,并小于第三阈值Thr 3,且所述电容变化量Diff(n)小于所述接近阈值Thr on时,将所述第(n-1)帧原始电容数据对应的基线值Ref(n-1)与第一修正值Corr 1之和,确定为所述第n帧原始电容数据对应的基线值Ref(n);
当所述第n帧原始电容数据对应的特征值Feature(n)大于或等于所述第三阈值Thr 3,且所述电容变化量Diff(n)小于所述接近阈值Thr on时,将所述第(n-1)帧原始电容数据对应的基线值Ref(n-1)与第二修正值Corr 2之和,确定为所述第n帧原始电容数据对应的基线值Ref(n);所述第三阈值Thr 3用于确定所述导体正在向所述电容检测装置靠近的程度;
所述第一修正值Corr 1和所述第二修正值Corr 2分别用于表征相应阶段内由环境因素导致的基线值的偏移量;
其中,所述第三阈值Thr 3大于所述第一阈值Thr 1
可选地,所述当所述第n帧原始电容数据对应的特征值Feature(n)大于或等于第二阈值Thr 2,并小于或等于所述第一阈值Thr 1,且所述电容变化量Diff(n)大于或等于所述接近阈值Thr on时,根据所述第n帧原始电容数据对应的特征值Feature(n)、所述第(n-1)帧原始电容数据对应的特征值Feature(n-1)、所述第(n-1)帧原始电容数据对应的基线值Ref(n-1)以及所述电容检测装置输出的第(n-2)帧原始电容数据对应的基线值Ref(n-2),确定所述第n帧原始电容数据对应的基线值Ref(n),进一步包括:
计算所述第n帧原始电容数据对应的特征值Feature(n)与所述第(n-1)帧原始电容数据对应的特征值Feature(n-1)之间的差值,得到第一变化量Diff_Feature(n);
计算所述第(n-1)帧原始电容数据对应的基线值Ref(n-1)与所述第(n-2)帧原始电容数据对应的基线值Ref(n-2)之间的差值,得到第二变化量Diff_Ref(n-1);
使得所述第n帧原始电容数据对应的基线值Ref(n)满足如下公式:
Figure PCTCN2021075882-appb-000001
其中,所述第二变化量Diff_Ref(n-1)的值不为零。
可选地,所述当所述第n帧原始电容数据对应的特征值Feature(n)小于所述第二阈值Thr 2或大于所述第一阈值Thr 1,且所述电容变化量Diff(n)大于或等于所述接近阈值Thr on时,根据所述第(n-1)帧原始电容数据对应的基线值Ref(n-1),确定所述第n帧原始电容数据对应的基线值Ref(n),进一步包括:
当所述第n帧原始电容数据对应的特征值Feature(n)大于所述第一阈值Thr 1,且所述电容变化量Diff(n)大于或等于所述接近阈值Thr on时,将所述第(n-1)帧原始电容数据对应的基线值Ref(n-1)与所述第二修正值Corr 2之和,确定为所述第n帧原始电容数据对应的基线值Ref(n);
当所述第n帧原始电容数据对应的特征值Feature(n)小于所述第二阈值Thr 2,且所述电容变化量Diff(n)大于或等于所述接近阈值Thr on时,将所述第(n-1)帧原始电容数据对应的基线值Ref(n-1)与第三修正值Corr 3之和,确定为所述第n帧原始电容数据对应的基线值Ref(n);
所述第三修正值Corr 3用于表征相应阶段内由环境因素导致的基线值的偏移量。
第二方面,本申请实施例提供一种芯片,包括:处理器和存储器,所述存储器与所述处理器耦合;
所述存储器,用于存储计算机程序指令;
所述处理器,用于调用所述存储器存储的计算机程序指令,使得所述芯片执行如第一方面或第一方面的任一可选方式所述的电容基线更新方法。
第三方面,本申请实施例提供一种电容检测装置,包括如第二方面所述的芯片。
第四方面,本申请实施例提供一种计算机可读存储介质,用于存储计算机程序,所述计算机程序使得计算机执行如第一方面或第一方面的任一可选方式所述的电容基线更新方法。
可以理解的是,上述提供的第二方面所述的芯片、第三方面所述的电容检测装置以及第四方面所述的计算机可读存储介质均用于执行上文所提供的对应的方法,因此,其所能达到的有益效果可参考上文所提供的对应的方法中的有益效果,此处不再赘述。
附图说明
一个或多个实施例通过与之对应的附图中的图片进行示例性说明,这些示例性说明并不构成对实施例的限定。另外,除非有特别申明,附图中的图不构成比例限制。
图1为一种典型的电容检测装置的结构示意图;
图2为图1所示的电容检测装置输出的原始电容信号RawData的波动示意图;
图3为本申请实施例提供的一种电容基线更新方法的示意性框图;
图4为本申请实施例提供的一种导体靠近和远离过程中原始电容信号和特征信号的波动示意图;
图5为本申请实施例提供的一种导体靠近和远离过程中基线信号的更新示意图;
图6为本申请实施例提供的一种导体靠近和远离过程中电容变化信号的波动示意图;
图7为本申请实施例提供的一种芯片结构示意图。
具体实施方式
下面将结合附图对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本申请的一部分实施例,而不是全部的实施例。
本申请使用的术语是仅仅出于描述特定实施例的目的,而非旨在限制本申请。在本申请和所附权利要求书中所使用的单数形式的“一种”、“所述”和“该”也旨在包括多数形式,除非上下文清楚地表示其他含义。
还应当理解,除非在本申请的上下文中清楚地说明了指定的顺序,否则可与指定的顺序不同地执行在此描述的处理步骤。也就是说,可以以指定的顺序执行每个步骤、基本上同时执行每个步骤、以相反的顺序执行每个步骤或者以不同的顺序执行每个步骤。
另外,“第一”、“第二”等术语仅用于区别类似的对象,而不能理解为指示或暗示相对重要性,或者隐含指明所指示的技术特征的数量。由此,限定有“第一”、“第二”等的特征可以明示或者隐含地包括一个或者更多个该特征。
如图3所示,为本申请实施例提供的一种电容基线更新方法的示意性框图。该方法可应用于电容检测装置中,具体包括以下步骤:
步骤S101:根据电容检测装置输出的第n帧原始电容数据RawData(n)和第(n-M)帧原始电容数据RawData(n-M),确定第n帧原始电容数据对应的特征值Feature(n)。
该第n帧原始电容数据对应的特征值Feature(n)可以指示导体(人体或其他导体)在靠近或远离该电容检测装置过程中的不同阶段。
步骤S102:计算第n帧原始电容数据RawData(n)与电容检测装置输出的第(n-1)帧原始电容数据对应的基线值Ref(n-1)之间的差值,得到电容变化量Diff(n)。
通过设置电容变化量Diff(n)=RawData(n)–Ref(n-1),则可以实现利用电容变化量Diff(n)对第n帧原始电容数据对应的电容变化量进行预判,从而确定导体的移动状态;具体的,移动状态可以包括:已靠近该电容检测装置(已靠近状态)和未靠近该电容检测装置(未靠近状态)。其中,第n帧原始电容数据对应的电容变化量为第n帧原 始电容数据RawData(n)与其对应的基线值Ref(n)之间的差值,即可以为RawData(n)-Ref(n),可用于表示当前由人体或其他导体引起的电容变化量。
步骤S103a:当第n帧原始电容数据对应的特征值Feature(n)小于第一阈值Thr 1,且电容变化量Diff(n)小于接近阈值Thr on时,将第n帧原始电容数据RawData(n)或第(n-1)帧原始电容数据RawData(n-1),确定为第n帧原始电容数据对应的基线值Ref(n)。其中,接近阈值Thr on可用于确定该导体是否已经靠近该电容检测装置;第一阈值Thr 1可用于确定该电容检测装置上是否有该导体的外加输入。
通过将电容变化量Diff(n)与接近阈值Thr on进行比较,则可以判定该导体是否已经靠近该电容检测装置,即判定该导体的移动状态;具体的,若电容变化量Diff(n)达到接近阈值Thr on,即大于或等于接近阈值Thr on,则可以确定该导体处于已靠近状态;若电容变化量Diff(n)未达到接近阈值Thr on,即小于接近阈值Thr on,则可以确定该导体处于未靠近状态。另外,接近阈值Thr on的大小可以通过基于训练数据的机器学习方法生成,训练数据可以包括但不限于:不同种类的导体以不同程度与该电容检测装置接触时对应的电容变化量Diff(n),以及不同种类的导体与该电容检测装置之间存在不同距离时对应的电容变化量Diff(n);另外,接近阈值Thr on的大小还可以根据后续用户的实际应用进行相应的调整,从而更加准确地分辨是否有人体或其他导体已经靠近该电容检测装置,更好地适应不同的应用场景。
步骤S103b:当第n帧原始电容数据对应的特征值Feature(n)大于或等于第一阈值Thr 1,且电容变化量Diff(n)小于接近阈值Thr on时,根据第(n-1)帧原始电容数据对应的基线值Ref(n-1),确定第n帧原始电容数据对应的基线值Ref(n)。
步骤S103c:当第n帧原始电容数据对应的特征值Feature(n)大于或等于第二阈值Thr 2,并小于或等于第一阈值Thr 1,且电容变化量Diff(n)大于或等于接近阈值Thr on时,根据第n帧原始电容数据对应的特征值Feature(n)、第(n-1)帧原始电容数据对应的特征值Feature(n-1)、第(n-1)帧原始电容数据对应的基线值Ref(n-1)以及电容检测装置输出的第(n-2)帧原始电容数据对应的基线值Ref(n-2),确定第n帧原始电容数据对应的基线值Ref(n)。
其中,第二阈值Thr 2小于第一阈值Thr 1,并且第二阈值Thr 2可用于确定该导体是否逐渐脱离与该电容检测装置的接触,具体的,可用于进一步确定该导体在已靠近状态下的移动趋势是保持与该电容检测装置的稳定接触,还是开始从该电容检测装置移开。
步骤S103d:当第n帧原始电容数据对应的特征值Feature(n)小于第二阈值Thr 2或大于第一阈值Thr 1,且电容变化量Diff(n)大于或等于接近阈值Thr on时,根据第(n-1)帧原始电容数据对应的基线值Ref(n-1),确定第n帧原始电容数据对应的基线值Ref(n)。
以上,n为大于2的正整数,M为大于或等于1的正整数,并且M<n。当n等于1或2时,可以设置Ref(1)或Ref(2)的值等于该电容检测装置在没有人体或其他导体外加输入的情况下输出的原始电容信号的信号值。
具体的,第一阈值Thr 1的设定也可以通过基于训练数据的机器学习方法生成,训练数据可以包括但不限于:该电容检测装置上未有人体或其他导体的外加输入时的电容变化量,有人体或其他导体开始靠近该电容检测装置时的电容变化量,人体或其他 导体开始远离该电容检测装置时的电容变化量。另外,第二阈值Thr 2可以设定为一个负数值,其绝对值的大小可以为第一阈值Thr 1的2~3倍。
根据第n帧原始电容数据RawData(n)和第(n-M)帧原始电容数据RawData(n-M)设置特征值Feature(n),以及将特征值Feature(n)的大小与预设阈值的大小进行比较,可以将人体或其他导体靠近或远离该电容检测装置的过程划分为不同的阶段,根据各个阶段内导体不同的移动状态(已靠近/未靠近)和移动趋势(靠近、保持接触、离开),设置相应的电容基线更新方式,能够实现对基线值进行实时、有效的更新。
具体的,当Feature(n)<Thr 1且Diff(n)<Thr on时,可以表示该电容检测装置上未有导体引起的外加输入,包括:未有导体开始靠近该电容检测装置,导体已经远离该电容检测装置;这一阶段内原始电容数据RawData(n)仅指示由环境噪声所引起的电容变化量,所以这一阶段可称为噪声阶段。
当Feature(n)≥Thr 1且Diff(n)<Thr on时,可以表示有导体正在缓慢/快速地向该电容检测装置靠近,但该导体仍处于未靠近状态,所以这一阶段可称为预靠近阶段。
当Thr 2≤Feature(n)≤Thr 1且Diff(n)≥Thr on时,可以表示有导体保持与该电容检测装置的稳定接触,并且已经达到最靠近的状态;当Feature(n)>Thr 1或Feature(n)<Thr 2,且Diff(n)≥Thr on时,表示该导体处于已靠近状态,并且正在进一步向该电容检测装置靠近,或者逐渐脱离与该电容检测装置的接触,即开始从该电容检测装置离开,这两个阶段可称为靠近阶段。
作为一种可能的实施方式,上述根据电容检测装置输出的第n帧原始电容数据RawData(n)和第(n-M)帧原始电容数据RawData(n-M),确定第n帧原始电容数据对应的特征值Feature(n),进一步包括:将第n帧原始电容数据RawData(n)与第(n-M)帧原始电容数据RawData(n-M)之间的差值,确定为第n帧原始电容数据对应的特征值Feature(n)。
因此,可以设置Feature(n)=RawData(n)-RawData(n-M)。其中,M的值可以根据实际的应用场景和所需达到的应用目标进行设定,最小可以为1,并且M的值越小,电容基线更新的实时性越好,但同时也会导致计算量越大。
作为一种可能的实施方式,当第n帧原始电容数据对应的特征值Feature(n)小于第一阈值Thr 1,且电容变化量Diff(n)小于接近阈值Thr on时,将第n帧原始电容数据RawData(n)或第(n-1)帧原始电容数据RawData(n-1),确定为第n帧原始电容数据对应的基线值Ref(n),进一步包括:将第n帧原始电容数据RawData(n)和第(n-1)帧原始电容数据RawData(n-1)中的最小值,确定为第n帧原始电容数据对应的基线值Ref(n)。
因此,在噪声阶段,可以设置Ref(n)=min{RawData(n),RawData(n-1)}。基于这种基线更新方式,可以使得在这一阶段内电容变化信号Diff中的噪声只有单向变化量,从而有效减少电容变化信号Diff中反向变化的噪声,相比于现有技术中常用的一阶磁滞滤波法,这一阶段内电容变化信号Diff中的噪声方差能够减小一半,并且不会损耗电容变化信号Diff中有效的信号分量,此外也可以使基线信号Ref能够实时追踪原始电容信号RawData的波动变化,从而降低噪声抖动和延迟响应对电容检测性能的影响。
作为一种可能的实施方式,当第n帧原始电容数据对应的特征值(n)大于或等于第一阈值Thr 1,且电容变化量Diff(n)小于接近阈值Thr on时,根据第(n-1)帧原始电容 数据对应的基线值Ref(n-1),确定第n帧原始电容数据对应的基线值Ref(n),进一步包括:
当第n帧原始电容数据对应的特征值Feature(n)大于或等于第一阈值Thr 1,并小于第三阈值Thr 3,且电容变化量Diff(n)小于接近阈值Thr on时,将第(n-1)帧原始电容数据对应的基线值Ref(n-1)与第一修正值Corr 1之和,确定为第n帧原始电容数据对应的基线值Ref(n);当第n帧原始电容数据对应的特征值Feature(n)大于或等于第三阈值Thr 3,且电容变化量Diff(n)小于接近阈值Thr on时,将第(n-1)帧原始电容数据对应的基线值Ref(n-1)与第二修正值Corr 2之和,确定为第n帧原始电容数据对应的基线值Ref(n)。其中,第三阈值Thr 3可用于确定导体正在向该电容检测装置靠近的程度,并且第三阈值Thr 3大于第一阈值Thr 1;第一修正值Corr 1和第二修正值Corr 2可分别用于表征相应阶段内由环境因素导致的基线值的偏移量。
由此,在预靠近阶段内,基于这一基线更新方式,可以减少由温度等环境因素导致的基线漂移噪声,提高电容变化信号Diff的信噪比,并且能够实现对基线信号Ref进行实时更新,从而降低噪声抖动和延迟响应对电容检测性能的影响。
因而,可以将预靠近阶段进一步划分为两个子阶段,并且在这两个子阶段内,人体或其他导体靠近该电容检测装置的程度不同;具体的,当Thr 1≤Feature(n)<Thr 3,Diff(n)<Thr on时,设置Ref(n)=Ref(n-1)+Corr 1,这一阶段可称为第一预靠近子阶段;当Feature(n)≥Thr 3,Diff(n)<Thr on时,设置Ref(n)=Ref(n-1)+Corr 2,这一阶段可称为第二预靠近子阶段。第二预靠近子阶段比第一预靠近子阶段的靠近程度更高。具体的,第一修正值Corr 1的大小可以设定在接近阈值Thr on的20%左右,第二修正值Corr 2可以设定为与第一修正值Corr 1相等,或者略小于第一修正值Corr 1。第三阈值Thr 3可以设置为第二阈值Thr 2的相反数,即为第一阈值Thr 1的2~3倍。
作为一种可能的实施方式,当第n帧原始电容数据对应的特征值Feature(n)大于或等于第二阈值Thr 2,并小于或等于第一阈值Thr 1,且电容变化量Diff(n)大于或等于接近阈值Thr on时,根据第n帧原始电容数据对应的特征值Feature(n)、第(n-1)帧原始电容数据对应的特征值Feature(n-1)、第(n-1)帧原始电容数据对应的基线值Ref(n-1)以及电容检测装置输出的第(n-2)帧原始电容数据对应的基线值Ref(n-2),确定第n帧原始电容数据对应的基线值Ref(n),进一步包括:
计算第n帧原始电容数据对应的特征值Feature(n)与第(n-1)帧原始电容数据对应的特征值Feature(n-1)之间的差值,得到第一变化量Diff_Feature(n);计算第(n-1)帧原始电容数据对应的基线值Ref(n-1)与电容检测装置输出的第(n-2)帧原始电容数据对应的基线值Ref(n-2)之间的差值,得到第二变化量Diff_Ref(n-1);使得第n帧原始电容数据对应的基线值Ref(n)满足公式:
Figure PCTCN2021075882-appb-000002
其中,第二变化量Diff_Ref(n-1)≠0。若在这一阶段内,存在Ref(n-1)与Ref(n-2)相等,则可以设置第二变化量Diff_Ref(n-1)为一个非零常数值,例如,可以设置为与前面某一帧非零的第二变化量Diff_Ref(n-1)的数值相等。
在这一阶段内,导体稳定地保持与该电容检测装置的接触,并且处于最靠近的状 态。由于导体一般存在一定程度的晃动或者与该电容检测装置中的传感器存在温度差,所以容易导致原始电容信号RawData发生异常的抖动变化,进而使得电容变化信号Diff中存在明显的噪声分量,影响电容检测结果的准确度,而采用上述方式对电容基线值进行实时更新,能够在导体持续稳定地接触该电容检测装置的过程中将原始电容信号RawData中的抖动变化量提取出来,并叠加至基线信号Ref中,从而减少电容变化信号Diff中的低频噪声,有效降低事件误识别或漏识别的概率。
作为一种可能的实施方式,当第n帧原始电容数据对应的特征值Feature(n)小于第二阈值Thr 2或大于第一阈值Thr 1,且电容变化量Diff(n)大于或等于接近阈值Thr on时,根据第(n-1)帧原始电容数据对应的基线值Ref(n-1),确定第n帧原始电容数据对应的基线值Ref(n),进一步包括:
当第n帧原始电容数据对应的特征值Feature(n)大于第一阈值Thr 1,且电容变化量Diff(n)大于或等于接近阈值Thr on时,将第(n-1)帧原始电容数据对应的基线值Ref(n-1)与第二修正值Corr 2之和,确定为第n帧原始电容数据对应的基线值Ref(n);当第n帧原始电容数据对应的特征值Feature(n)小于第二阈值Thr 2,且电容变化量Diff(n)大于或等于接近阈值Thr on时,将第(n-1)帧原始电容数据对应的基线值Ref(n-1)与第三修正值Corr 3之和,确定为第n帧原始电容数据对应的基线值Ref(n)。
其中,第三修正值Corr 3可以表征相应阶段内由环境因素导致的基线值的偏移量;具体的,第三修正值Corr 3的大小可以根据实际的应用场景进行设定,可以与第一修正值Corr 1和第二修正值Corr 2相等,或者略小于第一修正值Corr 1
因此,这一阶段可以被进一步分为两个子阶段,当Feature(n)>Thr 1,Diff(n)≥Thr on时,表征导体处于已靠近状态,并且正在进一步向该电容检测装置靠近,设置Ref(n)=Ref(n-1)+Corr 2,能够保证基线信号Ref在本阶段的信号值与上一阶段(第二预靠近子阶段)的信号值连续。当Feature(n)<Thr 2,Diff(n)≥Thr on时,表征导体处于已靠近状态,但是逐渐脱离与该电容检测装置的接触,即开始从该电容检测装置离开,设置Ref(n)=Ref(n-1)+Corr 3,能够使得基线信号Ref跟随原始电容信号RawData进行实时迅速的更新。
在这一阶段内,基于上述基线更新方式,可以减少由温度等环境因素导致的基线漂移噪声,提高电容变化信号Diff的信噪比,并且使基线信号Ref能够实时迅速地跟踪原始电容信号RawData的变化,降低噪声抖动和延迟响应对电容检测性能的影响。
如图4所示,为本申请实施例提供的一种导体靠近和远离过程中原始电容信号和特征信号的波动示意图。可以看到,通过比较Feature(n)与第一阈值Thr 1、第二阈值Thr 2、第三阈值Thr 3的大小,可以将导体靠近和远离电容检测装置的过程划分为不同的阶段,包括噪声阶段(T 1和T 4)、预靠近阶段(T 2)和靠近阶段(T 3),其中,噪声阶段的T 1时段内,该电容检测装置上未有导体的外加输入,噪声阶段的T 4时段内,导体已经远离该电容检测装置;并且,可以根据不同的靠近程度将预靠近阶段进一步划分为两个子阶段,以及根据不同的移动趋势将靠近阶段进一步划分为三个子阶段。另外,可以看到,M=10对应的特征信号Feature相比于M=20对应的特征信号Feature具有更小的延迟响应。
如图5所示,为本申请实施例提供的一种导体靠近和远离过程中基线信号的更新 示意图;其中,在导体靠近和远离电容检测装置的各个阶段内,分别采用了上述实施例提供的电容基线更新方法。可以看到,在T 1时段(噪声阶段),该电容检测装置上未有人体或其他导体的外加输入,基线信号Ref能够实时更新以跟踪原始电容信号RawData的变化;在T 2时段(预靠近阶段),有人体或其他导体正在靠近该电容检测装置,但仍然处于未靠近状态,基线信号Ref能够及时跟踪原始电容信号RawData的上升变化并实时更新;在T 3时段(靠近阶段),当有人体或其他导体处于已靠近状态,并且保持与该电容检测装置之间的稳定接触时,基线信号Ref也能够实时跟踪原始电容信号RawData的抖动变化,有效减少电容变化信号Diff中的低频噪声分量,提高电容变化信号Diff的信噪比,从而提升电容检测结果的准确度,当有人体或其他导体处于已靠近状态,并且进一步靠近该电容检测装置或者逐渐脱离与该电容检测装置的接触时,基线信号Ref能够根据原始电容信号RawData的变化进行实时更新;在T 4时段(噪声阶段),人体或其他导体已经远离该电容检测装置,基线信号Ref能够迅速更新并迅速恢复至常规的基线水平,从而减小延迟响应对后续电容检测的灵敏度和准确度的影响。
如图6所示,为本申请实施例提供的一种导体靠近和远离过程中电容变化信号的波动示意图,其中,在导体快速/缓慢靠近和远离电容检测装置的各个阶段内,分别采用了上述实施例提供的电容基线更新方法。可以看到,在人体或其他导体快速靠近远离和缓慢靠近远离电容检测装置的过程中,电容变化信号均能够迅速达到目标水平,并且实时准确地反映出人体或其他导体是否靠近该电容检测装置,提高了电容检测的灵敏度和准确度。
在实际应用中,往往需要实时、准确地识别人体或其他导体缓慢靠近并快速远离的过程,因此,本申请实施例提供的电容基线更新方法可以很好地适应在这一应用场景。
需要说明的是,为了适应不同阈值的大小,可以对第n帧原始电容数据对应的特征值Feature(n)进行相应的比例系数缩放,例如,可以设置:Feature(n)=[RawData(n)–RawData(n-M)]*a,其中a可以为大于0的常数,进而使得Feature(n)的值与预设阈值的大小相互对应,以有效区分导体在靠近或远离电容检测装置过程中的不同阶段,并通过针对不同阶段设置不同的基线更新方法,实时、有效地更新基线值,以减少噪声抖动和延迟响应对电容检测性能的影响,提高电容检测结果的准确度,降低事件误识别或漏识别的概率。
本申请实施例提供的电容基线更新方法可以适应各种需要精确检测电容的场景,包括佩戴检测,触控检测和SAR(Specific Absorption Rate,特定吸收率)应用等,例如,在蓝牙耳机(如TWS耳机)的入耳检测应用中,准确识别用户是否已佩戴该蓝牙耳机。
如图7所示,为本申请实施例提供的一种芯片结构示意图。芯片20包括存储器201和处理器202;其中,存储器201可以存储计算机程序指令,处理器202可以调用存储器201存储的计算机程序指令,使得芯片20可以执行如上述第一方面或第一方面的任意一种可能的实施方式所提供的电容基线更新方法。
具体的,存储器201可以是易失性存储器(Volatile Memory,VM),如随机存取 存储器(Random Access Memory,RAM)等,或者非易失性存储器(Non-Volatile Memory,NVM),如硬盘(Hard Disk Drive,HDD)、固态硬盘(Solid State Drive,SSD)等,又或者是电路或者其他任意能够实现存储功能的装置。存储器201是可以存储或携带具有指令或数据结构形式的期望的程序代码并能够由计算机存取的任何其他介质,并且不限于此。
处理器202可以是通用处理器(如微处理器)、数字信号处理器、专用集成电路、晶体管逻辑器件、现场可编程门阵列或者其他可编程逻辑器件,并且不限于此,可以实现或执行本申请实施例提供的各方法、步骤以及逻辑框图。结合本申请实施例所提供的各方法、步骤可以直接体现为硬件处理器执行完成,或者用处理器中的硬件及软件模块组合执行完成。
芯片20还可以称为***芯片,***级芯片,芯片***或片上***芯片等。
第三方面,本申请实施例提供一种电容检测装置,包括如上述第二方面所提供的芯片。
该电容检测装置可以执行如上述第一方面或第一方面的任意一种可能的实施方式所提供的电容基线更新方法。
第四方面,本申请实施例提供一种计算机可读存储介质,该计算机可读存储介质可以存储计算机程序,该计算机程序可以使得计算机执行如上述第一方面或第一方面的任意一种可能的实施方式所提供的电容基线更新方法。
该计算机可读存储介质可以是计算机可以存取的任何可用介质,或者是一个或多个可用介质集成的服务器、数据中心等数据存储设备。该可用介质可以是磁性介质(如硬盘、软盘、磁带等)、半导体介质(如固态硬盘等),或者光介质(如数字视频光盘(Digital Video Disk,DVD)等),并且不限于此。
本申请各实施例提供的方法可以全部或部分地通过软件、硬件、固件或者其任意组合来实现。当通过软件实现时,可以全部或部分地以计算机程序产品的形式实现,该计算机程序产品包括一个或多个计算机指令。在计算机上加载和执行该计算机指令时,可以全部或部分地产生按照本申请实施例所述的流程或功能,该计算机可以是通用计算机、专用计算机、计算机网络、网络设备、用户设备或者其他可编程装置,该计算机指令可以存储在计算机可读存储介质中,或者从一个计算机可读存储介质向另一个计算机可读存储介质传输,例如,该计算机指令可以从一个计算机、服务器、网站站点或数据中心通过有线(如光线、同轴电缆、数字用户线(Digital Subscriber Line,DSL)等)或者无线(如微波、毫米波、红外等)的方式向另一个计算机、服务器、网站站点或数据中心进行传输。
应理解,本申请实施例中的具体实施方式仅是为了帮助本领域技术人员更好地理解本申请实施例,而非限制本申请实施例的范围,本领域技术人员可以在上述实施例的基础上进行各种改进和变形,而这些改进或者变形均落入本申请的保护范围。

Claims (12)

  1. 一种电容基线更新方法,其特征在于,所述方法应用于电容检测装置中,所述方法包括:
    根据所述电容检测装置输出的第n帧原始电容数据RawData(n)和第(n-M)帧原始电容数据RawData(n-M),确定所述第n帧原始电容数据对应的特征值Feature(n);所述第n帧原始电容数据对应的特征值Feature(n)用于指示导体在靠近或远离所述电容检测装置过程中的不同阶段;
    计算所述第n帧原始电容数据RawData(n)与所述电容检测装置输出的第(n-1)帧原始电容数据对应的基线值Ref(n-1)之间的差值,得到电容变化量Diff(n);
    当所述第n帧原始电容数据对应的特征值Feature(n)小于第一阈值Thr 1,且所述电容变化量Diff(n)小于接近阈值Thr on时,将所述第n帧原始电容数据RawData(n)或所述第(n-1)帧原始电容数据RawData(n-1),确定为所述第n帧原始电容数据对应的基线值Ref(n);所述接近阈值Thr on用于确定所述导体是否已经靠近所述电容检测装置;所述第一阈值Thr 1用于确定所述电容检测装置上是否有所述导体的外加输入;
    其中,n为大于2的正整数,M为大于或等于1的正整数,并且M<n。
  2. 根据权利要求1所述的方法,其特征在于,进一步包括:
    当所述第n帧原始电容数据对应的特征值Feature(n)大于或等于所述第一阈值Thr 1,且所述电容变化量Diff(n)小于所述接近阈值Thr on时,根据所述第(n-1)帧原始电容数据对应的基线值Ref(n-1),确定所述第n帧原始电容数据对应的基线值Ref(n)。
  3. 根据权利要求2所述的方法,其特征在于,进一步包括:
    当所述第n帧原始电容数据对应的特征值Feature(n)大于或等于第二阈值Thr 2,并小于或等于所述第一阈值Thr 1,且所述电容变化量Diff(n)大于或等于所述接近阈值Thr on时,根据所述第n帧原始电容数据对应的特征值Feature(n)、所述第(n-1)帧原始电容数据对应的特征值Feature(n-1)、所述第(n-1)帧原始电容数据对应的基线值Ref(n-1)以及所述电容检测装置输出的第(n-2)帧原始电容数据对应的基线值Ref(n-2),确定所述第n帧原始电容数据对应的基线值Ref(n);所述第二阈值Thr 2用于确定所述导体是否逐渐脱离与所述电容检测装置的接触;
    其中,所述第二阈值Thr 2小于所述第一阈值Thr 1
  4. 根据权利要求3所述的方法,其特征在于,进一步包括:
    当所述第n帧原始电容数据对应的特征值Feature(n)小于所述第二阈值Thr 2或大于所述第一阈值Thr 1,且所述电容变化量Diff(n)大于或等于所述接近阈值Thr on时,根据所述第(n-1)帧原始电容数据对应的基线值Ref(n-1),确定所述第n帧原始电容数据对应的基线值Ref(n)。
  5. 根据权利要求1至4任一项所述的方法,其特征在于,所述根据所述电容检测装置输出的第n帧原始电容数据RawData(n)和第(n-M)帧原始电容数据RawData(n-M),确定所述第n帧原始电容数据对应的特征值Feature(n),进一步包括:
    将所述第n帧原始电容数据RawData(n)与所述第(n-M)帧原始电容数据RawData(n-M)之间的差值,确定为所述第n帧原始电容数据对应的特征值Feature(n)。
  6. 根据权利要求5所述的方法,其特征在于,所述当所述第n帧原始电容数据对应的特征值Feature(n)小于第一阈值Thr 1,且所述电容变化量Diff(n)小于接近阈值Thr on时,将所述第n帧原始电容数据RawData(n)或所述第(n-1)帧原始电容数据RawData(n-1),确定为所述第n帧原始电容数据对应的基线值Ref(n),进一步包括:
    将所述第n帧原始电容数据RawData(n)和所述第(n-1)帧原始电容数据RawData(n-1)中的最小值,确定为所述第n帧原始电容数据对应的基线值Ref(n)。
  7. 根据权利要求6所述的方法,其特征在于,所述当所述第n帧原始电容数据对应的特征值Feature(n)大于或等于所述第一阈值Thr 1,且所述电容变化量Diff(n)小于所述接近阈值Thr on时,根据所述第(n-1)帧原始电容数据对应的基线值Ref(n-1),确定所述第n帧原始电容数据对应的基线值Ref(n),进一步包括:
    当所述第n帧原始电容数据对应的特征值Feature(n)大于或等于所述第一阈值Thr 1,并小于第三阈值Thr 3,且所述电容变化量Diff(n)小于所述接近阈值Thr on时,将所述第(n-1)帧原始电容数据对应的基线值Ref(n-1)与第一修正值Corr 1之和,确定为所述第n帧原始电容数据对应的基线值Ref(n);
    当所述第n帧原始电容数据对应的特征值Feature(n)大于或等于所述第三阈值Thr 3,且所述电容变化量Diff(n)小于所述接近阈值Thr on时,将所述第(n-1)帧原始电容数据对应的基线值Ref(n-1)与第二修正值Corr 2之和,确定为所述第n帧原始电容数据对应的基线值Ref(n);所述第三阈值Thr 3用于确定所述导体正在向所述电容检测装置靠近的程度;
    所述第一修正值Corr 1和所述第二修正值Corr 2分别用于表征相应阶段内由环境因素导致的基线值的偏移量;
    其中,所述第三阈值Thr 3大于所述第一阈值Thr 1
  8. 根据权利要求7所述的方法,其特征在于,所述当所述第n帧原始电容数据对应的特征值Feature(n)大于或等于第二阈值Thr 2,并小于或等于所述第一阈值Thr 1,且所述电容变化量Diff(n)大于或等于所述接近阈值Thr on时,根据所述第n帧原始电容数据对应的特征值Feature(n)、所述第(n-1)帧原始电容数据对应的特征值Feature(n-1)、所述第(n-1)帧原始电容数据对应的基线值Ref(n-1)以及所述电容检测装置输出的第(n-2)帧原始电容数据对应的基线值Ref(n-2),确定所述第n帧原始电容数据对应的基线值Ref(n),进一步包括:
    计算所述第n帧原始电容数据对应的特征值Feature(n)与所述第(n-1)帧原始电容数据对应的特征值Feature(n-1)之间的差值,得到第一变化量Diff_Feature(n);
    计算所述第(n-1)帧原始电容数据对应的基线值Ref(n-1)与所述第(n-2)帧原始电容数据对应的基线值Ref(n-2)之间的差值,得到第二变化量Diff_Ref(n-1);
    使得所述第n帧原始电容数据对应的基线值Ref(n)满足如下公式:
    Figure PCTCN2021075882-appb-100001
    其中,所述第二变化量Diff_Ref(n-1)的值不为零。
  9. 根据权利要求8所述的方法,其特征在于,所述当所述第n帧原始电容数据对应的特征值Feature(n)小于所述第二阈值Thr 2或大于所述第一阈值Thr 1,且所述电容变化量Diff(n)大于或等于所述接近阈值Thr on时,根据所述第(n-1)帧原始电容数据对应的基线值Ref(n-1),确定所述第n帧原始电容数据对应的基线值Ref(n),进一步包括:
    当所述第n帧原始电容数据对应的特征值Feature(n)大于所述第一阈值Thr 1,且所述电容变化量Diff(n)大于或等于所述接近阈值Thr on时,将所述第(n-1)帧原始电容数据对应的基线值Ref(n-1)与所述第二修正值Corr 2之和,确定为所述第n帧原始电容数据对应的基线值Ref(n);
    当所述第n帧原始电容数据对应的特征值Feature(n)小于所述第二阈值Thr 2,且所述电容变化量Diff(n)大于或等于所述接近阈值Thr on时,将所述第(n-1)帧原始电容数据对应的基线值Ref(n-1)与第三修正值Corr 3之和,确定为所述第n帧原始电容数据对应的基线值Ref(n);
    所述第三修正值Corr 3用于表征相应阶段内由环境因素导致的基线值的偏移量。
  10. 一种芯片,其特征在于,包括:处理器和存储器,所述存储器与所述处理器耦合;
    所述存储器,用于存储计算机程序指令;
    所述处理器,用于调用所述存储器存储的计算机程序指令,使得所述芯片执行如权利要求1至9任一项所述的电容基线更新方法。
  11. 一种电容检测装置,其特征在于,包括如权利要求10所述的芯片。
  12. 一种计算机可读存储介质,其特征在于,用于存储计算机程序,所述计算机程序使得计算机执行如权利要求1至9任一项所述的电容基线更新方法。
PCT/CN2021/075882 2021-02-07 2021-02-07 电容基线更新方法、芯片以及电容检测装置 WO2022165816A1 (zh)

Priority Applications (3)

Application Number Priority Date Filing Date Title
EP21867867.0A EP4067912A4 (en) 2021-02-07 2021-02-07 PROCEDURE FOR UPDATING A CAPACITY REFERENCE LEAD, CHIP, AND CAPACITY METER
PCT/CN2021/075882 WO2022165816A1 (zh) 2021-02-07 2021-02-07 电容基线更新方法、芯片以及电容检测装置
US17/695,351 US20220260393A1 (en) 2021-02-07 2022-03-15 Method for updating capacitance reference, chip, and capacitance detection apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/CN2021/075882 WO2022165816A1 (zh) 2021-02-07 2021-02-07 电容基线更新方法、芯片以及电容检测装置

Related Child Applications (1)

Application Number Title Priority Date Filing Date
US17/695,351 Continuation US20220260393A1 (en) 2021-02-07 2022-03-15 Method for updating capacitance reference, chip, and capacitance detection apparatus

Publications (1)

Publication Number Publication Date
WO2022165816A1 true WO2022165816A1 (zh) 2022-08-11

Family

ID=82741950

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/075882 WO2022165816A1 (zh) 2021-02-07 2021-02-07 电容基线更新方法、芯片以及电容检测装置

Country Status (3)

Country Link
US (1) US20220260393A1 (zh)
EP (1) EP4067912A4 (zh)
WO (1) WO2022165816A1 (zh)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2023013710A (ja) * 2021-07-16 2023-01-26 アルプスアルパイン株式会社 接触判定装置

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101963873A (zh) * 2010-10-08 2011-02-02 展触光电科技股份有限公司 电容式触控面板电容基线值设定及校准方法
CN102855032A (zh) * 2011-06-27 2013-01-02 比亚迪股份有限公司 基线更新方法及触控装置
CN109601015A (zh) * 2017-07-31 2019-04-09 深圳市汇顶科技股份有限公司 触摸屏基准确定方法、装置、触摸屏及电子终端
US20200133412A1 (en) * 2018-10-30 2020-04-30 Synaptics Incorporated Baseline update for input object detection
CN111190507A (zh) * 2018-11-14 2020-05-22 阿尔派株式会社 具备触摸面板的电子装置及基线值的更新方法

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101963873A (zh) * 2010-10-08 2011-02-02 展触光电科技股份有限公司 电容式触控面板电容基线值设定及校准方法
CN102855032A (zh) * 2011-06-27 2013-01-02 比亚迪股份有限公司 基线更新方法及触控装置
CN109601015A (zh) * 2017-07-31 2019-04-09 深圳市汇顶科技股份有限公司 触摸屏基准确定方法、装置、触摸屏及电子终端
US20200133412A1 (en) * 2018-10-30 2020-04-30 Synaptics Incorporated Baseline update for input object detection
CN111190507A (zh) * 2018-11-14 2020-05-22 阿尔派株式会社 具备触摸面板的电子装置及基线值的更新方法

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
See also references of EP4067912A4 *

Also Published As

Publication number Publication date
EP4067912A4 (en) 2022-10-19
EP4067912A1 (en) 2022-10-05
US20220260393A1 (en) 2022-08-18

Similar Documents

Publication Publication Date Title
CN112986693B (zh) 电容基线更新方法、芯片以及电容检测装置
US9811220B2 (en) Signal adaptive filtering for touch detection
US9702899B2 (en) Pedometer with lag correction
WO2022165816A1 (zh) 电容基线更新方法、芯片以及电容检测装置
CA2955515C (en) Speed estimation systems
US20140168057A1 (en) Gyro aided tap gesture detection
JP6067930B2 (ja) 複数のマイクロフォンのための自動利得整合
CN104135576A (zh) 移动终端的指南针指向优化方法及***
US9690425B2 (en) Systems and methods for tracking baseline signals for touch detection
CN111816178A (zh) 语音设备的控制方法、装置和设备
CN104134440B (zh) 用于便携式终端的语音检测方法和语音检测装置
CN114113801A (zh) 电容检测方法及电容检测装置
US20220256271A1 (en) Method for determining capacitance reference, apparatus for determining capacitance reference, and device
CN112533102B (zh) 一种确定电容基准的方法、电容基准的确定装置和设备
WO2018081945A1 (zh) 传感器本底噪声的检测方法及其装置
TWI837397B (zh) 積體電路及用於製造瞬時傳感電路系統之方法
CN108287621B (zh) 触摸屏校准方法及***
TWI451303B (zh) 觸控點感測方法
CN114518109B (zh) 一种陀螺仪的零偏补偿方法
KR102276144B1 (ko) 근접 센서에서의 환경 보상 방법 및 개선된 환경 보상 성능을 가진 근접 센서
US10917723B2 (en) Audio signal processing device and audio signal adjusting method
JP2023529386A (ja) 感知機器の較正システム及び方法
CN113076826B (zh) 一种传感器的滤波方法和装置
CN115824271A (zh) 电容检测的方法、电容检测装置以及电子设备
CN112950672B (zh) 确定关键点的位置的方法、装置和电子设备

Legal Events

Date Code Title Description
ENP Entry into the national phase

Ref document number: 2021867867

Country of ref document: EP

Effective date: 20220321

121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 21867867

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE