A capacitive touch button reading circuit
By introducing sinusoidal wave signal integration and loop feedback into the capacitive touch button reading circuit, combined with a compensation module and filter, the problems of anti-interference and insufficient pin utilization in existing capacitive reading circuits are solved, achieving accurate touch event judgment within the chip and saving costs.
Patent Information
- Application Number
- CN202010142845.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-03-03
- Publication Date
- 2025-09-05
- Estimated Expiration
- 2040-03-03
AI Technical Summary
Existing capacitive touch button reading circuits have deficiencies in anti-interference ability and pin utilization. The oscillator-type structure is susceptible to interference and misjudgment, while the charge-sharing structure requires external large capacitors, which increases costs.
It uses a signal input and reading module, a waveform generation module, an integration module, a sampling module, a comparison module, and a signal output module. Through sine wave signal integration and loop feedback, it can directly judge touch events in the chip. Combined with the compensation module and filter, it improves anti-interference ability and saves external large capacitors.
This enables accurate judgment of touch button actions within the chip, improves anti-interference capabilities, and saves pins and costs.
Smart Images

Figure CN111181543B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of electronic circuits, and in particular to a capacitive touch button reading circuit. Background Art
[0002] The existing capacitive touch key reading circuit is generally divided into two types, one is based on an oscillator type structure, and the other is based on a charge-sharing type charging and discharging structure.
[0003] An oscillator-based touch key reading circuit generates a frequency F1 using an oscillator. A counter then calculates the time T1 for N cycles of F1. Finally, a clock F2, which is much faster than F1, quantizes T1, calculating that M clocks with the same frequency F2 exist within T1. When a touch event occurs, the oscillator's original oscillation frequency F1 decreases, denoted as F1'. Therefore, the time T1' corresponding to the same N cycles of F1' will be greater than the original time T1. At this point, the number M' obtained by quantizing T1' using the same fast clock F2 will be greater than the original M. By comparing M' with M, a touch event can be detected.
[0004] The drawback of the aforementioned oscillator-based readout circuit is its poor interference immunity. If interference with the touch button or power supply occurs during the oscillator's second count of N cycles, the oscillator will erroneously flip. This will result in a significant deviation in the recorded N cycles, leading to a false detection of a false touch when quantized using the frequency F2. The fundamental reason for this error is that the oscillator-based circuit only records the number of flips, not the actual cycles corresponding to each flip. This process loses the timeline data, leading to errors in the subsequent TDC (Time-to-Digital Converter) conversion.
[0005] The charge-sharing touch key reading circuit charges the touch key capacitor through the internal reference voltage, and then shares the charge on the touch key capacitor with a large capacitor, slowly charging the voltage on the large capacitor to the judgment voltage V CMP Then, a fast clock F1 is used to quantify the period of the comparator flip, and the number of cycles of the clock F1 corresponding to the period is N. When a touch event occurs, the capacitance on the touch button increases, and the charge shared with the large capacitor also increases. The voltage on the large capacitor can quickly reach V CMP Then the number of cycles N' is quantified by the fast clock F1. By comparing N and N', it can be determined whether a touch event occurs.
[0006] The above-mentioned charge-sharing touch button reading circuit makes judgments based on the principle of charge sharing between large and small capacitors. In this process, it is equivalent to integrating the signal on the touch capacitor, and has strong anti-interference ability. However, it is very difficult to implement a large capacitor (such as 1nF) inside a small chip. This requires connecting an external large capacitor through an additional pin, which wastes pins and increases costs. Summary of the Invention
[0007] In order to solve the above problems, the present invention provides a capacitive touch button reading circuit, which can accurately determine the touch action of the touch button without the need for a large external capacitor on the chip.
[0008] The above circuit is implemented by the following technical solutions:
[0009] A capacitive touch key reading circuit includes a signal input reading module, a waveform generation module, an integration module, a sampling module, a comparison module and a signal output module, wherein:
[0010] The waveform generating module is used to generate a waveform signal to output to the integration module;
[0011] The integration module is used to integrate the difference between the first signal output by the signal input and reading module and the waveform signal to output a second signal to the sampling module;
[0012] The sampling module is used to sample the continuous second signal into a discrete third signal, so as to output the third signal to the comparison module;
[0013] The comparison module is used to compare the third signal with the reference voltage to output a fourth signal to the signal output module, and feed the fourth signal back to the input signal reading module;
[0014] The signal output module is used to filter and output the fourth signal.
[0015] Specifically, the waveform signal is a sine wave signal.
[0016] Specifically, the circuit further includes a first compensation module and a second compensation module; the first compensation module outputs a compensation signal to the integration module to be superimposed with the first signal; the second compensation module outputs a compensation signal to the comparison module to be superimposed with the third signal.
[0017] Specifically, the signal input reading module includes an input pin, a first input current adjustment module and a second input current adjustment module, the output end of the first input current adjustment module is connected to the input end of the second input current adjustment module, and the input pin is connected to the output end of the first input current adjustment module and to the first signal input end of the integration module.
[0018] Specifically, the fourth signal is fed back to the first input current adjustment module, the second input current adjustment module, the first compensation module, and the second compensation module respectively.
[0019] Specifically, the first input current adjustment module includes a first current source and a first switch, and the second input current adjustment module includes a second current source and a second switch, one end of the first switch is connected to the output end of the first current source, the other end of the first switch is respectively connected to the input pin and one end of the second switch, and the other end of the second switch is connected to the input end of the second current source.
[0020] Specifically, the first input current adjustment module includes at least one, and the number of the second input current adjustment modules corresponds to the number of the first input current adjustment modules.
[0021] Specifically, the reading circuit further includes a clock module, which is connected to the sampling module to control the sampling period of the sampling module.
[0022] The capacitive touch key reading circuit provided by the present invention subtracts the sine wave signal generated by the waveform generation module from the output signal of the signal input reading module, and integrates the difference through the integration module. When the system is operating stably, the output signal of the signal input reading module will follow the changes of the sine wave signal. When there is interference on the touch key, the difference with the interference signal passes through the integration module, and the interference signal is averaged over time, thus effectively improving the signal's anti-interference ability. Then, discrete quantization is performed through the sampling module and the comparison module, and the touch action of the touch key is judged by analyzing the quantized data.
[0023] In addition, since the changing charge on the touch button is read directly, no additional capacitor is required. Therefore, compared with the charge-sharing reading circuit solution in the existing technology, external large capacitors can be saved and the reading circuit can be directly integrated into the chip, saving pins and costs. BRIEF DESCRIPTION OF THE DRAWINGS
[0024] Attachment Figure 1 This is a schematic diagram of the module structure of the capacitive touch button reading circuit provided by the present invention.
[0025] Attachment Figure 2 This is a schematic diagram of a further specific module structure of the capacitive touch button reading circuit provided by the present invention.
[0026] Attachment Figure 3 This is a schematic diagram of a further specific module structure of the capacitive touch button reading circuit provided by the present invention.
[0027] Attachment Figure 4 This is a circuit diagram of a capacitive touch button reading circuit provided in Embodiment 1 of the present invention.
[0028] Attachment Figure 5 This is a specific circuit diagram of the capacitive touch button reading circuit provided in the first embodiment of the present invention.
[0029] Attachment Figure 6 This is a specific circuit diagram of the capacitive touch button reading circuit provided in the second embodiment of the present invention.
[0030] Attachment Figure 7 Graph showing how the output signal amplitude A of the reading circuit changes with the touch capacitance CT in the first and second embodiments of the present invention. DETAILED DESCRIPTION
[0031] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. Therefore, the following detailed description of the embodiments of the present invention provided in the drawings is not intended to limit the scope of the invention claimed for protection, but merely represents selected embodiments of the present invention. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without making creative work are within the scope of protection of the present invention.
[0032] The present invention provides a capacitive touch button reading circuit, such as Figure 1 As shown, the circuit includes a signal input and reading module, a waveform generation module, an integration module, a sampling module, a comparison module and a signal output module, wherein,
[0033] The waveform generating module is used to generate a waveform signal to output to the integration module;
[0034] The integration module is used to integrate the difference between the first signal output by the signal input reading module and the waveform signal to output a second signal to the sampling module;
[0035] The sampling module is used to sample the continuous second signal into a discrete third signal, so as to output the third signal to the comparison module;
[0036] The comparison module is used to compare the third signal with the reference voltage to output a fourth signal to the signal output module, and feed the fourth signal back to the input signal module;
[0037] The signal output module is used to filter and output the fourth signal.
[0038] The waveform generating module is specifically a sine wave generating circuit. The generated waveform signal has a fixed frequency and amplitude. It is differentially integrated with the first signal in the integration module to eliminate abnormal interference of the first signal and improve the signal anti-interference capability of the reading circuit.
[0039] The signal output module is specifically a filter, which can be a FIR (Finite Impulse Response) filter.
[0040] Further, refer to Figure 2 As shown, the signal input and reading module specifically includes an input pin, a first input current adjustment module, and a second input current adjustment module. The output of the first input current adjustment module is connected to the input of the second input current adjustment module. The input pin is connected to the output of the first input current adjustment module and to the first signal input of the integration module. The fourth signal output by the comparison module is fed back to the first input current adjustment module and the second input current adjustment module, respectively.
[0041] When a touch event does not occur, the total current generated by the combined first and second input current adjustment modules charges the touch equivalent capacitor CT. Due to the negative feedback loop, the voltage waveform on the touch capacitor follows the waveform generated by the waveform generation circuit. At this point, the output module outputs a set of data, DATA1. When a touch event occurs, the touch equivalent capacitor changes CT'. Due to the negative feedback loop, the voltage waveform on the touch capacitor still needs to follow the waveform generated by the waveform generation circuit. At this time, the waveform generated by the waveform generation circuit is the same as when no touch occurs. Due to the change in the touch equivalent capacitor CT', the total current generated by the combined first and second current adjustment modules also changes accordingly, ensuring that the voltage waveform of the touch capacitor follows the waveform generated by the waveform generation circuit. At this time, due to the change in the total current generated by the combined first and second current adjustment modules, the data in the comparison output module also changes, recorded as DATA2. By comparing the changes in DATA1 and DATA2, it is possible to analyze whether a touch event has occurred.
[0042] When there is interference on the touch buttons, the loop has a low-pass filtering characteristic, which has a natural filtering effect on some high-frequency interference; as for the impact caused by low-frequency interference, since the effective information that this trigger reading circuit needs to obtain is at the same frequency as the waveform signal generated by the signal generating circuit, a bandpass filter can be added to the signal output module to filter out high-frequency and low-frequency interference.
[0043] Further, refer to Figure 3As shown, the above-mentioned reading circuit also includes a first compensation module and a second compensation module for adjusting the loop stability. The first compensation module outputs a compensation signal to the integration module, which is superimposed on the first signal and is used to perform signal compensation on the first signal. The second compensation module outputs a compensation signal to the comparison module, which is superimposed on the third signal and is used to perform signal compensation on the third signal.
[0044] Furthermore, the reading circuit further includes a clock module, which is connected to the sampling module to control the sampling period of the sampling module.
[0045] Example 1:
[0046] As a specific implementation of the present invention, refer to Figure 4 As shown, the above-mentioned reading circuit is arranged inside the integrated circuit chip, and the touch key outside the chip is represented by the equivalent capacitor CT shown in the figure. The chip includes a signal input reading module, a first-level integration module (represented by K / S) shown in the figure, a waveform generation module of the Sinwave waveform generation circuit shown in the figure, a sampling module and a comparison module of the quantizer shown in the figure, a signal output module of the digital filter shown in the figure, a first compensation module of the first compensation circuit shown in the figure, and a second compensation module of the second compensation circuit shown in the figure. The signal input reading module includes an input pin PIN, a first input current adjustment module composed of a first current source Ip and a first switch SWp, and a second input current adjustment module composed of a second current source In and a second switch SWn. One end of the first switch SWp is connected to the output end of the first current source Ip, and the other end of the first switch SWp is connected to the input pin PIN and one end of the second switch SWn respectively. The other end of the second switch SWn is connected to the input end of the second current source In. The currents of the first current source Ip and the second current source In are equal. In this embodiment, the first current source Ip is a P-type current source, and the second current source In is an N-type current source.
[0047] Further, refer to Figure 5, which illustrates the specific implementation means of the above-mentioned implementation method. The integration module is represented by the transconductance amplifier GM and capacitor C1 in the figure, the quantization module and the comparison module are represented by the comparator CMP in the figure, and the first compensation circuit and the second compensation circuit are integrated into the compensation circuit shown in the dashed box. The compensation circuit includes a third current source Icp, a third switch SWcp, a fourth current source Icn, and a fourth switch SWcn. One end of the third switch SWcp is connected to the output end of the third current source Icp, the other end of the third switch SWcp is connected to the output end of the integrator GM and one end of the fourth switch SWcn, respectively. The other end of the fourth switch SWcn is connected to the input end of the fourth current source Icn. The currents of the third current source Icp and the fourth current source Icn are equal. In addition, the fourth signal output by the comparator CMP is fed back to the first input current adjustment module, the second input current adjustment module, the first compensation circuit, and the second compensation circuit.
[0048] Continue to refer to Figure 4 、 5 , Sinwave waveform generator circuit generates a sin signal V with fixed frequency and amplitude sin =A*sin(2πf sig *t+θ), where A is the amplitude of the waveform generated by the waveform generating circuit, f sig is the signal frequency generated by the waveform generator, t is the time, and θ is the initial phase of the waveform signal.
[0049] V sin As the input of the system, the comparator CMP outputs V co As the output end of the reading circuit, the loop gain of the closed-loop feedback system is: Among them, I p is the current value of the first current source Ip, C T is the capacitance value of the equivalent capacitor CT, S is j*2*pi*f, M is the first compensation feedback coefficient, and K is the integration coefficient of the integrator.
[0050] The loop operates at f sig At the frequency, the loop gain of the closed-loop feedback system is much greater than 1, and V sin to V co The transfer function is:
[0051] The output signal is: V co =V sin *F loop,close =A*sin(2πf sig *t+θ)*F loop,close .
[0052] From the above formula, we can find that the output signal V co and waveform generation signal Vsin With the same frequency, the amplitude of the output signal is amplified by the loop closed-loop gain. At the same time, it can be observed that the loop closed-loop gain transfer function F loop,close There is only one variable C T , so the amplitude of the output waveform will change with the touch equivalent capacitance C T Therefore, by analyzing the change in the output signal waveform amplitude, it is possible to determine whether a touch event has occurred.
[0053] For a possible parameter of this embodiment, take I p =20uA, C T =10pF, M=0.25, K=64*10^6, take the touch capacitance CT change as -5%~+5%, Figure 7 The curve of the output signal amplitude A changing with the touch capacitance CT is shown. It can be seen from the figure that the output signal amplitude Amp changes with the touch capacitance CT, and the rate of change of the two is approximately a straight line with a slope of 1. Therefore, the reading circuit can effectively read the touch button information and can directly make a judgment after passing through the digital filter.
[0054] Example 2:
[0055] This embodiment differs from the first embodiment in the number of first and second input current adjustment modules. In this embodiment, there are multiple first input current adjustment modules, and the number of second input current adjustment modules corresponds to the number of first input current adjustment modules. As can be seen from the first embodiment, the first and second input current adjustment modules adjust their output currents based on the feedback fourth signal. When the feedback fourth signal is sufficiently large and the current value to be adjusted is close to the current value of the first current source Ip, the output current can be adjusted by disconnecting the first switch SWp. However, when the current value to be adjusted by the feedback fourth signal differs significantly from that of the first current source Ip and does not meet the adjustment requirements, the first input current adjustment module can only provide high current feedback. The amplitude of the input first signal is large, which places higher requirements on the integrator circuit design. This will also affect the stability of the circuit to a certain extent.
[0056] To improve circuit stability and reduce circuit design complexity, this embodiment provides multiple first input current adjustment modules. The second input current adjustment modules correspond to the first input current adjustment modules. The current values output by different first input current adjustment modules can be the same or different, depending on the number of first input current adjustment modules. That is, the first current sources Ip of different first input current adjustment modules can be the same or different. The same applies to the second input current adjustment modules. When the fourth feedback signal is relatively small, the total output current can be adjusted by disconnecting one or more first switches SWp. In the one or more first input current adjustment modules with the disconnected one or more first switches SWp, the total current value of the one or more first current sources Ip approaches the desired current value. When the fourth feedback signal is relatively large, the total output current can be adjusted by disconnecting the multiple first switches SWp. Similarly, in the multiple first input current adjustment modules with the disconnected multiple first switches SWp, the total current value of the multiple first current sources Ip approaches the desired current value. Meanwhile, the second input current adjustment modules corresponding to the first input current adjustment modules operate synchronously.
[0057] The foregoing description is merely a preferred embodiment of the present invention and is not intended to limit the present invention. Those skilled in the art will readily appreciate that various modifications and variations of the present invention are possible. Any modifications, equivalent substitutions, or improvements made within the spirit and principles of the present invention shall be included within the scope of protection of the present invention.
Claims
1. A capacitive touch button reading circuit, the circuit includes a signal input reading module, a waveform generation module, an integration module, a sampling module, a comparison module and a signal output module, wherein: The waveform generating module is used to generate a waveform signal to output to the integration module; The integration module is used to integrate the difference between the first signal output by the signal input and reading module and the waveform signal to output a second signal to the sampling module; The sampling module is used to sample the continuous second signal into a discrete third signal, so as to output the third signal to the comparison module; The comparison module is used to compare the third signal with the reference voltage to output a fourth signal to the signal output module, and feed the fourth signal back to the input signal reading module; The signal output module is used to filter and output the fourth signal. The signal input and reading module includes an input pin, a first input current adjustment module and a second input current adjustment module. The output end of the first input current adjustment module is connected to the input end of the second input current adjustment module. The input pin is connected to the output end of the first input current adjustment module and to the first signal input end of the integration module. 2 . The readout circuit according to claim 1 , wherein the waveform signal is a sinusoidal wave signal.
3. The reading circuit according to claim 1 further comprises a first compensation module and a second compensation module; the first compensation module outputs a compensation signal to the integration module to be superimposed on the first signal; the second compensation module outputs a compensation signal to the comparison module to be superimposed on the third signal. 4 . The reading circuit according to claim 1 , wherein the fourth signal is fed back to the first input current adjustment module, the second input current adjustment module, the first compensation module, and the second compensation module respectively.
5. The reading circuit according to claim 4, wherein the first input current adjustment module includes a first current source and a first switch, and the second input current adjustment module includes a second current source and a second switch, one end of the first switch is connected to the output end of the first current source, the other end of the first switch is respectively connected to the input pin and one end of the second switch, and the other end of the second switch is connected to the input end of the second current source. 6 . The reading circuit according to claim 5 , wherein the first input current adjustment module comprises at least one, and the number of the second input current adjustment modules corresponds to the number of the first input current adjustment modules. 7 . The reading circuit according to claim 1 , further comprising a clock module, wherein the clock module is connected to the sampling module to control a sampling period of the sampling module.
Citation Information
Patent Citations
Capacitive sensor with noise suppression function
CN106249970A
Capacitive touch key reading circuit
CN211089630U
Analog digital conversion system and method for noise reduction in touch sensor by integrating analog input signal
KR101150542B1