A capacitive touch detection method, system, intelligent terminal and storage medium
By dynamically adjusting the trigger threshold of the capacitive sensing unit, the abnormality of the capacitive sensor caused by temperature changes is solved, and accurate touch detection under the influence of temperature is achieved.
Patent Information
- Application Number
- CN202210232262.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-03-09
- Publication Date
- 2025-09-12
- Estimated Expiration
- 2042-03-09
AI Technical Summary
Temperature changes cause abnormal changes in the capacitance of the capacitive sensing unit, resulting in abnormal operation or failure of the capacitive sensor.
By dynamically adjusting the trigger threshold of the capacitive sensing unit, the current trigger threshold is adjusted in real time according to the change in capacitance to ensure the accuracy of judgment under the influence of temperature.
When the temperature rises, the trigger threshold is dynamically adjusted to avoid misjudgment, improve the accuracy of judgment and reduce resource consumption.
Smart Images

Figure CN114756144B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of touch detection, and in particular to a capacitance-based touch detection method, system, intelligent terminal, and storage medium. Background Art
[0002] Capacitive sensors are widely used in electronic products such as mobile phones, watches, speakers, and headphones. They are primarily used to identify the distance between the human body and electronic products and to detect user interface (UI) operations, such as the wear / remove detection function of popular headphones and UI operations such as single-click, double-click, long-press, and palm coverage. The specific recognition principle is to detect the corresponding user operation by detecting the capacitance between the human body and the capacitive sensing unit in the electronic product.
[0003] In actual product applications, since the capacitor sensing unit is generally located on the surface of the electronic product, during the user's relevant operations, the body temperature can easily cause the temperature of the capacitor sensing unit to rise. The temperature change will cause abnormal changes in the capacitance of the capacitor sensing unit, thereby causing the capacitor sensor to work abnormally or fail. Summary of the Invention
[0004] The technical problem to be solved by the present invention is that temperature changes will cause abnormal changes in the capacitance of the capacitive sensing unit, thereby causing the capacitive sensor to work abnormally or fail. In response to the above-mentioned defects of the prior art, a capacitance-based touch detection method, system, intelligent terminal and storage medium are provided to improve.
[0005] The technical solution adopted by the present invention to solve its technical problem is: providing a capacitance-based touch detection method applied to a smart device, wherein the smart device includes a capacitance sensing unit;
[0006] The capacitance-based touch detection method comprises the following steps:
[0007] Acquire the current capacitance of the capacitive sensing unit, determine whether the current capacitance is greater than a current trigger threshold, and if the current detected capacitance is greater than the current trigger value, determine that the trigger is started;
[0008] Continuing to obtain the current capacitance of the capacitive sensing unit, determining whether the current capacitance is increasing, and if the current capacitance is increasing, obtaining a capacitance change value of the current capacitance;
[0009] The current trigger threshold value plus the capacity change value is used as the new current trigger threshold value, and the current capacitance of the capacitive sensing unit is continued to be obtained to determine whether the current capacitance is less than the new current trigger threshold value. If the current capacitance is less than the new current trigger threshold value, the trigger is determined to be ended.
[0010] Wherein, after the step of determining whether the current capacitance is less than the new current trigger threshold, the following steps are included:
[0011] If the current capacitance is greater than or equal to the new current trigger threshold, the step of determining whether the current capacitance is in an increasing state and subsequent steps are performed.
[0012] Wherein, after the step of determining whether the current capacitance is greater than the current trigger threshold, the following steps are included:
[0013] If the current detected capacitance is less than or equal to the current trigger threshold, it is determined that the capacitive sensing unit is not triggered, and it is determined whether the current trigger threshold is the preset trigger threshold. If the current trigger threshold is not the preset trigger threshold, the current trigger threshold is modified to the preset trigger threshold.
[0014] The step of modifying the current trigger threshold to the preset trigger threshold includes:
[0015] Obtain the sensing capacitance of the capacitive sensing unit, determine whether the sensing capacitance is greater than the initial capacitance of the capacitive sensing unit, and if the sensing capacitance is not greater than the initial capacitance, reset the capacitive sensing unit and modify the current trigger threshold to the preset trigger threshold.
[0016] Wherein, after the step of determining the triggering end, the following steps are included:
[0017] The current trigger threshold is lowered to the preset trigger threshold.
[0018] The step of lowering the current trigger threshold to the preset trigger threshold includes:
[0019] Obtain the current capacitance of the capacitive sensing unit, determine whether the current capacitance is greater than the initial capacitance of the capacitive sensing unit, and if the current capacitance is greater than the initial capacitance, add the capacitance difference value between the current capacitance and the initial capacitance to the preset trigger threshold as a new current trigger threshold.
[0020] Wherein, after the step of determining whether the current capacitance is in a state of increasing, the following steps are included:
[0021] The current capacitance is not in a state of increasing, and it is determined whether the current capacitance is less than the current trigger threshold. If the target capacitance is less than the current trigger threshold, it is determined that the trigger is ended.
[0022] The present invention solves the technical problem by providing a capacitance-based touch detection system, which includes the following modules:
[0023] an acquisition module, configured to acquire the current capacitance of the capacitive sensing unit, determine whether the current capacitance is greater than a current trigger threshold, and determine that the trigger is started if the current detected capacitance is greater than the current trigger value;
[0024] a determination module, configured to continue acquiring a detected capacitance of the capacitive sensing unit, determine whether the detected capacitance is greater than the current capacitance, and if so, acquire a capacitance difference between the detected capacitance and the current capacitance;
[0025] The difference module is used to add the preset trigger threshold to the capacitance difference to obtain a target trigger threshold, continue to obtain the target capacitance of the capacitive sensing unit, and determine whether the target capacitance is less than the target trigger threshold. If the target capacitance is less than the target trigger threshold, it is determined that the trigger is terminated.
[0026] The technical solution adopted by the present invention to solve its technical problem is: providing a storage medium storing a computer program, which, when executed by a processor, causes the processor to execute the steps of the above method.
[0027] The technical solution adopted by the present invention to solve its technical problem is: providing an intelligent terminal including a memory and a processor, wherein the memory stores a computer program, and when the computer program is executed by the processor, the processor executes the steps of the above method.
[0028] The beneficial effect of the present invention is that, compared with the prior art, when the current capacitance of the capacitive sensing unit is affected by the temperature of the capacitive sensing unit and is in a state of increasing, the current trigger threshold for judging whether the trigger is ended is correspondingly increased according to the increase in the current capacitance. When the user no longer touches it, the current capacitance will decrease. Although the remaining capacitance of the capacitive sensing unit increases due to the increase in temperature, since the current trigger threshold is also increased, the higher remaining capacitance will not affect the accuracy of the judgment. There is no need to set up additional temperature monitoring equipment to adjust the trigger threshold, which can not only improve the accuracy of the judgment but also reduce resource consumption. BRIEF DESCRIPTION OF THE DRAWINGS
[0029] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the following briefly introduces the drawings required for use in the embodiments or the description of the prior art. Obviously, the drawings described below are only some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0030] Figure 1 1 is a flow chart of a first embodiment of a capacitance-based touch detection method provided by the present invention;
[0031] Figure 2 is a schematic diagram of a capacitance change curve detected by a capacitance sensing unit in an embodiment of the present invention;
[0032] Figure 3 is a schematic diagram of a capacitance change curve detected by a capacitance sensing unit in another embodiment of the present invention;
[0033] Figure 4 This is a schematic structural diagram of an embodiment of the smart device provided by the present invention;
[0034] Figure 5 1 is a flow chart of a second embodiment of a capacitance-based touch detection method provided by the present invention;
[0035] Figure 6 is a schematic flow chart of a third embodiment of a capacitance-based touch detection method provided by the present invention;
[0036] Figure 7 1 is a schematic structural diagram of an embodiment of a capacitance-based touch detection system provided by the present invention;
[0037] Figure 8 is a structural diagram of another embodiment of the smart device provided by the present invention;
[0038] Figure 9 It is a structural diagram of an embodiment of the storage medium provided by the present invention. DETAILED DESCRIPTION
[0039] The following will clearly and completely describe the technical solutions in the embodiments of the present invention in conjunction with the accompanying drawings. Obviously, the described embodiments are only part of the embodiments of the present invention, not all of the embodiments. All other embodiments obtained by ordinary technicians in this field based on the embodiments of the present invention without making any creative efforts shall fall within the scope of protection of the present invention.
[0040] Please refer to Figure 1 、 Figure 2 、 Figure 3 and Figure 4 . Figure 1 4 is a flow chart of a first embodiment of a capacitance-based touch detection method provided by the present invention. Figure 2 FIG. 1 is a schematic diagram of a capacitance change curve detected by a capacitance sensing unit in an embodiment of the present invention. Figure 3 FIG. 1 is a schematic diagram of a capacitance change curve detected by a capacitance sensing unit in another embodiment of the present invention. Figure 4 It is a structural diagram of an embodiment of the smart device provided by the present invention.
[0041] like Figure 4 As shown in , the smart device 10 includes a capacitive sensing detection unit 11. The smart device 10 can be an electronic product such as a mobile phone, a smart watch, a Bluetooth headset, etc. The capacitive sensing unit 11 is used to identify the distance between the human body and the electronic product and the user UI operation, such as the currently popular headset removal detection function, single-click / double-click / long press / palm cover and other UI operation functions. The recognition principle is to identify the corresponding user operation by detecting the capacitance value between the human body and the capacitive sensing unit in the electronic product. In this implementation scenario, the capacitive sensing unit 11 is in a real-time detection state, and the current capacitance of the capacitive sensing unit 11 can be obtained in real time. The capacitance of the capacitive sensing unit 11 will increase due to the increase in temperature when it is touched.
[0042] The capacitance-based touch detection method provided by the present invention comprises the following steps:
[0043] S101: Obtain the current capacitance of the capacitive sensing unit and determine whether the current capacitance is greater than the current trigger threshold. If so, execute step S102.
[0044] In a specific implementation scenario, the current capacitance of the capacitive sensing unit is obtained. The capacitive sensing unit has an initial capacitance, that is, the capacitance detected by the capacitive sensing unit in the initial state when the user does not touch the capacitive sensing unit. The capacitance may be caused by environmental noise. The initial capacitance can be recorded after the capacitive sensing unit is powered on and used. The capacitive sensing unit also has a current trigger threshold. The current trigger threshold can be an initial threshold, that is, the threshold used when the temperature of the capacitive sensing unit is not affected. The current trigger threshold can also be a threshold used after the capacitive sensing unit is affected by temperature. Under different temperature conditions, the threshold used by the capacitive sensing unit is also different. The higher the temperature, the larger the threshold.
[0045] S102: Determine whether the trigger is started.
[0046] In a specific implementation scenario, if the current detected capacitance of the capacitive sensing unit is greater than the current trigger value, it is determined that the user has touched the capacitive sensing unit of the smart device, triggering the start. The current time can also be obtained as the trigger start time node.
[0047] S103: Continue to obtain the current capacitance of the capacitive sensing unit and determine whether the current capacitance is increasing. If so, execute step S104.
[0048] In a specific implementation scenario, after determining that a trigger has been initiated, the capacitance of the capacitive sensing unit is continuously acquired as the detection capacitance, and the detection capacitance is used to determine whether the user has stopped touching. During the user's touch, the user's body temperature is transmitted to the capacitive sensing unit, causing the temperature of the capacitive sensing unit to rise, resulting in an increase in the capacitance of the capacitive sensing unit. As a result, the current capacitance detected by the capacitive sensing unit gradually increases as the temperature of the capacitive sensing unit rises.
[0049] Therefore, in this implementation scenario, if the current capacitance is increasing, it means that the user is still in the touch state, and the temperature of the capacitive sensing unit is also increasing due to the touch. It can be understood that since the human body temperature has an upper limit, and the ambient temperature in the scene where the capacitive sensing unit is used also has an upper limit, the current capacitance value of the capacitive sensing unit also has an upper limit. Therefore, the current capacitance does not need to be in a state of continuous increase. Instead, it only needs to be greater than the current capacitance value at the later time to be considered as the current capacitance increasing.
[0050] S104: Acquire a capacity change value of the current capacitance, add the capacity change value to the current trigger threshold to obtain a target trigger threshold, and continue to acquire the current capacitance of the capacitance sensing unit.
[0051] In a specific implementation scenario, the current capacitance is increasing, and a capacitance change value of the current capacitance is obtained. For example, the capacitance change value can be obtained by subtracting the current capacitance at the trigger start time from the current capacitance at the current time node. The current trigger threshold is added to the capacitance change value to obtain the target trigger threshold. In other words, the trigger threshold of the capacitance sensing unit is adjusted according to the capacitance change of the capacitance sensing unit.
[0052] In this implementation scenario, after obtaining a new current trigger threshold value according to the capacity change value, the current capacity of the capacitive sensing unit continues to be obtained.
[0053] S105: Determine whether the current capacitance is less than the new current trigger threshold. If so, execute step S106.
[0054] In a specific implementation scenario, if the user is always in the touching state, the current capacitance will be in a state of increasing, or in a constant state. When the user stops touching, the current capacitance will decrease because the user no longer touches. Due to the increase in the capacitance of the capacitive sensor itself, there is still some residual capacitance in the capacitive sensor.
[0055] The current capacitance is compared with the new current trigger threshold. Since the new current trigger threshold is obtained by adding the initial current trigger threshold to the capacitance change value, the remaining capacitance will not interfere with the judgment.
[0056] S106: Determine whether the trigger is completed.
[0057] In a specific implementation scenario, if the current capacitance is less than the new current trigger threshold, the trigger is determined to be complete, and the trigger is terminated. Furthermore, the time between the trigger end time node and the trigger start time node can be used to obtain the user's corresponding operation content for this trigger, such as turning on the screen, turning off the screen, enabling noise reduction mode, etc. The specific operation content is designed by the user or the manufacturer of the smart device and is not limited here.
[0058] In another implementation scenario, if the current capacitance is greater than or equal to the new current trigger value, it is determined that the user is still in the touch state and the trigger is still continuing, then step S103 is executed to continue to determine whether the current capacitance is in a state of increasing. If the current capacitance is in a state of increasing, the capacitance change value of the current capacitance is obtained. The current trigger threshold value plus the capacitance change value is used as the new current trigger threshold value. In other implementation scenarios, it is also possible that the current capacitance is already at its peak state and no longer changes, then the current trigger threshold value remains unchanged, but the current trigger threshold value has been adjusted in the previous round according to the capacitance change value of the previous round, so the judgment of whether the trigger stops will not be interfered with by the remaining capacitance.
[0059] Please combine Figure 2 For reference, Figure 2The dashed line represents the current trigger threshold, and the solid line represents the current capacitance. When the current capacitance is above the current trigger threshold, it is determined that the user is in the touch state. When the current capacitance is below the current trigger threshold, it is determined that the user has released the touch. At time T0, the user has not touched the capacitive sensing unit. The current capacitance of the capacitive sensing unit is the initial capacitance C0, and the current trigger threshold is C1, where C0 < C1. At this time, the current trigger threshold C1 is the preset trigger threshold. At time T1, the user approaches or touches the capacitive sensing unit, and the capacitance in the capacitive sensing unit increases by C2, where C0 + C2 > C1, and it is determined that the trigger is started. From time T2 to T3, due to the user's long-term touch, the capacitance of the capacitive sensing unit increases, and the current capacitance also increases by C3. Correspondingly, the current trigger threshold is also increased by C3. At time T3, the user moves away from the capacitive sensing unit, and the current capacitance decreases by C2. The current capacitance is C0 + C2 + C3 - C2 = C0 + C3, as shown by the black dot in the figure. The current trigger threshold is C1 + C3. Therefore, the current capacitance is less than the current trigger threshold, and it is determined that the trigger ends. Therefore, the problem of the capacitance increase of the capacitive sensing unit due to temperature rise does not affect the accuracy of the judgment.
[0060] S107: Reduce the current trigger threshold to the preset trigger threshold.
[0061] In a specific implementation scenario, after determining that the trigger ends, the current trigger threshold is reduced to the preset trigger threshold. For example Figure 2 As shown in, the current trigger threshold is reduced from C1 + C3 to the preset trigger threshold C1.
[0062] In another implementation scenario, after the user stops touching or moves away from the capacitive sensing unit, if the remaining capacitance of the capacitive sensing unit is large, the capacitance will be slowly released. Therefore, the capacitance will not suddenly drop to the initial capacitance. Therefore, refer to Figure 3 From time T3 to time T4 in, obtain the current capacitance of the capacitive sensing unit, and determine whether the current capacitance is greater than the initial capacitance of the capacitive sensing unit. If the current capacitance is greater than the initial capacitance, then according to the capacitance difference value between the current capacitance and the initial capacitance, add the capacitance difference value to the preset trigger threshold as the new current trigger threshold. This can ensure that after the user stops touching, the capacitive sensor will not be misjudged due to slow discharge, improving the accuracy of the judgment.
[0063] From the above description, it can be seen that in this embodiment, when the current capacitance of the capacitive sensing unit is affected by the temperature of the capacitive sensing unit and is in a state of increasing, the current trigger threshold used to determine whether the trigger is ended is increased accordingly according to the increase in the current capacitance. When the user no longer touches it, the current capacitance will decrease. Although the remaining capacitance of the capacitive sensing unit increases due to the increase in temperature, since the current trigger threshold is also increased, the higher remaining capacitance will not affect the accuracy of the judgment, and there is no need to set up additional temperature monitoring equipment to adjust the trigger threshold. This can not only improve the accuracy of the judgment, but also reduce resource consumption.
[0064] See also Figure 5 , Figure 5 FIG2 is a flow chart of a second embodiment of a capacitance-based touch detection method provided by the present invention. The capacitance-based touch detection method provided by the present invention comprises the following steps:
[0065] S201: Obtain the current capacitance of the capacitive sensing unit and determine whether the current capacitance is greater than the current trigger threshold. If not, execute step S202.
[0066] In a specific implementation scenario, step S201 is substantially the same as step S101 in the first embodiment of the capacitance-based touch detection method provided by the present invention, and will not be described in detail here.
[0067] S202: Determine whether the capacitive sensing unit is triggered.
[0068] In a specific implementation scenario, if the current capacitance is less than or equal to the current trigger threshold, it is determined that the capacitive sensing unit is not triggered.
[0069] S203: Determine whether the current trigger threshold is the preset trigger threshold, if not, execute step S204.
[0070] In a specific implementation scenario, a determination is made as to whether the current trigger threshold is the preset trigger threshold. For example, if the temperature rises due to the previous touch, causing the current trigger threshold to also rise and not exceed the preset trigger threshold, the next touch may result in insensitive touch feedback to the user due to the increased current trigger threshold, affecting the user experience. Therefore, if the current trigger threshold is not the preset trigger threshold, the current trigger threshold is modified to the preset trigger threshold. This allows accurate detection of the next touch by the user.
[0071] S204: Modify the current trigger threshold to the preset trigger threshold.
[0072] In a specific implementation scenario, if the current trigger threshold is not the preset trigger threshold, the current trigger threshold is modified to the preset trigger threshold.
[0073] In a specific implementation scenario, a determination is made as to whether the current trigger threshold is the preset trigger threshold. For example, if the temperature rises due to the previous touch, causing the current trigger threshold to also rise and not exceed the preset trigger threshold, the next touch may result in insensitive touch feedback to the user due to the increased current trigger threshold, affecting the user experience. Therefore, if the current trigger threshold is not the preset trigger threshold, the current trigger threshold is modified to the preset trigger threshold. This allows accurate detection of the next touch by the user.
[0074] From the above description, it can be seen that in this embodiment, when the capacitive sensing unit is not triggered, it is determined whether the current trigger threshold is the preset trigger threshold. If the current trigger threshold is not the preset trigger threshold, the current trigger threshold is modified to the preset trigger threshold to avoid the increased current trigger threshold causing insensitive touch feedback to the user, thereby improving detection accuracy.
[0075] See also Figure 6 , Figure 6 FIG3 is a flow chart of a third embodiment of a capacitance-based touch detection method provided by the present invention. The capacitance-based touch detection method provided by the present invention comprises the following steps:
[0076] S301: Obtain the current capacitance of the capacitive sensing unit and determine whether the current capacitance is greater than the current trigger threshold. If so, execute step S302.
[0077] S302: Determine whether the trigger is started.
[0078] S303: Continue to obtain the current capacitance of the capacitive sensing unit and determine whether the current capacitance is increasing. If not, execute step S104.
[0079] In a specific implementation scenario, steps S301 - S303 are substantially the same as steps S101 - S103 in the first embodiment of the capacitance-based touch detection method provided by the present invention, and are not described in detail here.
[0080] S304: Determine whether the current capacitance is less than the current trigger threshold. If so, execute step S305.
[0081] In a specific implementation scenario, if the current capacitance is not increasing, for example, it is in a stable state, then the capacitive sensor is not affected by temperature, or the effect is small and negligible. Therefore, there is no need to change the current trigger threshold, and the original current trigger threshold can be used. It should be noted that the stable state does not mean that the current capacitance does not change at all, but rather that the change in the current capacitance is small and below the preset change threshold. In other implementation scenarios, the current capacitance may also be decreasing.
[0082] When the current capacitance is not increasing, the current capacitance is continuously monitored to determine whether it is less than the current trigger threshold. If the target capacitance is less than the current trigger threshold, it means that the user is away from the capacitive sensing unit and the trigger is determined to be ended.
[0083] S305: Determine whether the trigger is completed.
[0084] In a specific implementation scenario, step S305 is substantially the same as step S106 in the first embodiment of the capacitance-based touch detection method provided by the present invention, and will not be described in detail here.
[0085] From the above description, it can be seen that in this implementation scenario, when the current capacitance is not in a state of increasing, it means that the capacitive sensing unit is not affected by the temperature or is less affected. There is no need to modify the current trigger threshold. The triggering can be judged based on the unmodified current trigger threshold. There is no need to add additional temperature detection devices. The detection results are accurate and the cost is low.
[0086] See also Figure 7 , Figure 7 FIG2 is a schematic diagram of a structure of an embodiment of a capacitance-based touch detection system provided by the present invention. The capacitance-based touch detection system 20 includes an acquisition module 21 , a judgment module 22 , and a difference module 23 .
[0087] The acquisition module 21 is used to obtain the current capacitance of the capacitive sensing unit and determine whether the current capacitance is greater than the current trigger threshold. If the current detected capacitance is greater than the current trigger value, the trigger is determined to be started. The judgment module 22 is used to continue to obtain the current capacitance of the capacitive sensing unit and determine whether the current capacitance is in a state of increasing. If the current capacitance is in a state of increasing, the capacitance change value of the current capacitance is obtained. The difference module 23 is used to add the capacitance change value to the current trigger threshold as the new current trigger threshold, continue to obtain the current capacitance of the capacitive sensing unit, determine whether the current capacitance is less than the new current trigger threshold, and if the current capacitance is less than the new current trigger threshold, the trigger is determined to be ended.
[0088] The difference module 23 is further configured to execute the step of determining whether the current capacitance is in an increasing state and subsequent steps if the current capacitance is greater than or equal to the new current trigger threshold.
[0089] The acquisition module 21 is also used to determine that the capacitive sensing unit is not triggered if the current detected capacitance is less than or equal to the current trigger threshold, and to determine whether the current trigger threshold is the preset trigger threshold. If the current trigger threshold is not the preset trigger threshold, the current trigger threshold is modified to the preset trigger threshold.
[0090] The acquisition module 21 is also used to obtain the sensing capacitance of the capacitive sensing unit, determine whether the sensing capacitance is greater than the initial capacitance of the capacitive sensing unit, and if the sensing capacitance is not greater than the initial capacitance, reset the capacitive sensing unit and modify the current trigger threshold to the preset trigger threshold.
[0091] The difference module 23 is further configured to reduce the current trigger threshold to a preset trigger threshold.
[0092] The judgment module 22 is further configured to judge whether the current capacitance is less than the current trigger threshold if the current capacitance is not increasing, and to determine that the trigger is terminated if the target capacitance is less than the current trigger threshold.
[0093] The difference module 23 is further configured to obtain a corresponding operation instruction according to the time length between the trigger start and the trigger end, and execute the operation content corresponding to the operation instruction.
[0094] From the above description, it can be seen that in this embodiment, when the current capacitance of the capacitive sensing unit is affected by the temperature of the capacitive sensing unit and is in a state of increasing, the current trigger threshold used to determine whether the trigger is ended is increased accordingly according to the increase in the current capacitance. When the user no longer touches it, the current capacitance will decrease. Although the remaining capacitance of the capacitive sensing unit increases due to the increase in temperature, since the current trigger threshold is also increased, the higher remaining capacitance will not affect the accuracy of the judgment, and there is no need to set up additional temperature monitoring equipment to adjust the trigger threshold. This can not only improve the accuracy of the judgment, but also reduce resource consumption.
[0095] See also Figure 8 , Figure 8 3 is a schematic diagram of the structure of an embodiment of the smart device provided by the present invention. The smart device includes a processor 31 and a memory 32. The processor 31 is coupled to the memory 32. The memory 32 stores a computer program, and the processor 31 executes the computer program when working to implement the following Figure 1 、 Figure 5 and Figure 6 The detailed method can be found in the above, which will not be described here.
[0096] See also Figure 9 , Figure 9 The storage medium 40 stores at least one computer program 41, which is used to be executed by the processor to implement the following. Figure 1 、 Figure 5 and Figure 6In one embodiment, the storage medium 40 may be a storage chip, a hard disk, a mobile hard disk, a USB flash drive, an optical disk, or other readable and writable storage tools in the terminal, or a server, etc.
[0097] Those skilled in the art will appreciate that all or part of the processes in the above-mentioned embodiments can be implemented by instructing the relevant hardware through a computer program. The program can be stored in a non-volatile computer-readable storage medium. When the program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in various forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
[0098] The technical features of the above embodiments can be combined arbitrarily. In order to make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0099] The above examples merely illustrate several implementation methods of the present application. While the descriptions are relatively specific and detailed, they should not be construed as limiting the scope of the present invention. It should be noted that a person skilled in the art could make various modifications and improvements without departing from the spirit of the present invention, all of which fall within the scope of protection of the present invention. Therefore, the scope of protection of the present invention shall be determined by the appended claims. Please enter the specific implementation details section.
Claims
1. A capacitance-based touch detection method, characterized in that: Applicable to a smart device, the smart device comprising a capacitive sensing unit; The capacitance-based touch detection method comprises the following steps: Acquire the current capacitance of the capacitive sensing unit, determine whether the current capacitance is greater than a current trigger threshold, and if the current detected capacitance is greater than the current trigger value, determine that the trigger is started; Continuing to obtain the current capacitance of the capacitive sensing unit, determining whether the current capacitance is increasing, and if the current capacitance is increasing, obtaining a capacitance change value of the current capacitance; adding the capacity change value to the current trigger threshold as a new current trigger threshold, continuing to obtain the current capacitance of the capacitive sensing unit, and determining whether the current capacitance is less than the new current trigger threshold. If the current capacitance is less than the new current trigger threshold, determining that the triggering is terminated; obtaining the current capacitance of the capacitive sensing unit, determining whether the current capacitance is greater than the initial capacitance of the capacitive sensing unit, and if the current capacitance is greater than the initial capacitance, obtaining a capacitance difference between the current capacitance and the initial capacitance, and adding a preset trigger threshold to the capacitance difference as a new current trigger threshold; If the current detected capacitance is less than or equal to the current trigger threshold, it is determined that the capacitive sensing unit is not triggered, and then it is determined whether the current trigger threshold is the preset trigger threshold. If the current trigger threshold is not the preset trigger threshold, the current trigger threshold is modified to the preset trigger threshold.
2. The capacitance-based touch detection method according to claim 1, wherein: After the step of determining whether the current capacitance is less than the new current trigger threshold, the method further includes: If the current capacitance is greater than or equal to the new current trigger threshold, the step of determining whether the current capacitance is in an increasing state and subsequent steps are performed.
3. The capacitance-based touch detection method according to claim 1, wherein: The step of modifying the current trigger threshold to the preset trigger threshold includes: Obtain the current capacitance of the capacitive sensing unit, determine whether the current capacitance is greater than the initial capacitance of the capacitive sensing unit, and if the current capacitance is not greater than the initial capacitance, reset the capacitive sensing unit and modify the current trigger threshold to the preset trigger threshold.
4. The capacitance-based touch detection method according to claim 1, wherein: After the step of determining the triggering end, the method includes: The current trigger threshold is lowered to the preset trigger threshold.
5. The capacitance-based touch detection method according to claim 1, wherein: After the step of determining whether the current capacitance is increasing, the method further includes: If the current capacitance is not increasing, it is determined whether the current capacitance is less than the current trigger threshold. If the current capacitance is less than the current trigger threshold, it is determined that the trigger is terminated.
6. A capacitance-based touch detection system, characterized in that: The capacitance-based touch detection system includes the following modules: an acquisition module, configured to acquire the current capacitance of the capacitive sensing unit, determine whether the current capacitance is greater than a current trigger threshold, and determine that the trigger is started if the current detected capacitance is greater than the current trigger value; a determination module, configured to continue acquiring the current capacitance of the capacitive sensing unit, determine whether the current capacitance is increasing, and if so, acquire a capacitance change value of the current capacitance; a difference module, configured to add the capacity change value to the current trigger threshold as a new current trigger threshold, continue to obtain the current capacitance of the capacitive sensing unit, determine whether the current capacitance is less than the new current trigger threshold, and if so, determine that the trigger is terminated, obtain the current capacitance of the capacitive sensing unit, determine whether the current capacitance is greater than the initial capacitance of the capacitive sensing unit, and if so, obtain a capacitance difference between the current capacitance and the initial capacitance, and add the preset trigger threshold to the capacitance difference as the new current trigger threshold; If the current detected capacitance is less than or equal to the current trigger threshold, it is determined that the capacitive sensing unit is not triggered, and then it is determined whether the current trigger threshold is the preset trigger threshold. If the current trigger threshold is not the preset trigger threshold, the current trigger threshold is modified to the preset trigger threshold.
7. A storage medium storing a computer program, wherein when the computer program is executed by a processor, the processor is caused to perform the steps of the method according to any one of claims 1 to 5.
8. An intelligent terminal comprising a memory and a processor, wherein the memory stores a computer program, and when the computer program is executed by the processor, the processor executes the steps of the method according to any one of claims 1 to 5.
Citation Information
Patent Citations
Capacitive touch detection method, device and mobile terminal
CN104423753A
Capacitive touch panel baseline value adjusting method
CN107817925A